Skip to content

Introduce a CallReflectionResolver#2658

Merged
TomasVotruba merged 1 commit intorectorphp:masterfrom
Lctrs:call-reflection-resolver
Jan 14, 2020
Merged

Introduce a CallReflectionResolver#2658
TomasVotruba merged 1 commit intorectorphp:masterfrom
Lctrs:call-reflection-resolver

Conversation

@Lctrs
Copy link
Copy Markdown
Contributor

@Lctrs Lctrs commented Jan 14, 2020

No description provided.

@TomasVotruba
Copy link
Copy Markdown
Member

Could elaborate on motivation and main features for this PR?

@Lctrs
Copy link
Copy Markdown
Contributor Author

Lctrs commented Jan 14, 2020

Main motivation was to reduce duplicated code and leverage PHPStan to create a class that is able to return the reflected function from any calls given, even on a variable that has been assigned a closure (eg. $f = function(){}; $f();)

@TomasVotruba
Copy link
Copy Markdown
Member

I see, thanks 👍

@TomasVotruba TomasVotruba merged commit 581010f into rectorphp:master Jan 14, 2020
@Lctrs
Copy link
Copy Markdown
Contributor Author

Lctrs commented Jan 14, 2020

Worth noting that Rector\PhpParser\Node\Manipulator\CallManipulator class is now unused across the project. Didn't had the gut to remove it.

@TomasVotruba
Copy link
Copy Markdown
Member

Go for it

@Lctrs Lctrs mentioned this pull request Jan 14, 2020
@Lctrs Lctrs deleted the call-reflection-resolver branch January 15, 2020 12:33
TomasVotruba added a commit that referenced this pull request Jul 13, 2022
rectorphp/rector-src@ae7648e [CodingStyle] Add StaticClosureRector (#2658)
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