Re: RFC: rules for #include directives
| From: | Max Kellermann | Date: | Fri, 20 Jan 2023 15:54:42 +0000 |
| Subject: | Re: RFC: rules for #include directives | ||
| References: | 1 2 3 4 5 6 7 8 9 10 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-119378@lists.php.net to get a copy of this message | ||
On 2023/01/20 14:49, Tim Düsterhus <tim@bastelstu.be> wrote:
> A reasonable first step might be just *adding* all the missing '#include's
> to '*.c' with one PR per ext/* directory
Sounds like a good plan, but after the discussion about maintaining
compatibility with bad out-of-tree code, I believe this should
actually be the *last* step.
Some in-tree extensions are buggy and need fixups (e.g. errno.h), but
if I don't fix them now, I can more easily verify if my php_compat.h
changes are good enough to avoid breakages in those in-tree
extensions.
Once the actual cleanup is merged, and we are confident enough that
php_compat.h works, we may clean up the in-tree extensions, and then
define a macro, say, PHP_NO_COMPAT, so all the compatibility tweaks
for bad extensions can be avoided for certain already-fixed
extensions.
Max