zend_string: Replace some macros by inline functions#21855
zend_string: Replace some macros by inline functions#21855TimWolla wants to merge 1 commit intophp:masterfrom
Conversation
Girgias
left a comment
There was a problem hiding this comment.
I'm not sure if I can find Nikita's review comment again when I did those sorts of refactorings, but IIRC uppercase really should be reserved for macro functions was his opinion.
So maybe naming those inline functions using the "usual style" and defining the macros to just be those functions might be a better idea? And then we can slowly migrate the use of macros to functions and keep the macros just as BC shims for a while.
I really don't want more BC layers that will never get removed in practice. Uppercase functions are a bit unorthodox, but feel like the lesser evil in practice - particularly for this kind of function-like macro. At least until the internal API gets a proper cleanup with a predictable function naming and clear header dependencies. |
|
I don't have a strong opinion, so I'll wait to see what @iluuu1994 thinks about the uppercase functions. |
|
I don't particularly care whether the function has an uppercase name or whether it's hidden behind a trivial macro, but I would not like to see the code churn of migrating the callers. |
No description provided.