master
1#target=x86_64-linux-selfhosted
2#target=x86_64-windows-selfhosted
3#target=x86_64-linux-cbe
4#target=x86_64-windows-cbe
5#target=wasm32-wasi-selfhosted
6#update=initial version with compile error
7#file=main.zig
8pub fn main() void {}
9comptime {
10 @compileError("this is an error");
11}
12comptime {
13 @compileLog("this is a log");
14}
15#expect_error=main.zig:3:5: error: this is an error
16#expect_compile_log=@as(*const [13:0]u8, "this is a log")
17
18#update=remove the compile error
19#file=main.zig
20pub fn main() void {}
21comptime {
22 //@compileError("this is an error");
23}
24comptime {
25 @compileLog("this is a log");
26}
27#expect_error=main.zig:6:5: error: found compile log statement
28#expect_compile_log=@as(*const [13:0]u8, "this is a log")