core: lexer: Fix up putback pop in consumption function

Signed-off-by: Ian Moffett <ian@mirocom.org>
This commit is contained in:
2026-05-23 09:01:02 -04:00
parent 07859d3735
commit 2ec8122a91
+2 -2
View File
@@ -73,11 +73,11 @@ lexer_consume_single(struct cescal_state *state, bool skip_ws)
} }
if ((c = lexer_putback_pop(state)) != '\0') { if ((c = lexer_putback_pop(state)) != '\0') {
if (!skip_ws) { if (skip_ws && !lexer_is_ws(c)) {
return c; return c;
} }
if (skip_ws && !lexer_is_ws(c)) { if (!skip_ws && lexer_is_ws(c)) {
return c; return c;
} }
} }