added missing null check
for p_func inside _parse_function
This commit is contained in:
parent
821351be04
commit
61a1f596cc
|
@ -1218,7 +1218,7 @@ Error GDCompiler::_parse_function(GDScript *p_script,const GDParser::ClassNode *
|
||||||
|
|
||||||
bool is_initializer=!p_for_ready && !p_func;
|
bool is_initializer=!p_for_ready && !p_func;
|
||||||
|
|
||||||
if (is_initializer || String(p_func->name)=="_init") {
|
if (is_initializer || (p_func && String(p_func->name)=="_init")) {
|
||||||
//parse initializer for class members
|
//parse initializer for class members
|
||||||
if (!p_func && p_class->extends_used && p_script->native.is_null()){
|
if (!p_func && p_class->extends_used && p_script->native.is_null()){
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue