Rename variadic to c_variadic

Function signatures with the `variadic` member set are actually
C-variadic functions. Make this a little more explicit by renaming the
`variadic` boolean value, `c_variadic`.
This commit is contained in:
Dan Robertson 2019-02-08 17:30:42 +00:00
parent a618ad6335
commit 08bd4ff998
No known key found for this signature in database
GPG key ID: 4DE6EEF84B5C9783
43 changed files with 119 additions and 119 deletions

View file

@ -1,8 +1,8 @@
error[E0045]: variadic function must have C or cdecl calling convention
error[E0045]: C-variadic function must have C or cdecl calling convention
--> $DIR/variadic-ffi-1.rs:5:5
|
LL | fn printf(_: *const u8, ...); //~ ERROR: variadic function must have C or cdecl calling
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ variadics require C or cdecl calling convention
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ C-variadics require C or cdecl calling convention
error: aborting due to previous error

View file

@ -1,8 +1,8 @@
error[E0045]: variadic function must have C or cdecl calling convention
error[E0045]: C-variadic function must have C or cdecl calling convention
--> $DIR/variadic-ffi-2.rs:3:11
|
LL | fn baz(f: extern "stdcall" fn(usize, ...)) {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ variadics require C or cdecl calling convention
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ C-variadics require C or cdecl calling convention
error: aborting due to previous error

View file

@ -1,8 +1,8 @@
error[E0045]: variadic function must have C or cdecl calling convention
error[E0045]: C-variadic function must have C or cdecl calling convention
--> $DIR/E0045.rs:1:17
|
LL | extern "Rust" { fn foo(x: u8, ...); } //~ ERROR E0045
| ^^^^^^^^^^^^^^^^^^^ variadics require C or cdecl calling convention
| ^^^^^^^^^^^^^^^^^^^ C-variadics require C or cdecl calling convention
error: aborting due to previous error

View file

@ -1,3 +1,3 @@
extern "C" fn foo(x: u8, ...);
//~^ ERROR only foreign functions are allowed to be variadic
//~^ ERROR only foreign functions are allowed to be C-variadic
//~| ERROR expected one of `->`, `where`, or `{`, found `;`

View file

@ -1,4 +1,4 @@
error: only foreign functions are allowed to be variadic
error: only foreign functions are allowed to be C-variadic
--> $DIR/invalid-variadic-function.rs:1:26
|
LL | extern "C" fn foo(x: u8, ...);

View file

@ -1,5 +1,5 @@
fn foo(x: isize, ...) {
//~^ ERROR: only foreign functions are allowed to be variadic
//~^ ERROR: only foreign functions are allowed to be C-variadic
}
fn main() {}

View file

@ -1,4 +1,4 @@
error: only foreign functions are allowed to be variadic
error: only foreign functions are allowed to be C-variadic
--> $DIR/variadic-ffi-3.rs:1:18
|
LL | fn foo(x: isize, ...) {

View file

@ -1,5 +1,5 @@
extern "C" fn foo(x: isize, ...) {
//~^ ERROR: only foreign functions are allowed to be variadic
//~^ ERROR: only foreign functions are allowed to be C-variadic
}
fn main() {}

View file

@ -1,4 +1,4 @@
error: only foreign functions are allowed to be variadic
error: only foreign functions are allowed to be C-variadic
--> $DIR/variadic-ffi-4.rs:1:29
|
LL | extern "C" fn foo(x: isize, ...) {