-
-
Notifications
You must be signed in to change notification settings - Fork 339
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove PARENT_NODE from RemoveUnusedVariableAssignRector (#3935)
- Loading branch information
1 parent
8f3569e
commit d603b00
Showing
17 changed files
with
154 additions
and
507 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
41 changes: 0 additions & 41 deletions
41
...s/DeadCode/Rector/Assign/RemoveUnusedVariableAssignRector/Fixture/on_new_instance.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
18 changes: 18 additions & 0 deletions
18
...or/Assign/RemoveUnusedVariableAssignRector/Fixture/skip_try_catch_on_new_instance.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,18 @@ | ||
<?php | ||
|
||
namespace Rector\Tests\DeadCode\Rector\Assign\RemoveUnusedVariableAssignRector\Fixture; | ||
|
||
use Rector\Tests\DeadCode\Rector\Assign\RemoveUnusedVariableAssignRector\Source\HeavyClass; | ||
use RuntimeException; | ||
|
||
final class SkipTryCatchOnNewInstance | ||
{ | ||
public function run() | ||
{ | ||
try { | ||
$obj = new HeavyClass(); | ||
} catch (RuntimeException $r) { | ||
throw $r; | ||
} | ||
} | ||
} |
16 changes: 0 additions & 16 deletions
16
...or/Assign/RemoveUnusedVariableAssignRector/Fixture/skip_used_as_variable_variable.php.inc
This file was deleted.
Oops, something went wrong.
11 changes: 11 additions & 0 deletions
11
...eadCode/Rector/Assign/RemoveUnusedVariableAssignRector/Fixture/skip_variable_name.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,11 @@ | ||
<?php | ||
|
||
namespace Rector\Tests\DeadCode\Rector\Assign\RemoveUnusedVariableAssignRector\Fixture; | ||
|
||
final class SkipVariableName | ||
{ | ||
public function run($abcdef = 'foo') | ||
{ | ||
$$abcdef = 'test'; | ||
} | ||
} |
26 changes: 0 additions & 26 deletions
26
.../RemoveUnusedVariableAssignRector/Fixture/variable_variable_not_has_next_variable.php.inc
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.