summaryrefslogtreecommitdiffstats
path: root/futures/src/subscription.rs
diff options
context:
space:
mode:
authorLibravatar Jonathan Lindsey <jonathanilindsey@gmail.com>2023-06-10 21:52:26 -0500
committerLibravatar Jonathan Lindsey <jonathanilindsey@gmail.com>2023-06-10 21:52:26 -0500
commitfcf906267997aae9ff7ee282b938cbb5f6119271 (patch)
tree72151abd04439a176d1d6d271d41575118a01b2f /futures/src/subscription.rs
parentc15f1b5f6575792cc89bb5fba2e613428397e46a (diff)
downloadiced-fcf906267997aae9ff7ee282b938cbb5f6119271.tar.gz
iced-fcf906267997aae9ff7ee282b938cbb5f6119271.tar.bz2
iced-fcf906267997aae9ff7ee282b938cbb5f6119271.zip
Make the subscription::channel function take a FnOnce closure instead of a Fn closure and remove Sync as a requirement for its output.
Diffstat (limited to '')
-rw-r--r--futures/src/subscription.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/futures/src/subscription.rs b/futures/src/subscription.rs
index 801c2694..0642a924 100644
--- a/futures/src/subscription.rs
+++ b/futures/src/subscription.rs
@@ -417,7 +417,7 @@ where
pub fn channel<I, Fut, Message>(
id: I,
size: usize,
- f: impl Fn(mpsc::Sender<Message>) -> Fut + MaybeSend + Sync + 'static,
+ f: impl FnOnce(mpsc::Sender<Message>) -> Fut + MaybeSend + 'static,
) -> Subscription<Message>
where
I: Hash + 'static,