Skip to content

Commit

Permalink
[automated] Re-Generate Nodes/Rectors Documentation (#5599)
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 Feb 11, 2024
1 parent fbc391a commit f4c674c
Showing 1 changed file with 46 additions and 3 deletions.
49 changes: 46 additions & 3 deletions build/target-repository/docs/rector_rules_overview.md
@@ -1,4 +1,4 @@
# 355 Rules Overview
# 358 Rules Overview

<br>

Expand Down Expand Up @@ -54,9 +54,9 @@

- [Strict](#strict) (5)

- [Transform](#transform) (22)
- [Transform](#transform) (23)

- [TypeDeclaration](#typedeclaration) (40)
- [TypeDeclaration](#typedeclaration) (42)

- [Visibility](#visibility) (3)

Expand Down Expand Up @@ -6085,6 +6085,21 @@ Replaces properties assign calls be defined methods.

<br>

### RectorConfigBuilderRector

Change RectorConfig to RectorConfigBuilder

- class: [`Rector\Transform\Rector\FileWithoutNamespace\RectorConfigBuilderRector`](../rules/Transform/Rector/FileWithoutNamespace/RectorConfigBuilderRector.php)

```diff
-return static function (RectorConfig $rectorConfig): void {
- $rectorConfig->rule(SomeRector::class);
-};
+return RectorConfig::configure()->rules([SomeRector::class]);
```

<br>

### ReplaceParentCallByPropertyCallRector

Changes method calls in child of specific types to defined property method call
Expand Down Expand Up @@ -6253,6 +6268,34 @@ Add known return type to arrow function

<br>

### AddClosureVoidReturnTypeWhereNoReturnRector

Add closure return type void if there is no return

- class: [`Rector\TypeDeclaration\Rector\Closure\AddClosureVoidReturnTypeWhereNoReturnRector`](../rules/TypeDeclaration/Rector/Closure/AddClosureVoidReturnTypeWhereNoReturnRector.php)

```diff
-function () {
+function (): void {
}
```

<br>

### AddFunctionVoidReturnTypeWhereNoReturnRector

Add function return type void if there is no return

- class: [`Rector\TypeDeclaration\Rector\Function_\AddFunctionVoidReturnTypeWhereNoReturnRector`](../rules/TypeDeclaration/Rector/Function_/AddFunctionVoidReturnTypeWhereNoReturnRector.php)

```diff
-function restore() {
+function restore(): void {
}
```

<br>

### AddMethodCallBasedStrictParamTypeRector

Change private method param type to strict type, based on passed strict types
Expand Down

0 comments on commit f4c674c

Please sign in to comment.