34 Commits

Author SHA1 Message Date
Tomas Votruba
5a35553a2f
[PHP 8.0] Add Annotation to Attribute rule based on php-parser (#4292)
* monorepob-builder: add v prefix

* monorepob-builder: add v prefix

* [PHP 8.0] Add Annotation to Attribute rule based on php-parser

* [rector] [PHP 8.0] Add Annotation to Attribute rule based on php-parser

* [cs] [PHP 8.0] Add Annotation to Attribute rule based on php-parser

Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-25 08:17:36 +00:00
Igor
f2ecdeb0b1
[Naming] Foreach over "data", renames to "datum" (#4221)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-15 10:23:13 +02:00
Tomas Votruba
7ac228c638
[CI] Add type-declaration set (#4089)
* [CI] Add type-declaration set

* [rector] [CI] Add type-declaration set

* [cs] [CI] Add type-declaration set

* skip nullable void

* add anonymous parent/interface support

* refactor MultiExceptionCatchRector to use Catch_ over integers

* type fixes

* fix unoin array type override

* remove unused test cases

* drop overcomplicated InlineValidationRulesToArrayDefinitionRector

* skip assign on var

* [rector] skip assign on var

* [cs] skip assign on var

* [rector] [cs] skip assign on var

* skip assign on var

* fixes

* [rector] fixes

* [cs] fixes

Co-authored-by: rector-bot <tomas@getrector.org>
2020-09-01 17:56:30 +00:00
Tomas Votruba
41b679cb2a
[DX] Replacing arrays with objects (#4008)
* [phpstan] Add forbidden array destruct to prevent array mess

* use ArrayCallable value object

* add OpeningAndClosingSpace

* drop ConstructorInjectionToActionInjectionRector, antipattern

* use value objects

* [rector] use value objects

Co-authored-by: rector-bot <tomas@getrector.org>
2020-08-23 09:39:09 +00:00
dobryy
411d76f9a9
[Order] Make OrderPrivateMethodsByUseRector process file in one run u… (#3889)
* [Order] Make OrderPrivateMethodsByUseRector process file in one run using while loop

* [Order] Enable rule in CI

* [rector] [Order] Enable rule in CI

* [cs] [Order] Enable rule in CI

* [Order] Use constant for number of max attempts and throw exception when exceeded.

* [rector] [Order] Use constant for number of max attempts and throw exception when exceeded.

* [cs] [Order] Use constant for number of max attempts and throw exception when exceeded.

Co-authored-by: rector-bot <tomas@getrector.org>
2020-08-05 22:45:36 +02:00
Tomas Votruba
e7429d96a4
make use of constant (#3875) 2020-08-02 13:17:33 +00:00
Tomas Votruba
55acb3578a
[MagicDisclosure] Add SetterOnSetterMethodCallToStandaloneAssignRector (#3860)
* [MagicDisclosure] Add MethodCallOnSetterMethodCallToStandaloneAssignRector

* merge ChainMethodCallManipulator to ChainMethodCallNodeAnalyzer for better DX

* [MagicDisclosure] Add in arg defluent

* rebase
2020-08-01 11:41:16 +00:00
dobryy
3aa2fc8727
[Order] Order properties and constants with respect of complexity and position (#3826)
Co-authored-by: rector-bot <tomas@getrector.org>
2020-07-31 22:20:45 +02:00
TomasVotruba
dc14ddd0b9 [PHP 8.0] Add ChangeSwitchToMatchRector 2020-07-30 18:19:53 +02:00
TomasVotruba
99db894192 restore types 2020-07-27 10:44:51 +02:00
dobryy
f37cd4cac3 [Order] Apply rule 2020-07-26 15:11:41 +02:00
TomasVotruba
dec0975c22 [PHP 8.0] Add ClassPropertyAssignToConstructorPromotionRector 2020-07-26 11:42:14 +02:00
TomasVotruba
7ed4cb19c4 simplify config globs 2020-07-25 20:14:28 +02:00
TomasVotruba
0944b75f7e correct namespace in configs 2020-07-18 11:58:17 +02:00
TomasVotruba
0c816d60f8 [config] switch rules config from YAML to PHP 2020-07-16 12:48:54 +02:00
TomasVotruba
f113d3d103 fix php80 set 2020-07-01 23:35:40 +02:00
TomasVotruba
a8a6e7bcad rename file to fileInfo 2020-06-30 01:45:05 +02:00
TomasVotruba
0cb82c2a6f apply new Naming_ 2020-06-30 00:57:38 +02:00
TomasVotruba
7f49658112 change test(string ) to test(SmartFileInfo ) in tests 2020-06-25 20:02:36 +02:00
TomasVotruba
641016f129 [PHP 8.0] Add RemoveUnusedVariableInCatchRector 2020-06-03 09:31:06 +02:00
TomasVotruba
56e2449918 [PHP 8.0] Add TokenGetAllToObjectRector 2020-06-02 18:12:19 +02:00
Guilliam Xavier
b118a18642
Fix typo in StrStartsWithRector code sample 2020-05-23 15:54:59 +02:00
TomasVotruba
ab4fe09dc3 [cs] update variable names 2020-05-03 13:38:00 +02:00
TomasVotruba
993550c9e9 [PHP 8.0] Add get_debug_type 2020-04-29 23:36:13 +02:00
TomasVotruba
a6b85af2cb [Php80] Add ClassOnObjectRector 2020-04-29 22:02:09 +02:00
TomasVotruba
1612ef2165 [PHP 8.0] Add attributes v2 2020-04-29 00:25:45 +02:00
TomasVotruba
1bf62ac1c7 [cs] sort private methods by call order and property by complexity 2020-04-26 02:57:47 +02:00
TomasVotruba
93dffbea56 [PHP 8.0] Add Stringable 2020-04-24 14:09:25 +02:00
TomasVotruba
833435037a [PHP 8] Add str_ends_with 2020-04-24 00:54:57 +02:00
TomasVotruba
55a122d205 StrStartWith refactoring 2020-04-24 00:22:46 +02:00
TomasVotruba
8082b3a2f2 [PHP 8.0] Add str_starts_with 2020-04-23 23:06:36 +02:00
TomasVotruba
8f1208d18b drop preg_match support from StrContains, too vague 2020-03-27 15:20:20 +01:00
TomasVotruba
3c3aa39f14 [PHP 80] Add StrContainsRector 2020-03-26 23:57:53 +01:00
TomasVotruba
d608507f2e rename PHP sets to comply with standard 2020-03-24 23:44:42 +01:00