-
Notifications
You must be signed in to change notification settings - Fork 898
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
Cannot handle generic associated type with where
statement
#6274
Comments
just wondering, is type Bar = u16
where Self: Sized; really the right syntax? |
@johnhuichen |
I am just thinking that Since you already declared the type, does it still make sense to have |
@ArcticLampyrid this one should be addressed once we merge #5887, which we're planning to do in the near future. @johnhuichen yes it's the correct syntax and it relates to rust-lang/rust#89122. Also, see the type alias docs of the rust reference. |
Thanks! I see what's going on now. I think the |
It is not code in the real world, it's just a test case. A more practical usage is: impl<A> Foo<A> for MyType<A> {
type Bar = u16
where
A: Sized;
} |
For code:
I got the error:
The text was updated successfully, but these errors were encountered: