| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:5:19 |
| | |
| LL | fn f1_1(x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:8:9 |
| | |
| LL | fn f1_2(_: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` is not supported for `extern "Rust"` functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:11:30 |
| | |
| LL | unsafe extern "Rust" fn f1_3(_: ...) {} |
| | ------------- ^^^^^^ |
| | | |
| | `extern "Rust"` because of this |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: functions with a C variable argument list must be unsafe |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:14:30 |
| | |
| LL | extern "C" fn f2_1(x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| help: add the `unsafe` keyword to this definition |
| | |
| LL | unsafe extern "C" fn f2_1(x: isize, _: ...) {} |
| | ++++++ |
| |
| error: functions with a C variable argument list must be unsafe |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:17:20 |
| | |
| LL | extern "C" fn f2_2(_: ...) {} |
| | ^^^^^^ |
| | |
| help: add the `unsafe` keyword to this definition |
| | |
| LL | unsafe extern "C" fn f2_2(_: ...) {} |
| | ++++++ |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:20:20 |
| | |
| LL | extern "C" fn f2_3(_: ..., x: isize) {} |
| | ^^^^^^ |
| |
| error: functions with a C variable argument list must be unsafe |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:23:30 |
| | |
| LL | extern "C" fn f3_1(x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| help: add the `unsafe` keyword to this definition |
| | |
| LL | unsafe extern "C" fn f3_1(x: isize, _: ...) {} |
| | ++++++ |
| |
| error: functions with a C variable argument list must be unsafe |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:26:20 |
| | |
| LL | extern "C" fn f3_2(_: ...) {} |
| | ^^^^^^ |
| | |
| help: add the `unsafe` keyword to this definition |
| | |
| LL | unsafe extern "C" fn f3_2(_: ...) {} |
| | ++++++ |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:29:20 |
| | |
| LL | extern "C" fn f3_3(_: ..., x: isize) {} |
| | ^^^^^^ |
| |
| error[E0658]: c-variadic const function definitions are unstable |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:32:1 |
| | |
| LL | const unsafe extern "C" fn f4_1(x: isize, _: ...) {} |
| | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| | |
| = note: see issue #151787 <https://github.com/rust-lang/rust/issues/151787> for more information |
| = help: add `#![feature(const_c_variadic)]` to the crate attributes to enable |
| = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date |
| |
| error[E0658]: c-variadic const function definitions are unstable |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:36:1 |
| | |
| LL | const extern "C" fn f4_2(x: isize, _: ...) {} |
| | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| | |
| = note: see issue #151787 <https://github.com/rust-lang/rust/issues/151787> for more information |
| = help: add `#![feature(const_c_variadic)]` to the crate attributes to enable |
| = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date |
| |
| error: functions with a C variable argument list must be unsafe |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:36:36 |
| | |
| LL | const extern "C" fn f4_2(x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| help: add the `unsafe` keyword to this definition |
| | |
| LL | const unsafe extern "C" fn f4_2(x: isize, _: ...) {} |
| | ++++++ |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:41:26 |
| | |
| LL | const extern "C" fn f4_3(_: ..., x: isize, _: ...) {} |
| | ^^^^^^ |
| |
| error[E0658]: c-variadic const function definitions are unstable |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:41:1 |
| | |
| LL | const extern "C" fn f4_3(_: ..., x: isize, _: ...) {} |
| | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| | |
| = note: see issue #151787 <https://github.com/rust-lang/rust/issues/151787> for more information |
| = help: add `#![feature(const_c_variadic)]` to the crate attributes to enable |
| = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date |
| |
| error: functions with a C variable argument list must be unsafe |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:41:44 |
| | |
| LL | const extern "C" fn f4_3(_: ..., x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| help: add the `unsafe` keyword to this definition |
| | |
| LL | const unsafe extern "C" fn f4_3(_: ..., x: isize, _: ...) {} |
| | ++++++ |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:47:13 |
| | |
| LL | fn e_f2(..., x: isize); |
| | ^^^ |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:54:23 |
| | |
| LL | fn i_f1(x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:56:13 |
| | |
| LL | fn i_f2(_: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:58:13 |
| | |
| LL | fn i_f3(_: ..., x: isize, _: ...) {} |
| | ^^^^^^ |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:58:31 |
| | |
| LL | fn i_f3(_: ..., x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:61:13 |
| | |
| LL | fn i_f4(_: ..., x: isize, _: ...) {} |
| | ^^^^^^ |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:61:31 |
| | |
| LL | fn i_f4(_: ..., x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error[E0658]: c-variadic const function definitions are unstable |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:64:5 |
| | |
| LL | const fn i_f5(x: isize, _: ...) {} |
| | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| | |
| = note: see issue #151787 <https://github.com/rust-lang/rust/issues/151787> for more information |
| = help: add `#![feature(const_c_variadic)]` to the crate attributes to enable |
| = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:64:29 |
| | |
| LL | const fn i_f5(x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:71:23 |
| | |
| LL | fn t_f1(x: isize, _: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:73:23 |
| | |
| LL | fn t_f2(x: isize, _: ...); |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:75:13 |
| | |
| LL | fn t_f3(_: ...) {} |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` is not supported for non-extern functions |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:77:13 |
| | |
| LL | fn t_f4(_: ...); |
| | ^^^^^^ |
| | |
| = help: only `extern "C"` and `extern "C-unwind"` functions may have a C variable argument list |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:79:13 |
| | |
| LL | fn t_f5(_: ..., x: isize) {} |
| | ^^^^^^ |
| |
| error: `...` must be the last argument of a C-variadic function |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:81:13 |
| | |
| LL | fn t_f6(_: ..., x: isize); |
| | ^^^^^^ |
| |
| error[E0493]: destructor of `VaList<'_>` cannot be evaluated at compile-time |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:32:43 |
| | |
| LL | const unsafe extern "C" fn f4_1(x: isize, _: ...) {} |
| | ^ - value is dropped here |
| | | |
| | the destructor for this type cannot be evaluated in constant functions |
| | |
| = note: see issue #133214 <https://github.com/rust-lang/rust/issues/133214> for more information |
| = help: add `#![feature(const_destruct)]` to the crate attributes to enable |
| = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date |
| |
| error[E0493]: destructor of `VaList<'_>` cannot be evaluated at compile-time |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:36:36 |
| | |
| LL | const extern "C" fn f4_2(x: isize, _: ...) {} |
| | ^ - value is dropped here |
| | | |
| | the destructor for this type cannot be evaluated in constant functions |
| | |
| = note: see issue #133214 <https://github.com/rust-lang/rust/issues/133214> for more information |
| = help: add `#![feature(const_destruct)]` to the crate attributes to enable |
| = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date |
| |
| error[E0493]: destructor of `VaList<'_>` cannot be evaluated at compile-time |
| --> $DIR/variadic-ffi-semantic-restrictions.rs:64:29 |
| | |
| LL | const fn i_f5(x: isize, _: ...) {} |
| | ^ - value is dropped here |
| | | |
| | the destructor for this type cannot be evaluated in constant functions |
| | |
| = note: see issue #133214 <https://github.com/rust-lang/rust/issues/133214> for more information |
| = help: add `#![feature(const_destruct)]` to the crate attributes to enable |
| = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date |
| |
| error: aborting due to 33 previous errors |
| |
| Some errors have detailed explanations: E0493, E0658. |
| For more information about an error, try `rustc --explain E0493`. |