2021-10-03 10:58:10 -05:00
|
|
|
error[E0568]: auto traits cannot have super traits or lifetime bounds
|
|
|
|
--> $DIR/supertrait-auto-trait.rs:8:17
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
2019-03-09 06:03:44 -06:00
|
|
|
LL | auto trait Magic: Copy {}
|
2021-10-03 10:58:10 -05:00
|
|
|
| -----^^^^^^ help: remove the super traits or lifetime bounds
|
2020-03-06 12:55:21 -06:00
|
|
|
| |
|
2023-02-25 07:53:42 -06:00
|
|
|
| auto traits cannot have super traits or lifetime bounds
|
2018-08-08 07:28:26 -05:00
|
|
|
|
2020-09-02 02:40:56 -05:00
|
|
|
error[E0277]: the trait bound `NoClone: Copy` is not satisfied
|
2021-02-08 16:15:45 -06:00
|
|
|
--> $DIR/supertrait-auto-trait.rs:16:23
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
2019-03-09 06:03:44 -06:00
|
|
|
LL | let (a, b) = copy(NoClone);
|
2021-09-07 06:30:53 -05:00
|
|
|
| ---- ^^^^^^^ the trait `Copy` is not implemented for `NoClone`
|
|
|
|
| |
|
|
|
|
| required by a bound introduced by this call
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
2022-08-15 15:31:37 -05:00
|
|
|
note: required for `NoClone` to implement `Magic`
|
2021-10-13 08:58:41 -05:00
|
|
|
--> $DIR/supertrait-auto-trait.rs:8:12
|
|
|
|
|
|
|
|
|
LL | auto trait Magic: Copy {}
|
|
|
|
| ^^^^^
|
2021-07-31 11:26:55 -05:00
|
|
|
note: required by a bound in `copy`
|
|
|
|
--> $DIR/supertrait-auto-trait.rs:10:12
|
|
|
|
|
|
|
|
|
LL | fn copy<T: Magic>(x: T) -> (T, T) { (x, x) }
|
|
|
|
| ^^^^^ required by this bound in `copy`
|
2022-03-31 09:58:45 -05:00
|
|
|
help: consider annotating `NoClone` with `#[derive(Copy)]`
|
|
|
|
|
|
2023-03-17 21:18:39 -05:00
|
|
|
LL + #[derive(Copy)]
|
|
|
|
LL | struct NoClone;
|
2022-03-31 09:58:45 -05:00
|
|
|
|
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|
2019-10-08 06:51:58 -05:00
|
|
|
Some errors have detailed explanations: E0277, E0568.
|
|
|
|
For more information about an error, try `rustc --explain E0277`.
|