diff options
| author | eska | 2016-06-05 14:52:07 +0200 |
|---|---|---|
| committer | eska | 2016-06-05 19:17:33 +0200 |
| commit | 3acbf8e71f15c682bcf4fee248f58180e689df1c (patch) | |
| tree | 1dd425297f15d5c13cd43c3932f32b1cb8b55022 /modules/gdscript/gd_compiler.cpp | |
| parent | 56348cbbfe82c2f5e2b95875e0687b664cc6e2d8 (diff) | |
| download | godot-3acbf8e71f15c682bcf4fee248f58180e689df1c.tar.gz godot-3acbf8e71f15c682bcf4fee248f58180e689df1c.tar.zst godot-3acbf8e71f15c682bcf4fee248f58180e689df1c.zip | |
Diffstat (limited to 'modules/gdscript/gd_compiler.cpp')
| -rw-r--r-- | modules/gdscript/gd_compiler.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/gdscript/gd_compiler.cpp b/modules/gdscript/gd_compiler.cpp index d51f1a4dd..072c53fb9 100644 --- a/modules/gdscript/gd_compiler.cpp +++ b/modules/gdscript/gd_compiler.cpp @@ -1588,6 +1588,12 @@ Error GDCompiler::_parse_class(GDScript *p_script, GDScript *p_owner, const GDPa } + } else { + // without extends, implicitly extend Reference + int native_idx = GDScriptLanguage::get_singleton()->get_global_map()["Reference"]; + native = GDScriptLanguage::get_singleton()->get_global_array()[native_idx]; + ERR_FAIL_COND_V(native.is_null(), ERR_BUG); + p_script->native=native; } |
