Skip to content

add failing testcase for anon classes#1820

Closed
bendavies wants to merge 1 commit intorectorphp:masterfrom
bendavies:PropertyTypeDeclarationRector-anon-class
Closed

add failing testcase for anon classes#1820
bendavies wants to merge 1 commit intorectorphp:masterfrom
bendavies:PropertyTypeDeclarationRector-anon-class

Conversation

@bendavies
Copy link
Copy Markdown
Contributor

@bendavies bendavies force-pushed the PropertyTypeDeclarationRector-anon-class branch 3 times, most recently from 8ffe0ce to 14c9c20 Compare August 6, 2019 10:34
@TomasVotruba
Copy link
Copy Markdown
Member

TomasVotruba commented Sep 11, 2019

Full feature is needed, I don't have free time for resolving these anymore.

Are you able to deliver or should we close this?

@bendavies
Copy link
Copy Markdown
Contributor Author

hey, the issue isn't actually with PropertyTypeDeclarationRector, but with some shared class that many rectors use.
as such lots of rectors do not work with files that have anonymous classes defined in them, so it's a bigger problem that it looks from this PR.

Yes, i can have a look at some point.

@TomasVotruba
Copy link
Copy Markdown
Member

Yea, anonymous classes are weak sposts for Rector now.
Let me know if you need any help

@bendavies
Copy link
Copy Markdown
Contributor Author

well so far i've figured out that this test isn't working in the first instance because the class is called AnonymousClass, and...
https://github.com/rectorphp/rector/blob/master/src/NodeContainer/ParsedNodesByType.php#L508

@bendavies bendavies force-pushed the PropertyTypeDeclarationRector-anon-class branch from 14c9c20 to 2c7ef27 Compare September 12, 2019 09:21
@bendavies
Copy link
Copy Markdown
Contributor Author

renamed, now we should get the real error.

TomasVotruba added a commit that referenced this pull request Feb 15, 2022
rectorphp/rector-src@a560205 [CodeQuality] Extend SimplifyForeachToArrayFilterRector with compare cond (#1820)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants