Tokio's watch channel has a Sender::<T>::subscribe(&self) -> Receiver<T> function, allowing you to create new receivers from just a sender. This would make my uses of a watch channel simpler, while not having to pull in tokio as a library dependency. Since the watch channel state is held just by an Arc, I suspect this would be very straightforward to add.
Edit: I just noticed that you already have this subscribe() function for dispatch channels! So, very simple to add indeed.
Tokio's watch channel has a
Sender::<T>::subscribe(&self) -> Receiver<T>
function, allowing you to create new receivers from just a sender. This would make my uses of a watch channel simpler, while not having to pull in tokio as a library dependency. Since the watch channel state is held just by anArc
, I suspect this would be very straightforward to add.Edit: I just noticed that you already have this
subscribe()
function for dispatch channels! So, very simple to add indeed.