-
-
Notifications
You must be signed in to change notification settings - Fork 364
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Privatization] Skip with parameter on PrivatizeLocalGetterToProperty…
…Rector (#6412) * [Privatization] Skip with parameter on PrivatizeLocalGetterToPropertyRector * Fix
- Loading branch information
1 parent
293eb97
commit 1b1807b
Showing
2 changed files
with
23 additions
and
0 deletions.
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
...ector/MethodCall/PrivatizeLocalGetterToPropertyRector/Fixture/skip_with_parameter.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,19 @@ | ||
<?php | ||
|
||
namespace Rector\Tests\Privatization\Rector\MethodCall\PrivatizeLocalGetterToPropertyRector\Fixture; | ||
|
||
class SkipWithParameter | ||
{ | ||
public $a = 'value'; | ||
|
||
public function run() | ||
{ | ||
$var = 'a'; | ||
return $this->getSome($var); | ||
} | ||
|
||
private function getSome(string $parameter) | ||
{ | ||
return (new SkipWithParameter())->$parameter; | ||
} | ||
} |
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