You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
collect.rs:6:12:6:25 error: unable to infer enough type information to locate the impl of the trait `core::kinds::Sized` forthe type `<generic #2>`;type annotations required
collect.rs:6let m:HashMap<_,_> = arr.iter().collect();
^~~~~~~~~~~~~
collect.rs:6:12:6:25 note:the trait `core::kinds::Sized` must be implemented because it is required by `std::collections::hashmap::map::HashMap`
collect.rs:6let m:HashMap<_,_> = arr.iter().collect();
^~~~~~~~~~~~~
error: aborting due to previous error
Compare it with the error reported with Rust 0.12:
<anon>:6:28:6:48 error:type mismatch: the type `std::collections::hashmap::map::HashMap<<generic #2>,<generic #3>>` implements the trait `core::iter::FromIterator<(<generic #220>,<generic #221>)>`, but the trait `core::iter::FromIterator<&(int,uint)>` is required(expected &-ptr,found tuple)<anon>:6letm:HashMap<_,_> = arr.iter().collect();
^~~~~~~~~~~~~~~~~~~~
error:aborting due to previous error
I thought this was the same as #17567, but the confusing error on #17567 also occurs with 0.12, which means that the issue reported here has been introduced more recently.
(Sorry for the poor title, feel free to change it)
STR
Error message
Compare it with the error reported with Rust 0.12:
Much better!
Version
I thought this was the same as #17567, but the confusing error on #17567 also occurs with 0.12, which means that the issue reported here has been introduced more recently.
cc @nikomatsakis
The text was updated successfully, but these errors were encountered: