cognitive-engineering-lab / rust-book

The Rust Programming Language: Experimental Edition
https://rust-book.cs.brown.edu
Other
593 stars 92 forks source link

Bad phrasing #74

Open seishun opened 1 year ago

seishun commented 1 year ago

URL to the section(s) of the book with this problem: https://rust-book.cs.brown.edu/ch20-02-multithreaded.html#sending-requests-to-threads-via-channels

Description of the problem:

We want the Worker structs that we just created to fetch the code to run from a queue held in the ThreadPool and send that code to its thread to run.

What's the antecedent of "its"? "Worker structs" is plural.

Suggested fix:

Replace "Worker structs" with "each Worker struct" or "its thread" with "their threads".

seishun commented 1 year ago

Ditto in the same section:

We’ll use a channel to function as the queue of jobs, and execute will send a job from the ThreadPool to the Worker instances, which will send the job to its thread.