zig/test/behavior/bugs/12043.zig
Cody Tapscott b1357091ae Add test case for #12043
This bug is already resolved, just want to make sure we don't lose
the test case. Closes #12043
2022-11-10 12:23:59 -07:00

13 lines
182 B
Zig

const std = @import("std");
const expect = std.testing.expect;
var ok = false;
fn foo(x: anytype) void {
ok = x;
}
test {
const x = &foo;
x(true);
try expect(ok);
}