On Sun, 2008-10-19 at 16:05 -0700, Don Stewart wrote:

> I'd like them strict and specialised,
> 
> So that:
> 
>     data IntMap a = Nil
>                   | Tip {-# UNPACK #-} !Key a
>                   | Bin {-# UNPACK #-} !Prefix {-# UNPACK #-} !Mask !(IntMap 
> a) !(IntMap a) 
> 
> applied as so,
> 
>     type T = IntMap {-# UNPACK #-} !Int

Yes, except that it should be newtype. That gives a proper boundary to
apply injection / projection functions for the different internal
representation.

Duncan

_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to