diff options
author | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-08-27 19:28:59 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-08-27 19:28:59 +0200 |
commit | 33773a24dc23f24dc4bfc11999cdaa9f49cb3dd0 (patch) | |
tree | 59081b9b5fff9a6060ccbb4de8057e8ad6d2c6eb /modules/gdscript/gdscript_parser.cpp | |
parent | 90a35dac489bcbe39de35af661367519b411cb98 (diff) | |
parent | 79578a5625f297dae632edc2a3aa385ccdb26ab3 (diff) |
Merge pull request #52105 from ldmnt/master
Diffstat (limited to 'modules/gdscript/gdscript_parser.cpp')
-rw-r--r-- | modules/gdscript/gdscript_parser.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp index af872e49e2..029e30080b 100644 --- a/modules/gdscript/gdscript_parser.cpp +++ b/modules/gdscript/gdscript_parser.cpp @@ -2365,6 +2365,9 @@ GDScriptParser::ExpressionNode *GDScriptParser::parse_assignment(ExpressionNode } assignment->assignee = p_previous_operand; assignment->assigned_value = parse_expression(false); + if (assignment->assigned_value == nullptr) { + push_error(R"(Expected an expression after "=".)"); + } #ifdef DEBUG_ENABLED if (has_operator && source_variable != nullptr && source_variable->assignments == 0) { |