-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Use new ZSTR_INIT_LITERAL macro #10879
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
Conversation
Good idea - though I wished these literal zend_strings could just automagically become known_strings. |
How did you perform and verify this change? There's also existing places that use Line 232 in 5efd60e
|
@TimWolla I used a naive global search ( |
I'm not a fan of macros at all, but at least the new one behaves like a function, yes. I wanted to check the changes with Coccinelle:
But it appears that Coccinelle gets confused by the ZPP macros for some reason. Bummer 😩 |
Yeah, the
I remember you mentioning it and couldn't remember the name. I'll look into it so I can use it in the future. Thanks 🙂 |
Basic usage would be:
However comparing the result with your PR does not make all the changes. Specifically looking at the change to
and then use So something about the macro causes Coccinelle to misparse the function and thus ignoring it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Didn't know about the other bizarre macro. And having those become known strings seems also interesting, especially as a lot are INI settings, but that can be done as a follow up. :)
I don't know how that would work though. Known strings are part of the |
Thanks for the review everyone 🙂 |
No description provided.