mirror of
https://github.com/rectorphp/rector.git
synced 2025-01-17 13:28:18 +01:00
Updated Rector to commit bb609b28e327ca1fb7827b6bc548013d19a2cf4e
bb609b28e3
[Core] Always reset stopTraversal to false on next Rector visit (#4182)
This commit is contained in:
parent
8ea0fec420
commit
3313a231b7
@ -8,13 +8,7 @@ use PHPStan\PhpDocParser\Ast\PhpDoc\PhpDocTagValueNode;
|
||||
use Stringable;
|
||||
final class ArrayItemNode implements PhpDocTagValueNode
|
||||
{
|
||||
/**
|
||||
* @var mixed
|
||||
*/
|
||||
public $value;
|
||||
/**
|
||||
* @var mixed
|
||||
*/
|
||||
public $key = null;
|
||||
use NodeAttributes;
|
||||
/**
|
||||
|
@ -40,42 +40,34 @@ use Rector\StaticTypeMapper\StaticTypeMapper;
|
||||
final class PhpDocInfo
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\PhpDocParser\Ast\PhpDoc\PhpDocNode
|
||||
*/
|
||||
private $phpDocNode;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\ValueObject\Parser\BetterTokenIterator
|
||||
*/
|
||||
private $betterTokenIterator;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PhpParser\Node
|
||||
*/
|
||||
private $node;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Annotation\AnnotationNaming
|
||||
*/
|
||||
private $annotationNaming;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\CurrentNodeProvider
|
||||
*/
|
||||
private $currentNodeProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\ChangesReporting\Collector\RectorChangeCollector
|
||||
*/
|
||||
private $rectorChangeCollector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocNodeFinder\PhpDocNodeByTypeFinder
|
||||
*/
|
||||
private $phpDocNodeByTypeFinder;
|
||||
|
@ -22,42 +22,34 @@ use Rector\StaticTypeMapper\StaticTypeMapper;
|
||||
final class PhpDocInfoFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocNodeMapper
|
||||
*/
|
||||
private $phpDocNodeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\CurrentNodeProvider
|
||||
*/
|
||||
private $currentNodeProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\PhpDocParser\Lexer\Lexer
|
||||
*/
|
||||
private $lexer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\BetterPhpDocParser
|
||||
*/
|
||||
private $betterPhpDocParser;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Annotation\AnnotationNaming
|
||||
*/
|
||||
private $annotationNaming;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\ChangesReporting\Collector\RectorChangeCollector
|
||||
*/
|
||||
private $rectorChangeCollector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocNodeFinder\PhpDocNodeByTypeFinder
|
||||
*/
|
||||
private $phpDocNodeByTypeFinder;
|
||||
|
@ -10,12 +10,10 @@ use Rector\Core\Util\Reflection\PrivatesAccessor;
|
||||
final class TokenIteratorFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\PhpDocParser\Lexer\Lexer
|
||||
*/
|
||||
private $lexer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Util\Reflection\PrivatesAccessor
|
||||
*/
|
||||
private $privatesAccessor;
|
||||
|
@ -15,7 +15,6 @@ use Rector\BetterPhpDocParser\ValueObject\PhpDocAttributeKey;
|
||||
final class PhpDocClassRenamer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\ClassAnnotationMatcher
|
||||
*/
|
||||
private $classAnnotationMatcher;
|
||||
|
@ -37,37 +37,30 @@ use Rector\TypeDeclaration\PhpDocParser\ParamPhpDocNodeFactory;
|
||||
final class PhpDocTypeChanger
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\TypeComparator\TypeComparator
|
||||
*/
|
||||
private $typeComparator;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\TypeDeclaration\PhpDocParser\ParamPhpDocNodeFactory
|
||||
*/
|
||||
private $paramPhpDocNodeFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Comment\CommentsMerger
|
||||
*/
|
||||
private $commentsMerger;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory
|
||||
*/
|
||||
private $phpDocInfoFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Guard\NewPhpDocFromPHPStanTypeGuard
|
||||
*/
|
||||
private $newPhpDocFromPHPStanTypeGuard;
|
||||
|
@ -10,7 +10,6 @@ use Rector\Naming\ValueObject\ParamRename;
|
||||
final class PropertyDocBlockManipulator
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory
|
||||
*/
|
||||
private $phpDocInfoFactory;
|
||||
|
@ -16,23 +16,19 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\ParentConnectingPhpDocNod
|
||||
final class PhpDocNodeMapper
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\DataProvider\CurrentTokenIteratorProvider
|
||||
*/
|
||||
private $currentTokenIteratorProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\ParentConnectingPhpDocNodeVisitor
|
||||
*/
|
||||
private $parentConnectingPhpDocNodeVisitor;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\CloningPhpDocNodeVisitor
|
||||
*/
|
||||
private $cloningPhpDocNodeVisitor;
|
||||
/**
|
||||
* @var BasePhpDocNodeVisitorInterface[]
|
||||
* @readonly
|
||||
*/
|
||||
private $phpDocNodeVisitors;
|
||||
/**
|
||||
|
@ -12,7 +12,6 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\AbstractPhpDocNodeVisitor
|
||||
final class ArrayTypePhpDocNodeVisitor extends AbstractPhpDocNodeVisitor implements BasePhpDocNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Attributes\AttributeMirrorer
|
||||
*/
|
||||
private $attributeMirrorer;
|
||||
|
@ -12,7 +12,6 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\AbstractPhpDocNodeVisitor
|
||||
final class CallableTypePhpDocNodeVisitor extends AbstractPhpDocNodeVisitor implements BasePhpDocNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Attributes\AttributeMirrorer
|
||||
*/
|
||||
private $attributeMirrorer;
|
||||
|
@ -12,7 +12,6 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\AbstractPhpDocNodeVisitor
|
||||
final class IntersectionTypeNodePhpDocNodeVisitor extends AbstractPhpDocNodeVisitor implements BasePhpDocNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Attributes\AttributeMirrorer
|
||||
*/
|
||||
private $attributeMirrorer;
|
||||
|
@ -18,12 +18,10 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\AbstractPhpDocNodeVisitor
|
||||
final class TemplatePhpDocNodeVisitor extends AbstractPhpDocNodeVisitor implements BasePhpDocNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\DataProvider\CurrentTokenIteratorProvider
|
||||
*/
|
||||
private $currentTokenIteratorProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Attributes\AttributeMirrorer
|
||||
*/
|
||||
private $attributeMirrorer;
|
||||
|
@ -17,12 +17,10 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeVisitor\AbstractPhpDocNodeVisitor
|
||||
final class UnionTypeNodePhpDocNodeVisitor extends AbstractPhpDocNodeVisitor implements BasePhpDocNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\DataProvider\CurrentTokenIteratorProvider
|
||||
*/
|
||||
private $currentTokenIteratorProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Attributes\AttributeMirrorer
|
||||
*/
|
||||
private $attributeMirrorer;
|
||||
|
@ -28,35 +28,31 @@ use Rector\Core\Util\Reflection\PrivatesAccessor;
|
||||
final class BetterPhpDocParser extends PhpDocParser
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\CurrentNodeProvider
|
||||
*/
|
||||
private $currentNodeProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\TokenIteratorFactory
|
||||
*/
|
||||
private $tokenIteratorFactory;
|
||||
/**
|
||||
* @var PhpDocNodeDecoratorInterface[]
|
||||
* @readonly
|
||||
*/
|
||||
private $phpDocNodeDecorators;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Util\Reflection\PrivatesAccessor
|
||||
* @var \Rector\Core\Util\Reflection\PrivatesAccessor|null
|
||||
*/
|
||||
private $privatesAccessor;
|
||||
/**
|
||||
* @param PhpDocNodeDecoratorInterface[] $phpDocNodeDecorators
|
||||
*/
|
||||
public function __construct(TypeParser $typeParser, ConstExprParser $constExprParser, CurrentNodeProvider $currentNodeProvider, TokenIteratorFactory $tokenIteratorFactory, array $phpDocNodeDecorators, PrivatesAccessor $privatesAccessor = null)
|
||||
public function __construct(TypeParser $typeParser, ConstExprParser $constExprParser, CurrentNodeProvider $currentNodeProvider, TokenIteratorFactory $tokenIteratorFactory, array $phpDocNodeDecorators, ?PrivatesAccessor $privatesAccessor = null)
|
||||
{
|
||||
$privatesAccessor = $privatesAccessor ?? new PrivatesAccessor();
|
||||
$this->currentNodeProvider = $currentNodeProvider;
|
||||
$this->tokenIteratorFactory = $tokenIteratorFactory;
|
||||
$this->phpDocNodeDecorators = $phpDocNodeDecorators;
|
||||
$this->privatesAccessor = $privatesAccessor;
|
||||
$this->privatesAccessor = $privatesAccessor ?? new PrivatesAccessor();
|
||||
parent::__construct($typeParser, $constExprParser);
|
||||
}
|
||||
public function parse(TokenIterator $tokenIterator) : PhpDocNode
|
||||
|
@ -13,7 +13,6 @@ use Rector\BetterPhpDocParser\ValueObject\StartAndEnd;
|
||||
final class BetterTypeParser extends TypeParser
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\TokenIteratorFactory
|
||||
*/
|
||||
private $tokenIteratorFactory;
|
||||
|
@ -19,17 +19,14 @@ use Rector\NodeTypeResolver\Node\AttributeKey;
|
||||
final class ClassAnnotationMatcher
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\CodingStyle\NodeAnalyzer\UseImportNameMatcher
|
||||
*/
|
||||
private $useImportNameMatcher;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Naming\Naming\UseImportsResolver
|
||||
*/
|
||||
private $useImportsResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
|
@ -19,12 +19,10 @@ use Rector\StaticTypeMapper\Naming\NameScopeFactory;
|
||||
final class ConstExprClassNameDecorator implements PhpDocNodeDecoratorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\Naming\NameScopeFactory
|
||||
*/
|
||||
private $nameScopeFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\PhpDocParser\PhpDocNodeTraverser
|
||||
*/
|
||||
private $phpDocNodeTraverser;
|
||||
|
@ -24,22 +24,18 @@ use Rector\Core\Util\StringUtils;
|
||||
final class DoctrineAnnotationDecorator implements PhpDocNodeDecoratorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\ClassAnnotationMatcher
|
||||
*/
|
||||
private $classAnnotationMatcher;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\StaticDoctrineAnnotationParser
|
||||
*/
|
||||
private $staticDoctrineAnnotationParser;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\TokenIteratorFactory
|
||||
*/
|
||||
private $tokenIteratorFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Attributes\AttributeMirrorer
|
||||
*/
|
||||
private $attributeMirrorer;
|
||||
|
@ -19,12 +19,10 @@ use Rector\BetterPhpDocParser\ValueObject\PhpDoc\DoctrineAnnotation\CurlyListNod
|
||||
final class StaticDoctrineAnnotationParser
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\StaticDoctrineAnnotationParser\PlainValueParser
|
||||
*/
|
||||
private $plainValueParser;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\StaticDoctrineAnnotationParser\ArrayParser
|
||||
*/
|
||||
private $arrayParser;
|
||||
|
@ -15,7 +15,6 @@ use Rector\BetterPhpDocParser\ValueObject\Parser\BetterTokenIterator;
|
||||
final class ArrayParser
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\StaticDoctrineAnnotationParser\PlainValueParser
|
||||
*/
|
||||
private $plainValueParser;
|
||||
|
@ -22,12 +22,10 @@ use RectorPrefix202306\Symfony\Contracts\Service\Attribute\Required;
|
||||
final class PlainValueParser
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocParser\ClassAnnotationMatcher
|
||||
*/
|
||||
private $classAnnotationMatcher;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\CurrentNodeProvider
|
||||
*/
|
||||
private $currentNodeProvider;
|
||||
|
@ -27,22 +27,18 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeTraverser;
|
||||
final class PhpDocInfoPrinter
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Printer\EmptyPhpDocDetector
|
||||
*/
|
||||
private $emptyPhpDocDetector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Printer\DocBlockInliner
|
||||
*/
|
||||
private $docBlockInliner;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Printer\RemoveNodesStartAndEndResolver
|
||||
*/
|
||||
private $removeNodesStartAndEndResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocNodeVisitor\ChangedPhpDocNodeVisitor
|
||||
*/
|
||||
private $changedPhpDocNodeVisitor;
|
||||
|
@ -10,7 +10,6 @@ final class CurlyListNode extends \Rector\BetterPhpDocParser\ValueObject\PhpDoc\
|
||||
{
|
||||
/**
|
||||
* @var ArrayItemNode[]
|
||||
* @readonly
|
||||
*/
|
||||
private $arrayItemNodes = [];
|
||||
/**
|
||||
|
@ -9,7 +9,6 @@ use Stringable;
|
||||
final class SpacingAwareTemplateTagValueNode extends TemplateTagValueNode
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $preposition;
|
||||
|
@ -7,12 +7,10 @@ use Rector\Core\Exception\ShouldNotHappenException;
|
||||
final class StartAndEnd
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var int
|
||||
*/
|
||||
private $start;
|
||||
/**
|
||||
* @readonly
|
||||
* @var int
|
||||
*/
|
||||
private $end;
|
||||
|
@ -9,7 +9,6 @@ use Stringable;
|
||||
final class BracketsAwareUnionTypeNode extends UnionTypeNode
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var bool
|
||||
*/
|
||||
private $isWrappedInBrackets = \false;
|
||||
|
@ -7,7 +7,6 @@ use Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface;
|
||||
final class Cache
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface
|
||||
*/
|
||||
private $cacheStorage;
|
||||
|
@ -11,12 +11,10 @@ use RectorPrefix202306\Symfony\Component\Filesystem\Filesystem;
|
||||
final class CacheFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\Parameter\ParameterProvider
|
||||
*/
|
||||
private $parameterProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Symfony\Component\Filesystem\Filesystem
|
||||
*/
|
||||
private $fileSystem;
|
||||
|
@ -15,17 +15,14 @@ use Rector\Core\Util\FileHasher;
|
||||
final class ChangedFilesDetector
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Caching\Config\FileHashComputer
|
||||
*/
|
||||
private $fileHashComputer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Caching\Cache
|
||||
*/
|
||||
private $cache;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Util\FileHasher
|
||||
*/
|
||||
private $fileHasher;
|
||||
|
@ -11,17 +11,14 @@ use Rector\Core\Util\Reflection\PrivatesAccessor;
|
||||
final class DependencyResolver
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Analyser\NodeScopeResolver
|
||||
*/
|
||||
private $nodeScopeResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var PHPStanDependencyResolver
|
||||
*/
|
||||
private $phpStanDependencyResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Util\Reflection\PrivatesAccessor
|
||||
*/
|
||||
private $privatesAccessor;
|
||||
|
@ -7,7 +7,6 @@ use Rector\Caching\Detector\ChangedFilesDetector;
|
||||
final class UnchangedFilesFilter
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Caching\Detector\ChangedFilesDetector
|
||||
*/
|
||||
private $changedFilesDetector;
|
||||
|
@ -6,17 +6,14 @@ namespace Rector\Caching\ValueObject;
|
||||
final class CacheFilePaths
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $firstDirectory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $secondDirectory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $filePath;
|
||||
|
@ -10,14 +10,9 @@ namespace Rector\Caching\ValueObject;
|
||||
final class CacheItem
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $variableKey;
|
||||
/**
|
||||
* @readonly
|
||||
* @var mixed
|
||||
*/
|
||||
private $data;
|
||||
/**
|
||||
* @param mixed $data
|
||||
|
@ -17,12 +17,10 @@ use Rector\Core\Exception\Cache\CachingException;
|
||||
final class FileCacheStorage implements CacheStorageInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $directory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Symfony\Component\Filesystem\Filesystem
|
||||
*/
|
||||
private $filesystem;
|
||||
|
@ -7,7 +7,6 @@ use Rector\Core\Contract\Rector\RectorInterface;
|
||||
final class RectorsChangelogResolver
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\ChangesReporting\Annotation\AnnotationExtractor
|
||||
*/
|
||||
private $annotationExtractor;
|
||||
|
@ -12,12 +12,10 @@ use Rector\Core\ValueObject\Application\File;
|
||||
final class RectorChangeCollector
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Logging\CurrentRectorProvider
|
||||
*/
|
||||
private $currentRectorProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Provider\CurrentFileProvider
|
||||
*/
|
||||
private $currentFileProvider;
|
||||
|
@ -14,12 +14,10 @@ use Rector\Core\ValueObject\Reporting\FileDiff;
|
||||
final class ConsoleOutputFormatter implements OutputFormatterInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Contract\Console\OutputStyleInterface
|
||||
*/
|
||||
private $rectorOutputStyle;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\ChangesReporting\Annotation\RectorsChangelogResolver
|
||||
*/
|
||||
private $rectorsChangelogResolver;
|
||||
|
@ -13,7 +13,6 @@ use Rector\Parallel\ValueObject\Bridge;
|
||||
final class JsonOutputFormatter implements OutputFormatterInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\ChangesReporting\Annotation\RectorsChangelogResolver
|
||||
*/
|
||||
private $rectorsChangelogResolver;
|
||||
|
@ -9,7 +9,6 @@ use RectorPrefix202306\Webmozart\Assert\Assert;
|
||||
final class RectorWithLineChange implements SerializableInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var int
|
||||
*/
|
||||
private $line;
|
||||
|
@ -10,12 +10,10 @@ use Rector\Core\ValueObject\Error\SystemError;
|
||||
final class ErrorFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Error\ExceptionCorrector
|
||||
*/
|
||||
private $exceptionCorrector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\FileSystem\FilePathHelper
|
||||
*/
|
||||
private $filePathHelper;
|
||||
|
@ -12,17 +12,14 @@ use Rector\Core\ValueObject\Reporting\FileDiff;
|
||||
final class FileDiffFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Differ\DefaultDiffer
|
||||
*/
|
||||
private $defaultDiffer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Console\Formatter\ConsoleDiffer
|
||||
*/
|
||||
private $consoleDiffer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\FileSystem\FilePathHelper
|
||||
*/
|
||||
private $filePathHelper;
|
||||
|
@ -11,7 +11,6 @@ use Rector\Comments\NodeTraverser\CommentRemovingNodeTraverser;
|
||||
final class CommentRemover
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Comments\NodeTraverser\CommentRemovingNodeTraverser
|
||||
*/
|
||||
private $commentRemovingNodeTraverser;
|
||||
|
@ -12,7 +12,6 @@ use Rector\NodeTypeResolver\Node\AttributeKey;
|
||||
final class DocBlockUpdater
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Printer\PhpDocInfoPrinter
|
||||
*/
|
||||
private $phpDocInfoPrinter;
|
||||
@ -36,20 +35,6 @@ final class DocBlockUpdater
|
||||
// this is needed to remove duplicated // commentsAsText
|
||||
$node->setDocComment(new Doc($phpDoc));
|
||||
}
|
||||
public function updateRefactoredNodeWithPhpDocInfo(Node $node) : void
|
||||
{
|
||||
// nothing to change? don't save it
|
||||
$phpDocInfo = $this->resolveChangedPhpDocInfo($node);
|
||||
if (!$phpDocInfo instanceof PhpDocInfo) {
|
||||
return;
|
||||
}
|
||||
$phpDocNode = $phpDocInfo->getPhpDocNode();
|
||||
if ($phpDocNode->children === []) {
|
||||
$this->setCommentsAttribute($node);
|
||||
return;
|
||||
}
|
||||
$node->setDocComment(new Doc((string) $phpDocNode));
|
||||
}
|
||||
private function setCommentsAttribute(Node $node) : void
|
||||
{
|
||||
if ($node->hasAttribute(AttributeKey::PREVIOUS_DOCS_AS_COMMENTS)) {
|
||||
|
@ -12,7 +12,6 @@ use Rector\FamilyTree\Reflection\FamilyRelationsAnalyzer;
|
||||
final class ClassChildAnalyzer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\FamilyTree\Reflection\FamilyRelationsAnalyzer
|
||||
*/
|
||||
private $familyRelationsAnalyzer;
|
||||
|
@ -14,22 +14,18 @@ use Rector\NodeNameResolver\NodeNameResolver;
|
||||
final class FamilyRelationsAnalyzer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Util\Reflection\PrivatesAccessor
|
||||
*/
|
||||
private $privatesAccessor;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\AstResolver
|
||||
*/
|
||||
private $astResolver;
|
||||
|
@ -15,17 +15,14 @@ use Rector\NodeTypeResolver\NodeScopeAndMetadataDecorator;
|
||||
final class FileInfoParser
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeScopeAndMetadataDecorator
|
||||
*/
|
||||
private $nodeScopeAndMetadataDecorator;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\NodeTraverser\FileWithoutNamespaceNodeTraverser
|
||||
*/
|
||||
private $fileWithoutNamespaceNodeTraverser;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Parser\RectorParser
|
||||
*/
|
||||
private $rectorParser;
|
||||
|
@ -33,27 +33,22 @@ use Rector\NodeTypeResolver\NodeTypeResolver;
|
||||
final class ArrayCallableMethodMatcher
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeTypeResolver
|
||||
*/
|
||||
private $nodeTypeResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\Value\ValueResolver
|
||||
*/
|
||||
private $valueResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
|
@ -8,17 +8,14 @@ use Rector\Core\Validation\RectorAssert;
|
||||
final class ArrayCallable
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PhpParser\Node\Expr
|
||||
*/
|
||||
private $callerExpr;
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $class;
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $method;
|
||||
|
@ -11,17 +11,14 @@ use Rector\Core\Validation\RectorAssert;
|
||||
final class ArrayCallableDynamicMethod
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PhpParser\Node\Expr
|
||||
*/
|
||||
private $callerExpr;
|
||||
/**
|
||||
* @readonly
|
||||
* @var string
|
||||
*/
|
||||
private $class;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PhpParser\Node\Expr
|
||||
*/
|
||||
private $method;
|
||||
|
@ -21,23 +21,19 @@ use Rector\NodeTypeResolver\Node\AttributeKey;
|
||||
final class NodeNameResolver
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\Regex\RegexPatternDetector
|
||||
*/
|
||||
private $regexPatternDetector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\CodingStyle\Naming\ClassNaming
|
||||
*/
|
||||
private $classNaming;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\NodeAnalyzer\CallAnalyzer
|
||||
*/
|
||||
private $callAnalyzer;
|
||||
/**
|
||||
* @var NodeNameResolverInterface[]
|
||||
* @readonly
|
||||
*/
|
||||
private $nodeNameResolvers = [];
|
||||
/**
|
||||
|
@ -17,7 +17,6 @@ use Rector\NodeTypeResolver\Node\AttributeKey;
|
||||
final class FuncCallNameResolver implements NodeNameResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
|
@ -15,7 +15,6 @@ use Rector\NodeTypeResolver\Node\AttributeKey;
|
||||
final class NameNameResolver implements NodeNameResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver\FuncCallNameResolver
|
||||
*/
|
||||
private $funcCallNameResolver;
|
||||
|
@ -13,7 +13,6 @@ use Rector\NodeNestingScope\ValueObject\ControlStructure;
|
||||
final class ContextAnalyzer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
|
@ -13,7 +13,6 @@ use Rector\Core\PhpParser\Node\BetterNodeFinder;
|
||||
final class ParentScopeFinder
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
|
@ -14,12 +14,10 @@ use Rector\NodeNestingScope\ValueObject\ControlStructure;
|
||||
final class ScopeNestingComparator
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Comparing\NodeComparator
|
||||
*/
|
||||
private $nodeComparator;
|
||||
|
@ -25,12 +25,10 @@ use RectorPrefix202306\Symfony\Component\Filesystem\Filesystem;
|
||||
final class PHPStanServicesFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\Parameter\ParameterProvider
|
||||
*/
|
||||
private $parameterProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\DependencyInjection\PHPStanExtensionsConfigResolver
|
||||
*/
|
||||
private $phpStanExtensionsConfigResolver;
|
||||
|
@ -13,7 +13,6 @@ use Rector\NodeTypeResolver\PHPStan\Scope\PHPStanNodeScopeResolver;
|
||||
final class NodeScopeAndMetadataDecorator
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\PHPStan\Scope\PHPStanNodeScopeResolver
|
||||
*/
|
||||
private $phpStanNodeScopeResolver;
|
||||
|
@ -12,7 +12,6 @@ use PHPStan\Type\TypeTraverser;
|
||||
final class GenericClassStringTypeCorrector
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
|
@ -43,32 +43,26 @@ use Rector\TypeDeclaration\PHPStan\ObjectTypeSpecifier;
|
||||
final class NodeTypeResolver
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\TypeDeclaration\PHPStan\ObjectTypeSpecifier
|
||||
*/
|
||||
private $objectTypeSpecifier;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\NodeAnalyzer\ClassAnalyzer
|
||||
*/
|
||||
private $classAnalyzer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeTypeCorrector\GenericClassStringTypeCorrector
|
||||
*/
|
||||
private $genericClassStringTypeCorrector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeTypeCorrector\AccessoryNonEmptyStringTypeCorrector
|
||||
*/
|
||||
private $accessoryNonEmptyStringTypeCorrector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\RenamedClassesDataCollector
|
||||
*/
|
||||
private $renamedClassesDataCollector;
|
||||
|
@ -23,7 +23,6 @@ use Rector\NodeTypeResolver\Node\AttributeKey;
|
||||
final class ClassAndInterfaceTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
|
@ -19,7 +19,6 @@ use RectorPrefix202306\Symfony\Contracts\Service\Attribute\Required;
|
||||
final class ClassMethodOrClassConstTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
|
@ -26,17 +26,14 @@ use Rector\NodeTypeResolver\Contract\NodeTypeResolverInterface;
|
||||
final class NameTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
|
@ -25,12 +25,10 @@ use Rector\StaticTypeMapper\ValueObject\Type\FullyQualifiedObjectType;
|
||||
final class NewTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\NodeAnalyzer\ClassAnalyzer
|
||||
*/
|
||||
private $classAnalyzer;
|
||||
|
@ -31,22 +31,18 @@ use RectorPrefix202306\Symfony\Contracts\Service\Attribute\Required;
|
||||
final class ParamTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser
|
||||
*/
|
||||
private $simpleCallableNodeTraverser;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory
|
||||
*/
|
||||
private $phpDocInfoFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
|
@ -25,17 +25,14 @@ use RectorPrefix202306\Symfony\Contracts\Service\Attribute\Required;
|
||||
final class PropertyFetchTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
|
@ -23,12 +23,10 @@ use RectorPrefix202306\Symfony\Contracts\Service\Attribute\Required;
|
||||
final class StaticCallMethodCallTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
|
@ -19,7 +19,6 @@ use Rector\NodeTypeResolver\Contract\NodeTypeResolverInterface;
|
||||
final class TraitTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
|
@ -20,12 +20,10 @@ use Rector\NodeTypeResolver\Node\AttributeKey;
|
||||
final class VariableTypeResolver implements NodeTypeResolverInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory
|
||||
*/
|
||||
private $phpDocInfoFactory;
|
||||
|
@ -10,7 +10,6 @@ final class ObjectWithoutClassTypeWithParentTypes extends ObjectWithoutClassType
|
||||
{
|
||||
/**
|
||||
* @var TypeWithClassName[]
|
||||
* @readonly
|
||||
*/
|
||||
private $parentTypes;
|
||||
/**
|
||||
|
@ -15,7 +15,6 @@ use Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser;
|
||||
final class ByRefReturnNodeVisitor extends NodeVisitorAbstract implements ScopeResolverNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser
|
||||
*/
|
||||
private $simpleCallableNodeTraverser;
|
||||
|
@ -16,7 +16,6 @@ use Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser;
|
||||
final class ByRefVariableNodeVisitor extends NodeVisitorAbstract implements ScopeResolverNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser
|
||||
*/
|
||||
private $simpleCallableNodeTraverser;
|
||||
|
@ -17,7 +17,6 @@ use Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser;
|
||||
final class GlobalVariableNodeVisitor extends NodeVisitorAbstract implements ScopeResolverNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser
|
||||
*/
|
||||
private $simpleCallableNodeTraverser;
|
||||
|
@ -19,7 +19,6 @@ use Rector\NodeTypeResolver\PHPStan\Scope\Contract\NodeVisitor\ScopeResolverNode
|
||||
final class RemoveDeepChainMethodCallNodeVisitor extends NodeVisitorAbstract implements ScopeResolverNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
|
@ -17,7 +17,6 @@ use Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser;
|
||||
final class StaticVariableNodeVisitor extends NodeVisitorAbstract implements ScopeResolverNodeVisitorInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PhpDocParser\NodeTraverser\SimpleCallableNodeTraverser
|
||||
*/
|
||||
private $simpleCallableNodeTraverser;
|
||||
|
@ -61,47 +61,38 @@ use RectorPrefix202306\Webmozart\Assert\Assert;
|
||||
final class PHPStanNodeScopeResolver
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Caching\Detector\ChangedFilesDetector
|
||||
*/
|
||||
private $changedFilesDetector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Caching\FileSystem\DependencyResolver
|
||||
*/
|
||||
private $dependencyResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Analyser\NodeScopeResolver
|
||||
*/
|
||||
private $nodeScopeResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\PHPStan\Scope\ScopeFactory
|
||||
*/
|
||||
private $scopeFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Util\Reflection\PrivatesAccessor
|
||||
*/
|
||||
private $privatesAccessor;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\NodeAnalyzer\ClassAnalyzer
|
||||
*/
|
||||
private $classAnalyzer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\NodeTraverser\FileWithoutNamespaceNodeTraverser
|
||||
*/
|
||||
private $fileWithoutNamespaceNodeTraverser;
|
||||
|
@ -9,7 +9,6 @@ use PHPStan\Analyser\ScopeFactory as PHPStanScopeFactory;
|
||||
final class ScopeFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var PHPStanScopeFactory
|
||||
*/
|
||||
private $phpStanScopeFactory;
|
||||
|
@ -15,7 +15,6 @@ use Rector\PHPStanStaticTypeMapper\TypeAnalyzer\UnionTypeAnalyzer;
|
||||
final class StaticTypeAnalyzer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PHPStanStaticTypeMapper\TypeAnalyzer\UnionTypeAnalyzer
|
||||
*/
|
||||
private $unionTypeAnalyzer;
|
||||
|
@ -21,7 +21,6 @@ use Rector\NodeTypeResolver\PHPStan\TypeHasher;
|
||||
final class TypeFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\PHPStan\TypeHasher
|
||||
*/
|
||||
private $typeHasher;
|
||||
|
@ -10,7 +10,6 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeTraverser;
|
||||
final class DocBlockClassRenamer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\PhpDocNodeVisitor\ClassRenamePhpDocNodeVisitor
|
||||
*/
|
||||
private $classRenamePhpDocNodeVisitor;
|
||||
|
@ -10,7 +10,6 @@ use Rector\PhpDocParser\PhpDocParser\PhpDocNodeTraverser;
|
||||
final class DocBlockNameImporter
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\PhpDocNodeVisitor\NameImportingPhpDocNodeVisitor
|
||||
*/
|
||||
private $nameImportingPhpDocNodeVisitor;
|
||||
|
@ -10,7 +10,6 @@ use Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfo;
|
||||
final class DocBlockTagReplacer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\Annotation\AnnotationNaming
|
||||
*/
|
||||
private $annotationNaming;
|
||||
|
@ -12,7 +12,6 @@ use Rector\StaticTypeMapper\StaticTypeMapper;
|
||||
final class PhpDocTypeRenamer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
|
@ -29,32 +29,26 @@ use Rector\StaticTypeMapper\ValueObject\Type\ShortenedObjectType;
|
||||
final class ClassRenamePhpDocNodeVisitor extends AbstractPhpDocNodeVisitor
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\CurrentNodeProvider
|
||||
*/
|
||||
private $currentNodeProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Naming\Naming\UseImportsResolver
|
||||
*/
|
||||
private $useImportsResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\RectorConfigProvider
|
||||
*/
|
||||
private $rectorConfigProvider;
|
||||
|
@ -26,32 +26,26 @@ use Rector\StaticTypeMapper\ValueObject\Type\FullyQualifiedObjectType;
|
||||
final class NameImportingPhpDocNodeVisitor extends AbstractPhpDocNodeVisitor
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\Parameter\ParameterProvider
|
||||
*/
|
||||
private $parameterProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\CodingStyle\ClassNameImport\ClassNameImportSkipper
|
||||
*/
|
||||
private $classNameImportSkipper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PostRector\Collector\UseNodesToAddCollector
|
||||
*/
|
||||
private $useNodesToAddCollector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Provider\CurrentFileProvider
|
||||
*/
|
||||
private $currentFileProvider;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
|
@ -13,17 +13,14 @@ use Rector\StaticTypeMapper\StaticTypeMapper;
|
||||
final class UnderscoreRenamePhpDocNodeVisitor extends AbstractPhpDocNodeVisitor
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Renaming\ValueObject\PseudoNamespaceToNamespace
|
||||
*/
|
||||
private $pseudoNamespaceToNamespace;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PhpParser\Node
|
||||
*/
|
||||
private $phpNode;
|
||||
|
@ -13,12 +13,10 @@ use Rector\NodeTypeResolver\Reflection\BetterReflection\SourceLocator\Intermedia
|
||||
final class RectorBetterReflectionSourceLocatorFactory
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\BetterReflection\BetterReflectionSourceLocatorFactory
|
||||
*/
|
||||
private $betterReflectionSourceLocatorFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\Reflection\BetterReflection\SourceLocator\IntermediateSourceLocator
|
||||
*/
|
||||
private $intermediateSourceLocator;
|
||||
|
@ -12,7 +12,6 @@ use Rector\NodeTypeResolver\Reflection\BetterReflection\SourceLocatorProvider\Dy
|
||||
final class IntermediateSourceLocator implements SourceLocator
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\Reflection\BetterReflection\SourceLocatorProvider\DynamicSourceLocatorProvider
|
||||
*/
|
||||
private $dynamicSourceLocatorProvider;
|
||||
|
@ -17,12 +17,10 @@ use RectorPrefix202306\Webmozart\Assert\Assert;
|
||||
final class DynamicSourceLocatorProvider
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\BetterReflection\SourceLocator\FileNodesFetcher
|
||||
*/
|
||||
private $fileNodesFetcher;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Php\PhpVersion
|
||||
*/
|
||||
private $phpVersion;
|
||||
|
@ -27,27 +27,22 @@ use Rector\NodeTypeResolver\NodeTypeResolver;
|
||||
final class ArrayTypeAnalyzer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeNameResolver\NodeNameResolver
|
||||
*/
|
||||
private $nodeNameResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeTypeResolver
|
||||
*/
|
||||
private $nodeTypeResolver;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\PhpParser\Node\BetterNodeFinder
|
||||
*/
|
||||
private $betterNodeFinder;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory
|
||||
*/
|
||||
private $phpDocInfoFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Reflection\ReflectionResolver
|
||||
*/
|
||||
private $reflectionResolver;
|
||||
|
@ -9,12 +9,10 @@ use Rector\NodeTypeResolver\NodeTypeResolver;
|
||||
final class CountableTypeAnalyzer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\TypeAnalyzer\ArrayTypeAnalyzer
|
||||
*/
|
||||
private $arrayTypeAnalyzer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeTypeResolver
|
||||
*/
|
||||
private $nodeTypeResolver;
|
||||
|
@ -8,7 +8,6 @@ use Rector\NodeTypeResolver\NodeTypeResolver;
|
||||
final class StringTypeAnalyzer
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeTypeResolver
|
||||
*/
|
||||
private $nodeTypeResolver;
|
||||
|
@ -14,7 +14,6 @@ use Rector\PHPStanStaticTypeMapper\TypeAnalyzer\UnionTypeCommonTypeNarrower;
|
||||
final class ArrayTypeComparator
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\PHPStanStaticTypeMapper\TypeAnalyzer\UnionTypeCommonTypeNarrower
|
||||
*/
|
||||
private $unionTypeCommonTypeNarrower;
|
||||
|
@ -31,37 +31,30 @@ use Rector\TypeDeclaration\TypeNormalizer;
|
||||
final class TypeComparator
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\PHPStan\TypeHasher
|
||||
*/
|
||||
private $typeHasher;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\TypeDeclaration\TypeNormalizer
|
||||
*/
|
||||
private $typeNormalizer;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\StaticTypeMapper\StaticTypeMapper
|
||||
*/
|
||||
private $staticTypeMapper;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\TypeComparator\ArrayTypeComparator
|
||||
*/
|
||||
private $arrayTypeComparator;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\TypeComparator\ScalarTypeComparator
|
||||
*/
|
||||
private $scalarTypeComparator;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\PHPStan\Type\TypeFactory
|
||||
*/
|
||||
private $typeFactory;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Reflection\ReflectionResolver
|
||||
*/
|
||||
private $reflectionResolver;
|
||||
|
@ -7,12 +7,10 @@ use PHPStan\Type\Type;
|
||||
final class OldToNewType
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Type\Type
|
||||
*/
|
||||
private $oldType;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Type\Type
|
||||
*/
|
||||
private $newType;
|
||||
|
@ -18,7 +18,6 @@ final class PHPStanStaticTypeMapper
|
||||
{
|
||||
/**
|
||||
* @var TypeMapperInterface[]
|
||||
* @readonly
|
||||
*/
|
||||
private $typeMappers;
|
||||
/**
|
||||
|
@ -21,12 +21,10 @@ use Rector\NodeTypeResolver\NodeTypeCorrector\GenericClassStringTypeCorrector;
|
||||
final class UnionTypeCommonTypeNarrower
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\NodeTypeResolver\NodeTypeCorrector\GenericClassStringTypeCorrector
|
||||
*/
|
||||
private $genericClassStringTypeCorrector;
|
||||
/**
|
||||
* @readonly
|
||||
* @var \PHPStan\Reflection\ReflectionProvider
|
||||
*/
|
||||
private $reflectionProvider;
|
||||
|
@ -18,7 +18,6 @@ use Rector\PHPStanStaticTypeMapper\Contract\TypeMapperInterface;
|
||||
final class AccessoryLiteralStringTypeMapper implements TypeMapperInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Php\PhpVersionProvider
|
||||
*/
|
||||
private $phpVersionProvider;
|
||||
|
@ -18,7 +18,6 @@ use Rector\PHPStanStaticTypeMapper\Contract\TypeMapperInterface;
|
||||
final class AccessoryNonEmptyStringTypeMapper implements TypeMapperInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Php\PhpVersionProvider
|
||||
*/
|
||||
private $phpVersionProvider;
|
||||
|
@ -18,7 +18,6 @@ use Rector\PHPStanStaticTypeMapper\Contract\TypeMapperInterface;
|
||||
final class AccessoryNonFalsyStringTypeMapper implements TypeMapperInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Php\PhpVersionProvider
|
||||
*/
|
||||
private $phpVersionProvider;
|
||||
|
@ -18,7 +18,6 @@ use Rector\PHPStanStaticTypeMapper\Contract\TypeMapperInterface;
|
||||
final class AccessoryNumericStringTypeMapper implements TypeMapperInterface
|
||||
{
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Php\PhpVersionProvider
|
||||
*/
|
||||
private $phpVersionProvider;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user