mirror of
https://github.com/ziglang/zig.git
synced 2024-11-27 15:42:49 +00:00
22 lines
330 B
Zig
22 lines
330 B
Zig
const builtin = @import("builtin");
|
|
|
|
const Namespace = struct {
|
|
test "thingy" {}
|
|
};
|
|
|
|
fn thingy(a: usize, b: usize) usize {
|
|
return a + b;
|
|
}
|
|
|
|
comptime {
|
|
_ = Namespace;
|
|
}
|
|
|
|
test "thingy" {}
|
|
|
|
test thingy {
|
|
if (builtin.zig_backend == .stage2_spirv64) return error.SkipZigTest;
|
|
|
|
if (thingy(1, 2) != 3) unreachable;
|
|
}
|