Re: offset of structure fields

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

 



Eljay Love-Jensen <eljay@xxxxxxxxx> writes:

> Hi Massimiliano,
> 
>  >I'm using gcc 3.3.2 cross compiler for renesas h8s micros, and it
> doesn't work.
> 
> What does it do?
> 
> Can you drop in the offsetof macro?
> 
> #define offsetof(s_type,field) ((size_t)&(((s_type*)0)->field))
> 
>  >In the official gcc docs it seems that offsetof (and
> __builtin_offsetof) is supported in version 3.5.0.
> 
> Then can you use GCC 3.5.0 (pre)?

This probably isn't a good idea right now. AFAICT, mainline (gcc
    3.5.0) is particularly unstable right now, even more so than
    usual. 

[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