mirror of
https://github.com/godotengine/godot.git
synced 2025-11-01 06:01:14 +00:00
GDScript: Add disassembling implicit and lambda functions
This commit is contained in:
parent
d09d82d433
commit
a73573b093
4 changed files with 77 additions and 36 deletions
|
|
@ -2266,7 +2266,7 @@ GDScriptFunction *GDScriptCompiler::_parse_function(Error &r_error, GDScript *p_
|
|||
return_type = _gdtype_from_datatype(p_func->get_datatype(), p_script);
|
||||
} else {
|
||||
if (p_for_ready) {
|
||||
func_name = SceneStringName(_ready);
|
||||
func_name = "@implicit_ready";
|
||||
} else {
|
||||
func_name = "@implicit_new";
|
||||
}
|
||||
|
|
@ -2351,7 +2351,7 @@ GDScriptFunction *GDScriptCompiler::_parse_function(Error &r_error, GDScript *p_
|
|||
}
|
||||
|
||||
if (field->onready != is_implicit_ready) {
|
||||
// Only initialize in @implicit_ready.
|
||||
// Only initialize in `@implicit_ready()`.
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
@ -2953,7 +2953,7 @@ Error GDScriptCompiler::_compile_class(GDScript *p_script, const GDScriptParser:
|
|||
}
|
||||
|
||||
{
|
||||
// Create an implicit constructor in any case.
|
||||
// Create `@implicit_new()` special function in any case.
|
||||
Error err = OK;
|
||||
_parse_function(err, p_script, p_class, nullptr);
|
||||
if (err) {
|
||||
|
|
@ -2962,7 +2962,7 @@ Error GDScriptCompiler::_compile_class(GDScript *p_script, const GDScriptParser:
|
|||
}
|
||||
|
||||
if (p_class->onready_used) {
|
||||
// Create an implicit_ready constructor.
|
||||
// Create `@implicit_ready()` special function.
|
||||
Error err = OK;
|
||||
_parse_function(err, p_script, p_class, nullptr, true);
|
||||
if (err) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue