"Claus Reinke" <claus.rei...@talk21.com> wrote:

> A while ago, I needed lots of fairly small positive numbers,
> together with a small number of flags for each, so I thought
> I'd switch from Int to Word, and map the flags to bits.

Since there are few guarantees about the size of a Word (or Int), surely
it would be better to choose a definitely sized basic type, e.g. Word8
or Word16?  I vaguely recall that ghc used to generate better code for
definitely sized WordN than the generic unguaranteed-size Word.

Regards,
    Malcolm
_______________________________________________
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to