mirror of
https://github.com/rectorphp/rector.git
synced 2025-02-23 11:14:38 +01:00
f9de5d311e
[Php80] Handle RenameClassRector+AnnotationToAttributeRector with auto import and existing attribute defined (#5219)
19 lines
737 B
PHP
19 lines
737 B
PHP
<?php
|
|
|
|
declare (strict_types=1);
|
|
namespace RectorPrefix202311;
|
|
|
|
use Rector\Config\RectorConfig;
|
|
use Rector\Php52\Rector\Property\VarToPublicPropertyRector;
|
|
use Rector\Php52\Rector\Switch_\ContinueToBreakInSwitchRector;
|
|
use Rector\Removing\Rector\FuncCall\RemoveFuncCallArgRector;
|
|
use Rector\Removing\ValueObject\RemoveFuncCallArg;
|
|
return static function (RectorConfig $rectorConfig) : void {
|
|
$rectorConfig->rule(VarToPublicPropertyRector::class);
|
|
$rectorConfig->rule(ContinueToBreakInSwitchRector::class);
|
|
$rectorConfig->ruleWithConfiguration(RemoveFuncCallArgRector::class, [
|
|
// see https://www.php.net/manual/en/function.ldap-first-attribute.php
|
|
new RemoveFuncCallArg('ldap_first_attribute', 2),
|
|
]);
|
|
};
|