Zig Version
0.11.0-dev.2969+855493bb8
Steps to Reproduce and Observed Behavior
conststd=@import("std");
pubfnmain() void {}
test {
std.debug.print("\nNew line!\n", .{});
returnerror.ThisIsAnError;
}Put this in a blank zig project and run zig build test. This causes this output:
run test: error: 'test_0' failed: New line!
/home/emma/zig-bugs/newline/src/main.zig:7:5: 0x20efe9 in test_0 (test)
return error.ThisIsAnError;
^
run test: error: m
First, the leading newline before the message is stripped, and second an erroneous run test: error: m is printed.
Expected Behavior
Expected an output like this:
run test: error: 'test_0' failed:
New line!
/home/emma/zig-bugs/newline/src/main.zig:7:5: 0x20efe9 in test_0 (test)
return error.ThisIsAnError;
^
Zig Version
0.11.0-dev.2969+855493bb8
Steps to Reproduce and Observed Behavior
Put this in a blank zig project and run
zig build test. This causes this output:First, the leading newline before the message is stripped, and second an erroneous
run test: error: mis printed.Expected Behavior
Expected an output like this: