From 466a76ac2c7c6634ed1d78fde4ac011e2e70b710 Mon Sep 17 00:00:00 2001 From: Bojidar Marinov Date: Sat, 16 Mar 2019 18:49:29 +0200 Subject: Fix GDScriptCompiler bugging out with identically-named inner class Fixes #27111 --- modules/gdscript/gdscript_compiler.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'modules/gdscript/gdscript_compiler.h') diff --git a/modules/gdscript/gdscript_compiler.h b/modules/gdscript/gdscript_compiler.h index 8440807a56..2cf630ba72 100644 --- a/modules/gdscript/gdscript_compiler.h +++ b/modules/gdscript/gdscript_compiler.h @@ -38,9 +38,8 @@ class GDScriptCompiler { const GDScriptParser *parser; - Map > class_map; - Set parsed_classes; - Set parsing_classes; + Set parsed_classes; + Set parsing_classes; GDScript *main_script; struct CodeGen { @@ -149,9 +148,9 @@ class GDScriptCompiler { int _parse_expression(CodeGen &codegen, const GDScriptParser::Node *p_expression, int p_stack_level, bool p_root = false, bool p_initializer = false); Error _parse_block(CodeGen &codegen, const GDScriptParser::BlockNode *p_block, int p_stack_level = 0, int p_break_addr = -1, int p_continue_addr = -1); Error _parse_function(GDScript *p_script, const GDScriptParser::ClassNode *p_class, const GDScriptParser::FunctionNode *p_func, bool p_for_ready = false); - Error _parse_class_level(GDScript *p_script, GDScript *p_owner, const GDScriptParser::ClassNode *p_class, bool p_keep_state); + Error _parse_class_level(GDScript *p_script, const GDScriptParser::ClassNode *p_class, bool p_keep_state); Error _parse_class_blocks(GDScript *p_script, const GDScriptParser::ClassNode *p_class, bool p_keep_state); - void _make_scripts(const GDScript *p_script, const GDScriptParser::ClassNode *p_class, bool p_keep_state); + void _make_scripts(GDScript *p_script, const GDScriptParser::ClassNode *p_class, bool p_keep_state); int err_line; int err_column; StringName source; -- cgit v1.2.3