@@ -131,7 +131,7 @@ Notice that Rust’s `await` keyword goes _after_ the expression you’re awaiti
131131not before it. That is, it’s a _ postfix_ keyword. This may differ from what
132132you’re used to if you’ve used ` async ` in other languages, but in Rust it makes
133133chains of methods much nicer to work with. As a result, we can change the body
134- of ` page_url_for ` to chain the ` trpl::get ` and ` text ` function calls together
134+ of ` page_title ` to chain the ` trpl::get ` and ` text ` function calls together
135135with ` await ` between them, as shown in Listing 17-2.
136136
137137<Listing number =" 17-2 " file-name =" src/main.rs " caption =" Chaining with the `await` keyword " >
@@ -319,7 +319,7 @@ function in `main` to set up a runtime and run the future returned by the
319319
320320> Note: Some runtimes provide macros so you _ can_ write an async ` main `
321321> function. Those macros rewrite ` async fn main() { ... } ` to be a normal `fn
322- > main`, which does the same thing we did by hand in Listing 17-5 : call a
322+ > main`, which does the same thing we did by hand in Listing 17-4 : call a
323323> function that runs a future to completion the way ` trpl::run ` does.
324324
325325Now let’s put these pieces together and see how we can write concurrent code.
@@ -364,10 +364,11 @@ enum Either<A, B> {
364364}
365365```
366366
367- The ` race ` function returns ` Left ` with that future’s output if the first
368- argument wins, and ` Right ` with the second future argument’s output if _ that_
369- one wins. This matches the order the arguments appear in when calling the
370- function: the first argument is to the left of the second argument.
367+ The ` race ` function returns ` Left ` with the output from the first future
368+ argument it finishes first, or ` Right ` with the output of the second future
369+ argument if that one finishes first. This matches the order the arguments appear
370+ in when calling the function: the first argument is to the left of the second
371+ argument.
371372
372373We also update ` page_title ` to return the same URL passed in. That way, if
373374the page that returns first does not have a ` <title> ` we can resolve, we can
0 commit comments