#E0025: unsupported ABI
An extern names an ABI Nabi does not support, or leaves it out. Write extern "C" (or "system" for the platform's system calls).
nabi
extern "fastcall" {
fn abs(x: i32) -> i32;
}
error[E0025]: unsupported ABI `"fastcall"` (`"C"`, `"system"`, `"objc"`, or `"nabi"` for the runtime) --> main.nabi:1:1 | 1 | extern "fastcall" { | ^^^^^^
Write "C":
nabi
extern "C" {
fn abs(x: i32) -> i32;
}
println(f"{unsafe { abs(-3) }}");
3
Related: E0084 invalid foreign-function use
Found a mistake? Edit this page on GitHub. Last updated