### Godot version

4.0.beta10.mono.official

### System information

Windows 11

### Issue description

After registering a C# Script with Autoload and trying to connect to a signal using the `Signal.connect` method (`Singleton.Signal.connect(xxx)`) fails with `Invalid get index 'Signal' (on base: 'Node (Singleton.cs)'). But with `Object.connect` it works.

### Steps to reproduce

- Create a C# class script with a Signal named `Signal` (could be any other).
- Register it with Autoload with the name `Singleton` (could be any other).
- Create a GDScript script and try to connect the Singleton's signal using `Singleton.Signal.connect(xxx)`
- When running the project it fails with `Invalid get index 'Sample' (on base: 'Node (Singleton.cs)').`

### Minimal reproduction project

[example.zip](https://github.com/godotengine/godot/files/10414500/example.zip)

r_enum_itype.cs_type = r_enum_itype.proxy_name;
	r_enum_itype.cs_in_expr = "(int)%0";
	r_enum_itype.cs_out = "%5return (%2)%0(%1);";
	{
		
		r_enum_itype.c_in = "%5%0 %1_in = %1;\n";
		r_enum_itype.c_out = "%5return (%0)%1;\n";
		r_enum_itype.c_type = "long";
		r_enum_itype.c_arg_in = "&%s_in";
	}
	r_enum_itype.c_type_in = "int";
	r_enum_itype.c_type_out = r_enum_itype.c_type_in;
	r_enum_itype.class_doc = &EditorHelp::get_doc_data()->class_list[r_enum_itype.proxy_name];
}
static String fix_doc_description(const String &p_bbcode) {
	
	return p_bbcode.dedent()
			.replace("\t", "")
			.replace("\r", "")
			.strip_edges();
}
static String snake_to_pascal_case(const String &p_identifier, bool p_input_is_upper = false) {