blob: 13350a6d14a42dee4d3ecf2347e22d7f032ca4cb [file] [log] [blame]
Deadbeef4c6ddc02023-04-16 11:12:371error: const `impl` for trait `Drop` which is not marked with `#[const_trait]`
2 --> $DIR/const-drop-fail-2.rs:23:25
Deadbeefb17e6682023-03-24 09:17:513 |
Deadbeef4c6ddc02023-04-16 11:12:374LL | impl<T: ~const A> const Drop for ConstDropImplWithBounds<T> {
5 | ^^^^
Deadbeefb17e6682023-03-24 09:17:516 |
Deadbeef4c6ddc02023-04-16 11:12:377 = note: marking a trait with `#[const_trait]` ensures all default method bodies are `const`
8 = note: adding a non-const method body in the future would be a breaking change
Deadbeefb17e6682023-03-24 09:17:519
Deadbeef4c6ddc02023-04-16 11:12:3710error: ~const can only be applied to `#[const_trait]` traits
11 --> $DIR/const-drop-fail-2.rs:29:26
Deadbeefb17e6682023-03-24 09:17:5112 |
Deadbeef4c6ddc02023-04-16 11:12:3713LL | const fn check<T: ~const Destruct>(_: T) {}
14 | ^^^^^^^^
Deadbeefb17e6682023-03-24 09:17:5115
Deadbeef4c6ddc02023-04-16 11:12:3716error: const `impl` for trait `Drop` which is not marked with `#[const_trait]`
17 --> $DIR/const-drop-fail-2.rs:39:25
Deadbeefb17e6682023-03-24 09:17:5118 |
19LL | impl<T: ~const A> const Drop for ConstDropImplWithNonConstBounds<T> {
Deadbeef4c6ddc02023-04-16 11:12:3720 | ^^^^
Deadbeefb17e6682023-03-24 09:17:5121 |
Deadbeef4c6ddc02023-04-16 11:12:3722 = note: marking a trait with `#[const_trait]` ensures all default method bodies are `const`
23 = note: adding a non-const method body in the future would be a breaking change
Deadbeefb17e6682023-03-24 09:17:5124
25error: aborting due to 3 previous errors
26