From 537755a44aa892cc2495ff8fa308ce44d74aa891 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 31 Jan 2021 09:12:01 +0100 Subject: [PATCH] [automated] Re-Generate Nodes/Rectors Documentation (#5387) Co-authored-by: kodiakhq --- docs/rector_rules_overview.md | 49 ++++++++++++++++++++++++----------- 1 file changed, 34 insertions(+), 15 deletions(-) diff --git a/docs/rector_rules_overview.md b/docs/rector_rules_overview.md index b10e11fc14c..38469e1e0be 100644 --- a/docs/rector_rules_overview.md +++ b/docs/rector_rules_overview.md @@ -1,4 +1,4 @@ -# 661 Rules Overview +# 662 Rules Overview
@@ -20,7 +20,7 @@ - [DeadCode](#deadcode) (47) -- [DeadDocBlock](#deaddocblock) (4) +- [DeadDocBlock](#deaddocblock) (5) - [Defluent](#defluent) (8) @@ -252,8 +252,12 @@ return static function (ContainerConfigurator $containerConfigurator): void { $services->set(MoveValueObjectsToValueObjectDirectoryRector::class) ->call('configure', [[ - MoveValueObjectsToValueObjectDirectoryRector::TYPES => ['ValueObjectInterfaceClassName'], - MoveValueObjectsToValueObjectDirectoryRector::SUFFIXES => ['Search'], + MoveValueObjectsToValueObjectDirectoryRector::TYPES => [ + 'ValueObjectInterfaceClassName', + ], + MoveValueObjectsToValueObjectDirectoryRector::SUFFIXES => [ + 'Search', + ], MoveValueObjectsToValueObjectDirectoryRector::ENABLE_VALUE_OBJECT_GUESSING => true, ]]); }; @@ -2492,7 +2496,7 @@ return static function (ContainerConfigurator $containerConfigurator): void { ### SplitDoubleAssignRector -Split multiple inline assigns to each own lines default value, to prevent undefined array issues +Split multiple inline assigns to `each` own lines default value, to prevent undefined array issues - class: `Rector\CodingStyle\Rector\Assign\SplitDoubleAssignRector` @@ -4092,6 +4096,24 @@ Remove `@return` docblock with same type as defined in PHP
+### RemoveUselessVarTagRector + +Remove unused `@var` annotation for properties + +- class: `Rector\DeadDocBlock\Rector\Property\RemoveUselessVarTagRector` + +```diff + final class SomeClass + { +- /** +- * @var string +- */ + public string $name = 'name'; + } +``` + +
+ ## Defluent ### DefluentReturnMethodCallRector @@ -6912,10 +6934,7 @@ return static function (ContainerConfigurator $containerConfigurator): void { $services->set(InjectAnnotationClassRector::class) ->call('configure', [[ - InjectAnnotationClassRector::ANNOTATION_CLASSES => [ - 'DI\Annotation\Inject', - 'JMS\DiExtraBundle\Annotation\Inject', - ], + InjectAnnotationClassRector::ANNOTATION_CLASSES => ['DI\Annotation\Inject', 'JMS\DiExtraBundle\Annotation\Inject'], ]]); }; ``` @@ -7448,7 +7467,10 @@ return static function (ContainerConfigurator $containerConfigurator): void { $services->set(AddTopIncludeRector::class) ->call('configure', [[ AddTopIncludeRector::AUTOLOAD_FILE_PATH => '/../autoloader.php', - AddTopIncludeRector::PATTERNS => ['pat*/*/?ame.php', 'somepath/?ame.php'], + AddTopIncludeRector::PATTERNS => [ + 'pat*/*/?ame.php', + 'somepath/?ame.php', + ], ]]); }; ``` @@ -13452,7 +13474,7 @@ return static function (ContainerConfigurator $containerConfigurator): void { ### PassFactoryToUniqueObjectRector -Convert new `X/Static::call()` to factories in entities, pass them via constructor to each other +Convert new `X/Static::call()` to factories in entities, pass them via constructor to `each` other :wrench: **configure it!** @@ -14430,10 +14452,7 @@ return static function (ContainerConfigurator $containerConfigurator): void { $services->set(GetToConstructorInjectionRector::class) ->call('configure', [[ - GetToConstructorInjectionRector::GET_METHOD_AWARE_TYPES => [ - 'SymfonyControllerClassName', - 'GetTraitClassName', - ], + GetToConstructorInjectionRector::GET_METHOD_AWARE_TYPES => ['SymfonyControllerClassName', 'GetTraitClassName'], ]]); }; ```