Skip to content

Commit 9ec1127

Browse files
committed
Clarify what tx/rx mean in concurrency docs
1 parent 77f9231 commit 9ec1127

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/doc/book/concurrency.md

+2
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,8 @@ use std::sync::mpsc;
286286
fn main() {
287287
let data = Arc::new(Mutex::new(0));
288288

289+
// `tx` is the "transmitter" or "sender"
290+
// `rx` is the "receiver"
289291
let (tx, rx) = mpsc::channel();
290292

291293
for _ in 0..10 {

0 commit comments

Comments
 (0)