Skip to content

Commit 221a2b9

Browse files
committed
skip negative offset
1 parent 30b2074 commit 221a2b9

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?php
2+
3+
namespace Rector\Tests\DowngradePhp80\Rector\FuncCall\DowngradeSubstrFalsyRector\Fixture;
4+
5+
/**
6+
* zero offset with no length can't be false
7+
*/
8+
class SkipNegativeOffset
9+
{
10+
public function run(string $name)
11+
{
12+
return substr($name, -1);
13+
}
14+
}

0 commit comments

Comments
 (0)