diff options
| author | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-09-28 19:57:46 -0400 |
|---|---|---|
| committer | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-09-28 19:57:46 -0400 |
| commit | 8108406b5c7be2875502260a0168636976a7bbbc (patch) | |
| tree | 31cccb32c1939d64eeb5d52730890f83d27b2e61 /tests | |
| parent | 342fdfdd764311beda4efd1c185cbee8b12e864f (diff) | |
Find and replace poly types for call expr
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/hover_test.odin | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/hover_test.odin b/tests/hover_test.odin index d0b844e..f2ff18c 100644 --- a/tests/hover_test.odin +++ b/tests/hover_test.odin @@ -5112,6 +5112,29 @@ ast_hover_matrix_index_twice :: proc(t: ^testing.T) { } test.expect_hover(t, &source, "test.b: f32") } + +@(test) +ast_hover_parapoly_proc_slice_param_return :: proc(t: ^testing.T) { + source := test.Source { + main = `package test + + Iter :: struct(T: typeid) { + slice: []T, + index: int, + } + + make_iter :: proc(slice: []$T) -> Iter(T) { + return { slice, 0 } + } + + main :: proc() { + slice := []string{} + i{*}t := make_iter(slice) + } + `, + } + test.expect_hover(t, &source, "test.it: test.Iter(string)") +} /* Waiting for odin fix |