### Godot version

4.0.beta10

### System information

Windows 11

### Issue description
UPDATE: This problem only occurs when the source code contains inner classes

Before 4.0.Beta9, I could get a GDScript instance by `GDScript.new()` and then set the `source_code` property and then `reload()`, but now it throws an error 
```
USER SCRIPT ERROR: Parse Error: Could not find script "".
   at: GDScript::reload (built-in:1644)
```
In my software, I use the above method when the user modifies the code text, and then read the godot log to implement real-time error checking of the custom user script editor. But now this functionality is completely broken

### Steps to reproduce

1. Create a GDScript instance by `GDScript.new()`
2. set the `source_code` property and then `reload()`

### Minimal reproduction project

N/A
DocData::method_doc_from_methodinfo(method_doc, methods[i], doc_functions[methods[i].name]);
		} else {
			DocData::method_doc_from_methodinfo(method_doc, methods[i], String());
		}
		doc.methods.push_back(method_doc);
	}
	List<PropertyInfo> props;
	_get_script_property_list(&props, false);
	for (int i = 0; i < props.size(); i++) {
		if (props[i].usage & PROPERTY_USAGE_CATEGORY || props[i].usage & PROPERTY_USAGE_GROUP || props[i].usage & PROPERTY_USAGE_SUBGROUP) {
			continue;
		}
		ScriptMemberInfo scr_member_info;
		scr_member_info.propinfo = props[i];
		scr_member_info.propinfo.usage |= PROPERTY_USAGE_NIL_IS_VARIANT;
		if (member_indices.has(props[i].name)) {
			const MemberInfo &mi = member_indices[props[i].name];
			scr_member_info.setter = mi.setter;
			scr_member_info.getter = mi.getter;
			if (mi.data_type.kind == GDScriptDataType::GDSCRIPT) {
				scr_member_info.propinfo.class_name = _get_gdscript_reference_class_name(
						Object::cast_to<GDScript>(mi.data_type.script_type));
			}
		}
		if (member_default_values.has(props[i].name)) {
			scr_member_info.has_default_value = true;
			scr_member_info.default_value = member_default_values[props[i].name];
		}
		if (doc_variables.has(props[i].name)) {
			scr_member_info.doc_string = doc_variables[props[i].name];