diff --git a/rector.php b/rector.php index 29227a82a..d2a8c3682 100644 --- a/rector.php +++ b/rector.php @@ -11,8 +11,6 @@ use Rector\DeadCode\Rector\ClassMethod\RemoveUnusedPrivateMethodRector; use Rector\DeadCode\Rector\ClassMethod\RemoveUnusedPromotedPropertyRector; use Rector\DeadCode\Rector\ClassMethod\RemoveUnusedPublicMethodParameterRector; -use Rector\DeadCode\Rector\ClassMethod\RemoveUselessParamTagRector; -use Rector\DeadCode\Rector\ClassMethod\RemoveUselessReturnTagRector; use Rector\DeadCode\Rector\Expression\RemoveDeadStmtRector; use Rector\DeadCode\Rector\If_\RemoveAlwaysTrueIfConditionRector; use Rector\DeadCode\Rector\Property\RemoveUselessVarTagRector; @@ -111,16 +109,6 @@ // ArrayAccess usage __DIR__ . '/src/Session/tests/SessionTest.php', ], - - // nullable @template usage, see https://github.com/rectorphp/rector-src/pull/6409 - // can be re-enabled on next rector release - RemoveUselessParamTagRector::class => [ - __DIR__ . '/src/Interceptors/src/Context/Target.php', - ], - - RemoveUselessReturnTagRector::class => [ - __DIR__ . '/src/Interceptors/src/Context/TargetInterface.php', - ], ]) ->withPhpSets(php81: true) ->withPreparedSets(deadCode: true, phpunit: true) diff --git a/src/Interceptors/src/Context/Target.php b/src/Interceptors/src/Context/Target.php index 291a93068..841c08701 100644 --- a/src/Interceptors/src/Context/Target.php +++ b/src/Interceptors/src/Context/Target.php @@ -12,7 +12,7 @@ final class Target implements TargetInterface { /** * @param list $path - * @param TController|null $object + * @param TController $object * @param \Closure|array{class-string|object, non-empty-string}|null $callable */ private function __construct( diff --git a/src/Interceptors/src/Context/TargetInterface.php b/src/Interceptors/src/Context/TargetInterface.php index fb9cc3854..559b2ad0b 100644 --- a/src/Interceptors/src/Context/TargetInterface.php +++ b/src/Interceptors/src/Context/TargetInterface.php @@ -48,7 +48,7 @@ public function getReflection(): ?\ReflectionFunctionAbstract; * * If the object is present, it always corresponds to the method reflection from {@see getReflection()}. * - * @return TController|null + * @return TController */ public function getObject(): ?object;