Merge pull request #43045 from DavidSichma/gdmatch

Fixed match for expression pattern
This commit is contained in:
Rémi Verschelde 2021-03-03 08:29:37 +01:00 committed by GitHub
commit 43264c6372
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1176,7 +1176,7 @@ GDScriptCodeGenerator::Address GDScriptCompiler::_parse_match_pattern(CodeGen &c
codegen.generator->write_and_left_operand(result_addr);
// Check value equality.
codegen.generator->write_binary_operator(result_addr, Variant::OP_EQUAL, p_value_addr, expr_addr);
codegen.generator->write_binary_operator(equality_test_addr, Variant::OP_EQUAL, p_value_addr, expr_addr);
codegen.generator->write_and_right_operand(equality_test_addr);
// AND both type and value equality.