Files
rust/tests/ui/consts/fn_trait_refs.stderr

192 lines
7.2 KiB
Plaintext

error[E0635]: unknown feature `const_fn_trait_ref_impls`
--> $DIR/fn_trait_refs.rs:3:12
|
LL | #![feature(const_fn_trait_ref_impls)]
| ^^^^^^^^^^^^^^^^^^^^^^^^
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:14:6
|
LL | T: [const] Fn<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `Fn`
|
note: `Fn` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:14:6
|
LL | T: [const] Fn<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `Fn`
|
note: `Fn` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:14:6
|
LL | T: [const] Fn<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `Fn`
|
note: `Fn` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:21:6
|
LL | T: [const] FnMut<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `FnMut`
|
note: `FnMut` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:21:6
|
LL | T: [const] FnMut<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `FnMut`
|
note: `FnMut` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:21:6
|
LL | T: [const] FnMut<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `FnMut`
|
note: `FnMut` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:28:6
|
LL | T: [const] FnOnce<()>,
| ^^^^^^^^^ can't be applied to `FnOnce`
|
note: `FnOnce` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:28:6
|
LL | T: [const] FnOnce<()>,
| ^^^^^^^^^ can't be applied to `FnOnce`
|
note: `FnOnce` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:28:6
|
LL | T: [const] FnOnce<()>,
| ^^^^^^^^^ can't be applied to `FnOnce`
|
note: `FnOnce` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:35:6
|
LL | T: [const] Fn<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `Fn`
|
note: `Fn` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:35:6
|
LL | T: [const] Fn<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `Fn`
|
note: `Fn` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:35:6
|
LL | T: [const] Fn<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `Fn`
|
note: `Fn` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:49:6
|
LL | T: [const] FnMut<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `FnMut`
|
note: `FnMut` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:49:6
|
LL | T: [const] FnMut<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `FnMut`
|
note: `FnMut` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `[const]` can only be applied to `#[const_trait]` traits
--> $DIR/fn_trait_refs.rs:49:6
|
LL | T: [const] FnMut<()> + [const] Destruct,
| ^^^^^^^^^ can't be applied to `FnMut`
|
note: `FnMut` can't be used with `[const]` because it isn't annotated with `#[const_trait]`
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error[E0277]: the trait bound `(i32, i32, i32): const PartialEq` is not satisfied
--> $DIR/fn_trait_refs.rs:71:17
|
LL | assert!(test_one == (1, 1, 1));
| ^^^^^^^^^^^^^^^^^^^^^
error[E0277]: the trait bound `(i32, i32): const PartialEq` is not satisfied
--> $DIR/fn_trait_refs.rs:74:17
|
LL | assert!(test_two == (2, 2));
| ^^^^^^^^^^^^^^^^^^
error[E0015]: cannot call non-const closure in constant functions
--> $DIR/fn_trait_refs.rs:16:5
|
LL | f()
| ^^^
|
= note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
error[E0015]: cannot call non-const closure in constant functions
--> $DIR/fn_trait_refs.rs:23:5
|
LL | f()
| ^^^
|
= note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
error[E0015]: cannot call non-const closure in constant functions
--> $DIR/fn_trait_refs.rs:30:5
|
LL | f()
| ^^^
|
= note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
error: aborting due to 21 previous errors
Some errors have detailed explanations: E0015, E0277, E0635.
For more information about an error, try `rustc --explain E0015`.