fix test typo

This commit is contained in:
kalsprite
2026-08-21 17:59:02 -07:00
parent f8bdfa0857
commit c29596e88f

View File

@@ -1,25 +1,9 @@
// The field comparison that guards this had been reading a type's name as its field list, so
// signatures this different were accepted whenever the two names differed in length
// Two declarations of the same foreign symbol whose parameters reach a named struct through a
// slice or a field read the wrong member of the type union and segfaulted the compiler
package test_issues
foreign import lib "this_library_does_not_exist"
Ints :: struct { a: i32, b: i32 }
Floats :: struct { c: f32, d: f32 }
@(default_calling_convention="c")
foreign lib {
@(link_name="mismatched") mismatched_1 :: proc(x: []Ints) ---
}
@(default_calling_convention="c")
foreign lib {
@(link_name="mismatched") mismatched_2 :: proc(x: []Floats) ---
}
// Two declarations of the same foreign symbol whose parameters reach a named struct through a
// slice or a field read the wrong member of the type union and segfaulted the compiler
Inner :: struct { a: i32, b: i32 }
Other :: struct { c: i32, d: i32 }