diff options
Diffstat (limited to 'tests/ui/traits/const-traits/const-closures.stderr')
| -rw-r--r-- | tests/ui/traits/const-traits/const-closures.stderr | 80 |
1 files changed, 40 insertions, 40 deletions
diff --git a/tests/ui/traits/const-traits/const-closures.stderr b/tests/ui/traits/const-traits/const-closures.stderr index 92f3ba20820..c76a73418a5 100644 --- a/tests/ui/traits/const-traits/const-closures.stderr +++ b/tests/ui/traits/const-traits/const-closures.stderr @@ -1,76 +1,76 @@ -error: `~const` can only be applied to `#[const_trait]` traits - --> $DIR/const-closures.rs:8:12 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:8:10 | -LL | F: ~const FnOnce() -> u8, - | ^^^^^^ can't be applied to `FnOnce` +LL | F: [const] FnOnce() -> u8, + | ^^^^^^^^^ can't be applied to `FnOnce` | -note: `FnOnce` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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/const-closures.rs:9:12 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:9:10 | -LL | F: ~const FnMut() -> u8, - | ^^^^^^ can't be applied to `FnMut` +LL | F: [const] FnMut() -> u8, + | ^^^^^^^^^ can't be applied to `FnMut` | -note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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/const-closures.rs:10:12 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:10:10 | -LL | F: ~const Fn() -> u8, - | ^^^^^^ can't be applied to `Fn` +LL | F: [const] Fn() -> u8, + | ^^^^^^^^^ can't be applied to `Fn` | -note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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/const-closures.rs:8:12 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:8:10 | -LL | F: ~const FnOnce() -> u8, - | ^^^^^^ can't be applied to `FnOnce` +LL | F: [const] FnOnce() -> u8, + | ^^^^^^^^^ can't be applied to `FnOnce` | -note: `FnOnce` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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/const-closures.rs:9:12 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:9:10 | -LL | F: ~const FnMut() -> u8, - | ^^^^^^ can't be applied to `FnMut` +LL | F: [const] FnMut() -> u8, + | ^^^^^^^^^ can't be applied to `FnMut` | -note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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/const-closures.rs:10:12 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:10:10 | -LL | F: ~const Fn() -> u8, - | ^^^^^^ can't be applied to `Fn` +LL | F: [const] Fn() -> u8, + | ^^^^^^^^^ can't be applied to `Fn` | -note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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/const-closures.rs:23:20 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:23:18 | -LL | const fn answer<F: ~const Fn() -> u8>(f: &F) -> u8 { - | ^^^^^^ can't be applied to `Fn` +LL | const fn answer<F: [const] Fn() -> u8>(f: &F) -> u8 { + | ^^^^^^^^^ can't be applied to `Fn` | -note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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/const-closures.rs:23:20 +error: `[const]` can only be applied to `#[const_trait]` traits + --> $DIR/const-closures.rs:23:18 | -LL | const fn answer<F: ~const Fn() -> u8>(f: &F) -> u8 { - | ^^^^^^ can't be applied to `Fn` +LL | const fn answer<F: [const] Fn() -> u8>(f: &F) -> u8 { + | ^^^^^^^^^ can't be applied to `Fn` | -note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]` +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` |
