-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add getProperties() and getConstants() to ClassLike #629
Conversation
I think these should just be on ClassLike. I know not everything is supported everywhere, but that just means you get an empty array (also, at the parser level they are supported anyway...) |
Even if constants are not allowed in traits and properties are not allowed in interfaces? |
CI fail is not related to this feature, but rather some bug in The command "if [ $TRAVIS_PHP_VERSION = '7.2' ]; then test_old/run-php-src.sh; fi" exited with 1. |
@TomasVotruba Fixed with 5644a91. |
I think so. For a couple of reasons:
|
Ok, I'd prefer it too, less code to maintain and more ClassLikely :) Will re-do. Thanks for reasoning 👍 |
Thank you 👍 |
As there is
getMethods()
atClassLike
, I often tend to usegetProperties()
andgetConstants()
, but there are none. I understood that's probably because onlygetMethods()
is inClassLike
for all 3 sub-classes.Yet the API is inconsistent and confusing. This would fix that.
vs.
This keeps happening to me last 2 years so I finally do something about it