On 11/15/23 00:13, Sam James wrote:
Florian Weimer <fwei...@redhat.com> writes:
* Sam James:
Florian Weimer <fwei...@redhat.com> writes:

Most -Wimplicit-int warnings were unconditionally disabled for system
headers.  Only missing types for parameters in old-style function
definitions resulted in warnings.  This is inconsistent with the
treatment of other permerrors, which are active in system headers.

The situation with system headers is kind of a mess still. I went
looking for a bug for the -Wimplicit-int behaviour but I only found
PR78000 for -Wimplicit-function-declaration. But in the bug, Joseph
makes the same observation.

I don't suppose he'll want to block on that at this late point though.

Do you know offhand what Clang's behaviour is wrt warnings in system
headers?

Clang ignores these new errors in system headers by default.  I don't
know if that's deliberate or a bug.  Our permerrors are deliberately
active in system headers.  As the test shows, -Wimplicit-int really was
the outlier here because of that check outside the permerror machinery.

Thanks - my assumption was that it was more widespread because of a few
lingering bugs I've seen a few projects complain about, but maybe they
were using old versions or similar.

The permerror behavior was chosen for C++, which was the only front-end that used it before; we might want to reconsider if this patch set runs into problems with system C headers.

Jason

Reply via email to