zig/test/hello.zig
Andrew Kelley 09f68c7c33 support linker directives
now you can depend on libc in zig language instead of it being
hardcoded in the compiler.
2015-11-24 23:44:41 -07:00

11 lines
165 B
Zig

#link("c")
extern {
fn puts(s: *mut u8) -> i32;
fn exit(code: i32) -> unreachable;
}
fn _start() -> unreachable {
puts("Hello, world!");
exit(0);
}