diff options
-rw-r--r-- | events/src/Events/Spec/Types.hs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/events/src/Events/Spec/Types.hs b/events/src/Events/Spec/Types.hs index 1f319c7..cc3c4e4 100644 --- a/events/src/Events/Spec/Types.hs +++ b/events/src/Events/Spec/Types.hs | |||
@@ -44,14 +44,14 @@ instance (Val m a ~ m a, Bindable m b) => Bindable m (m a -> b) where | |||
44 | liftE :: (m a -> b) -> Expr m (a ': Ctx m b) (Fin m b) | 44 | liftE :: (m a -> b) -> Expr m (a ': Ctx m b) (Fin m b) |
45 | liftE = (EPri :: (Val m a -> Expr m (Ctx m b) (Fin m b)) -> Expr m (a ': Ctx m b) (Fin m b)) . ((liftE :: b -> Expr m (Ctx m b) (Fin m b)) . ) | 45 | liftE = (EPri :: (Val m a -> Expr m (Ctx m b) (Fin m b)) -> Expr m (a ': Ctx m b) (Fin m b)) . ((liftE :: b -> Expr m (Ctx m b) (Fin m b)) . ) |
46 | 46 | ||
47 | instance {-# OVERLAPPABLE #-} (Val m a ~ m a, Val m b ~ m b, Ctx m (m b) ~ '[], Fin m (m b) ~ b) => Bindable m (m a -> m b) where | ||
48 | liftE :: (m a -> m b) -> Expr m '[a] b | ||
49 | liftE = EPri . (EVal .) | ||
50 | |||
51 | instance (Val m a ~ m a, Fin m (m a) ~ a, Ctx m (m a) ~ '[]) => Bindable m (m a) where | 47 | instance (Val m a ~ m a, Fin m (m a) ~ a, Ctx m (m a) ~ '[]) => Bindable m (m a) where |
52 | liftE :: m a -> Expr m '[] a | 48 | liftE :: m a -> Expr m '[] a |
53 | liftE = EVal | 49 | liftE = EVal |
54 | 50 | ||
51 | instance {-# OVERLAPS #-} (Applicative m, Val m a ~ m a, Fin m a ~ a, Ctx m a ~ '[]) => Bindable m a where | ||
52 | liftE :: a -> Expr m '[] a | ||
53 | liftE = EVal . pure | ||
54 | |||
55 | 55 | ||
56 | type Spec m = Expr (Eval m) '[] () | 56 | type Spec m = Expr (Eval m) '[] () |
57 | 57 | ||