tinycc-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Tinycc-devel] bug in preprocessor


From: gz8cx4
Subject: Re: [Tinycc-devel] bug in preprocessor
Date: Fri, 19 Jan 2024 14:20:07 +0100

On Fri, Jan 19, 2024 at 11:26:42AM +0100, Harald Arnesen via Tinycc-devel wrote:
> Fred van Kempen via Tinycc-devel [18/01/2024 21.35]:
[...]
> #ifdef FOO
>      printf("Foo: %s\n", argv[0]);
> #endif  bar
[...]
> > should not compile, for obvious reasons, but it does..
[...]
> It also compiles, with a warning, both with GCC (13.2.0) and Clang (15.0.7).

To put some text after #endif on the same line, this used to be customary
in K&R age, wasn't it? There are K&R sources still valuable today and
it is really useful that Tinycc is capable of compiling them.

IOW - the example should compile, for that reason.

Offtopic: Even when something looks obvious to the writer, the readers
almost guaranteed have different backgrounds and experiences. They can
miss the point. It helps a lot, to specify what one means.

/ tccm



reply via email to

[Prev in Thread] Current Thread [Next in Thread]