mirror of
https://github.com/rectorphp/rector.git
synced 2025-01-17 21:38:22 +01:00
Updated Rector to commit 2ffa009e08d06c7522a1f3b066f90e8edbee8210
2ffa009e08
[DX] Make use of Laravel container in few tests - step #1 (#4672)
This commit is contained in:
parent
c3e12c8e9c
commit
6f8ff0f9d5
@ -6,7 +6,6 @@ namespace Rector\BetterPhpDocParser\PhpDocParser;
|
||||
use PhpParser\Node;
|
||||
use PhpParser\Node\Identifier;
|
||||
use PhpParser\Node\Stmt\GroupUse;
|
||||
use PhpParser\Node\Stmt\Property;
|
||||
use PhpParser\Node\Stmt\Use_;
|
||||
use PHPStan\Analyser\Scope;
|
||||
use PHPStan\Reflection\ReflectionProvider;
|
||||
@ -43,18 +42,7 @@ final class ClassAnnotationMatcher
|
||||
$this->useImportsResolver = $useImportsResolver;
|
||||
$this->reflectionProvider = $reflectionProvider;
|
||||
}
|
||||
/**
|
||||
* @api doctrine
|
||||
*/
|
||||
public function resolveTagToKnownFullyQualifiedName(string $tag, Property $property) : ?string
|
||||
{
|
||||
return $this->_resolveTagFullyQualifiedName($tag, $property, \true);
|
||||
}
|
||||
public function resolveTagFullyQualifiedName(string $tag, Node $node) : ?string
|
||||
{
|
||||
return $this->_resolveTagFullyQualifiedName($tag, $node, \false);
|
||||
}
|
||||
private function _resolveTagFullyQualifiedName(string $tag, Node $node, bool $returnNullOnUnknownClass) : ?string
|
||||
public function resolveTagFullyQualifiedName(string $tag, Node $node) : string
|
||||
{
|
||||
$uniqueHash = $tag . \spl_object_hash($node);
|
||||
if (isset($this->fullyQualifiedNameByHash[$uniqueHash])) {
|
||||
@ -62,11 +50,8 @@ final class ClassAnnotationMatcher
|
||||
}
|
||||
$tag = \ltrim($tag, '@');
|
||||
$uses = $this->useImportsResolver->resolve();
|
||||
$fullyQualifiedClass = $this->resolveFullyQualifiedClass($uses, $node, $tag, $returnNullOnUnknownClass);
|
||||
$fullyQualifiedClass = $this->resolveFullyQualifiedClass($uses, $node, $tag, \false);
|
||||
if ($fullyQualifiedClass === null) {
|
||||
if ($returnNullOnUnknownClass) {
|
||||
return null;
|
||||
}
|
||||
$fullyQualifiedClass = $tag;
|
||||
}
|
||||
$this->fullyQualifiedNameByHash[$uniqueHash] = $fullyQualifiedClass;
|
||||
|
@ -157,7 +157,7 @@ final class DoctrineAnnotationDecorator implements PhpDocNodeDecoratorInterface
|
||||
continue;
|
||||
}
|
||||
// known doc tag to annotation class
|
||||
$fullyQualifiedAnnotationClass = (string) $this->classAnnotationMatcher->resolveTagFullyQualifiedName($phpDocChildNode->name, $currentPhpNode);
|
||||
$fullyQualifiedAnnotationClass = $this->classAnnotationMatcher->resolveTagFullyQualifiedName($phpDocChildNode->name, $currentPhpNode);
|
||||
// not an annotations class
|
||||
if (\strpos($fullyQualifiedAnnotationClass, '\\') === \false && !\in_array($fullyQualifiedAnnotationClass, self::ALLOWED_SHORT_ANNOTATIONS, \true)) {
|
||||
continue;
|
||||
|
@ -48,7 +48,6 @@ use PHPStan\Analyser\MutatingScope;
|
||||
use PHPStan\Analyser\NodeScopeResolver;
|
||||
use PHPStan\Analyser\ScopeContext;
|
||||
use PHPStan\Node\UnreachableStatementNode;
|
||||
use PHPStan\Reflection\ClassReflection;
|
||||
use PHPStan\Reflection\ReflectionProvider;
|
||||
use PHPStan\Type\ObjectType;
|
||||
use PHPStan\Type\TypeCombinator;
|
||||
@ -226,11 +225,12 @@ final class PHPStanNodeScopeResolver
|
||||
$traitName = $this->resolveClassName($node);
|
||||
$traitClassReflection = $this->reflectionProvider->getClass($traitName);
|
||||
$traitScope = clone $mutatingScope;
|
||||
$scopeContext = $this->privatesAccessor->getPrivatePropertyOfClass($traitScope, self::CONTEXT, ScopeContext::class);
|
||||
/** @var ScopeContext $scopeContext */
|
||||
$scopeContext = $this->privatesAccessor->getPrivateProperty($traitScope, self::CONTEXT);
|
||||
$traitContext = clone $scopeContext;
|
||||
// before entering the class/trait again, we have to tell scope no class was set, otherwise it crashes
|
||||
$this->privatesAccessor->setPrivatePropertyOfClass($traitContext, 'classReflection', $traitClassReflection, ClassReflection::class);
|
||||
$this->privatesAccessor->setPrivatePropertyOfClass($traitScope, self::CONTEXT, $traitContext, ScopeContext::class);
|
||||
$this->privatesAccessor->setPrivateProperty($traitContext, 'classReflection', $traitClassReflection);
|
||||
$this->privatesAccessor->setPrivateProperty($traitScope, self::CONTEXT, $traitContext);
|
||||
$node->setAttribute(AttributeKey::SCOPE, $traitScope);
|
||||
$this->nodeScopeResolver->processNodes($node->stmts, $traitScope, $nodeCallback);
|
||||
$this->decorateTraitAttrGroups($node, $traitScope);
|
||||
|
@ -25,6 +25,11 @@ use RectorPrefix202308\Symfony\Contracts\Service\Attribute\Required;
|
||||
*/
|
||||
final class NameScopeFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Naming\Naming\UseImportsResolver
|
||||
*/
|
||||
private $useImportsResolver;
|
||||
/**
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
@ -33,10 +38,6 @@ final class NameScopeFactory
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory
|
||||
*/
|
||||
private $phpDocInfoFactory;
|
||||
/**
|
||||
* @var \Rector\Naming\Naming\UseImportsResolver
|
||||
*/
|
||||
private $useImportsResolver;
|
||||
/**
|
||||
* @var \Rector\Core\Reflection\ReflectionResolver
|
||||
*/
|
||||
@ -45,15 +46,18 @@ final class NameScopeFactory
|
||||
* @var \Rector\Core\PhpParser\ClassLikeAstResolver
|
||||
*/
|
||||
private $classLikeAstResolver;
|
||||
public function __construct(UseImportsResolver $useImportsResolver)
|
||||
{
|
||||
$this->useImportsResolver = $useImportsResolver;
|
||||
}
|
||||
// This is needed to avoid circular references
|
||||
/**
|
||||
* @required
|
||||
*/
|
||||
public function autowire(PhpDocInfoFactory $phpDocInfoFactory, StaticTypeMapper $staticTypeMapper, UseImportsResolver $useImportsResolver, ReflectionResolver $reflectionResolver, ClassLikeAstResolver $classLikeAstResolver) : void
|
||||
public function autowire(PhpDocInfoFactory $phpDocInfoFactory, StaticTypeMapper $staticTypeMapper, ReflectionResolver $reflectionResolver, ClassLikeAstResolver $classLikeAstResolver) : void
|
||||
{
|
||||
$this->phpDocInfoFactory = $phpDocInfoFactory;
|
||||
$this->staticTypeMapper = $staticTypeMapper;
|
||||
$this->useImportsResolver = $useImportsResolver;
|
||||
$this->reflectionResolver = $reflectionResolver;
|
||||
$this->classLikeAstResolver = $classLikeAstResolver;
|
||||
}
|
||||
|
@ -3,8 +3,8 @@
|
||||
declare (strict_types=1);
|
||||
namespace Rector\Testing\PHPUnit;
|
||||
|
||||
use RectorPrefix202308\Illuminate\Container\Container;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Rector\Core\DependencyInjection\LazyContainerFactory;
|
||||
abstract class AbstractLazyTestCase extends TestCase
|
||||
{
|
||||
/**
|
||||
@ -14,7 +14,9 @@ abstract class AbstractLazyTestCase extends TestCase
|
||||
*/
|
||||
protected function make(string $class) : object
|
||||
{
|
||||
$container = new Container();
|
||||
// @todo cache container
|
||||
$lazyContainerFactory = new LazyContainerFactory();
|
||||
$container = $lazyContainerFactory->create();
|
||||
return $container->make($class);
|
||||
}
|
||||
}
|
||||
|
@ -76,8 +76,8 @@ final class TypeNormalizer
|
||||
if ($this->isConstantArrayNever($traversedType)) {
|
||||
\assert($traversedType instanceof ConstantArrayType);
|
||||
// not sure why, but with direct new node everything gets nulled to MixedType
|
||||
$this->privatesAccessor->setPrivatePropertyOfClass($traversedType, 'keyType', new MixedType(), Type::class);
|
||||
$this->privatesAccessor->setPrivatePropertyOfClass($traversedType, 'itemType', new MixedType(), Type::class);
|
||||
$this->privatesAccessor->setPrivateProperty($traversedType, 'keyType', new MixedType());
|
||||
$this->privatesAccessor->setPrivateProperty($traversedType, 'itemType', new MixedType());
|
||||
return $traversedType;
|
||||
}
|
||||
if ($traversedType instanceof UnionType) {
|
||||
|
@ -19,12 +19,12 @@ final class VersionResolver
|
||||
* @api
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGE_VERSION = '3dbaeb0cadbc3a31d21849fab5494a1a828d792b';
|
||||
public const PACKAGE_VERSION = '2ffa009e08d06c7522a1f3b066f90e8edbee8210';
|
||||
/**
|
||||
* @api
|
||||
* @var string
|
||||
*/
|
||||
public const RELEASE_DATE = '2023-08-06 21:43:51';
|
||||
public const RELEASE_DATE = '2023-08-06 16:10:36';
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
|
119
src/DependencyInjection/LazyContainerFactory.php
Normal file
119
src/DependencyInjection/LazyContainerFactory.php
Normal file
@ -0,0 +1,119 @@
|
||||
<?php
|
||||
|
||||
declare (strict_types=1);
|
||||
namespace Rector\Core\DependencyInjection;
|
||||
|
||||
use RectorPrefix202308\Doctrine\Inflector\Inflector;
|
||||
use RectorPrefix202308\Doctrine\Inflector\Rules\English\InflectorFactory;
|
||||
use RectorPrefix202308\Illuminate\Container\Container;
|
||||
use PhpParser\Lexer;
|
||||
use PHPStan\Parser\Parser;
|
||||
use PHPStan\PhpDoc\TypeNodeResolver;
|
||||
use PHPStan\Reflection\ReflectionProvider;
|
||||
use Rector\BetterPhpDocParser\Contract\BasePhpDocNodeVisitorInterface;
|
||||
use Rector\BetterPhpDocParser\Contract\PhpDocParser\PhpDocNodeDecoratorInterface;
|
||||
use Rector\BetterPhpDocParser\PhpDocNodeMapper;
|
||||
use Rector\BetterPhpDocParser\PhpDocParser\BetterPhpDocParser;
|
||||
use Rector\Caching\Cache;
|
||||
use Rector\Caching\CacheFactory;
|
||||
use Rector\Core\Configuration\Option;
|
||||
use Rector\Core\Configuration\Parameter\SimpleParameterProvider;
|
||||
use Rector\Core\Util\Reflection\PrivatesAccessor;
|
||||
use Rector\NodeNameResolver\Contract\NodeNameResolverInterface;
|
||||
use Rector\NodeNameResolver\NodeNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\ClassConstFetchNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\ClassConstNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\ClassNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\EmptyNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\FuncCallNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\FunctionNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\NameNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\ParamNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\PropertyNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\UseNameResolver;
|
||||
use Rector\NodeNameResolver\NodeNameResolver\VariableNameResolver;
|
||||
use Rector\NodeTypeResolver\Contract\NodeTypeResolverInterface;
|
||||
use Rector\NodeTypeResolver\DependencyInjection\PHPStanServicesFactory;
|
||||
use Rector\NodeTypeResolver\NodeTypeResolver;
|
||||
use Rector\PHPStanStaticTypeMapper\Contract\TypeMapperInterface;
|
||||
use Rector\PHPStanStaticTypeMapper\PHPStanStaticTypeMapper;
|
||||
use Rector\StaticTypeMapper\Contract\PhpDocParser\PhpDocTypeMapperInterface;
|
||||
use Rector\StaticTypeMapper\Contract\PhpParser\PhpParserNodeMapperInterface;
|
||||
use Rector\StaticTypeMapper\Mapper\PhpParserNodeMapper;
|
||||
use Rector\StaticTypeMapper\PhpDoc\PhpDocTypeMapper;
|
||||
use RectorPrefix202308\Symfony\Component\Console\Application;
|
||||
final class LazyContainerFactory
|
||||
{
|
||||
/**
|
||||
* @var array<class-string<NodeNameResolverInterface>>
|
||||
*/
|
||||
private const NODE_NAME_RESOLVER_CLASSES = [ClassConstFetchNameResolver::class, ClassConstNameResolver::class, ClassNameResolver::class, EmptyNameResolver::class, FuncCallNameResolver::class, FunctionNameResolver::class, NameNameResolver::class, ParamNameResolver::class, PropertyNameResolver::class, UseNameResolver::class, VariableNameResolver::class];
|
||||
/**
|
||||
* @api used as next container factory
|
||||
*/
|
||||
public function create() : Container
|
||||
{
|
||||
$container = new Container();
|
||||
// setup base parameters - from RectorConfig
|
||||
SimpleParameterProvider::setParameter(Option::CACHE_DIR, \sys_get_temp_dir() . '/rector_cached_files');
|
||||
SimpleParameterProvider::setParameter(Option::CONTAINER_CACHE_DIRECTORY, \sys_get_temp_dir());
|
||||
$container->singleton(Application::class, static function () : Application {
|
||||
$application = new Application();
|
||||
// @todo inject commands
|
||||
$privatesAccessor = new PrivatesAccessor();
|
||||
$privatesAccessor->propertyClosure($application, 'commands', static function (array $commands) : array {
|
||||
unset($commands['completion']);
|
||||
unset($commands['help']);
|
||||
return $commands;
|
||||
});
|
||||
return $application;
|
||||
});
|
||||
$container->singleton(Inflector::class, static function () : Inflector {
|
||||
$inflectorFactory = new InflectorFactory();
|
||||
return $inflectorFactory->build();
|
||||
});
|
||||
// caching
|
||||
$container->singleton(Cache::class, static function (Container $container) : Cache {
|
||||
/** @var CacheFactory $cacheFactory */
|
||||
$cacheFactory = $container->make(CacheFactory::class);
|
||||
return $cacheFactory->create();
|
||||
});
|
||||
// tagged services
|
||||
$container->when(BetterPhpDocParser::class)->needs('$phpDocNodeDecorators')->giveTagged(PhpDocNodeDecoratorInterface::class);
|
||||
$container->when(PHPStanStaticTypeMapper::class)->needs('$typeMappers')->giveTagged(TypeMapperInterface::class);
|
||||
$container->when(PhpDocTypeMapper::class)->needs('$phpDocTypeMappers')->giveTagged(PhpDocTypeMapperInterface::class);
|
||||
$container->when(PhpParserNodeMapper::class)->needs('$phpParserNodeMappers')->giveTagged(PhpParserNodeMapperInterface::class);
|
||||
$container->when(NodeTypeResolver::class)->needs('$nodeTypeResolvers')->giveTagged(NodeTypeResolverInterface::class);
|
||||
// node name resolvers
|
||||
$container->when(NodeNameResolver::class)->needs('$nodeNameResolvers')->giveTagged(NodeNameResolverInterface::class);
|
||||
foreach (self::NODE_NAME_RESOLVER_CLASSES as $nodeNameResolverClass) {
|
||||
$container->singleton($nodeNameResolverClass);
|
||||
$container->tag($nodeNameResolverClass, NodeNameResolverInterface::class);
|
||||
}
|
||||
$container->singleton(Parser::class, static function (Container $container) {
|
||||
$phpstanServiceFactory = $container->make(PHPStanServicesFactory::class);
|
||||
return $phpstanServiceFactory->createPHPStanParser();
|
||||
});
|
||||
// phpstan factory
|
||||
$container->singleton(ReflectionProvider::class, static function (Container $container) : ReflectionProvider {
|
||||
$phpstanServiceFactory = $container->make(PHPStanServicesFactory::class);
|
||||
return $phpstanServiceFactory->createReflectionProvider();
|
||||
});
|
||||
$container->singleton(Parser::class, static function (Container $container) {
|
||||
$phpstanServiceFactory = $container->make(PHPStanServicesFactory::class);
|
||||
return $phpstanServiceFactory->createPHPStanParser();
|
||||
});
|
||||
$container->singleton(Lexer::class, static function (Container $container) {
|
||||
$phpstanServiceFactory = $container->make(PHPStanServicesFactory::class);
|
||||
return $phpstanServiceFactory->createEmulativeLexer();
|
||||
});
|
||||
$container->singleton(TypeNodeResolver::class, static function (Container $container) {
|
||||
$phpstanServiceFactory = $container->make(PHPStanServicesFactory::class);
|
||||
return $phpstanServiceFactory->createTypeNodeResolver();
|
||||
});
|
||||
// @todo add base node visitors
|
||||
$container->singleton(PhpDocNodeMapper::class, PhpDocNodeMapper::class);
|
||||
$container->when(PhpDocNodeMapper::class)->needs('$phpDocNodeVisitors')->giveTagged(BasePhpDocNodeVisitorInterface::class);
|
||||
return $container;
|
||||
}
|
||||
}
|
@ -1,9 +0,0 @@
|
||||
<?php
|
||||
|
||||
declare (strict_types=1);
|
||||
namespace Rector\Core\Exception\Reflection;
|
||||
|
||||
use Exception;
|
||||
final class InvalidPrivatePropertyTypeException extends Exception
|
||||
{
|
||||
}
|
@ -3,7 +3,6 @@
|
||||
declare (strict_types=1);
|
||||
namespace Rector\Core\Util\Reflection;
|
||||
|
||||
use Rector\Core\Exception\Reflection\InvalidPrivatePropertyTypeException;
|
||||
use Rector\Core\Exception\Reflection\MissingPrivatePropertyException;
|
||||
use ReflectionClass;
|
||||
use ReflectionMethod;
|
||||
@ -13,6 +12,16 @@ use ReflectionProperty;
|
||||
*/
|
||||
final class PrivatesAccessor
|
||||
{
|
||||
/**
|
||||
* @param callable(mixed $value): mixed $closure
|
||||
*/
|
||||
public function propertyClosure(object $object, string $propertyName, callable $closure) : void
|
||||
{
|
||||
$property = $this->getPrivateProperty($object, $propertyName);
|
||||
// modify value
|
||||
$property = $closure($property);
|
||||
$this->setPrivateProperty($object, $propertyName, $property);
|
||||
}
|
||||
/**
|
||||
* @param object|class-string $object
|
||||
* @param mixed[] $arguments
|
||||
@ -28,21 +37,6 @@ final class PrivatesAccessor
|
||||
$reflectionMethod = $this->createAccessibleMethodReflection($object, $methodName);
|
||||
return $reflectionMethod->invokeArgs($object, $arguments);
|
||||
}
|
||||
/**
|
||||
* @template T of object
|
||||
*
|
||||
* @param class-string<T> $valueClassName
|
||||
* @return T
|
||||
*/
|
||||
public function getPrivatePropertyOfClass(object $object, string $propertyName, string $valueClassName) : object
|
||||
{
|
||||
$value = $this->getPrivateProperty($object, $propertyName);
|
||||
if ($value instanceof $valueClassName) {
|
||||
return $value;
|
||||
}
|
||||
$errorMessage = \sprintf('The type "%s" is required, but "%s" type given', $valueClassName, \get_class($value));
|
||||
throw new InvalidPrivatePropertyTypeException($errorMessage);
|
||||
}
|
||||
/**
|
||||
* @return mixed
|
||||
*/
|
||||
@ -52,21 +46,6 @@ final class PrivatesAccessor
|
||||
$reflectionProperty->setAccessible(\true);
|
||||
return $reflectionProperty->getValue($object);
|
||||
}
|
||||
/**
|
||||
* @template T of object
|
||||
*
|
||||
* @param class-string<T> $valueClassName
|
||||
* @param mixed $value
|
||||
*/
|
||||
public function setPrivatePropertyOfClass(object $object, string $propertyName, $value, string $valueClassName) : void
|
||||
{
|
||||
if ($value instanceof $valueClassName) {
|
||||
$this->setPrivateProperty($object, $propertyName, $value);
|
||||
return;
|
||||
}
|
||||
$errorMessage = \sprintf('The type "%s" is required, but "%s" type given', $valueClassName, \get_class($value));
|
||||
throw new InvalidPrivatePropertyTypeException($errorMessage);
|
||||
}
|
||||
/**
|
||||
* @param mixed $value
|
||||
*/
|
||||
|
2
vendor/autoload.php
vendored
2
vendor/autoload.php
vendored
@ -22,4 +22,4 @@ if (PHP_VERSION_ID < 50600) {
|
||||
|
||||
require_once __DIR__ . '/composer/autoload_real.php';
|
||||
|
||||
return ComposerAutoloaderInit183f3281a4de228a5fb2a420c5c87348::getLoader();
|
||||
return ComposerAutoloaderInit960639b9b816f607e946e8b0525ee335::getLoader();
|
||||
|
2
vendor/composer/autoload_classmap.php
vendored
2
vendor/composer/autoload_classmap.php
vendored
@ -1535,6 +1535,7 @@ return array(
|
||||
'Rector\\Core\\DependencyInjection\\Collector\\ConfigureCallValuesCollector' => $baseDir . '/src/DependencyInjection/Collector/ConfigureCallValuesCollector.php',
|
||||
'Rector\\Core\\DependencyInjection\\CompilerPass\\MergeImportedRectorConfigureCallValuesCompilerPass' => $baseDir . '/src/DependencyInjection/CompilerPass/MergeImportedRectorConfigureCallValuesCompilerPass.php',
|
||||
'Rector\\Core\\DependencyInjection\\CompilerPass\\RemoveSkippedRectorsCompilerPass' => $baseDir . '/src/DependencyInjection/CompilerPass/RemoveSkippedRectorsCompilerPass.php',
|
||||
'Rector\\Core\\DependencyInjection\\LazyContainerFactory' => $baseDir . '/src/DependencyInjection/LazyContainerFactory.php',
|
||||
'Rector\\Core\\DependencyInjection\\Loader\\ConfigurableCallValuesCollectingPhpFileLoader' => $baseDir . '/src/DependencyInjection/Loader/ConfigurableCallValuesCollectingPhpFileLoader.php',
|
||||
'Rector\\Core\\DependencyInjection\\RectorContainerFactory' => $baseDir . '/src/DependencyInjection/RectorContainerFactory.php',
|
||||
'Rector\\Core\\Differ\\DefaultDiffer' => $baseDir . '/src/Differ/DefaultDiffer.php',
|
||||
@ -1544,7 +1545,6 @@ return array(
|
||||
'Rector\\Core\\Exception\\Configuration\\InvalidConfigurationException' => $baseDir . '/src/Exception/Configuration/InvalidConfigurationException.php',
|
||||
'Rector\\Core\\Exception\\DeprecatedException' => $baseDir . '/src/Exception/DeprecatedException.php',
|
||||
'Rector\\Core\\Exception\\NotImplementedYetException' => $baseDir . '/src/Exception/NotImplementedYetException.php',
|
||||
'Rector\\Core\\Exception\\Reflection\\InvalidPrivatePropertyTypeException' => $baseDir . '/src/Exception/Reflection/InvalidPrivatePropertyTypeException.php',
|
||||
'Rector\\Core\\Exception\\Reflection\\MissingPrivatePropertyException' => $baseDir . '/src/Exception/Reflection/MissingPrivatePropertyException.php',
|
||||
'Rector\\Core\\Exception\\ShouldNotHappenException' => $baseDir . '/src/Exception/ShouldNotHappenException.php',
|
||||
'Rector\\Core\\Exception\\VersionException' => $baseDir . '/src/Exception/VersionException.php',
|
||||
|
10
vendor/composer/autoload_real.php
vendored
10
vendor/composer/autoload_real.php
vendored
@ -2,7 +2,7 @@
|
||||
|
||||
// autoload_real.php @generated by Composer
|
||||
|
||||
class ComposerAutoloaderInit183f3281a4de228a5fb2a420c5c87348
|
||||
class ComposerAutoloaderInit960639b9b816f607e946e8b0525ee335
|
||||
{
|
||||
private static $loader;
|
||||
|
||||
@ -22,17 +22,17 @@ class ComposerAutoloaderInit183f3281a4de228a5fb2a420c5c87348
|
||||
return self::$loader;
|
||||
}
|
||||
|
||||
spl_autoload_register(array('ComposerAutoloaderInit183f3281a4de228a5fb2a420c5c87348', 'loadClassLoader'), true, true);
|
||||
spl_autoload_register(array('ComposerAutoloaderInit960639b9b816f607e946e8b0525ee335', 'loadClassLoader'), true, true);
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit183f3281a4de228a5fb2a420c5c87348', 'loadClassLoader'));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit960639b9b816f607e946e8b0525ee335', 'loadClassLoader'));
|
||||
|
||||
require __DIR__ . '/autoload_static.php';
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInit183f3281a4de228a5fb2a420c5c87348::getInitializer($loader));
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInit960639b9b816f607e946e8b0525ee335::getInitializer($loader));
|
||||
|
||||
$loader->setClassMapAuthoritative(true);
|
||||
$loader->register(true);
|
||||
|
||||
$filesToLoad = \Composer\Autoload\ComposerStaticInit183f3281a4de228a5fb2a420c5c87348::$files;
|
||||
$filesToLoad = \Composer\Autoload\ComposerStaticInit960639b9b816f607e946e8b0525ee335::$files;
|
||||
$requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
|
||||
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
||||
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
|
||||
|
10
vendor/composer/autoload_static.php
vendored
10
vendor/composer/autoload_static.php
vendored
@ -4,7 +4,7 @@
|
||||
|
||||
namespace Composer\Autoload;
|
||||
|
||||
class ComposerStaticInit183f3281a4de228a5fb2a420c5c87348
|
||||
class ComposerStaticInit960639b9b816f607e946e8b0525ee335
|
||||
{
|
||||
public static $files = array (
|
||||
'ad155f8f1cf0d418fe49e248db8c661b' => __DIR__ . '/..' . '/react/promise/src/functions_include.php',
|
||||
@ -1789,6 +1789,7 @@ class ComposerStaticInit183f3281a4de228a5fb2a420c5c87348
|
||||
'Rector\\Core\\DependencyInjection\\Collector\\ConfigureCallValuesCollector' => __DIR__ . '/../..' . '/src/DependencyInjection/Collector/ConfigureCallValuesCollector.php',
|
||||
'Rector\\Core\\DependencyInjection\\CompilerPass\\MergeImportedRectorConfigureCallValuesCompilerPass' => __DIR__ . '/../..' . '/src/DependencyInjection/CompilerPass/MergeImportedRectorConfigureCallValuesCompilerPass.php',
|
||||
'Rector\\Core\\DependencyInjection\\CompilerPass\\RemoveSkippedRectorsCompilerPass' => __DIR__ . '/../..' . '/src/DependencyInjection/CompilerPass/RemoveSkippedRectorsCompilerPass.php',
|
||||
'Rector\\Core\\DependencyInjection\\LazyContainerFactory' => __DIR__ . '/../..' . '/src/DependencyInjection/LazyContainerFactory.php',
|
||||
'Rector\\Core\\DependencyInjection\\Loader\\ConfigurableCallValuesCollectingPhpFileLoader' => __DIR__ . '/../..' . '/src/DependencyInjection/Loader/ConfigurableCallValuesCollectingPhpFileLoader.php',
|
||||
'Rector\\Core\\DependencyInjection\\RectorContainerFactory' => __DIR__ . '/../..' . '/src/DependencyInjection/RectorContainerFactory.php',
|
||||
'Rector\\Core\\Differ\\DefaultDiffer' => __DIR__ . '/../..' . '/src/Differ/DefaultDiffer.php',
|
||||
@ -1798,7 +1799,6 @@ class ComposerStaticInit183f3281a4de228a5fb2a420c5c87348
|
||||
'Rector\\Core\\Exception\\Configuration\\InvalidConfigurationException' => __DIR__ . '/../..' . '/src/Exception/Configuration/InvalidConfigurationException.php',
|
||||
'Rector\\Core\\Exception\\DeprecatedException' => __DIR__ . '/../..' . '/src/Exception/DeprecatedException.php',
|
||||
'Rector\\Core\\Exception\\NotImplementedYetException' => __DIR__ . '/../..' . '/src/Exception/NotImplementedYetException.php',
|
||||
'Rector\\Core\\Exception\\Reflection\\InvalidPrivatePropertyTypeException' => __DIR__ . '/../..' . '/src/Exception/Reflection/InvalidPrivatePropertyTypeException.php',
|
||||
'Rector\\Core\\Exception\\Reflection\\MissingPrivatePropertyException' => __DIR__ . '/../..' . '/src/Exception/Reflection/MissingPrivatePropertyException.php',
|
||||
'Rector\\Core\\Exception\\ShouldNotHappenException' => __DIR__ . '/../..' . '/src/Exception/ShouldNotHappenException.php',
|
||||
'Rector\\Core\\Exception\\VersionException' => __DIR__ . '/../..' . '/src/Exception/VersionException.php',
|
||||
@ -3011,9 +3011,9 @@ class ComposerStaticInit183f3281a4de228a5fb2a420c5c87348
|
||||
public static function getInitializer(ClassLoader $loader)
|
||||
{
|
||||
return \Closure::bind(function () use ($loader) {
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInit183f3281a4de228a5fb2a420c5c87348::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInit183f3281a4de228a5fb2a420c5c87348::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInit183f3281a4de228a5fb2a420c5c87348::$classMap;
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInit960639b9b816f607e946e8b0525ee335::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInit960639b9b816f607e946e8b0525ee335::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInit960639b9b816f607e946e8b0525ee335::$classMap;
|
||||
|
||||
}, null, ClassLoader::class);
|
||||
}
|
||||
|
13
vendor/composer/installed.json
vendored
13
vendor/composer/installed.json
vendored
@ -530,7 +530,10 @@
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
}
|
||||
},
|
||||
"patches_applied": [
|
||||
"patches\/illuminate-container-container-php.patch"
|
||||
]
|
||||
},
|
||||
"installation-source": "dist",
|
||||
"autoload": {
|
||||
@ -1917,12 +1920,12 @@
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https:\/\/github.com\/rectorphp\/rector-doctrine.git",
|
||||
"reference": "25c2946d440af0d8be800d6aba4c3a8326fde000"
|
||||
"reference": "e49883509c494a7508f07fb1d4fdedcdda717db4"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-doctrine\/zipball\/25c2946d440af0d8be800d6aba4c3a8326fde000",
|
||||
"reference": "25c2946d440af0d8be800d6aba4c3a8326fde000",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-doctrine\/zipball\/e49883509c494a7508f07fb1d4fdedcdda717db4",
|
||||
"reference": "e49883509c494a7508f07fb1d4fdedcdda717db4",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -1948,7 +1951,7 @@
|
||||
"tomasvotruba\/type-coverage": "^0.2",
|
||||
"tomasvotruba\/unused-public": "^0.1"
|
||||
},
|
||||
"time": "2023-08-06T14:42:34+00:00",
|
||||
"time": "2023-08-06T15:03:12+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
2
vendor/illuminate/container/Container.php
vendored
2
vendor/illuminate/container/Container.php
vendored
@ -694,7 +694,7 @@ class Container implements ArrayAccess, ContainerContract
|
||||
// If the requested type is registered as a singleton we'll want to cache off
|
||||
// the instances in "memory" so we can return it later without creating an
|
||||
// entirely new instance of an object on each subsequent request for it.
|
||||
if ($this->isShared($abstract) && !$needsContextualBuild) {
|
||||
if (!$needsContextualBuild) {
|
||||
$this->instances[$abstract] = $object;
|
||||
}
|
||||
if ($raiseEvents) {
|
||||
|
7
vendor/illuminate/container/PATCHES.txt
vendored
Normal file
7
vendor/illuminate/container/PATCHES.txt
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
This file was automatically generated by Composer Patches (https://github.com/cweagans/composer-patches)
|
||||
Patches applied to this directory:
|
||||
|
||||
0
|
||||
Source: patches/illuminate-container-container-php.patch
|
||||
|
||||
|
@ -9,7 +9,7 @@ namespace Rector\RectorInstaller;
|
||||
*/
|
||||
final class GeneratedConfig
|
||||
{
|
||||
public const EXTENSIONS = array('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 25c2946'), 'rector/rector-downgrade-php' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-downgrade-php', 'relative_install_path' => '../../rector-downgrade-php', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 44cec67'), '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 0438162'), '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 40cd007'));
|
||||
public const EXTENSIONS = array('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 e498835'), 'rector/rector-downgrade-php' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-downgrade-php', 'relative_install_path' => '../../rector-downgrade-php', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 44cec67'), '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 0438162'), '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 40cd007'));
|
||||
private function __construct()
|
||||
{
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user