### Godot version

Beta 17, master

### System information

Windows 11

### Issue description

Godot gets a hard crash while attempting to code-complete for member `const` of a class.

### Steps to reproduce

```GDScript
enum E { V1 }

const e := E
```

And then type a `.` after the last `E`, which triggers code hints/auto-completion for subscripts based on `E` and causes a hard crash.

Does not happen for `var e := E.V1`.

### Minimal reproduction project

See above.
for (int i = 0; i < p_array->elements.size(); i++) {
		GDScriptParser::ExpressionNode *element_node = p_array->elements[i];
		if (element_node->is_constant) {
			update_const_expression_builtin_type(element_node, p_element_type, "include");
		}
		const GDScriptParser::DataType &element_type = element_node->get_datatype();
		if (element_type.has_no_type() || element_type.is_variant() || !element_type.is_hard_type()) {
			mark_node_unsafe(element_node);
			continue;
		}
		if (!is_type_compatible(p_element_type, element_type, true, p_array)) {
			push_error(vformat(R"(Cannot have an element of type "%s" in an array of type "Array[%s]".)", element_type.to_string(), p_element_type.to_string()), element_node);
			return;
		}
	}
	GDScriptParser::DataType array_type = p_array->get_datatype();
	array_type.set_container_element_type(p_element_type);
	p_array->set_datatype(array_type);
}
void GDScriptAnalyzer::reduce_assignment(GDScriptParser::AssignmentNode *p_assignment) {