-
-
Notifications
You must be signed in to change notification settings - Fork 357
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c00a50d
commit a279265
Showing
6 changed files
with
50 additions
and
47 deletions.
There are no files selected for viewing
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
45 changes: 45 additions & 0 deletions
45
...Declaration/Rector/FunctionLike/ReturnTypeDeclarationRector/Fixture/return_static.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,45 @@ | ||
<?php | ||
|
||
namespace Rector\Tests\TypeDeclaration\Rector\FunctionLike\ReturnTypeDeclarationRector\Fixture; | ||
|
||
final class ReturnStatic | ||
{ | ||
public function run() | ||
{ | ||
return new static(); | ||
} | ||
|
||
public function run2() | ||
{ | ||
if (rand(0, 1)) { | ||
return new static(); | ||
} | ||
|
||
return null; | ||
} | ||
} | ||
|
||
?> | ||
----- | ||
<?php | ||
|
||
namespace Rector\Tests\TypeDeclaration\Rector\FunctionLike\ReturnTypeDeclarationRector\Fixture; | ||
|
||
final class ReturnStatic | ||
{ | ||
public function run(): self | ||
{ | ||
return new static(); | ||
} | ||
|
||
public function run2(): ?self | ||
{ | ||
if (rand(0, 1)) { | ||
return new static(); | ||
} | ||
|
||
return null; | ||
} | ||
} | ||
|
||
?> |
20 changes: 0 additions & 20 deletions
20
...ration/Rector/FunctionLike/ReturnTypeDeclarationRector/Fixture/skip_return_static.php.inc
This file was deleted.
Oops, something went wrong.
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
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
16 changes: 0 additions & 16 deletions
16
...s/TypeDeclaration/Rector/FunctionLike/ReturnTypeDeclarationRector/config/scalar_types.php
This file was deleted.
Oops, something went wrong.