-
Notifications
You must be signed in to change notification settings - Fork 0
generalization ambiguity 2 - even yoke-ier #110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
likely caused by closure signature inference |
#![allow(unused)]
trait HigherRanked {
type Output<'a>;
}
trait Id {
type Refl: HigherRanked;
}
fn foo<T: Id>() -> for<'a> fn(<<T as Id>::Refl as HigherRanked>::Output<'a>) {
todo!()
}
fn bar<T: Id>() {
// generalize here:
let x = foo::<T>();
}
fn main() {} |
not caused by closure signature inference: if the outer alias refernces a bound var, the generalizer recurses into it, but then if the nested alias does not refer to bound vars, it gets replaced with an inference variable: We generalize |
fixed by rust-lang/rust#124827 |
The text was updated successfully, but these errors were encountered: