mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2024-11-27 22:22:17 +00:00
update noops flag while parsing a translatable string
This commit is contained in:
parent
7838e772de
commit
66317aaef9
1 changed files with 2 additions and 0 deletions
2
parser.c
2
parser.c
|
@ -1313,10 +1313,12 @@ static ast_expression* parse_expression_leave(parser_t *parser, bool stopatcomma
|
|||
goto onerr;
|
||||
}
|
||||
|
||||
parser->lex->flags.noops = true;
|
||||
if (!parser_next(parser) || parser->tok != '(') {
|
||||
parseerror(parser, "use _(\"string\") to create a translatable string constant");
|
||||
goto onerr;
|
||||
}
|
||||
parser->lex->flags.noops = false;
|
||||
if (!parser_next(parser) || parser->tok != TOKEN_STRINGCONST) {
|
||||
parseerror(parser, "expected a constant string in translatable-string extension");
|
||||
goto onerr;
|
||||
|
|
Loading…
Reference in a new issue