On Mon, 1 Sep 2025, Jakub Jelinek wrote:

> Hi!
> 
> The following patch implements the
> https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3457.htm
> paper without the first 3 lines in Recommended practice.
> Seems GCC behavior already matches the expected behavior except for
> diagnostics of more than 2147483648 __COUNTER__ expansions, so the
> patch adds a diagnostic for that (but not testcase because
> #define A __COUNTER__ __COUNTER__ __COUNTER__ __COUNTER__ __COUNTER__ 
> __COUNTER__ __COUNTER__ __COUNTER__
> #define B A A A A A A A A
> #define C B B B B B B B B
> #define D C C C C C C C C
> #define E D D D D D D D D
> #define F E E E E E E E E
> #define G F F F F F F F F
> #define H G G G G G G G G
> #define I H H H H H H H H
> #define J I I I I I I I I
> J J J J
> __COUNTER__
> just takes too long to preprocess).
> Plus I've included all the snippets from the paper into one testcase.
> 
> Tested on x86_64-linux, ok for trunk?

OK.

-- 
Joseph S. Myers
[email protected]

Reply via email to