From 1376c5a617be5c25655d0d7cb63e3beaa5a6e026 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:20:39 +0200 Subject: Merging upstream version 1.70.0+dfsg1. Signed-off-by: Daniel Baumann --- tests/ui/consts/const-block-const-bound.stderr | 38 ++++++++------------------ 1 file changed, 12 insertions(+), 26 deletions(-) (limited to 'tests/ui/consts/const-block-const-bound.stderr') diff --git a/tests/ui/consts/const-block-const-bound.stderr b/tests/ui/consts/const-block-const-bound.stderr index b9c4d8866..fef4914fa 100644 --- a/tests/ui/consts/const-block-const-bound.stderr +++ b/tests/ui/consts/const-block-const-bound.stderr @@ -1,44 +1,30 @@ error[E0277]: can't drop `UnconstDrop` in const contexts - --> $DIR/const-block-const-bound.rs:20:11 + --> $DIR/const-block-const-bound.rs:20:9 | LL | f(UnconstDrop); - | - ^^^^^^^^^^^ the trait `~const Destruct` is not implemented for `UnconstDrop` - | | - | required by a bound introduced by this call + | ^^^^^^^^^^^^^^ the trait `~const Destruct` is not implemented for `UnconstDrop` | = note: the trait bound `UnconstDrop: ~const Destruct` is not satisfied -note: required by a bound in `f` - --> $DIR/const-block-const-bound.rs:6:15 - | -LL | const fn f(x: T) {} - | ^^^^^^^^^^^^^^^ required by this bound in `f` help: consider borrowing here | -LL | f(&UnconstDrop); - | + -LL | f(&mut UnconstDrop); - | ++++ +LL | &f(UnconstDrop); + | + +LL | &mut f(UnconstDrop); + | ++++ error[E0277]: can't drop `NonDrop` in const contexts - --> $DIR/const-block-const-bound.rs:22:11 + --> $DIR/const-block-const-bound.rs:22:9 | LL | f(NonDrop); - | - ^^^^^^^ the trait `~const Destruct` is not implemented for `NonDrop` - | | - | required by a bound introduced by this call + | ^^^^^^^^^^ the trait `~const Destruct` is not implemented for `NonDrop` | = note: the trait bound `NonDrop: ~const Destruct` is not satisfied -note: required by a bound in `f` - --> $DIR/const-block-const-bound.rs:6:15 - | -LL | const fn f(x: T) {} - | ^^^^^^^^^^^^^^^ required by this bound in `f` help: consider borrowing here | -LL | f(&NonDrop); - | + -LL | f(&mut NonDrop); - | ++++ +LL | &f(NonDrop); + | + +LL | &mut f(NonDrop); + | ++++ error: aborting due to 2 previous errors -- cgit v1.2.3