diff --git a/composer.json b/composer.json index 58c64141..a67414ff 100644 --- a/composer.json +++ b/composer.json @@ -8,13 +8,13 @@ }, "require-dev": { "phpstan/extension-installer": "^1.3", - "phpstan/phpstan": "^1.9", + "phpstan/phpstan": "^1.10", "phpstan/phpstan-deprecation-rules": "^1.1", "phpstan/phpstan-webmozart-assert": "^1.2", "phpunit/phpunit": "^10.3", "rector/phpstan-rules": "^0.7", "rector/rector-generator": "^0.7.3", - "rector/rector-src": "dev-tv-narrow-abstract-10", + "rector/rector-src": "dev-tv-less-autowire", "symplify/easy-ci": "^11.2", "symplify/easy-coding-standard": "^12.0", "symplify/phpstan-extensions": "^11.3", diff --git a/rules/DowngradePhp74/Rector/ClassMethod/DowngradeCovariantReturnTypeRector.php b/rules/DowngradePhp74/Rector/ClassMethod/DowngradeCovariantReturnTypeRector.php index 8c1844c5..6c8509a4 100644 --- a/rules/DowngradePhp74/Rector/ClassMethod/DowngradeCovariantReturnTypeRector.php +++ b/rules/DowngradePhp74/Rector/ClassMethod/DowngradeCovariantReturnTypeRector.php @@ -18,6 +18,7 @@ use PHPStan\Type\StaticType; use PHPStan\Type\ThisType; use PHPStan\Type\Type; +use Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory; use Rector\BetterPhpDocParser\PhpDocManipulator\PhpDocTypeChanger; use Rector\Comments\NodeDocBlock\DocBlockUpdater; use Rector\Core\Rector\AbstractRector; @@ -45,6 +46,7 @@ public function __construct( private readonly PrivatesAccessor $privatesAccessor, private readonly UnionTypeAnalyzer $unionTypeAnalyzer, private readonly DocBlockUpdater $docBlockUpdater, + private readonly PhpDocInfoFactory $phpDocInfoFactory, ) { } diff --git a/rules/DowngradePhp80/Rector/Class_/DowngradePropertyPromotionRector.php b/rules/DowngradePhp80/Rector/Class_/DowngradePropertyPromotionRector.php index bf9c06f6..245a9549 100644 --- a/rules/DowngradePhp80/Rector/Class_/DowngradePropertyPromotionRector.php +++ b/rules/DowngradePhp80/Rector/Class_/DowngradePropertyPromotionRector.php @@ -16,6 +16,7 @@ use PhpParser\Node\Stmt\PropertyProperty; use PHPStan\PhpDocParser\Ast\PhpDoc\ParamTagValueNode; use Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfo; +use Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory; use Rector\BetterPhpDocParser\PhpDocManipulator\PhpDocTypeChanger; use Rector\Core\PhpParser\Printer\BetterStandardPrinter; use Rector\Core\Rector\AbstractRector; @@ -34,6 +35,7 @@ final class DowngradePropertyPromotionRector extends AbstractRector public function __construct( private readonly PhpDocTypeChanger $phpDocTypeChanger, private readonly BetterStandardPrinter $betterStandardPrinter, + private readonly PhpDocInfoFactory $phpDocInfoFactory, ) { } diff --git a/rules/DowngradePhp80/Rector/Enum_/DowngradeEnumToConstantListClassRector.php b/rules/DowngradePhp80/Rector/Enum_/DowngradeEnumToConstantListClassRector.php index 4f366226..eafdc18e 100644 --- a/rules/DowngradePhp80/Rector/Enum_/DowngradeEnumToConstantListClassRector.php +++ b/rules/DowngradePhp80/Rector/Enum_/DowngradeEnumToConstantListClassRector.php @@ -19,6 +19,7 @@ use PHPStan\Reflection\ClassReflection; use PHPStan\Reflection\ReflectionProvider; use Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfo; +use Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory; use Rector\Comments\NodeDocBlock\DocBlockUpdater; use Rector\Core\Rector\AbstractRector; use Rector\DowngradePhp80\NodeAnalyzer\EnumAnalyzer; @@ -36,6 +37,7 @@ public function __construct( private readonly ReflectionProvider $reflectionProvider, private readonly EnumAnalyzer $enumAnalyzer, private readonly DocBlockUpdater $docBlockUpdater, + private readonly PhpDocInfoFactory $phpDocInfoFactory, ) { } diff --git a/rules/DowngradePhp81/Rector/Property/DowngradeReadonlyPropertyRector.php b/rules/DowngradePhp81/Rector/Property/DowngradeReadonlyPropertyRector.php index fb783cef..7f2aa1c0 100644 --- a/rules/DowngradePhp81/Rector/Property/DowngradeReadonlyPropertyRector.php +++ b/rules/DowngradePhp81/Rector/Property/DowngradeReadonlyPropertyRector.php @@ -9,6 +9,7 @@ use PhpParser\Node\Stmt\Property; use PHPStan\PhpDocParser\Ast\PhpDoc\GenericTagValueNode; use PHPStan\PhpDocParser\Ast\PhpDoc\PhpDocTagNode; +use Rector\BetterPhpDocParser\PhpDocInfo\PhpDocInfoFactory; use Rector\Comments\NodeDocBlock\DocBlockUpdater; use Rector\Core\Rector\AbstractRector; use Rector\Privatization\NodeManipulator\VisibilityManipulator; @@ -30,6 +31,7 @@ final class DowngradeReadonlyPropertyRector extends AbstractRector public function __construct( private readonly VisibilityManipulator $visibilityManipulator, private readonly DocBlockUpdater $docBlockUpdater, + protected PhpDocInfoFactory $phpDocInfoFactory, ) { }