RealWorld

Simon Marlow simonmar at microsoft.com
Thu Sep 18 11:02:56 EDT 2003


 
> I'm a bit confused here.
> 
> Is the proposal that the library design exposes to the programmer the
> following type synonyms:
> 
> 	type IO a = ST IORegion a
> 	type IORef a = STRef IORegion a
> 
> I think it is sound to do so.  The advantage would be that 
> newIORef and
> newSTRef would be the same (newRef, perhaps); ditto readRef, writeRef
> etc.

And possibly

   type IOArray  ix e = STArray  IORegion ix e
   type IOUArray ix e = STUArray IORegion ix e

and lots of duplication in the overloaded array support goes away.

I'd be very careful that we're not burning any bridges before doing
this, though.

Cheers,
	Simon


More information about the Libraries mailing list