summaryrefslogtreecommitdiff
path: root/modules/gdscript
diff options
context:
space:
mode:
authorGeorge Marques <george@gmarqu.es>2020-11-25 11:37:51 -0300
committerGeorge Marques <george@gmarqu.es>2020-11-25 11:37:51 -0300
commited3d8f31df143337f43bb219da12f68f1d620df7 (patch)
tree61067a5b1d8e7392c975c00494e08e9f21cb7f76 /modules/gdscript
parentfb3dc2670a7d086933d056096cefd26362951e93 (diff)
GDScript: Fix return of cast expression on compilation
It was mistakenly returning the source instead of the result.
Diffstat (limited to 'modules/gdscript')
-rw-r--r--modules/gdscript/gdscript_compiler.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/gdscript_compiler.cpp b/modules/gdscript/gdscript_compiler.cpp
index 69fe6d27cc..499cd09b4e 100644
--- a/modules/gdscript/gdscript_compiler.cpp
+++ b/modules/gdscript/gdscript_compiler.cpp
@@ -437,7 +437,7 @@ GDScriptCodeGenerator::Address GDScriptCompiler::_parse_expression(CodeGen &code
gen->pop_temporary();
}
- return source;
+ return result;
} break;
case GDScriptParser::Node::CALL: {
const GDScriptParser::CallNode *call = static_cast<const GDScriptParser::CallNode *>(p_expression);