Updated Rector to commit 5a1512b4c0939c1b8f9ab7a1c0eb40029acb1537

5a1512b4c0 [TypeDeclaration] Allow return static from under function on ReturnTypeFromStrictTypedCallRector (#5358)
This commit is contained in:
Tomas Votruba 2023-12-13 14:10:43 +00:00
parent b571b1cd51
commit 7c223ab41f
2 changed files with 3 additions and 6 deletions

View File

@ -117,10 +117,7 @@ final class ReturnStrictTypeAnalyzer
private function normalizeStaticType($call, Type $type) : Type
{
$reflectionClass = $this->reflectionResolver->resolveClassReflection($call);
if (!$reflectionClass instanceof ClassReflection) {
return $type;
}
$currentClassName = $reflectionClass->getName();
$currentClassName = $reflectionClass instanceof ClassReflection ? $reflectionClass->getName() : null;
return TypeTraverser::map($type, static function (Type $currentType, callable $traverseCallback) use($currentClassName) : Type {
if ($currentType instanceof StaticType && $currentClassName !== $currentType->getClassName()) {
return new FullyQualifiedObjectType($currentType->getClassName());

View File

@ -19,12 +19,12 @@ final class VersionResolver
* @api
* @var string
*/
public const PACKAGE_VERSION = '0817980433aaf92d2b71e4d9804ec1988afbf908';
public const PACKAGE_VERSION = '5a1512b4c0939c1b8f9ab7a1c0eb40029acb1537';
/**
* @api
* @var string
*/
public const RELEASE_DATE = '2023-12-13 19:58:49';
public const RELEASE_DATE = '2023-12-13 14:08:34';
/**
* @var int
*/