mirror of
https://github.com/rectorphp/rector.git
synced 2025-01-18 22:08:00 +01:00
Updated Rector to commit a6fb82623b836a681530ba3db383ec52c68d4d55
a6fb82623b
Bump to phpstan/phpdoc-parser 1.6.2 (#2473)
This commit is contained in:
parent
418223409c
commit
aac6955d81
2
vendor/autoload.php
vendored
2
vendor/autoload.php
vendored
@ -9,4 +9,4 @@ if (PHP_VERSION_ID < 50600) {
|
||||
|
||||
require_once __DIR__ . '/composer/autoload_real.php';
|
||||
|
||||
return ComposerAutoloaderInitf354a4a385286515533124cb7526750f::getLoader();
|
||||
return ComposerAutoloaderInit4eaac544738882e01680b0ef5c66efdd::getLoader();
|
||||
|
14
vendor/composer/autoload_real.php
vendored
14
vendor/composer/autoload_real.php
vendored
@ -2,7 +2,7 @@
|
||||
|
||||
// autoload_real.php @generated by Composer
|
||||
|
||||
class ComposerAutoloaderInitf354a4a385286515533124cb7526750f
|
||||
class ComposerAutoloaderInit4eaac544738882e01680b0ef5c66efdd
|
||||
{
|
||||
private static $loader;
|
||||
|
||||
@ -22,19 +22,19 @@ class ComposerAutoloaderInitf354a4a385286515533124cb7526750f
|
||||
return self::$loader;
|
||||
}
|
||||
|
||||
spl_autoload_register(array('ComposerAutoloaderInitf354a4a385286515533124cb7526750f', 'loadClassLoader'), true, true);
|
||||
spl_autoload_register(array('ComposerAutoloaderInit4eaac544738882e01680b0ef5c66efdd', 'loadClassLoader'), true, true);
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInitf354a4a385286515533124cb7526750f', 'loadClassLoader'));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit4eaac544738882e01680b0ef5c66efdd', 'loadClassLoader'));
|
||||
|
||||
require __DIR__ . '/autoload_static.php';
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInitf354a4a385286515533124cb7526750f::getInitializer($loader));
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInit4eaac544738882e01680b0ef5c66efdd::getInitializer($loader));
|
||||
|
||||
$loader->setClassMapAuthoritative(true);
|
||||
$loader->register(true);
|
||||
|
||||
$includeFiles = \Composer\Autoload\ComposerStaticInitf354a4a385286515533124cb7526750f::$files;
|
||||
$includeFiles = \Composer\Autoload\ComposerStaticInit4eaac544738882e01680b0ef5c66efdd::$files;
|
||||
foreach ($includeFiles as $fileIdentifier => $file) {
|
||||
composerRequiref354a4a385286515533124cb7526750f($fileIdentifier, $file);
|
||||
composerRequire4eaac544738882e01680b0ef5c66efdd($fileIdentifier, $file);
|
||||
}
|
||||
|
||||
return $loader;
|
||||
@ -46,7 +46,7 @@ class ComposerAutoloaderInitf354a4a385286515533124cb7526750f
|
||||
* @param string $file
|
||||
* @return void
|
||||
*/
|
||||
function composerRequiref354a4a385286515533124cb7526750f($fileIdentifier, $file)
|
||||
function composerRequire4eaac544738882e01680b0ef5c66efdd($fileIdentifier, $file)
|
||||
{
|
||||
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
||||
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
|
||||
|
8
vendor/composer/autoload_static.php
vendored
8
vendor/composer/autoload_static.php
vendored
@ -4,7 +4,7 @@
|
||||
|
||||
namespace Composer\Autoload;
|
||||
|
||||
class ComposerStaticInitf354a4a385286515533124cb7526750f
|
||||
class ComposerStaticInit4eaac544738882e01680b0ef5c66efdd
|
||||
{
|
||||
public static $files = array (
|
||||
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
|
||||
@ -3389,9 +3389,9 @@ class ComposerStaticInitf354a4a385286515533124cb7526750f
|
||||
public static function getInitializer(ClassLoader $loader)
|
||||
{
|
||||
return \Closure::bind(function () use ($loader) {
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInitf354a4a385286515533124cb7526750f::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInitf354a4a385286515533124cb7526750f::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInitf354a4a385286515533124cb7526750f::$classMap;
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInit4eaac544738882e01680b0ef5c66efdd::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInit4eaac544738882e01680b0ef5c66efdd::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInit4eaac544738882e01680b0ef5c66efdd::$classMap;
|
||||
|
||||
}, null, ClassLoader::class);
|
||||
}
|
||||
|
16
vendor/composer/installed.json
vendored
16
vendor/composer/installed.json
vendored
@ -1923,12 +1923,12 @@
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https:\/\/github.com\/rectorphp\/rector-doctrine.git",
|
||||
"reference": "ac93c3f4103c986bc19aab8b871c6714b93c59b6"
|
||||
"reference": "b695bf660e70f7159bbaaa2e0a3380c32f54b7e1"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-doctrine\/zipball\/ac93c3f4103c986bc19aab8b871c6714b93c59b6",
|
||||
"reference": "ac93c3f4103c986bc19aab8b871c6714b93c59b6",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-doctrine\/zipball\/b695bf660e70f7159bbaaa2e0a3380c32f54b7e1",
|
||||
"reference": "b695bf660e70f7159bbaaa2e0a3380c32f54b7e1",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -1953,7 +1953,7 @@
|
||||
"symplify\/rule-doc-generator": "^10.2",
|
||||
"symplify\/vendor-patches": "^10.2"
|
||||
},
|
||||
"time": "2022-06-09T10:01:30+00:00",
|
||||
"time": "2022-06-10T12:43:35+00:00",
|
||||
"default-branch": true,
|
||||
"type": "rector-extension",
|
||||
"extra": {
|
||||
@ -2279,12 +2279,12 @@
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https:\/\/github.com\/rectorphp\/rector-phpunit.git",
|
||||
"reference": "e6ed24fc884b9ad71342d03f2c5eaaf1c00b9b0b"
|
||||
"reference": "b220a7f45912752dc53f196595b101c15e864176"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-phpunit\/zipball\/e6ed24fc884b9ad71342d03f2c5eaaf1c00b9b0b",
|
||||
"reference": "e6ed24fc884b9ad71342d03f2c5eaaf1c00b9b0b",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-phpunit\/zipball\/b220a7f45912752dc53f196595b101c15e864176",
|
||||
"reference": "b220a7f45912752dc53f196595b101c15e864176",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -2309,7 +2309,7 @@
|
||||
"symplify\/rule-doc-generator": "^10.2",
|
||||
"symplify\/vendor-patches": "^10.2"
|
||||
},
|
||||
"time": "2022-06-09T09:50:22+00:00",
|
||||
"time": "2022-06-10T10:45:04+00:00",
|
||||
"default-branch": true,
|
||||
"type": "rector-extension",
|
||||
"extra": {
|
||||
|
2
vendor/composer/installed.php
vendored
2
vendor/composer/installed.php
vendored
File diff suppressed because one or more lines are too long
@ -9,7 +9,7 @@ namespace Rector\RectorInstaller;
|
||||
*/
|
||||
final class GeneratedConfig
|
||||
{
|
||||
public const EXTENSIONS = array('rector/rector-cakephp' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-cakephp', 'relative_install_path' => '../../rector-cakephp', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main f84ea17'), 'rector/rector-doctrine' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-doctrine', 'relative_install_path' => '../../rector-doctrine', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main ac93c3f'), 'rector/rector-generator' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-generator', 'relative_install_path' => '../../rector-generator', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 623c9e2'), 'rector/rector-laravel' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-laravel', 'relative_install_path' => '../../rector-laravel', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 1194b1b'), 'rector/rector-nette' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-nette', 'relative_install_path' => '../../rector-nette', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main f29fa56'), 'rector/rector-phpoffice' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-phpoffice', 'relative_install_path' => '../../rector-phpoffice', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 15ee440'), 'rector/rector-phpunit' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-phpunit', 'relative_install_path' => '../../rector-phpunit', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main e6ed24f'), 'rector/rector-symfony' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-symfony', 'relative_install_path' => '../../rector-symfony', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 36747ba'));
|
||||
public const EXTENSIONS = array('rector/rector-cakephp' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-cakephp', 'relative_install_path' => '../../rector-cakephp', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main f84ea17'), 'rector/rector-doctrine' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-doctrine', 'relative_install_path' => '../../rector-doctrine', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main b695bf6'), 'rector/rector-generator' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-generator', 'relative_install_path' => '../../rector-generator', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 623c9e2'), 'rector/rector-laravel' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-laravel', 'relative_install_path' => '../../rector-laravel', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 1194b1b'), 'rector/rector-nette' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-nette', 'relative_install_path' => '../../rector-nette', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main f29fa56'), 'rector/rector-phpoffice' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-phpoffice', 'relative_install_path' => '../../rector-phpoffice', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 15ee440'), 'rector/rector-phpunit' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-phpunit', 'relative_install_path' => '../../rector-phpunit', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main b220a7f'), 'rector/rector-symfony' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-symfony', 'relative_install_path' => '../../rector-symfony', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 36747ba'));
|
||||
private function __construct()
|
||||
{
|
||||
}
|
||||
|
@ -74,11 +74,13 @@ final class ParamFactory
|
||||
// the param is optional - make it nullable
|
||||
if (\in_array($propertyName, $optionalParamNames, \true)) {
|
||||
if (!$paramTypeNode instanceof ComplexType && $paramTypeNode !== null) {
|
||||
$paramTypeNode = new NullableType($paramTypeNode);
|
||||
$param->type = new NullableType($paramTypeNode);
|
||||
}
|
||||
$param->default = $this->nodeFactory->createNull();
|
||||
}
|
||||
$param->type = $paramTypeNode;
|
||||
if ($param->type === null) {
|
||||
$param->type = $paramTypeNode;
|
||||
}
|
||||
return $param;
|
||||
}
|
||||
}
|
||||
|
@ -179,11 +179,11 @@ CODE_SAMPLE
|
||||
$smartFileInfo = $this->file->getSmartFileInfo();
|
||||
$classShortName = $class->name . 'Translation';
|
||||
$filePath = \dirname($smartFileInfo->getRealPath()) . \DIRECTORY_SEPARATOR . $classShortName . '.php';
|
||||
$namespace = $class->getAttribute(AttributeKey::PARENT_NODE);
|
||||
if (!$namespace instanceof Namespace_) {
|
||||
$parentNode = $class->getAttribute(AttributeKey::PARENT_NODE);
|
||||
if (!$parentNode instanceof Namespace_) {
|
||||
throw new ShouldNotHappenException();
|
||||
}
|
||||
$namespace = new Namespace_($namespace->name);
|
||||
$namespace = new Namespace_($parentNode->name);
|
||||
$class = $this->translationClassNodeFactory->create($classShortName);
|
||||
foreach ($propertyNamesAndPhpDocInfos->all() as $propertyNameAndPhpDocInfo) {
|
||||
$property = $this->nodeFactory->createPrivateProperty($propertyNameAndPhpDocInfo->getPropertyName());
|
||||
|
@ -118,6 +118,9 @@ CODE_SAMPLE
|
||||
if ($this->valueResolver->isNull($defaultExpr)) {
|
||||
return null;
|
||||
}
|
||||
if ($defaultExpr instanceof ClassConstFetch || $defaultExpr instanceof ConstFetch) {
|
||||
return null;
|
||||
}
|
||||
throw new NotImplementedYetException();
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user