From 0dfd64b8b5e82048f72d4cf1dbfb4906a2ec41b6 Mon Sep 17 00:00:00 2001 From: yaozm Date: Mon, 8 Jan 2024 16:15:36 +0800 Subject: [PATCH] refactor(coding-style): remove unused Rectors - Remove AddArrayDefaultToArrayPropertyRector - Remove UnSpreadOperatorRector --- rector.php | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/rector.php b/rector.php index 61b30ed..ba2f3f4 100644 --- a/rector.php +++ b/rector.php @@ -18,8 +18,6 @@ use Rector\CodeQuality\Rector\If_\ExplicitBoolCompareRector; use Rector\CodeQuality\Rector\LogicalAnd\LogicalToBooleanRector; use Rector\CodingStyle\Rector\ArrowFunction\StaticArrowFunctionRector; -use Rector\CodingStyle\Rector\Class_\AddArrayDefaultToArrayPropertyRector; -use Rector\CodingStyle\Rector\ClassMethod\UnSpreadOperatorRector; use Rector\CodingStyle\Rector\Closure\StaticClosureRector; use Rector\CodingStyle\Rector\Encapsed\EncapsedStringsToSprintfRector; use Rector\CodingStyle\Rector\Encapsed\WrapEncapsedVariableInCurlyBracesRector; @@ -45,6 +43,11 @@ use Rector\Strict\Rector\Empty_\DisallowedEmptyRuleFixerRector; return static function (RectorConfig $rectorConfig): void { + define('MHASH_XXH3', 1); + define('MHASH_XXH32', 1); + define('MHASH_XXH64', 1); + define('MHASH_XXH128', 1); + $rectorConfig->importNames(false, false); $rectorConfig->importShortClasses(false); // $rectorConfig->disableParallel(); @@ -82,7 +85,6 @@ $rectorConfig->skip([ // rules - // AddArrayDefaultToArrayPropertyRector::class, // CallableThisArrayToAnonymousFunctionRector::class, // ChangeAndIfToEarlyReturnRector::class, // ExplicitBoolCompareRector::class, @@ -91,7 +93,6 @@ // ReturnBinaryOrToEarlyReturnRector::class, // SimplifyBoolIdenticalTrueRector::class, // StaticClosureRector::class, - // UnSpreadOperatorRector::class, EncapsedStringsToSprintfRector::class, // InlineIfToExplicitIfRector::class, @@ -125,9 +126,6 @@ // ReturnEarlyIfVariableRector::class => [ // __DIR__.'/src/Support/EscapeArg.php', // ], - // UnSpreadOperatorRector::class => [ - // __DIR__.'/src/Concerns/WithDumpable.php', - // ], // paths __DIR__.'/tests/AspectMock',