Skip to content

Commit cfb7778

Browse files
committed
Auto merge of #26559 - BrodyHolden:ffi-doc-references-std-comm, r=bluss
The FFI documentation references std::comm. Replace with std::sync::mpsc. Also wrap the line.
2 parents b213c94 + 165a281 commit cfb7778

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/doc/trpl/ffi.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -309,8 +309,8 @@ and invokes callbacks from there.
309309
In these cases access to Rust data structures inside the callbacks is
310310
especially unsafe and proper synchronization mechanisms must be used.
311311
Besides classical synchronization mechanisms like mutexes, one possibility in
312-
Rust is to use channels (in `std::comm`) to forward data from the C thread
313-
that invoked the callback into a Rust thread.
312+
Rust is to use channels (in `std::sync::mpsc`) to forward data from the C
313+
thread that invoked the callback into a Rust thread.
314314
315315
If an asynchronous callback targets a special object in the Rust address space
316316
it is also absolutely necessary that no more callbacks are performed by the

0 commit comments

Comments
 (0)