aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorBradley Lewis <22850972+BradLewis@users.noreply.github.com>2025-10-28 05:55:11 -0400
committerGitHub <noreply@github.com>2025-10-28 05:55:11 -0400
commite8b2b18f24973c4bde9e235cb083043a896fb705 (patch)
tree0a49750e76553865431aa4803eee5e4b993e2eb0 /tests
parentffb7b58d3841cf50103ab21148b814a3ad29afa4 (diff)
parent23f9be141bb0f7dc5eb35f395d5cf4011edac836 (diff)
Merge pull request #1127 from BradLewis/fix/enum-completion-array-values
Correctly resolve enum types that are array values
Diffstat (limited to 'tests')
-rw-r--r--tests/completions_test.odin18
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/completions_test.odin b/tests/completions_test.odin
index 01f718b..7b12828 100644
--- a/tests/completions_test.odin
+++ b/tests/completions_test.odin
@@ -4828,3 +4828,21 @@ ast_completion_named_proc_arg_comp_lit :: proc(t: ^testing.T) {
}
test.expect_completion_docs(t, &source, "", {"Bar.bar: int"})
}
+
+@(test)
+ast_completion_fixed_array_enum :: proc(t: ^testing.T) {
+ source := test.Source {
+ main = `package test
+ Foo :: enum {
+ A,
+ B,
+ C,
+ }
+
+ foos := [3]Foo {
+ .{*}
+ }
+ `,
+ }
+ test.expect_completion_docs(t, &source, "", {"A", "B", "C"})
+}