rector-src
rector-src copied to clipboard
Development repository for Rector
Test for https://github.com/rectorphp/rector/issues/7453 Seems like bug in php-parser: https://github.com/nikic/PHP-Parser/pull/887
# Failing Test for ReturnTypeDeclarationRector Based on https://getrector.org/demo/a97ca4ba-526f-4d02-8e5c-c13cc7a82171
Previously, `NormalizeNamespaceByPSR4ComposerAutoloadRector` did not update references to other normalized classes properly. This change fixes that by recording the renames using `RenamedClassesDataCollector`. Supersedes https://github.com/rectorphp/rector-src/pull/2482
Hi, sorry for the delayed response. I put this together in order to try to answer question in discussion: [Make RenameClassRector more flexible by supporting callbacks?](https://github.com/rectorphp/rector/discussions/7556). This is not (even...
Given the following code: ```php final class SkipIntersectionIterable { /** @var \Doctrine\Common\Collections\Collection */ private \Doctrine\Common\Collections\Collection $socialAccounts; public function __construct() { $this->socialAccounts = new \Doctrine\Common\Collections\ArrayCollection(); } /** @return \Doctrine\Common\Collections\Collection */ public...
# Failing Test for NullToStrictStringFuncCallArgRector Based on https://getrector.org/demo/9a90408b-44b7-48f9-a5fa-458a526e8749 Code should be untouched: `trim` can't get a `null` value. If method is used without trait, it works fine.
# Failing Test for RenameNamespaceRector Based on https://getrector.org/demo/2b0021b2-3080-449a-95b8-01084ba16c8c The RenameNamespaceRector doesn't work as I would expect it. Discovered this when I tried to rename a namespace in an legacy Symfony...
This is just to see possible upgrade needed when use php-parser 5, beside looking on changelog, as php-parser 5 is based on dev-master
Found few dozen misspellings, including file names. One commit per directory! Fixes https://github.com/rectorphp/rector/issues/8585
@nuryagdym @TomasVotruba this is experimental for https://github.com/rectorphp/rector/issues/8557