### Godot version

4.1.stable

### System information

Linux 5.10.181-2-MANJARO

### Issue description

A class with a function defined like this:

```gdscript
class_name Foo extends Node

func my_func(arr: Array[int]) -> Array[int]:
	return arr

```

Will show up in the docs as:

![image](https://github.com/godotengine/godot/assets/9107253/a4b2f5a5-beab-4c8f-9a1f-dab39ea3ea6e)

Whereas i'd expect it to show up as
```
Array[int] my_func(arr: Array[int])
```

The same seems to be true for properties.

### Steps to reproduce

1. Add script
```gdscript
class_name Foo extends Node

func my_func(arr: Array[int]) -> Array[int]:
	return arr
```
2. open class `Foo` in help

### Minimal reproduction project

N/A
if (m_func->return_type) {
					mi.return_val = _property_info_from_datatype(m_func->return_type->get_datatype());
				}
				for (const GDScriptParser::ParameterNode *p : m_func->parameters) {
					PropertyInfo pi = _property_info_from_datatype(p->get_datatype());
					pi.name = p->identifier->name;
					mi.arguments.push_back(pi);
				}
				DocData::MethodDoc method_doc;
				DocData::method_doc_from_methodinfo(method_doc, mi, m_func->doc_data.description);
				method_doc.is_deprecated = m_func->doc_data.is_deprecated;
				method_doc.is_experimental = m_func->doc_data.is_experimental;
				doc.methods.push_back(method_doc);
			} break;
			case GDP::ClassNode::Member::SIGNAL: {
				const GDP::SignalNode *m_signal = member.signal;
				const StringName &signal_name = m_signal->identifier->name;
				p_script->member_lines[signal_name] = m_signal->start_line;
				MethodInfo mi;
				mi.name = signal_name;
				for (const GDScriptParser::ParameterNode *p : m_signal->parameters) {
					PropertyInfo pi = _property_info_from_datatype(p->get_datatype());
					pi.name = p->identifier->name;
					mi.arguments.push_back(pi);
				}
				DocData::MethodDoc signal_doc;
				DocData::signal_doc_from_methodinfo(signal_doc, mi, m_signal->doc_data.description);
				signal_doc.is_deprecated = m_signal->doc_data.is_deprecated;
				signal_doc.is_experimental = m_signal->doc_data.is_experimental;
				doc.signals.push_back(signal_doc);