Re: bytes calculation
- From: Nick Keighley <nick_keighley_nospam@xxxxxxxxxxx>
- Date: Mon, 30 Jul 2007 08:35:08 -0700
On 30 Jul, 15:55, jacob navia <ja...@xxxxxxxxxxxxxxxx> wrote:
Spoon wrote:
Pietro Cerutti wrote:
Assuming that sizeof(unsigned long long) == 64 and sizeof(int) == 32
I think you meant "Assuming CHAR_BIT == 8, sizeof(int) == 4, and
sizeof(unsigned long long) == 8".
Please, are you a lawyer?
you say that like it's a bad thing...
Note: sizeof returns the number of chars in an object (or type)
*not* the number of bits.
Can you tell me of a machine where char_bit != 8 ?
And please, a machine in use 2007 ok?
But like you I'm puzzled as to why a 32-bit shift
on a 64-bit quantity doesn't yield the top 32-bits.
Unless I misunderstood something...
--
Nick Keighley
.
- Follow-Ups:
- Re: bytes calculation
- From: Kelsey Bjarnason
- Re: bytes calculation
- References:
- bytes calculation
- From: seema
- Re: bytes calculation
- From: Pietro Cerutti
- Re: bytes calculation
- From: Spoon
- Re: bytes calculation
- From: jacob navia
- bytes calculation
- Prev by Date: Re: The chart of comp.lang.c
- Next by Date: Re: bytes calculation
- Previous by thread: Re: bytes calculation
- Next by thread: Re: bytes calculation
- Index(es):
Relevant Pages
|