Skip to content

Fix typo #1045

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

Merged
merged 1 commit into from
Oct 29, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions posts/2022-10-28-gats-stabilization.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ trait LendingIterator {

Most of this should look familiar; this trait looks *very* similar to the [`Iterator`][Iterator] trait from the standard library. Fundamentally, this version of the trait allows the `next` function to return an item that *borrows* from `self`. For more detail about the example, as well as some info on what that `where Self: 'a` is for, check out the [push for stabilization post][stabilization_post].

In general, GATs provide a foundational basis for a vast range of patterns and APIs. If you really want to get a feel for how many projects how been blocked on GATs being stable, go scroll through either the [tracking issue]: you will find numerous issues from other projects linking to those threads over the years saying something along the lines of "we want the API to look like X, but for that we need GATs" (or see [this comment](https://github.com/rust-lang/rust/pull/96709#issuecomment-1173170243) that has some of these put together already). If you're interested in how GATs enable a library to do zero-copy parsing, resulting in nearly a ten-fold performance increase, you might be interested in checking out a [blog post][chumsky_blog_post] on it by Niko Matsakis.
In general, GATs provide a foundational basis for a vast range of patterns and APIs. If you really want to get a feel for how many projects have been blocked on GATs being stable, go scroll through either the [tracking issue]: you will find numerous issues from other projects linking to those threads over the years saying something along the lines of "we want the API to look like X, but for that we need GATs" (or see [this comment](https://github.com/rust-lang/rust/pull/96709#issuecomment-1173170243) that has some of these put together already). If you're interested in how GATs enable a library to do zero-copy parsing, resulting in nearly a ten-fold performance increase, you might be interested in checking out a [blog post][chumsky_blog_post] on it by Niko Matsakis.

All in all, even if *you* won't need to use GATs directly, it's very possible that the *libraries* you use will use GATs either internally or publically for ergonomics, performance, or just because that's the only way the implementation works.

Expand Down Expand Up @@ -274,4 +274,4 @@ To conclude things, all the various people involved in getting this stabilizatio
[Iterator]: https://doc.rust-lang.org/stable/std/iter/trait.Iterator.html
[tracking issue]: https://github.com/rust-lang/rust/issues/44265
[stabilization pull request]: https://github.com/rust-lang/rust/pull/96709
[chumsky_blog_post]: https://smallcultfollowing.com/babysteps/blog/2022/06/27/many-modes-a-gats-pattern/
[chumsky_blog_post]: https://smallcultfollowing.com/babysteps/blog/2022/06/27/many-modes-a-gats-pattern/