std :: sync::channel
Struct std::Chan
generic<T: Send> struct Chan { }Methods
buffered channel of cap slots
1 on success, 0 if closed (or never created)
null once closed and drained
No more sends; wakes every blocked sender/receiver (receivers drain what is buffered first). The runtime channel itself is never freed (there is no destroy), so a Chan is not a Drop type.
send/recv under the Fifo names (std/collections/traits.h), so generic producer/consumer code takes a Chan like any queue. Both block.