2021-09-02 10:59:53 +00:00
|
|
|
error[E0277]: the trait bound `NonTrivialDrop: Drop` is not satisfied
|
2022-01-18 01:42:35 -08:00
|
|
|
--> $DIR/const-drop-fail.rs:44:5
|
2021-09-02 10:59:53 +00:00
|
|
|
|
|
2021-09-16 14:01:37 +00:00
|
|
|
LL | const _: () = check($exp);
|
|
|
|
| ----- required by a bound introduced by this call
|
|
|
|
...
|
2021-09-02 10:59:53 +00:00
|
|
|
LL | NonTrivialDrop,
|
|
|
|
| ^^^^^^^^^^^^^^ the trait `Drop` is not implemented for `NonTrivialDrop`
|
|
|
|
|
|
|
|
|
note: required by a bound in `check`
|
2022-01-18 01:42:35 -08:00
|
|
|
--> $DIR/const-drop-fail.rs:35:19
|
2021-09-02 10:59:53 +00:00
|
|
|
|
|
|
|
|
LL | const fn check<T: ~const Drop>(_: T) {}
|
|
|
|
| ^^^^^^^^^^^ required by this bound in `check`
|
|
|
|
|
2022-01-18 01:42:35 -08:00
|
|
|
error[E0277]: the trait bound `NonTrivialDrop: Drop` is not satisfied in `ConstImplWithDropGlue`
|
|
|
|
--> $DIR/const-drop-fail.rs:46:5
|
2021-09-02 10:59:53 +00:00
|
|
|
|
|
2021-09-16 14:01:37 +00:00
|
|
|
LL | const _: () = check($exp);
|
|
|
|
| ----- required by a bound introduced by this call
|
|
|
|
...
|
2021-09-02 10:59:53 +00:00
|
|
|
LL | ConstImplWithDropGlue(NonTrivialDrop),
|
2022-01-18 01:42:35 -08:00
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ within `ConstImplWithDropGlue`, the trait `Drop` is not implemented for `NonTrivialDrop`
|
2021-09-02 10:59:53 +00:00
|
|
|
|
|
2022-01-18 01:42:35 -08:00
|
|
|
note: required because it appears within the type `ConstImplWithDropGlue`
|
|
|
|
--> $DIR/const-drop-fail.rs:17:8
|
|
|
|
|
|
|
|
|
LL | struct ConstImplWithDropGlue(NonTrivialDrop);
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^
|
2021-09-02 10:59:53 +00:00
|
|
|
note: required by a bound in `check`
|
2022-01-18 01:42:35 -08:00
|
|
|
--> $DIR/const-drop-fail.rs:35:19
|
2021-09-02 10:59:53 +00:00
|
|
|
|
|
|
|
|
LL | const fn check<T: ~const Drop>(_: T) {}
|
|
|
|
| ^^^^^^^^^^^ required by this bound in `check`
|
|
|
|
|
2021-09-03 10:04:43 +00:00
|
|
|
error[E0277]: the trait bound `NonTrivialDrop: A` is not satisfied
|
2022-01-18 01:42:35 -08:00
|
|
|
--> $DIR/const-drop-fail.rs:48:5
|
2021-09-03 10:04:43 +00:00
|
|
|
|
|
2022-01-18 01:42:35 -08:00
|
|
|
LL | const _: () = check($exp);
|
|
|
|
| ----- required by a bound introduced by this call
|
|
|
|
...
|
2021-09-03 10:04:43 +00:00
|
|
|
LL | ConstDropImplWithBounds::<NonTrivialDrop>(PhantomData),
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `A` is not implemented for `NonTrivialDrop`
|
|
|
|
|
|
2022-01-18 01:42:35 -08:00
|
|
|
note: required because of the requirements on the impl of `Drop` for `ConstDropImplWithBounds<NonTrivialDrop>`
|
|
|
|
--> $DIR/const-drop-fail.rs:29:25
|
2021-09-03 10:04:43 +00:00
|
|
|
|
|
2022-01-18 01:42:35 -08:00
|
|
|
LL | impl<T: ~const A> const Drop for ConstDropImplWithBounds<T> {
|
|
|
|
| ^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
note: required by a bound in `check`
|
|
|
|
--> $DIR/const-drop-fail.rs:35:19
|
|
|
|
|
|
|
|
|
LL | const fn check<T: ~const Drop>(_: T) {}
|
|
|
|
| ^^^^^^^^^^^ required by this bound in `check`
|
2021-09-03 10:04:43 +00:00
|
|
|
|
2022-01-18 01:42:35 -08:00
|
|
|
error: aborting due to 3 previous errors
|
2021-09-02 10:59:53 +00:00
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0277`.
|