Skip to content

Conversation

samsonasik
Copy link
Contributor

No description provided.

@samsonasik
Copy link
Contributor Author

Ready to merge 👍

@ondrejmirtes
Copy link
Member

What do you need this for?

@samsonasik
Copy link
Contributor Author

First, it is for consistency with other virtual node,
Second, I was experimenting to set scope on original node on rector side, when calling NodeScopeResolver::processNodes(), while only detected is ClassPropertyNode over original Property node.

@ondrejmirtes
Copy link
Member

The point of ClassPropertyNode is that it abstracts away Param and Property. It doesn't make sense to offer getOriginalNode because users would have to make if-else condition in their code about these two node types.

You can still hook your custom rector onto Param or Property, they do not disappear.

@samsonasik
Copy link
Contributor Author

Ok 👍

@samsonasik samsonasik closed this Dec 20, 2024
@samsonasik samsonasik deleted the add-get-original-ode branch December 20, 2024 07:00
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