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

Revert "Remove name field from the zend_constant struct (#10954)" #11604

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

Merged
iluuu1994 merged 1 commit into php:master from iluuu1994:revert-f42992f
Jul 17, 2023

Conversation

Copy link
Member

@iluuu1994 iluuu1994 commented Jul 6, 2023

This reverts commit f42992f.


ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(EG(zend_constants), const_name, val) {
ZEND_HASH_MAP_FOREACH_PTR(EG(zend_constants), val) {
if (!val->name) {
Copy link
Member

@kocsismate kocsismate Jul 17, 2023

Choose a reason for hiding this comment

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

IIRC even special constants have a name, so this condition (and the one below) are a no-op

Copy link
Member Author

@iluuu1994 iluuu1994 Jul 17, 2023

Choose a reason for hiding this comment

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

Probably, but let's fix that in a separate PR as this is a clean revert.

Copy link
Member

@kocsismate kocsismate Jul 18, 2023

Choose a reason for hiding this comment

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

Sure! So at last you didn't have to fix anything?

Copy link
Member Author

@iluuu1994 iluuu1994 Jul 18, 2023

Choose a reason for hiding this comment

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

No, I think there must've been a bug in gcc that was patched.

@iluuu1994 iluuu1994 merged commit 1a0ef2c into php:master Jul 17, 2023
Copy link
Contributor

dktapps commented Jul 24, 2023

What was the motive for this reversion?

dktapps added a commit to pmmp/ext-pmmpthread that referenced this pull request Jul 24, 2023
This reverts commit 40a6626.
The change related to this commit was reverted by php/php-src#11604.
Copy link
Member Author

@dktapps Fixing the BC break of lowercasing the constant name through reflection. See ext/zend_test/tests/gh11423.phpt.

Copy link
Contributor

dktapps commented Jul 25, 2023

Thanks for explaining, that makes sense. #11423 is still open though.

Copy link
Member Author

@dktapps Ah, good catch, thanks!

ju1ius reacted with hooray emoji

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@kocsismate kocsismate kocsismate left review comments

@dstogov dstogov Awaiting requested review from dstogov dstogov will be requested when the pull request is marked ready for review dstogov is a code owner

@DanielEScherzer DanielEScherzer Awaiting requested review from DanielEScherzer DanielEScherzer will be requested when the pull request is marked ready for review DanielEScherzer is a code owner

Assignees
No one assigned
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

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