Re: class size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>> However sizeof prints 12 on my system (g++ 4.5.1 64bit).
>>
>> What's using the other 2bytes? Is it an alignment thing? Is there a way to remove this?
>>
>> My apologies if this is a stupid question.
>> If there's a good reference for this I'd be interested too.
>>
>> Many Thanks,
>>
>> Nav
>>
> Check out the packed attribute.
>
> http://gcc.gnu.org/onlinedocs/gcc-3.2.3/gcc/Type-Attributes.html
>
> Regards,
>
> JT

Thanks that's exactly what I was looking for.

-- 
Nav


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux