Re-allow indexing on "self" and object types in GDScript

Fixes #25081
This commit is contained in:
Bojidar Marinov 2019-09-02 15:38:32 +03:00
parent 7e731bbce2
commit e3d05fa42d
No known key found for this signature in database
GPG key ID: 4B0FD31949AD430D

View file

@ -6510,7 +6510,7 @@ GDScriptParser::DataType GDScriptParser::_reduce_node_type(Node *p_node) {
return DataType(); return DataType();
} }
} }
if (check_types && !node_type.has_type) { if (check_types && !node_type.has_type && base_type.kind == DataType::BUILTIN) {
// Can infer indexing type for some variant types // Can infer indexing type for some variant types
DataType result; DataType result;
result.has_type = true; result.has_type = true;