Path: csiph.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: gcc and 'include' Date: Mon, 30 Mar 2026 18:07:53 -0700 Organization: None to speak of Lines: 36 Message-ID: <87qzp0u7py.fsf@example.invalid> References: <10q4ceb$38i2d$1@dont-email.me> <87ikaiw5g0.fsf@example.invalid> <10q5nnr$3l3lc$1@dont-email.me> <10q6snp$2nka$5@dont-email.me> <10q6uv4$419b$1@dont-email.me> <20260328203718.00005c70@yahoo.com> <10q96uf$rjbn$1@dont-email.me> <10q9t6d$2p36t$1@paganini.bofh.team> <10qc632$1uds9$1@dont-email.me> <86mrzp1oql.fsf@linuxsc.com> <10qdujq$2g7uj$1@dont-email.me> <87v7edtafm.fsf@example.invalid> <10qenu5$2q4nh$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain Injection-Date: Tue, 31 Mar 2026 01:07:54 +0000 (UTC) Injection-Info: dont-email.me; posting-host="43a39da5ea826f3cab717fc4bda0b1e9"; logging-data="3096137"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/NBng9KhAdKupPxRXbL6Sa" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:Cr10INDV7vPghA2les2LPo85lJ0= sha1:RvDrd6+z35ZV0boq9w10+/YoUO4= Xref: csiph.com comp.lang.c:397318 Bart writes: > On 30/03/2026 19:54, Keith Thompson wrote: [...] >> You're complaining about gcc being lax, not about the C language >> being lax. > > It's both. Example: > > signed char* p; > unsigned char* q; > p = q; > > This compiles OK with no options. But should it; what does the > language say about it? As I think you already know, that's a constraint violation, requiring a diagnostic. > Another example: > > int F(){} > > Here not even -Wextra touches it. I need -Wpedantic, which tells me a > lot about C! "gcc -Wpedantic" doesn't complain about that. There is no syntax error and no constraint violation, so the language does not require a diagnostic. If you have a point, feel free to make it more clearly. [...] -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com void Void(void) { Void(); } /* The recursive call of the void */