Skip to content

Commit

Permalink
[automated] Re-Generate Nodes/Rectors Documentation (#4665)
Browse files Browse the repository at this point in the history
Co-authored-by: TomasVotruba <TomasVotruba@users.noreply.github.com>
  • Loading branch information
TomasVotruba and TomasVotruba committed Aug 6, 2023
1 parent 4cfe654 commit 44e0216
Showing 1 changed file with 19 additions and 15 deletions.
34 changes: 19 additions & 15 deletions build/target-repository/docs/rector_rules_overview.md
@@ -1,4 +1,4 @@
# 362 Rules Overview
# 361 Rules Overview

<br>

Expand All @@ -14,6 +14,8 @@

- [EarlyReturn](#earlyreturn) (9)

- [Instanceof_](#instanceof) (1)

- [Naming](#naming) (6)

- [Php52](#php52) (2)
Expand Down Expand Up @@ -52,7 +54,7 @@

- [Transform](#transform) (22)

- [TypeDeclaration](#typedeclaration) (44)
- [TypeDeclaration](#typedeclaration) (43)

- [Visibility](#visibility) (3)

Expand Down Expand Up @@ -3382,6 +3384,21 @@ Replace if conditioned variable override with direct return

<br>

## Instanceof_

### FlipNegatedTernaryInstanceofRector

Flip negated ternary of instanceof to direct use of object

- class: [`Rector\Instanceof_\Rector\Ternary\FlipNegatedTernaryInstanceofRector`](../rules/Instanceof_/Rector/Ternary/FlipNegatedTernaryInstanceofRector.php)

```diff
-echo ! $object instanceof Product ? null : $object->getPrice();
+echo $object instanceof Product ? $object->getPrice() : null;
```

<br>

## Naming

### RenameForeachValueVariableToMatchExprVariableRector
Expand Down Expand Up @@ -7722,19 +7739,6 @@ Change `empty()` on nullable object to instanceof check

<br>

### FlipNegatedTernaryInstanceofRector

Flip negated ternary of instanceof to direct use of object

- class: [`Rector\TypeDeclaration\Rector\Ternary\FlipNegatedTernaryInstanceofRector`](../rules/TypeDeclaration/Rector/Ternary/FlipNegatedTernaryInstanceofRector.php)

```diff
-echo ! $object instanceof Product ? null : $object->getPrice();
+echo $object instanceof Product ? $object->getPrice() : null;
```

<br>

### NumericReturnTypeFromStrictScalarReturnsRector

Change numeric return type based on strict returns type operations
Expand Down

0 comments on commit 44e0216

Please sign in to comment.