RE: composed contexts

1998-11-06 Thread Simon Peyton-Jones
class (Monad m, Monad (t m)) = MonadT t m where lift :: m a - t m a instance (Monad m, Monad (StateT s m)) = MonadT (StateT s) m where lift m = \s - m = \x - return (s,x) If the definitions from the paper can be turned into valid Haskell 98 w.l.o.g. now, then I'm happy. No,

RE: composed contexts

1998-11-06 Thread Frank A. Christoph
class (Monad m, Monad (t m)) = MonadT t m where lift :: m a - t m a instance (Monad m, Monad (StateT s m)) = MonadT (StateT s) m where lift m = \s - m = \x - return (s,x) If the definitions from the paper can be turned into valid Haskell 98 w.l.o.g. now, then I'm happy. No,

RE: composed contexts

1998-11-05 Thread Frank A. Christoph
Simon Peyton-Jones [EMAIL PROTECTED] writes - The simple-context restriction. ... My default position is not to change. Question: who, apart from Ralf, has actually tripped over the lack of contexts of the form (C (a t1 .. tn)) in Haskell 1.4? Is their lack a real problem in practice?