From 0124b513cd0dc8f1c8c4233b258ff7e6e4a59e57 Mon Sep 17 00:00:00 2001 From: Emmanuel Leblond Date: Tue, 26 Dec 2023 12:24:56 +0100 Subject: [PATCH] Fix `ScriptLanguageExtension::_find_function` documentation --- core/object/script_language_extension.cpp | 2 +- doc/classes/ScriptLanguageExtension.xml | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/core/object/script_language_extension.cpp b/core/object/script_language_extension.cpp index 79f39cb62664..be62cabe259d 100644 --- a/core/object/script_language_extension.cpp +++ b/core/object/script_language_extension.cpp @@ -107,7 +107,7 @@ void ScriptLanguageExtension::_bind_methods() { GDVIRTUAL_BIND(_supports_builtin_mode); GDVIRTUAL_BIND(_supports_documentation); GDVIRTUAL_BIND(_can_inherit_from_file); - GDVIRTUAL_BIND(_find_function, "class_name", "function_name"); + GDVIRTUAL_BIND(_find_function, "function", "code"); GDVIRTUAL_BIND(_make_function, "class_name", "function_name", "function_args"); GDVIRTUAL_BIND(_open_in_external_editor, "script", "line", "column"); GDVIRTUAL_BIND(_overrides_external_editor); diff --git a/doc/classes/ScriptLanguageExtension.xml b/doc/classes/ScriptLanguageExtension.xml index b4e2f406127c..c5248f48889b 100644 --- a/doc/classes/ScriptLanguageExtension.xml +++ b/doc/classes/ScriptLanguageExtension.xml @@ -114,9 +114,10 @@ - - + + + Returns the line where the function is defined in the code, or [code]-1[/code] if the function is not present.