Make thread-pool optional in iced_futures

This commit is contained in:
Héctor Ramón Jiménez 2020-01-19 11:08:47 +01:00
parent b8b0d97525
commit 35760ac68f
3 changed files with 10 additions and 2 deletions

View file

@ -8,6 +8,7 @@ pub trait Executor {
}
}
#[cfg(feature = "thread-pool")]
impl Executor for futures::executor::ThreadPool {
fn spawn(&self, future: impl Future<Output = ()> + Send + 'static) {
self.spawn_ok(future);