fix: Found and fixed some spelling errors.
This commit is contained in:
@@ -119,8 +119,8 @@ this task.
|
||||
|
||||
So, how does these three parts work together? They do that through an object called the `Waker`.
|
||||
The `Waker` is how the reactor tells the executor that a specific Future is ready to run. Once you
|
||||
understand the lifecycle and ownership of a Waker, you'll understand how futures work from a user's
|
||||
perspective. Here is the lifecycle:
|
||||
understand the life cycle and ownership of a Waker, you'll understand how futures work from a user's
|
||||
perspective. Here is the life cycle:
|
||||
|
||||
- A Waker is created by the **executor**
|
||||
- When a future is registered with an executor, it’s given a clone of the Waker object created by
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
The main goal in this part is to build a high level
|
||||
mental model of how the different pieces we read about in the previous chapter
|
||||
works toghether. I hope this will make it easier to understand what we just read
|
||||
works together. I hope this will make it easier to understand what we just read
|
||||
about in the previous chapter and also explain why we take a deep dive into topics
|
||||
like trait objects and generators in the next few chapters.
|
||||
|
||||
|
||||
@@ -677,7 +677,7 @@ The last point is relevant when we move on the the last paragraph.
|
||||
> also look at ways to fix it. For now, just make a note of it so you're aware
|
||||
> of the problem.
|
||||
|
||||
## Async/Await and concurrecy
|
||||
## Async/Await and concurrency
|
||||
|
||||
The `async` keyword can be used on functions as in `async fn(...)` or on a
|
||||
block as in `async { ... }`. Both will turn your function, or block, into a
|
||||
|
||||
@@ -30,7 +30,7 @@ thing in a slightly different way to get some inspiration.
|
||||
* Do you want to pass around a reference to this information using an `Arc`?
|
||||
* Do you want to make a global `Reactor` so it can be accessed from anywhere?
|
||||
|
||||
### Building a better exectuor
|
||||
### Building a better executor
|
||||
|
||||
Right now, we can only run one and one future only. Most runtimes has a `spawn`
|
||||
function which let's you start off a future and `await` it later so you
|
||||
|
||||
Reference in New Issue
Block a user