From 36e207afd431d650a7b4f1a1ffc5283b72c5137c Mon Sep 17 00:00:00 2001 From: chrchr-github <78114321+chrchr-github@users.noreply.github.com> Date: Tue, 14 Jul 2026 09:49:39 +0200 Subject: [PATCH 1/2] Update tokenlist.cpp --- lib/tokenlist.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/tokenlist.cpp b/lib/tokenlist.cpp index 594de5c0295..847af978292 100644 --- a/lib/tokenlist.cpp +++ b/lib/tokenlist.cpp @@ -2029,9 +2029,9 @@ void TokenList::validateAst(bool print) const "' doesn't have two operands.", InternalError::AST); } - if (tok->str() == "case" && !tok->astOperand1()) { + if (!tok->astOperand1() && Token::Match(tok, "case|!")) { throw InternalError(tok, - "Syntax Error: AST broken, 'case' doesn't have an operand.", + "Syntax Error: AST broken, '" + tok->str() + "' doesn't have an operand.", InternalError::AST); } From 5eb5f4913eb29f4fa2bb81bf3d27fa8285787e34 Mon Sep 17 00:00:00 2001 From: chrchr-github <78114321+chrchr-github@users.noreply.github.com> Date: Tue, 14 Jul 2026 09:50:41 +0200 Subject: [PATCH 2/2] Create crash-401f925d3c6fd78f864ffd7bf0531bd6a76bb832 --- .../fuzz-crash_c/crash-401f925d3c6fd78f864ffd7bf0531bd6a76bb832 | 1 + 1 file changed, 1 insertion(+) create mode 100644 test/cli/fuzz-crash_c/crash-401f925d3c6fd78f864ffd7bf0531bd6a76bb832 diff --git a/test/cli/fuzz-crash_c/crash-401f925d3c6fd78f864ffd7bf0531bd6a76bb832 b/test/cli/fuzz-crash_c/crash-401f925d3c6fd78f864ffd7bf0531bd6a76bb832 new file mode 100644 index 00000000000..a778e6e2823 --- /dev/null +++ b/test/cli/fuzz-crash_c/crash-401f925d3c6fd78f864ffd7bf0531bd6a76bb832 @@ -0,0 +1 @@ +i(){!!:!=!&&d}