Closed
Description
The following ICEs:
fn foo(x: &bool) -> impl Into<&bool> { x }
The message is: error: internal compiler error: /checkout/src/librustc_typeck/check/mod.rs:618: escaping regions in predicate Obligation(predicate=Binder(TraitPredicate(<_ as std::convert::Into<&bool>>)),depth=0) --> src/main.rs:6:21
.
Should we explicitly disallow lifetime elision in impl Trait
?