On Mon, 2011-04-04, Riccardo Manfrin wrote:
> I'm messing with the followig structure, compiling with GNU GCC on an
> ARM architecture.
>
> typedef union _waltdisney{
> struct{
> uint8_t goofy : 5;
> uint8_t pluto : 1;
> uint8_t donald : 2;
> } __packed family;
> uint8_t val;
> } __packed waltdisney_t;
Which version of gcc is this? My documentation for gcc 4.4 doesn't
mention "__packed", except perhaps in combination with __attribute__.
And it doesn't compile:
salix:~% gcc -c /tmp/q.c
/tmp/q.c:8: error: expected ':', ',', ';', '}' or '__attribute__' before 'family'
/tmp/q.c:10: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'waltdisney_t'
/tmp/q.c:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'foo'
/Jorgen
--
// Jorgen Grahn <grahn@ Oo o. . .
\X/ snipabacken.se> O o .
|