Skip to content

Commit 4613632

Browse files
committed
Updated Rector to commit 4d47e8afcf17b3170c3fa39211e92ad527e645fa
rectorphp/rector-src@4d47e8a bump versoins to current
1 parent 8259269 commit 4613632

File tree

10 files changed

+34
-28
lines changed

10 files changed

+34
-28
lines changed

rules/Php84/Rector/Foreach_/ForeachToArrayFindKeyRector.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
declare (strict_types=1);
44
namespace Rector\Php84\Rector\Foreach_;
55

6-
use PhpParser\Node\Expr;
76
use PhpParser\Node;
7+
use PhpParser\Node\Expr;
88
use PhpParser\Node\Expr\ArrowFunction;
99
use PhpParser\Node\Expr\Assign;
1010
use PhpParser\Node\Expr\Variable;

src/Application/VersionResolver.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,12 @@ final class VersionResolver
1919
* @api
2020
* @var string
2121
*/
22-
public const PACKAGE_VERSION = 'c8d728c6bd1ff67f6ca38944050b1ae02bb2e74f';
22+
public const PACKAGE_VERSION = '4d47e8afcf17b3170c3fa39211e92ad527e645fa';
2323
/**
2424
* @api
2525
* @var string
2626
*/
27-
public const RELEASE_DATE = '2025-06-22 21:36:54';
27+
public const RELEASE_DATE = '2025-06-24 22:03:41';
2828
/**
2929
* @var int
3030
*/

vendor/autoload.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919

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

22-
return ComposerAutoloaderInit78fb90a05527c4e1e3e0271783524c1e::getLoader();
22+
return ComposerAutoloaderInitdb65f1617bfddbb41dc0dee4425e5c9b::getLoader();

vendor/composer/autoload_real.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
// autoload_real.php @generated by Composer
44

5-
class ComposerAutoloaderInit78fb90a05527c4e1e3e0271783524c1e
5+
class ComposerAutoloaderInitdb65f1617bfddbb41dc0dee4425e5c9b
66
{
77
private static $loader;
88

@@ -22,17 +22,17 @@ public static function getLoader()
2222
return self::$loader;
2323
}
2424

25-
spl_autoload_register(array('ComposerAutoloaderInit78fb90a05527c4e1e3e0271783524c1e', 'loadClassLoader'), true, true);
25+
spl_autoload_register(array('ComposerAutoloaderInitdb65f1617bfddbb41dc0dee4425e5c9b', 'loadClassLoader'), true, true);
2626
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
27-
spl_autoload_unregister(array('ComposerAutoloaderInit78fb90a05527c4e1e3e0271783524c1e', 'loadClassLoader'));
27+
spl_autoload_unregister(array('ComposerAutoloaderInitdb65f1617bfddbb41dc0dee4425e5c9b', 'loadClassLoader'));
2828

2929
require __DIR__ . '/autoload_static.php';
30-
call_user_func(\Composer\Autoload\ComposerStaticInit78fb90a05527c4e1e3e0271783524c1e::getInitializer($loader));
30+
call_user_func(\Composer\Autoload\ComposerStaticInitdb65f1617bfddbb41dc0dee4425e5c9b::getInitializer($loader));
3131

3232
$loader->setClassMapAuthoritative(true);
3333
$loader->register(true);
3434

35-
$filesToLoad = \Composer\Autoload\ComposerStaticInit78fb90a05527c4e1e3e0271783524c1e::$files;
35+
$filesToLoad = \Composer\Autoload\ComposerStaticInitdb65f1617bfddbb41dc0dee4425e5c9b::$files;
3636
$requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
3737
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
3838
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;

vendor/composer/autoload_static.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace Composer\Autoload;
66

7-
class ComposerStaticInit78fb90a05527c4e1e3e0271783524c1e
7+
class ComposerStaticInitdb65f1617bfddbb41dc0dee4425e5c9b
88
{
99
public static $files = array (
1010
'ad155f8f1cf0d418fe49e248db8c661b' => __DIR__ . '/..' . '/react/promise/src/functions_include.php',
@@ -2981,9 +2981,9 @@ class ComposerStaticInit78fb90a05527c4e1e3e0271783524c1e
29812981
public static function getInitializer(ClassLoader $loader)
29822982
{
29832983
return \Closure::bind(function () use ($loader) {
2984-
$loader->prefixLengthsPsr4 = ComposerStaticInit78fb90a05527c4e1e3e0271783524c1e::$prefixLengthsPsr4;
2985-
$loader->prefixDirsPsr4 = ComposerStaticInit78fb90a05527c4e1e3e0271783524c1e::$prefixDirsPsr4;
2986-
$loader->classMap = ComposerStaticInit78fb90a05527c4e1e3e0271783524c1e::$classMap;
2984+
$loader->prefixLengthsPsr4 = ComposerStaticInitdb65f1617bfddbb41dc0dee4425e5c9b::$prefixLengthsPsr4;
2985+
$loader->prefixDirsPsr4 = ComposerStaticInitdb65f1617bfddbb41dc0dee4425e5c9b::$prefixDirsPsr4;
2986+
$loader->classMap = ComposerStaticInitdb65f1617bfddbb41dc0dee4425e5c9b::$classMap;
29872987

29882988
}, null, ClassLoader::class);
29892989
}

vendor/composer/installed.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1748,12 +1748,12 @@
17481748
"source": {
17491749
"type": "git",
17501750
"url": "https:\/\/github.com\/rectorphp\/rector-downgrade-php.git",
1751-
"reference": "1454a52955bec8fe173d05b1d682844683cd811f"
1751+
"reference": "4b311807e9aa0c8db1999c5a1adee09396f03bec"
17521752
},
17531753
"dist": {
17541754
"type": "zip",
1755-
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-downgrade-php\/zipball\/1454a52955bec8fe173d05b1d682844683cd811f",
1756-
"reference": "1454a52955bec8fe173d05b1d682844683cd811f",
1755+
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-downgrade-php\/zipball\/4b311807e9aa0c8db1999c5a1adee09396f03bec",
1756+
"reference": "4b311807e9aa0c8db1999c5a1adee09396f03bec",
17571757
"shasum": ""
17581758
},
17591759
"require": {
@@ -1771,7 +1771,7 @@
17711771
"tomasvotruba\/class-leak": "^1.0",
17721772
"tracy\/tracy": "^2.10"
17731773
},
1774-
"time": "2025-05-31T06:44:59+00:00",
1774+
"time": "2025-06-24T20:02:20+00:00",
17751775
"default-branch": true,
17761776
"type": "rector-extension",
17771777
"extra": {

vendor/composer/installed.php

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

vendor/rector/extension-installer/src/GeneratedConfig.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010
final class GeneratedConfig
1111
{
12-
public const EXTENSIONS = array('rector/rector-doctrine' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-doctrine', 'relative_install_path' => '../../rector-doctrine', 'extra' => NULL, 'version' => 'dev-main 0231850'), 'rector/rector-downgrade-php' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-downgrade-php', 'relative_install_path' => '../../rector-downgrade-php', 'extra' => NULL, 'version' => 'dev-main 1454a52'), 'rector/rector-phpunit' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-phpunit', 'relative_install_path' => '../../rector-phpunit', 'extra' => NULL, 'version' => 'dev-main 3bc079d'), 'rector/rector-symfony' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-symfony', 'relative_install_path' => '../../rector-symfony', 'extra' => NULL, 'version' => 'dev-main 0002ab1'));
12+
public const EXTENSIONS = array('rector/rector-doctrine' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-doctrine', 'relative_install_path' => '../../rector-doctrine', 'extra' => NULL, 'version' => 'dev-main 0231850'), 'rector/rector-downgrade-php' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-downgrade-php', 'relative_install_path' => '../../rector-downgrade-php', 'extra' => NULL, 'version' => 'dev-main 4b31180'), 'rector/rector-phpunit' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-phpunit', 'relative_install_path' => '../../rector-phpunit', 'extra' => NULL, 'version' => 'dev-main 3bc079d'), 'rector/rector-symfony' => array('install_path' => '/home/runner/work/rector-src/rector-src/rector-build/vendor/rector/rector-symfony', 'relative_install_path' => '../../rector-symfony', 'extra' => NULL, 'version' => 'dev-main 0002ab1'));
1313
private function __construct()
1414
{
1515
}

vendor/rector/rector-downgrade-php/rules/DowngradePhp80/Rector/MethodCall/DowngradeNamedArgumentRector.php

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
use PhpParser\Node\Expr\StaticCall;
1212
use PHPStan\Reflection\FunctionReflection;
1313
use PHPStan\Reflection\MethodReflection;
14+
use PHPStan\Type\MixedType;
1415
use Rector\DowngradePhp80\NodeAnalyzer\UnnamedArgumentResolver;
1516
use Rector\NodeAnalyzer\ArgsAnalyzer;
1617
use Rector\Rector\AbstractRector;
@@ -83,7 +84,7 @@ private function execute($a = null, $b = null)
8384
public function refactor(Node $node) : ?Node
8485
{
8586
$args = $node->getArgs();
86-
if ($this->shouldSkip($args)) {
87+
if (!$this->argsAnalyzer->hasNamedArg($args)) {
8788
return null;
8889
}
8990
return $this->removeNamedArguments($node, $args);
@@ -100,16 +101,21 @@ private function removeNamedArguments($node, array $args) : ?Node
100101
$functionLikeReflection = $this->reflectionResolver->resolveFunctionLikeReflectionFromCall($node);
101102
}
102103
if (!$functionLikeReflection instanceof MethodReflection && !$functionLikeReflection instanceof FunctionReflection) {
104+
// remove leftovers in case of unknown type, to avoid crashing on unknown syntax
105+
if ($node instanceof MethodCall) {
106+
$callerType = $this->getType($node->var);
107+
if ($callerType instanceof MixedType) {
108+
foreach ($node->getArgs() as $arg) {
109+
if ($arg->name instanceof Node) {
110+
$arg->name = null;
111+
}
112+
}
113+
return $node;
114+
}
115+
}
103116
return null;
104117
}
105118
$node->args = $this->unnamedArgumentResolver->resolveFromReflection($functionLikeReflection, $args);
106119
return $node;
107120
}
108-
/**
109-
* @param mixed[]|Arg[] $args
110-
*/
111-
private function shouldSkip(array $args) : bool
112-
{
113-
return !$this->argsAnalyzer->hasNamedArg($args);
114-
}
115121
}

vendor/scoper-autoload.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ function humbug_phpscoper_expose_class($exposed, $prefixed) {
3030
}
3131
}
3232
humbug_phpscoper_expose_class('AutoloadIncluder', 'RectorPrefix202506\AutoloadIncluder');
33-
humbug_phpscoper_expose_class('ComposerAutoloaderInit78fb90a05527c4e1e3e0271783524c1e', 'RectorPrefix202506\ComposerAutoloaderInit78fb90a05527c4e1e3e0271783524c1e');
33+
humbug_phpscoper_expose_class('ComposerAutoloaderInitdb65f1617bfddbb41dc0dee4425e5c9b', 'RectorPrefix202506\ComposerAutoloaderInitdb65f1617bfddbb41dc0dee4425e5c9b');
3434
humbug_phpscoper_expose_class('Product', 'RectorPrefix202506\Product');
3535
humbug_phpscoper_expose_class('SomeTest', 'RectorPrefix202506\SomeTest');
3636

0 commit comments

Comments
 (0)