No longer show completions for declarations in aggregate types when

field accessing instances of those types.
This commit is contained in:
Alexandros Naskos 2021-05-08 19:30:22 +03:00
parent 5631b8d202
commit 759a7b7fd9
No known key found for this signature in database
GPG Key ID: 02BF2E72B0EA32D2

View File

@ -2103,6 +2103,11 @@ fn iterateSymbolsContainerInternal(
if (node_tags[node].isContainerField()) { if (node_tags[node].isContainerField()) {
if (!instance_access and !is_enum) continue; if (!instance_access and !is_enum) continue;
if (instance_access and is_enum) continue; if (instance_access and is_enum) continue;
} else if (node_tags[node] == .global_var_decl or
node_tags[node] == .local_var_decl or
node_tags[node] == .simple_var_decl or
node_tags[node] == .aligned_var_decl) {
if (instance_access) continue;
} }
}, },
.label_decl => continue, .label_decl => continue,