summaryrefslogtreecommitdiff
path: root/modules/gdscript/gdscript_parser.cpp
diff options
context:
space:
mode:
authorGeorge Marques <george@gmarqu.es>2019-03-03 22:53:50 -0300
committerGeorge Marques <george@gmarqu.es>2019-03-03 22:53:50 -0300
commit67fee40483258a90bc47abeba02deee7fa744317 (patch)
tree915a82764abbba102582c936717141578a614314 /modules/gdscript/gdscript_parser.cpp
parentb24cb92240e047a7976f9eccc1b390ac090692e7 (diff)
GDScript: Fix issue when detecting file class in inner class
Diffstat (limited to 'modules/gdscript/gdscript_parser.cpp')
-rw-r--r--modules/gdscript/gdscript_parser.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp
index 7c4ed84757..5619729c13 100644
--- a/modules/gdscript/gdscript_parser.cpp
+++ b/modules/gdscript/gdscript_parser.cpp
@@ -5444,7 +5444,7 @@ GDScriptParser::DataType GDScriptParser::_resolve_type(const DataType &p_source,
String script_path = ScriptServer::get_global_class_path(id);
if (script_path == self_path) {
result.kind = DataType::CLASS;
- result.class_type = current_class;
+ result.class_type = static_cast<ClassNode *>(head);
} else {
Ref<Script> script = ResourceLoader::load(script_path);
Ref<GDScript> gds = script;