Diffstat (limited to 'src/effect.rs')
| -rw-r--r-- | src/effect.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/effect.rs b/src/effect.rs index 092705e..0b1a76b 100644 --- a/src/effect.rs +++ b/src/effect.rs @@ -95,7 +95,16 @@ pub type ErasedEffective<'lt, Output, E, Bound = ()> = < Erased::ForLt<'lt, Output, E, &'lt (Output, Bound)> >::Effective; +pub trait BlockOn: Ss + Sized + 'static { + fn block_on<F>(future: F) -> F::Output + where + F: core::future::Future + Ss, + <F as core::future::Future>::Output: Ss; +} + pub trait Effect: Join<Effect = Self> + TryJoin<Effect = Self> + Ss + Sized + 'static { + type BlockOn: BlockOn; + type Erased<T: Ss>: Erased::Hkt<T, Self>; fn ready<'a, T: Ss + 'a>(value: T) -> ErasedEffective<'a, T, Self>; |