Skip to content

Commit

Permalink
Fix typo in async. Fixes #220
Browse files Browse the repository at this point in the history
  • Loading branch information
willcrichton committed Jan 1, 2025
1 parent 5bb8001 commit 7353259
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ch17-01-futures-and-syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ Notice that Rust’s `await` keyword goes after the expression you are awaiting,
not before it. That is, it is a *postfix keyword*. This may be different from
what you might be used to if you have used async in other languages. Rust chose
this because it makes chains of methods much nicer to work with. As a result, we
can change the body of `page_url_for` to chain the `trpl::get` and `text`
can change the body of `page_title` to chain the `trpl::get` and `text`
function calls together with `await` between them, as shown in Listing 17-2:

<Listing number="17-2" file-name="src/main.rs" caption="Chaining with the `await` keyword">
Expand Down

0 comments on commit 7353259

Please sign in to comment.