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

pattern matcher: Implemented transformations

This commit is contained in:
Karroffel
2016-10-05 18:48:38 +02:00
committed by karroffel
parent f8a7c46273
commit d445f0639f
3 changed files with 393 additions and 35 deletions

View File

@@ -980,7 +980,7 @@ int GDCompiler::_parse_expression(CodeGen& codegen,const GDParser::Node *p_expre
} break;
//TYPE_TYPE,
default: {
ERR_EXPLAIN("Bug in bytecode compiler, unexpected node in parse tree while parsing expression.");
ERR_FAIL_V(-1); //unreachable code
} break;
@@ -1019,7 +1019,13 @@ Error GDCompiler::_parse_block(CodeGen& codegen,const GDParser::BlockNode *p_blo
switch(cf->cf_type) {
case GDParser::ControlFlowNode::CF_MATCH: {
Error err = _parse_block(codegen,cf->match->compiled_block,p_stack_level,p_break_addr,p_continue_addr);
if (err)
return err;
} break;
case GDParser::ControlFlowNode::CF_IF: {
#ifdef DEBUG_ENABLED