mirror of
https://github.com/godotengine/godot.git
synced 2025-10-26 19:24:18 +00:00
Merge pull request #52063 from KoBeWi/double_comma_of_doom
Fix crash with consecutive commas in Dictionary
This commit is contained in:
commit
6423e891a6
3 changed files with 8 additions and 2 deletions
|
|
@ -2464,8 +2464,10 @@ GDScriptParser::ExpressionNode *GDScriptParser::parse_dictionary(ExpressionNode
|
|||
push_error(R"(Expected "=" after dictionary key.)");
|
||||
}
|
||||
}
|
||||
key->is_constant = true;
|
||||
key->reduced_value = static_cast<IdentifierNode *>(key)->name;
|
||||
if (key != nullptr) {
|
||||
key->is_constant = true;
|
||||
key->reduced_value = static_cast<IdentifierNode *>(key)->name;
|
||||
}
|
||||
break;
|
||||
case DictionaryNode::PYTHON_DICT:
|
||||
if (!match(GDScriptTokenizer::Token::COLON)) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue