austinjones / postage-rs

The feature-rich, portable async channel library
MIT License
251 stars 9 forks source link

Would like non-async sender on postage::watch #55

Open ijackson opened 2 years ago

ijackson commented 2 years ago

postage::watch::Sender offers, really, just the interface of Sink. But in fact its implementation never blocks (never returns Pending).

It would be nice to make this a formal part of the API and to have a method which wasn't async. tokio::sync::watch::Sender calls that method send.

ijackson commented 2 years ago

This would be a convenience method, equivalent roughly to *self.borrow_mut() = value.