From c09f8981961ad8b0d2006104857122f381db13c7 Mon Sep 17 00:00:00 2001 From: lemon Date: Thu, 23 Oct 2025 17:33:32 +0200 Subject: lex: fix expansion for fn like macros passed as macro arguments --- c/lex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'c') diff --git a/c/lex.c b/c/lex.c index 4b41483..1c30da6 100644 --- a/c/lex.c +++ b/c/lex.c @@ -998,7 +998,7 @@ tryexpand(struct lexer *lx, struct token *tk) tk2[0] = *tk_, tk2[1] = tk; noexpandmac = 0; pushmacstk(lx, &span, &(struct macrostack) { - .rlist = { tk2, 2 }, + .rlist = { tk2, 2 - (tk.t == TKEOF) }, .exspan = span.ex, .macno = macidx, }); -- cgit v1.2.3