<div dir="ltr"><div>Hi,</div><div>In Scope.hs there is one instance of Monad and one instance of MonadTrans for Scope,</div><div>For the Monad instance, it is defined like this: Monad (Scope b f);</div><div>For the MonadTrans instance, it is like this: MonadTrans (Scope b);</div><div>Does it mean:</div><div> In ">>=" the e represents  (a)  of (Scope b f a)?</div><div> In lift function the m represents (f a) of (Scope b f a)?</div><div><br></div><div><a href="https://github.com/ekmett/bound/blob/master/src/Bound/Scope.hs">https://github.com/ekmett/bound/blob/master/src/Bound/Scope.hs</a><br></div><div>========================Scope.hs================================<br></div><div>instance Monad f => Monad (Scope b f) where</div>#if !MIN_VERSION_base(4,8,0)<br>  return a = Scope (return (F (return a)))<br>  {-# INLINE return #-}<br>#endif<br>  Scope e >>= f = Scope $ e >>= \v -> case v of<br>    B b -> return (B b)<br>    F ea -> ea >>= unscope . f<br>  {-# INLINE (>>=) #-}<br><br>instance MonadTrans (Scope b) where<br>  lift m = Scope (return (F m))<br>  {-# INLINE lift #-}<br></div>