Haskell-MMorph-Library icon indicating copy to clipboard operation
Haskell-MMorph-Library copied to clipboard

Monad morphisms

Results 11 Haskell-MMorph-Library issues
Sort by recently updated
recently updated
newest added

As discussed in [this SO post](http://stackoverflow.com/q/39928488/1477667), the `Monad m` constraint on `hoist` feels too strong in the face of `hoist id = id`. Cirdec thinks it probably should be `Functor`....

Is the argument to `embed` expected to be a monad morphism? I'm *guessing* so? I believe that having only a `Monad n` constraint, and not a `Monad m` one, makes...

As you've already seen, GHC 8.6 wins ```haskell instance (MFunctor f, MFunctor g, forall m. Monad m => Monad (g m)) => MFunctor (ComposeT f g) ``` But it has...

Hello! Is it possible to add a MonadMorph type class to the library? Its implementation is very simple: ``` class MonadMorph m n where morph :: m a -> n...

I was looking for a type ``` data ProductT (f :: (* -> *) -> * -> *) (g :: (* -> *) -> * -> *) m a =...

Given some random transformer stack, where all of the transformers implement `MMonad`: ``` newtype FooT m a = FooT { unFoo :: ExceptT () (StateT Int (BarT m)) a }...

I found myself wanting [distribute](https://hackage.haskell.org/package/pipes-4.3.2/docs/Pipes-Lift.html#v:distribute) for a number of transformers, including transformer stacks. It seems like this is similar to [Distributive](http://hackage.haskell.org/package/distributive-0.5.2/docs/Data-Distributive.html#t:Distributive) but for transformers. Does this makes sense as a...

Sometimes it can be difficult to implement an `MFunctor` instance for a given type due to the lack of a `Monad` constraint on the result type of `hoist`. Especially if...

It seems I very frequently run into trouble with `MFunctor` instances that carry an `MFunctor` constraint forward. This is probably not a legitimate type, but consider: ``` newtype Stream t...

``` haskell readOnly :: Monad m => ReaderT s m r -> StateT s m r readOnly readerT = StateT $ \s -> do r