[MLton] Word<N>

Neophytos Michael nmichael@yahoo.com
Tue, 15 Mar 2005 13:22:22 -0800 (PST)

Yes, all my data is in 2d arrays so as you say there is no benefit.  And Word8
operations (addition for example) should be faster than in the representation
you gave below.


--- Stephen Weeks <sweeks@sweeks.com> wrote:
> > I do everything is Word8 and make sure I only use one bit.
> One advantage of "datatype word1 = W0 | W1" is that MLton can tell
> that only one bit of storage is needed to represent a value of type
> word1.  This might save some space in a packed record.  Unfortunately,
> because MLton doesn't support array elements smaller than one byte,
> there is no advantage for word1 arrays, as either approach will
> require one byte per element.
> _______________________________________________
> MLton mailing list
> MLton@mlton.org
> http://mlton.org/mailman/listinfo/mlton

Do you Yahoo!? 
Take Yahoo! Mail with you! Get it on your mobile phone.