11error[E0277]: the trait bound `NonTrivialDrop: ~const A` is not satisfied
22 --> $DIR/const-drop-fail-2.rs:31:23
33 |
4- LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(ConstDropImplWithBounds(PhantomData));
4+ LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(
55 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `~const A` is not implemented for `NonTrivialDrop`
66 |
77note: the trait `A` is implemented for `NonTrivialDrop`, but that implementation is not `const`
88 --> $DIR/const-drop-fail-2.rs:31:23
99 |
10- LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(ConstDropImplWithBounds(PhantomData));
10+ LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(
1111 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1212note: required by a bound in `ConstDropImplWithBounds`
1313 --> $DIR/const-drop-fail-2.rs:21:35
@@ -16,30 +16,30 @@ LL | struct ConstDropImplWithBounds<T: ~const A>(PhantomData<T>);
1616 | ^^^^^^^^ required by this bound in `ConstDropImplWithBounds`
1717
1818error[E0277]: the trait bound `NonTrivialDrop: ~const A` is not satisfied
19- --> $DIR/const-drop-fail-2.rs:31:64
19+ --> $DIR/const-drop-fail-2.rs:33:5
2020 |
21- LL | const _: () = check::< ConstDropImplWithBounds<NonTrivialDrop>>(ConstDropImplWithBounds( PhantomData));
22- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `~const A` is not implemented for `NonTrivialDrop`
21+ LL | ConstDropImplWithBounds( PhantomData)
22+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `~const A` is not implemented for `NonTrivialDrop`
2323 |
2424note: the trait `A` is implemented for `NonTrivialDrop`, but that implementation is not `const`
25- --> $DIR/const-drop-fail-2.rs:31:64
25+ --> $DIR/const-drop-fail-2.rs:33:5
2626 |
27- LL | const _: () = check::< ConstDropImplWithBounds<NonTrivialDrop>>(ConstDropImplWithBounds( PhantomData));
28- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
27+ LL | ConstDropImplWithBounds( PhantomData)
28+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2929note: required by a bound in `ConstDropImplWithBounds`
3030 --> $DIR/const-drop-fail-2.rs:21:35
3131 |
3232LL | struct ConstDropImplWithBounds<T: ~const A>(PhantomData<T>);
3333 | ^^^^^^^^ required by this bound in `ConstDropImplWithBounds`
3434
3535error[E0367]: `Drop` impl requires `T: ~const A` but the struct it is implemented for does not
36- --> $DIR/const-drop-fail-2.rs:37 :9
36+ --> $DIR/const-drop-fail-2.rs:39 :9
3737 |
3838LL | impl<T: ~const A> const Drop for ConstDropImplWithNonConstBounds<T> {
3939 | ^^^^^^^^
4040 |
4141note: the implementor must specify the same requirement
42- --> $DIR/const-drop-fail-2.rs:35 :1
42+ --> $DIR/const-drop-fail-2.rs:37 :1
4343 |
4444LL | struct ConstDropImplWithNonConstBounds<T: A>(PhantomData<T>);
4545 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
0 commit comments