Hacker News new | past | comments | ask | show | jobs | submit login

> it was my impression that there is no firm commitment to stabilizing GAT

Certainly, but not in the sense of being uncertain about whether or not GAT are worthwhile, only in the sense of not wanting to make promises that may not be able to be kept. The Rust developers want GAT--or something analogous to GAT--and much work has been put in towards that goal (work that will have been useful even without GAT), and at this juncture there's no foreseen theoretical impediments; however, that's not to say that some unforeseen impediment won't yet arise. Such a thing happened with specialization, which has been in the works for much longer (current status: https://github.com/rust-lang/rust/pull/68970), and the lesson has been to not incite expectation until you are extremely certain the promise will be able to be kept. As a mere half-informed bystander it seems that GAT not encountering the problems that specialization did, but don't take this as any sort of promise. :)




While I personally would really want both GAT (+ full HKT) and specialization, I could emphasize with some opposition to stabilizing them.

Rust is already a complicated language. Those two features would increase the complexity of the type system quite significantly.

Possibly beyond what is healthy for Rust adoption.


The neat thing about GAT is that it doesn't really increase the user-facing complexity of the language. Conceptually, users already need to understand generics, and they need to understand associated types. GAT, which allows users to use generics within associated types, doesn't feel like a new feature so much as it just feels like letting two existing features play nicely.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: