From: Wolfgang Bumiller Date: Tue, 5 Feb 2013 16:17:38 +0000 (+0100) Subject: insert an error when an operator doesn't get found - note the comment... X-Git-Tag: before-library~152^2~1 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=15141897aebe66883c23ac6a7cb28a3935ecdce8;p=xonotic%2Fgmqcc.git insert an error when an operator doesn't get found - note the comment... --- 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];