Skip to content

Commit

Permalink
Updated Rector to commit b70a9a1e93744c656241dad6afa251ea8f30ff0f
Browse files Browse the repository at this point in the history
rectorphp/rector-src@b70a9a1  [Php81] Skip call by ref on ReadOnlyPropertyRector on FuncCall  (#4630)
  • Loading branch information
TomasVotruba committed Aug 3, 2023
1 parent 38d5eac commit 307a014
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 15 deletions.
4 changes: 2 additions & 2 deletions src/Application/VersionResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ final class VersionResolver
* @api
* @var string
*/
public const PACKAGE_VERSION = '56d1c1822bd594c2643a0f5431444d1454cf2335';
public const PACKAGE_VERSION = 'b70a9a1e93744c656241dad6afa251ea8f30ff0f';
/**
* @api
* @var string
*/
public const RELEASE_DATE = '2023-08-03 16:51:46';
public const RELEASE_DATE = '2023-08-03 17:17:50';
/**
* @var int
*/
Expand Down
7 changes: 4 additions & 3 deletions src/PhpParser/NodeFinder/PropertyFetchFinder.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
use PhpParser\Node\Expr;
use PhpParser\Node\Expr\ArrayDimFetch;
use PhpParser\Node\Expr\Assign;
use PhpParser\Node\Expr\FuncCall;
use PhpParser\Node\Expr\MethodCall;
use PhpParser\Node\Expr\PropertyFetch;
use PhpParser\Node\Expr\StaticCall;
Expand Down Expand Up @@ -167,7 +168,7 @@ private function findPropertyFetchesInClassLike($class, array $stmts, string $pr
{
/** @var PropertyFetch[]|StaticPropertyFetch[] $propertyFetches */
$propertyFetches = $this->betterNodeFinder->find($stmts, function (Node $subNode) use($class, $hasTrait, $propertyName, $scope) : bool {
if ($subNode instanceof MethodCall || $subNode instanceof StaticCall) {
if ($subNode instanceof MethodCall || $subNode instanceof StaticCall || $subNode instanceof FuncCall) {
$this->decoratePropertyFetch($subNode, $scope);
return \false;
}
Expand All @@ -186,7 +187,7 @@ private function findPropertyFetchesInClassLike($class, array $stmts, string $pr
}
private function decoratePropertyFetch(Node $node, Scope $scope) : void
{
if (!$node instanceof MethodCall && !$node instanceof StaticCall) {
if (!$node instanceof MethodCall && !$node instanceof StaticCall && !$node instanceof FuncCall) {
return;
}
if ($node->isFirstClassCallable()) {
Expand All @@ -203,7 +204,7 @@ private function decoratePropertyFetch(Node $node, Scope $scope) : void
}
}
/**
* @param \PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall $node
* @param \PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall|\PhpParser\Node\Expr\FuncCall $node
*/
private function isFoundByRefParam($node, int $key, Scope $scope) : bool
{
Expand Down
2 changes: 1 addition & 1 deletion vendor/autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@

require_once __DIR__ . '/composer/autoload_real.php';

return ComposerAutoloaderInitcedfab466762a8b8436ad45ca0447c5a::getLoader();
return ComposerAutoloaderInit5cc722a19865302eedd3a26c7653422f::getLoader();
10 changes: 5 additions & 5 deletions vendor/composer/autoload_real.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

// autoload_real.php @generated by Composer

class ComposerAutoloaderInitcedfab466762a8b8436ad45ca0447c5a
class ComposerAutoloaderInit5cc722a19865302eedd3a26c7653422f
{
private static $loader;

Expand All @@ -22,17 +22,17 @@ public static function getLoader()
return self::$loader;
}

spl_autoload_register(array('ComposerAutoloaderInitcedfab466762a8b8436ad45ca0447c5a', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInit5cc722a19865302eedd3a26c7653422f', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
spl_autoload_unregister(array('ComposerAutoloaderInitcedfab466762a8b8436ad45ca0447c5a', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInit5cc722a19865302eedd3a26c7653422f', 'loadClassLoader'));

require __DIR__ . '/autoload_static.php';
call_user_func(\Composer\Autoload\ComposerStaticInitcedfab466762a8b8436ad45ca0447c5a::getInitializer($loader));
call_user_func(\Composer\Autoload\ComposerStaticInit5cc722a19865302eedd3a26c7653422f::getInitializer($loader));

$loader->setClassMapAuthoritative(true);
$loader->register(true);

$filesToLoad = \Composer\Autoload\ComposerStaticInitcedfab466762a8b8436ad45ca0447c5a::$files;
$filesToLoad = \Composer\Autoload\ComposerStaticInit5cc722a19865302eedd3a26c7653422f::$files;
$requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
Expand Down
8 changes: 4 additions & 4 deletions vendor/composer/autoload_static.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Composer\Autoload;

class ComposerStaticInitcedfab466762a8b8436ad45ca0447c5a
class ComposerStaticInit5cc722a19865302eedd3a26c7653422f
{
public static $files = array (
'ad155f8f1cf0d418fe49e248db8c661b' => __DIR__ . '/..' . '/react/promise/src/functions_include.php',
Expand Down Expand Up @@ -3025,9 +3025,9 @@ class ComposerStaticInitcedfab466762a8b8436ad45ca0447c5a
public static function getInitializer(ClassLoader $loader)
{
return \Closure::bind(function () use ($loader) {
$loader->prefixLengthsPsr4 = ComposerStaticInitcedfab466762a8b8436ad45ca0447c5a::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInitcedfab466762a8b8436ad45ca0447c5a::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInitcedfab466762a8b8436ad45ca0447c5a::$classMap;
$loader->prefixLengthsPsr4 = ComposerStaticInit5cc722a19865302eedd3a26c7653422f::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInit5cc722a19865302eedd3a26c7653422f::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInit5cc722a19865302eedd3a26c7653422f::$classMap;

}, null, ClassLoader::class);
}
Expand Down

0 comments on commit 307a014

Please sign in to comment.