From f6c0a27feedb8258afbf10d64c7040e327377250 Mon Sep 17 00:00:00 2001 From: "Ian M." Date: Sun, 4 Oct 2026 22:00:53 +0000 Subject: lexer: Bail if the token is invalid Signed-off-by: Ian M. --- core/lexer.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/core/lexer.c b/core/lexer.c index 53a418d..163e2f5 100644 --- a/core/lexer.c +++ b/core/lexer.c @@ -4,6 +4,7 @@ */ #include +#include #include #include @@ -79,5 +80,7 @@ atas_lexer_scan(struct atas_state *state, struct atas_token *token) return 0; } + trace_fatal("unexpected token '%c' while scanning\n", c); + atas_fatal(state); return -1; } -- cgit v1.2.3