-Rust only supports variadic parameters for interoperability with C code in its
-FFI. As such, variadic parameters can only be used with functions which are
-using the C ABI. Examples of erroneous code:
-
-```compile_fail
-#![feature(unboxed_closures)]
+Variadic parameters have been used on a non-C ABI function.
-extern "rust-call" { fn foo(x: u8, ...); }
+Erroneous code example:
-// or
+```compile_fail,E0045
+#![feature(unboxed_closures)]
-fn foo(x: u8, ...) {}
+extern "rust-call" {
+ fn foo(x: u8, ...); // error!
+}
```
-To fix such code, put them in an extern "C" block:
+Rust only supports variadic parameters for interoperability with C code in its
+FFI. As such, variadic parameters can only be used with functions which are
+using the C ABI. To fix such code, put them in an extern "C" block:
```
extern "C" {