summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-02-21 12:17:14 +0100
committerGitHub <noreply@github.com>2022-02-21 12:17:14 +0100
commitd42250e2fbc513c6a906c4b427dcdcc3fe5645b8 (patch)
tree1c8dcc7113be3e98145ea789a1385b557edd5898 /modules
parentac1a55bc63ddedd85a048049aea708276dbc9bea (diff)
parentae0026bc7b0b33195a2f8c5a8e85afd2127ffd05 (diff)
Merge pull request #58275 from V-Sekai/attribute_parse_crash_fix
Diffstat (limited to 'modules')
-rw-r--r--modules/gdscript/gdscript_parser.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp
index 8e4e457ec1..725b62f6d6 100644
--- a/modules/gdscript/gdscript_parser.cpp
+++ b/modules/gdscript/gdscript_parser.cpp
@@ -2692,12 +2692,13 @@ GDScriptParser::ExpressionNode *GDScriptParser::parse_attribute(ExpressionNode *
}
}
- attribute->is_attribute = true;
attribute->base = p_previous_operand;
if (!consume(GDScriptTokenizer::Token::IDENTIFIER, R"(Expected identifier after "." for attribute access.)")) {
return attribute;
}
+
+ attribute->is_attribute = true;
attribute->attribute = parse_identifier();
return attribute;