rust/tests/ui/traits/map-types.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
614 B
Plaintext
Raw Normal View History

error[E0277]: the trait bound `Box<dyn Map<isize, isize>>: Map<usize, isize>` is not satisfied
2019-05-28 18:46:13 +00:00
--> $DIR/map-types.rs:17:41
2018-08-08 12:28:26 +00:00
|
2019-05-28 18:46:13 +00:00
LL | let y: Box<dyn Map<usize, isize>> = Box::new(x);
| ^^^^^^^^^^^ the trait `Map<usize, isize>` is not implemented for `Box<dyn Map<isize, isize>>`
2018-08-08 12:28:26 +00:00
|
= help: the trait `Map<K, V>` is implemented for `HashMap<K, V>`
2023-05-11 02:10:56 +00:00
= note: required for the cast from `Box<Box<dyn Map<isize, isize>>>` to `Box<dyn Map<usize, isize>>`
2018-08-08 12:28:26 +00:00
error: aborting due to 1 previous error
2018-08-08 12:28:26 +00:00
For more information about this error, try `rustc --explain E0277`.