Fix parsing of enums allowing for juxtaposed identifiers

Fixes #28727
This commit is contained in:
Bojidar Marinov 2019-07-05 21:40:40 +03:00
parent 4cb0887660
commit c43e050145
No known key found for this signature in database
GPG Key ID: 4D546A8F1E091856
1 changed files with 3 additions and 0 deletions

View File

@ -5084,6 +5084,9 @@ void GDScriptParser::_parse_class(ClassNode *p_class) {
if (tokenizer->get_token() == GDScriptTokenizer::TK_COMMA) {
tokenizer->advance();
} else if (tokenizer->is_token_literal(0, true)) {
_set_error("Unexpected identifier");
return;
}
if (enum_name != "") {