Merge pull request #49544 from akien-mga/variantparser-stringname-compat
VariantParser: Fix reading StringNames with '&'.
This commit is contained in:
commit
edee798628
1 changed files with 5 additions and 2 deletions
|
@ -190,10 +190,13 @@ Error VariantParser::get_token(Stream *p_stream, Token &r_token, int &line, Stri
|
|||
r_token.type = TK_COLOR;
|
||||
return OK;
|
||||
}
|
||||
case '@': {
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
case '@': // Compatibility with 3.x StringNames.
|
||||
#endif
|
||||
case '&': { // StringName.
|
||||
cchar = p_stream->get_char();
|
||||
if (cchar != '"') {
|
||||
r_err_str = "Expected '\"' after '@'";
|
||||
r_err_str = "Expected '\"' after '&'";
|
||||
r_token.type = TK_ERROR;
|
||||
return ERR_PARSE_ERROR;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue