it would be nice to have a
pub fn sender(&'static self) -> Option<StaticSender<T, R>>
on the StaticChannel types. The split method can only be called once because it creates the receiver, and this is a single-receiver channel, but the channel type should be able to create multiple senders, rather than just returning a StaticSender that can be Cloned.
the method would need to return an Option (or Result?) though, because it shouldn't be able to make a new sender once the channel has closed (if either the rx was dropped or all the txs have been dropped).
it would be nice to have a
on the
StaticChanneltypes. Thesplitmethod can only be called once because it creates the receiver, and this is a single-receiver channel, but the channel type should be able to create multiple senders, rather than just returning aStaticSenderthat can beCloned.the method would need to return an
Option(orResult?) though, because it shouldn't be able to make a new sender once the channel has closed (if either the rx was dropped or all the txs have been dropped).