### Godot version

4.1.3

### System information

Linux

### Issue description

I'm trying to make an editor plugin on Rust:

```rust
#[derive(GodotClass)]
#[class(tool, editor_plugin, init, base=EditorPlugin)]
pub struct MyEditorPluginBase {}
```

But due to some limitations, I still have to use GDScript for some specific things.

So I tried to make a subclass of this Rust class:

```gdscript
@tool
class_name MyEditorPlugin
extends MyEditorPluginBase
```

This would work if `MyEditorPluginBase` was a GDScript class, but since it's a GDExtension class in my case, it doesn't work:

> Unable to load addon script from path: 'res://addons/my_addon/my_editor_plugin.gd' Base type is not EditorPlugin.

But it obviously **IS** EditorPlugin!

![godot-editorplugin-docs](https://github.com/godotengine/godot/assets/3236464/4665deeb-30f0-45cd-bfff-56101b9d4875)

![godot-editorplugin](https://github.com/godotengine/godot/assets/3236464/b1b6ecb4-de22-4abd-91a3-e180691f67ee)

If I understand correctly, this behavior is caused by this function, which checks some mysterious "instance base type" instead of real inheritance:

https://github.com/godotengine/godot/blob/fa4a65387ea41506ecc519fc61a06da110dce51c/editor/editor_node.cpp#L3456-L3458

https://github.com/godotengine/godot/blob/fa4a65387ea41506ecc519fc61a06da110dce51c/modules/gdscript/gdscript.cpp#L260-L263

Since the [documentation](https://docs.godotengine.org/en/stable/tutorials/plugins/editor/making_plugins.html#the-script-file) doesn't say that the script must be a **direct** subclass of EditorPlugin (and an indirect subclass works fine in GDScript), I interpret this behavior as a Godot bug.

### Steps to reproduce

See above

### Minimal reproduction project

[gdext_editor_plugin_test.zip](https://github.com/godotengine/godot/files/13451014/gdext_editor_plugin_test.zip)
node_tc->set_themes(editor_themes);
	} else {
		ThemeDB::get_singleton()->create_theme_context(this, editor_themes);
	}
	Window *window = get_window();
	if (window) {
		ThemeContext *window_tc = ThemeDB::get_singleton()->get_theme_context(window);
		if (window_tc) {
			window_tc->set_themes(editor_themes);
		} else {
			ThemeDB::get_singleton()->create_theme_context(window, editor_themes);
		}
	}
	if (CanvasItemEditor::get_singleton()->get_theme_preview() == CanvasItemEditor::THEME_PREVIEW_EDITOR) {
		update_preview_themes(CanvasItemEditor::THEME_PREVIEW_EDITOR);
	}
	gui_base->add_theme_style_override("panel", theme->get_stylebox(SNAME("Background"), EditorStringName(EditorStyles)));
	main_vbox->set_anchors_and_offsets_preset(Control::PRESET_FULL_RECT, Control::PRESET_MODE_MINSIZE, theme->get_constant(SNAME("window_border_margin"), EditorStringName(Editor)));
	main_vbox->add_theme_constant_override("separation", theme->get_constant(SNAME("top_bar_separation"), EditorStringName(Editor)));
	scene_root_parent->add_theme_style_override("panel", theme->get_stylebox(SNAME("Content"), EditorStringName(EditorStyles)));
	bottom_panel->add_theme_style_override("panel", theme->get_stylebox(SNAME("BottomPanel"), EditorStringName(EditorStyles)));
	main_menu->add_theme_style_override("hover", theme->get_stylebox(SNAME("MenuHover"), EditorStringName(EditorStyles)));
	distraction_free->set_icon(theme->get_icon(SNAME("DistractionFree"), EditorStringName(EditorIcons)));
	bottom_panel_raise->set_icon(theme->get_icon(SNAME("ExpandBottomDock"), EditorStringName(EditorIcons)));
	if (gui_base->is_layout_rtl()) {
		dock_tab_move_left->set_icon(theme->get_icon(SNAME("Forward"), EditorStringName(EditorIcons)));
		dock_tab_move_right->set_icon(theme->get_icon(SNAME("Back"), EditorStringName(EditorIcons)));
	} else {
		dock_tab_move_left->set_icon(theme->get_icon(SNAME("Back"), EditorStringName(EditorIcons)));
		dock_tab_move_right->set_icon(theme->get_icon(SNAME("Forward"), EditorStringName(EditorIcons)));