Skip to content

Commit

Permalink
[CodeQuality] Drop ArrayThisCallToThisMethodCallRector as changes beh…
Browse files Browse the repository at this point in the history
…avior and better handled by FirstClassCallableRector (#2571)
  • Loading branch information
TomasVotruba committed Jun 26, 2022
1 parent 237f255 commit 80715e6
Show file tree
Hide file tree
Showing 15 changed files with 2 additions and 405 deletions.
28 changes: 2 additions & 26 deletions build/target-repository/docs/rector_rules_overview.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# 520 Rules Overview
# 519 Rules Overview

<br>

## Categories

- [Arguments](#arguments) (5)

- [CodeQuality](#codequality) (73)
- [CodeQuality](#codequality) (72)

- [CodingStyle](#codingstyle) (35)

Expand Down Expand Up @@ -390,30 +390,6 @@ Change array_merge of non arrays to array directly

<br>

### ArrayThisCallToThisMethodCallRector

Change `[$this, someMethod]` without any args to `$this->someMethod()`

- class: [`Rector\CodeQuality\Rector\Array_\ArrayThisCallToThisMethodCallRector`](../rules/CodeQuality/Rector/Array_/ArrayThisCallToThisMethodCallRector.php)

```diff
class SomeClass
{
public function run()
{
- $values = [$this, 'giveMeMore'];
+ $values = $this->giveMeMore();
}

public function giveMeMore()
{
return 'more';
}
}
```

<br>

### BooleanNotIdenticalToNotIdenticalRector

Negated identical boolean compare to not identical compare (does not apply to non-bool values)
Expand Down
2 changes: 0 additions & 2 deletions config/set/code-quality.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

declare(strict_types=1);

use Rector\CodeQuality\Rector\Array_\ArrayThisCallToThisMethodCallRector;
use Rector\CodeQuality\Rector\Array_\CallableThisArrayToAnonymousFunctionRector;
use Rector\CodeQuality\Rector\Assign\CombinedAssignRector;
use Rector\CodeQuality\Rector\Assign\SplitListAssignToSeparateLineRector;
Expand Down Expand Up @@ -162,7 +161,6 @@
ArrayKeysAndInArrayToArrayKeyExistsRector::class,
SplitListAssignToSeparateLineRector::class,
UnusedForeachValueToArrayKeysRector::class,
ArrayThisCallToThisMethodCallRector::class,
CommonNotEqualRector::class,
SetTypeToCastRector::class,
LogicalToBooleanRector::class,
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

0 comments on commit 80715e6

Please sign in to comment.