Existential constraint

Posted on 2016-06-16 by Oleg Grenrus

This is short gist about problem I run today into, and it's solution. It feels that probably I'm over engineering stuff, so: please comment!

How to write something like:

instance Renderable C where
    -- 'env' is existential here: for some 'env'
    type RenderableC C m = (MonadReader env m, HasUTCTime env)

    ...

Gist source


Site proudly generated by Hakyll