github rectorphp/rector 0.18.12
Released Rector 0.18.12

latest releases: 1.2.10, 1.2.9, 1.2.8...
11 months ago

New Features 🥳

  • [CodeQuality] Add RemoveUselessIsObjectCheckRector (#5316)
  • [PHP83] Implements a rule to add types to class constants (#5290), Thanks @peterfox!

Bugfixes 🐛

  • [TypeDeclaration] Skip iterable already there in AddReturnTypeDeclarationFromYieldsRector (#5291)
  • [TypeDeclaration] Remove ParamTypeFromStrictTypedPropertyRector as seems similar feature with AddParamTypeFromPropertyTypeRector (#5293)
  • [CodingStyle] Remove AddArrayDefaultToArrayPropertyRector as based on docblock types and public contract, better use type declaration set instad (#5298)
  • [TypeDeclaration] Skip return void in abstract empty class in AddVoidReturnTypeWhereNoReturnRector (#5311)
  • [Php80] Skip PDO::query() on AddParamBasedOnParentClassMethodRector (#5313)
  • [TypeDeclaration] Add If else assign support on TypedPropertyFromAssignsRector (#5314)
  • [CodeQuality] Make CommonNotEqualRector skip if not <> (#5292)
  • [Naming] Skip singularize "cms" on RenameForeachValueVariableToMatchExprVariableRector (#5294)
  • [TypeDeclaration][Performance] Check typed param already early on ParamTypeByMethodCallTypeRector (#5295)
  • [Strict] Fix DisallowedEmptyRuleFixerRector empty() allow string '0' check (#5296)
  • [EarlyReturn] Skip duplicating complex expression in ChangeAndIfToEarlyReturnRector (#5301)
  • [Scoped] Exclude symfony/console/Debug/CliRequest.php from parallel-lint PHP 7.2 syntax check (#5304)
  • Skip RenameMethodRector in never (#5305), Thanks @staabm!
  • [CodeQuality] Skip with else on SimplifyForeachToCoalescingRector (#5307)
  • [Doc] Typo fix on sample code documentation on SimplifyForeachToCoalescingRector (#5308)
  • [Privatization] Skip call non-private method on non-final class on PrivatizeLocalGetterToPropertyRector (#5309)
  • [Privatization] Fix first class callable in PrivatizeLocalGetterToPropertyRector (#5310)
  • [TypeDeclaration] Keep constant false return type from strict native call (#5223), Thanks @tomi85!
  • [PHP 7.0] Skip mt_rand() replacement as not valuable (#5315)
  • [Strict] Allow check '0' empty zero on BooleanInTernaryOperatorRuleFixerRector on string type (#5297)
  • Fix annotation to attribute parsing string (#5317)
  • [Instanceof] Fix combination of dead instance and compare (#5319)
  • Remove isPositiveInteger() check for third argument to strpos() (#5257), Thanks @ikari7789!
  • Remove return type in case of void in RemoveUselessReturnTagRector (#5318)
  • [DeadCode] Skip @return never with void on RemoveUselessReturnTagRector (#5320)
  • [DeadCode] Remove useless nullable @return doc on RemoveUselessReturnTagRector (#5321)

Don't miss a new rector release

NewReleases is sending notifications on new releases.