File tree Expand file tree Collapse file tree
rules/TypeDeclaration/Rector/ClassMethod Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1010use PhpParser \Node \Stmt \Class_ ;
1111use Rector \Rector \AbstractRector ;
1212use Rector \ValueObject \MethodName ;
13+ use Rector \ValueObject \PhpVersionFeature ;
14+ use Rector \VersionBonding \Contract \MinPhpVersionInterface ;
1315use Symplify \RuleDocGenerator \ValueObject \CodeSample \CodeSample ;
1416use Symplify \RuleDocGenerator \ValueObject \RuleDefinition ;
1517
1820 *
1921 * @see https://www.php.net/manual/en/language.oop5.overloading.php#object.call
2022 */
21- final class KnownMagicClassMethodTypeRector extends AbstractRector
23+ final class KnownMagicClassMethodTypeRector extends AbstractRector implements MinPhpVersionInterface
2224{
2325 public function getRuleDefinition (): RuleDefinition
2426 {
@@ -89,4 +91,9 @@ public function refactor(Node $node): ?Node
8991
9092 return null ;
9193 }
94+
95+ public function provideMinPhpVersion (): int
96+ {
97+ return PhpVersionFeature::SCALAR_TYPES ;
98+ }
9299}
You can’t perform that action at this time.
0 commit comments