2022-04-27 21:37:54 +08:00
|
|
|
pub fn main() void {
|
|
|
|
const number = 1234;
|
|
|
|
const x = asm volatile ("syscall"
|
|
|
|
: [o] "{rax}" (-> number),
|
|
|
|
: [number] "{rax}" (231),
|
|
|
|
[arg1] "{rdi}" (60),
|
|
|
|
: "rcx", "r11", "memory"
|
|
|
|
);
|
|
|
|
_ = x;
|
|
|
|
}
|
|
|
|
|
|
|
|
// error
|
|
|
|
// output_mode=Exe
|
|
|
|
// target=x86_64-linux
|
|
|
|
//
|
2022-06-27 23:32:59 +08:00
|
|
|
// :4:27: error: expected type 'type', found 'comptime_int'
|