Commit c4d297b1af
Changed files (3)
test
test/cases/x86_64-windows/hello_world_with_updates.0.zig
@@ -0,0 +1,6 @@
+// error
+// output_mode=Exe
+// target=x86_64-windows
+//
+// :130:9: error: struct 'tmp.tmp' has no member named 'main'
+// :7:1: note: struct declared here
test/cases/x86_64-windows/hello_world_with_updates.1.zig
@@ -0,0 +1,6 @@
+pub export fn main() noreturn {}
+
+// error
+//
+// :1:32: error: function declared 'noreturn' returns
+// :1:22: note: 'noreturn' declared here
test/cases/x86_64-windows/hello_world_with_updates.2.zig
@@ -0,0 +1,16 @@
+const std = @import("std");
+
+pub fn main() void {
+ print();
+}
+
+fn print() void {
+ const msg = "Hello, World!\n";
+ const stdout = std.io.getStdOut();
+ stdout.writeAll(msg) catch unreachable;
+}
+
+// run
+//
+// Hello, World!
+//