Re: [2.6 patch] Define BITS_PER_BYTE

From: H. Peter Anvin
Date: Thu Jan 05 2006 - 14:18:58 EST


Followup to: <1136474301.31922.1.camel@xxxxxxxxxxxxxxxxxxxxxxxx>
By author: "Bryan O'Sullivan" <bos@xxxxxxxxxxxxx>
In newsgroup: linux.dev.kernel
>
> On Thu, 2006-01-05 at 08:03 +0100, Jan Engelhardt wrote:
>
> > Oh no :( This sounds as uncommon as CHAR_BIT in C.
>
> CHAR_BIT is completely unclear. BITS_PER_BYTE is self-evident, and
> makes it a lot more obvious when you're doing arithmetic that involves
> counting bits.
>

Tough cookies. The standard name for this define is CHAR_BIT, and
anyone who doesn't know that "char" means byte in C doesn't know the C
language. "char" certainly doesn't mean "character" in this day of
UTF-8 and friends.

-hpa

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/