Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Implement ReflectionConstant #13669

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

Closed
iluuu1994 wants to merge 2 commits into php:master from iluuu1994:reflection-constant
Closed

Conversation

Copy link
Member

@iluuu1994 iluuu1994 commented Mar 11, 2024

Fixes GH-13570

arnaud-lb and vudaltsov reacted with thumbs up emoji
@iluuu1994 iluuu1994 changed the title (削除) Implement reflection constant (削除ここまで) (追記) Implement ReflectionConstant (追記ここまで) Mar 11, 2024
Copy link
Member

Some reflection classes also have a name property, such that dumping it somewhere makes it easy to see what it refers to. Does it make sense to add it here too?

mvorisek, iluuu1994, and arnaud-lb reacted with thumbs up emoji

Copy link
Member

@arnaud-lb arnaud-lb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most Reflection classes implements Reflector and provide a __toString() method. I think that's useful and we could implement that for ReflectionConstant as well (using _const_string()).

Copy link
Member

@arnaud-lb arnaud-lb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM !

@iluuu1994 iluuu1994 force-pushed the reflection-constant branch 2 times, most recently from 0f1ec56 to e99930c Compare March 20, 2024 10:44
Copy link
Member

@Girgias Girgias left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor nits, and maybe renaming const_ to const_ptr? I find the trailing underscore somewhat weird.

Copy link
Contributor

staabm commented Apr 18, 2024

Thank you 🙏

iluuu1994 reacted with thumbs up emoji

TimWolla added a commit to TimWolla/php-src that referenced this pull request Apr 30, 2024
This is in preparation for php#11293 and for consistency with
ReflectionConstant::isDeprecated() that was added in php#13669.
TimWolla added a commit that referenced this pull request Apr 30, 2024
This is in preparation for #11293 and for consistency with
ReflectionConstant::isDeprecated() that was added in #13669.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@arnaud-lb arnaud-lb arnaud-lb approved these changes

@kocsismate kocsismate kocsismate approved these changes

@Girgias Girgias Girgias approved these changes

+4 more reviewers

@staabm staabm staabm left review comments

@alcaeus alcaeus alcaeus left review comments

@Bilge Bilge Bilge left review comments

@mvorisek mvorisek mvorisek left review comments

Reviewers whose approvals may not affect merge requirements
Assignees
No one assigned
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

use reflection to determine whether a global constant is deprecated

AltStyle によって変換されたページ (->オリジナル) /