1
1
error[E0277]: the trait bound `NonTrivialDrop: ~const A` is not satisfied
2
2
--> $DIR/const-drop-fail-2.rs:31:23
3
3
|
4
- LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(ConstDropImplWithBounds(PhantomData));
4
+ LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(
5
5
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `~const A` is not implemented for `NonTrivialDrop`
6
6
|
7
7
note: the trait `A` is implemented for `NonTrivialDrop`, but that implementation is not `const`
8
8
--> $DIR/const-drop-fail-2.rs:31:23
9
9
|
10
- LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(ConstDropImplWithBounds(PhantomData));
10
+ LL | const _: () = check::<ConstDropImplWithBounds<NonTrivialDrop>>(
11
11
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
12
12
note: required by a bound in `ConstDropImplWithBounds`
13
13
--> $DIR/const-drop-fail-2.rs:21:35
@@ -16,30 +16,30 @@ LL | struct ConstDropImplWithBounds<T: ~const A>(PhantomData<T>);
16
16
| ^^^^^^^^ required by this bound in `ConstDropImplWithBounds`
17
17
18
18
error[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
20
20
|
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`
23
23
|
24
24
note: 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
26
26
|
27
- LL | const _: () = check::< ConstDropImplWithBounds<NonTrivialDrop>>(ConstDropImplWithBounds( PhantomData));
28
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
27
+ LL | ConstDropImplWithBounds( PhantomData)
28
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
29
29
note: required by a bound in `ConstDropImplWithBounds`
30
30
--> $DIR/const-drop-fail-2.rs:21:35
31
31
|
32
32
LL | struct ConstDropImplWithBounds<T: ~const A>(PhantomData<T>);
33
33
| ^^^^^^^^ required by this bound in `ConstDropImplWithBounds`
34
34
35
35
error[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
37
37
|
38
38
LL | impl<T: ~const A> const Drop for ConstDropImplWithNonConstBounds<T> {
39
39
| ^^^^^^^^
40
40
|
41
41
note: 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
43
43
|
44
44
LL | struct ConstDropImplWithNonConstBounds<T: A>(PhantomData<T>);
45
45
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
0 commit comments