-
-
Notifications
You must be signed in to change notification settings - Fork 371
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DeadCode] Skip @return positive-int|0 on RemoveUselessReturnTagRector (
- Loading branch information
1 parent
96110a9
commit 362e9b5
Showing
2 changed files
with
15 additions
and
15 deletions.
There are no files selected for viewing
14 changes: 14 additions & 0 deletions
14
...Rector/ClassMethod/RemoveUselessReturnTagRector/Fixture/skip_positive_int_or_zero.php.inc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?php | ||
|
||
namespace Rector\Tests\DeadCode\Rector\ClassMethod\RemoveUselessReturnTagRector\Fixture; | ||
|
||
class SkipPositiveIntOrZero | ||
{ | ||
/** | ||
* @return positive-int|0 | ||
*/ | ||
function foo(): int | ||
{ | ||
return rand(0, 1) ? 10 : 0; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters