At 8:17 PM +0200 7/11/02, Marco Pantaleoni wrote:
>On Thu, Jul 11, 2002 at 10:41:13AM -0700, Mark Wilden wrote:
>>
>> "Short short." Now that's what I call short. But why stop there?
>>
>> struct {
>> unsigned reallyReallyShort : 0.5;
>> };
>
>hmmm... fractional bitfields...
>don't say it too loud... you never know where ANSI C committee members
>are wandering...
Actually, I think that "fractional bitfields" are used in arithmetic
compression. It's a bit like Huffman in that common characters are
encoded with shorter bit sequences and infrequent characters are
encoded with longer bit sequences, but takes advantage of the fact
that, for optimal encoding, some characters need to be encoded with a
"bit sequence" that is conceptually between two integral bit
sequences.
-- Keith
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/support/forums/