Updated Rector to commit 54799fc3d3a341643d050d06ecf72b467c8d37e8

54799fc3d3 [TypeDeclaration] Skip return after return closure on AddVoidReturnTypeWhereNoReturnRector (#4930)
This commit is contained in:
Tomas Votruba 2023-09-07 02:10:00 +00:00
parent 087ff4d5eb
commit 94613faf8f
5 changed files with 19 additions and 16 deletions

View File

@ -49,10 +49,13 @@ final class SilentVoidResolver
if ($this->betterNodeFinder->hasInstancesOfInFunctionLikeScoped($functionLike, Yield_::class)) {
return \false;
}
$return = $this->betterNodeFinder->findFirstInFunctionLikeScoped($functionLike, static function (Node $node) : bool {
return $node instanceof Return_ && $node->expr instanceof Expr;
});
return !$return instanceof Return_;
$returns = $this->betterNodeFinder->findInstancesOfInFunctionLikeScoped($functionLike, Return_::class);
foreach ($returns as $return) {
if ($return->expr instanceof Expr) {
return \false;
}
}
return \true;
}
public function hasSilentVoid(FunctionLike $functionLike) : bool
{

View File

@ -19,12 +19,12 @@ final class VersionResolver
* @api
* @var string
*/
public const PACKAGE_VERSION = 'e47f63176a7913ff040bfbce75a260a4ec47ceab';
public const PACKAGE_VERSION = '54799fc3d3a341643d050d06ecf72b467c8d37e8';
/**
* @api
* @var string
*/
public const RELEASE_DATE = '2023-09-07 08:47:29';
public const RELEASE_DATE = '2023-09-07 02:07:31';
/**
* @var int
*/

2
vendor/autoload.php vendored
View File

@ -22,4 +22,4 @@ if (PHP_VERSION_ID < 50600) {
require_once __DIR__ . '/composer/autoload_real.php';
return ComposerAutoloaderInit77dba623b1889c05f4e604bb54bdbc24::getLoader();
return ComposerAutoloaderInitedff5d0460f6c5a02f977a6f9323808d::getLoader();

View File

@ -2,7 +2,7 @@
// autoload_real.php @generated by Composer
class ComposerAutoloaderInit77dba623b1889c05f4e604bb54bdbc24
class ComposerAutoloaderInitedff5d0460f6c5a02f977a6f9323808d
{
private static $loader;
@ -22,17 +22,17 @@ class ComposerAutoloaderInit77dba623b1889c05f4e604bb54bdbc24
return self::$loader;
}
spl_autoload_register(array('ComposerAutoloaderInit77dba623b1889c05f4e604bb54bdbc24', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInitedff5d0460f6c5a02f977a6f9323808d', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
spl_autoload_unregister(array('ComposerAutoloaderInit77dba623b1889c05f4e604bb54bdbc24', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInitedff5d0460f6c5a02f977a6f9323808d', 'loadClassLoader'));
require __DIR__ . '/autoload_static.php';
call_user_func(\Composer\Autoload\ComposerStaticInit77dba623b1889c05f4e604bb54bdbc24::getInitializer($loader));
call_user_func(\Composer\Autoload\ComposerStaticInitedff5d0460f6c5a02f977a6f9323808d::getInitializer($loader));
$loader->setClassMapAuthoritative(true);
$loader->register(true);
$filesToLoad = \Composer\Autoload\ComposerStaticInit77dba623b1889c05f4e604bb54bdbc24::$files;
$filesToLoad = \Composer\Autoload\ComposerStaticInitedff5d0460f6c5a02f977a6f9323808d::$files;
$requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;

View File

@ -4,7 +4,7 @@
namespace Composer\Autoload;
class ComposerStaticInit77dba623b1889c05f4e604bb54bdbc24
class ComposerStaticInitedff5d0460f6c5a02f977a6f9323808d
{
public static $files = array (
'ad155f8f1cf0d418fe49e248db8c661b' => __DIR__ . '/..' . '/react/promise/src/functions_include.php',
@ -2603,9 +2603,9 @@ class ComposerStaticInit77dba623b1889c05f4e604bb54bdbc24
public static function getInitializer(ClassLoader $loader)
{
return \Closure::bind(function () use ($loader) {
$loader->prefixLengthsPsr4 = ComposerStaticInit77dba623b1889c05f4e604bb54bdbc24::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInit77dba623b1889c05f4e604bb54bdbc24::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInit77dba623b1889c05f4e604bb54bdbc24::$classMap;
$loader->prefixLengthsPsr4 = ComposerStaticInitedff5d0460f6c5a02f977a6f9323808d::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInitedff5d0460f6c5a02f977a6f9323808d::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInitedff5d0460f6c5a02f977a6f9323808d::$classMap;
}, null, ClassLoader::class);
}