code wiki / (root) / smoke_call.nx

smoke_call.nx source

↩ module page · 12 lines · 264 B

1// smoke_call.nx -- verify a function call returns its value through the chain. 2 3import "syscalls.nx" 4 5func add(a: i64, b: i64) -> i64 { 6 return a + b 7} 8 9func main() -> i64 { 10 let v: i64 = add(15, 27) 11 return __syscall(93, v, 0, 0, 0, 0, 0) 12}