From 15141897aebe66883c23ac6a7cb28a3935ecdce8 Mon Sep 17 00:00:00 2001 From: Wolfgang Bumiller Date: Tue, 5 Feb 2013 17:17:38 +0100 Subject: [PATCH] insert an error when an operator doesn't get found - note the comment... --- parser.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/parser.c b/parser.c index 3375acc..73ced3a 100644 --- a/parser.c +++ b/parser.c @@ -1898,8 +1898,13 @@ static ast_expression* parse_expression_leave(parser_t *parser, bool stopatcomma } } if (o == operator_count) { + compile_error(parser_ctx(parser), "unknown operator: %s", parser_tokval(parser)); + goto onerr; +#if 0 +Are there any expressions which actually end with an operator? /* no operator found... must be the end of the statement */ break; +#endif } /* found an operator */ op = &operators[o]; -- 2.39.2