Hi Meng, To me, the current policy for tcc source is described in CodingStyle: tcc is mostly implemented in C90, and new non-C90 constructs shouldn't be introduced unless already used. The current "-Wdeclaration-after-statement" check helps preserve that style while still leaving GCC/Clang in their normal GNU mode.
Replacing it with "-std=c99" would weaken that check because it permits mixed declarations and statements. It also changes the host compiler into strict ISO C mode, which affects system header visibility: the need to add _DEFAULT_SOURCE for usleep in your patch is a symptom of that. So I wouldn't replace "-Wdeclaration-after-statement" with "-std=c99" just because the CI passes. If there is a specific build issue with the current flag, we should address that directly. If the goal is to check that tcc can also be built under a C99 host compiler mode, that could be considered as an optional CI and configuration test, but it shouldn't replace the current style check. Regards, Mounir IDRASSI From: Meng Zhuo <[email protected]> To: <[email protected]> Date: Mon, 01 Jun 2026 18:06:11 +0900 Subject: [Tinycc-devel] Changing std to C99? > Hi, everyone > > I notice TinyCC should follow C99 instead of GNU99 according to > https://bellard.org/tcc , is it designed by that way or something that I > missed? > > > I have tested C99 on my Github and all testes passed > > https://github.com/mengzhuo/tinycc/actions/runs/26745551862 > > > _______________________________________________ > Tinycc-devel mailing list > [email protected] > https://lists.nongnu.org/mailman/listinfo/tinycc-devel > _______________________________________________ Tinycc-devel mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/tinycc-devel
