Closed
Description
@Ms2ger reported that on rustc-1.3.0-dev (f3b97a7), https://github.com/mlalic/solicit ICEs with:
src/libcore/iter.rs:804:35: 804:42 error: internal compiler error: Encountered errors
`[FulfillmentError(Obligation(predicate=Binder(TraitPredicate(<http::session::DefaultStream as core::cmp::PartialOrd>)),depth=1),Unimplemented)]`
fulfilling during trans
This turned out to occur due to the instantiation of Iterator::min
's default body for a vtable, while Self::Item
doesn't implement Ord
.
#26677 left two uses of infer::new_infer_ctxt
in trans, where only infer::normalizing_infer_ctxt
should be used.
Shorter testcase:
struct NonOrd;
fn main() {
let _: Box<Iterator<Item = _>> = Box::new(vec![NonOrd].into_iter());
}
src/libcore/iter.rs:804:35: 804:42 error: internal compiler error: Encountered error
`Unimplemented` selecting `Binder(<NonOrd as core::cmp::PartialOrd>)`
during trans
Metadata
Metadata
Assignees
Labels
No labels