the Word type

Manuel M T Chakravarty chak@cse.unsw.edu.au
Sat, 12 Apr 2003 14:15:02 +1000 (EST)


"Simon Marlow" <simonmar@microsoft.com> wrote,

> 
> > > Comments in the Hugs sources claim that the Word type is deprecated,
> > > and it's not mentioned in the FFI spec, but it's present with a full
> > > set of instances in the libraries.  Which is right?
> > 
> > It is not part of the ffi spec because it can't be used in a portable
> > manner.  (The same problem goes for Int too, of course.)
> > 
> > I've argued for its complete removal from the libraries because the
> > vast majority of the code written with it will be non-portable.  I
> > think the counter-argument was that some portable usages are possible
> > with one of Chris Okasaki's data structures being an example.
> > 
> > So, at least for now, it remains alive and well in the Hugs code in
> > the interests of GHC-compatability and backwards-compatability.
> > 
> > Hopefully the comments in the Hugs source code (which were probably
> > added by me) match the above.
> 
> I think it's there for symmetry, not much else.  Word suffers from the
> same problems as Int, so while we have one we might as well have the
> other.

We nevertheless decided against Word last time this issue
was discussed; on the grounds of, while should we further
promote bad practice.

Cheers,
Manuel