1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00

GDScript: Fix return of cast expression on compilation

It was mistakenly returning the source instead of the result.
This commit is contained in:
George Marques
2020-11-25 11:37:51 -03:00
parent fb3dc2670a
commit ed3d8f31df

View File

@@ -437,7 +437,7 @@ GDScriptCodeGenerator::Address GDScriptCompiler::_parse_expression(CodeGen &code
gen->pop_temporary(); gen->pop_temporary();
} }
return source; return result;
} break; } break;
case GDScriptParser::Node::CALL: { case GDScriptParser::Node::CALL: {
const GDScriptParser::CallNode *call = static_cast<const GDScriptParser::CallNode *>(p_expression); const GDScriptParser::CallNode *call = static_cast<const GDScriptParser::CallNode *>(p_expression);