mirror of
https://codeberg.org/ziglang/zig.git
synced 2026-05-21 08:32:02 +03:00
e411467e1d
it gets implicitly casted to whatever is needed. closes #24
13 lines
225 B
Zig
13 lines
225 B
Zig
export executable "hello";
|
|
|
|
#link("c")
|
|
extern {
|
|
fn printf(__format: *const u8, ...) -> i32;
|
|
fn exit(__status: i32) -> unreachable;
|
|
}
|
|
|
|
export fn _start() -> unreachable {
|
|
printf(c"Hello, world!\n");
|
|
exit(0);
|
|
}
|