Derived class problem

2000-04-27 Thread Mike Jones
All, I am having a problem with a derived class. I define: class (Monad m) = InstrumentMonad m where yuck :: a - m a Then I define: instance InstrumentMonad Vi where (Line 30) return a = Vi (\s - (s, a)) Vi sf0 = f = Vi $ \s0 -

Derived class problem

2000-04-27 Thread Frank Atanassow
Mike Jones writes: I am having a problem with a derived class. I define: class (Monad m) = InstrumentMonad m where yuck :: a - m a Then I define: instance InstrumentMonad Vi where (Line 30) return a = Vi (\s - (s, a)) Vi sf0 = f =

Re: Derived class problem

2000-04-27 Thread Marcin 'Qrczak' Kowalczyk
Thu, 27 Apr 2000 00:27:05 -0700, Mike Jones [EMAIL PROTECTED] pisze: class (Monad m) = InstrumentMonad m where yuck :: a - m a This means that any type constructor that is an instance of Monad can be made an instance of InstrumentMonad by providing the implementation of yuck for this