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

Fix cyclic reference errors while reducing identifiers.

Co-authored-by: Dmitrii Maganov <vonagam@gmail.com>
This commit is contained in:
Adam Scott
2023-01-14 15:58:34 -05:00
parent 91fedb60de
commit 48e041458f
2 changed files with 3 additions and 3 deletions

View File

@@ -2910,8 +2910,8 @@ void GDScriptAnalyzer::reduce_identifier_from_base_set_class(GDScriptParser::Ide
p_identifier->set_datatype(p_identifier_datatype);
Error err = OK;
GDScript *scr = GDScriptCache::get_full_script(p_identifier_datatype.script_path, err).ptr();
ERR_FAIL_COND_MSG(err != OK, "Error while getting full script.");
GDScript *scr = GDScriptCache::get_shallow_script(p_identifier_datatype.script_path, err).ptr();
ERR_FAIL_COND_MSG(err != OK, vformat(R"(Error while getting cache for script "%s".)", p_identifier_datatype.script_path));
scr = scr->find_class(p_identifier_datatype.class_type->fqcn);
p_identifier->reduced_value = scr;
p_identifier->is_constant = true;