diff options
| author | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-07-01 09:29:45 -0400 |
|---|---|---|
| committer | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-07-01 09:29:45 -0400 |
| commit | 75bc2135dbc17e2770c3ec8e3585d481a0b100bb (patch) | |
| tree | 1633c8d7b7d98eb990c8143f7cffd6c54ec7a957 /tests | |
| parent | 8e6ddab0ed0b17230103d4a4a563c7f6b3b6e775 (diff) | |
As struct poly info to hover information
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/hover_test.odin | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/hover_test.odin b/tests/hover_test.odin index 1511af6..b91ed6b 100644 --- a/tests/hover_test.odin +++ b/tests/hover_test.odin @@ -1595,6 +1595,7 @@ ast_hover_distinct_definition_external_package :: proc(t: ^testing.T) { test.expect_hover(t, &source, "my_package.A: distinct u64") } + @(test) ast_hover_poly_type :: proc(t: ^testing.T) { source := test.Source { @@ -1723,6 +1724,19 @@ ast_hover_poly_type_external_package_with_external_type :: proc(t: ^testing.T) { test.expect_hover(t, &source, "test.foo: small_array.Foo :: struct {}") } + +@(test) +ast_hover_struct_poly_type :: proc(t: ^testing.T) { + source := test.Source { + main = `package test + F{*}oo :: struct($T: typeid) { + foo: T, + } + `, + } + + test.expect_hover(t, &source, "test.Foo: struct($T: typeid) {\n\tfoo: T,\n}") +} /* Waiting for odin fix |