At 2002-02-07 00:52, John Hughes wrote: >Hmm. Yes. But you still haven't addressed dropping references created in the >transformed monad back into the underlying one again.
Oh that's easy: liftedNewSTRef :: (LiftedMonad (ST s) m) => a -> m (Ref (ST s) a); liftedNewSTRef = lift . newSTRef; >And this does seem to >be getting rather complicated and expensive... are you sure it's worth the >candle? I suspect any alternative will be at least as complicated. Bear in mind you are still going to need a type for your references and also get and set functions that work in all your monads. >I'm quite happy to have references depend on a state identifier myself. For instance...? -- Ashley Yakeley, Seattle WA _______________________________________________ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell