mirror of
https://github.com/rectorphp/rector.git
synced 2025-02-25 04:03:55 +01:00
separate
This commit is contained in:
parent
1b6f616cf9
commit
6b6350d2bc
@ -9,10 +9,6 @@ final class Numbers
|
||||
if (!$item) {
|
||||
return 'empty';
|
||||
}
|
||||
|
||||
if ($item) {
|
||||
return 'not empty';
|
||||
}
|
||||
}
|
||||
|
||||
public function go(float $item)
|
||||
@ -40,10 +36,6 @@ final class Numbers
|
||||
if ($item === 0) {
|
||||
return 'empty';
|
||||
}
|
||||
|
||||
if ($item !== 0) {
|
||||
return 'not empty';
|
||||
}
|
||||
}
|
||||
|
||||
public function go(float $item)
|
||||
|
@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace Rector\CodeQuality\Tests\Rector\If_\ExplicitBoolCompareRector\Fixture;
|
||||
|
||||
final class PhpStan0126Break
|
||||
{
|
||||
public function run(int $item)
|
||||
{
|
||||
if ($item) {
|
||||
return 'not empty';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
-----
|
||||
<?php
|
||||
|
||||
namespace Rector\CodeQuality\Tests\Rector\If_\ExplicitBoolCompareRector\Fixture;
|
||||
|
||||
final class PhpStan0126Break
|
||||
{
|
||||
public function run(int $item)
|
||||
{
|
||||
if ($item !== 0) {
|
||||
return 'not empty';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
Loading…
x
Reference in New Issue
Block a user