At 2002-02-05 16:54, I wrote: > data Ref m a = MkRef > { > get :: m a, > set :: a -> m (), > modify :: (a -> a) -> m () > }; Better, data Ref m a = MkRef { get :: m a, set :: a -> m () }; modify :: (Monad m) => Ref m a -> (a -> a) -> m (); modify ref map = (get ref) >>= ((set ref) . map); -- Ashley Yakeley, Seattle WA