1#exe {
2-Mroot=main.zig
3#}
4
5#write main.zig {
6const std = @import("std");
7pub fn main() !void {
8 try std.Io.File.stdout().writeStreamingAll(io, "Hello, World!\n");
9}
10const io = std.Io.Threaded.global_single_threaded.io();
11#}
12#update "no compile log"
13#check stdout {
14Hello, World!
15#}
16
17#write main.zig {
18const std = @import("std");
19pub fn main() !void {
20 try std.Io.File.stdout().writeStreamingAll(io, "Hello, World!\n");
21 @compileLog("this is a log");
22}
23const io = std.Io.Threaded.global_single_threaded.io();
24#}
25#update "add compile log"
26#check errors {
27main.zig:4:5: error: found compile log statement
28
29Compile Log Output:
30@as(*const [13:0]u8, "this is a log")
31#}
32
33#write main.zig {
34const std = @import("std");
35pub fn main() !void {
36 try std.Io.File.stdout().writeStreamingAll(io, "Hello, World!\n");
37}
38const io = std.Io.Threaded.global_single_threaded.io();
39#}
40#update "remove compile log"
41#check stdout {
42Hello, World!
43#}