haskell Comonad transformers using functional dependencies