Re: How to explain this syntax?

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

 



I meet odd struct + colon syntax:
in gcc/gcc/testsuite/gcc.c-torture/compile/init-3.c
is

struct something X = {
 foo: { },
 bar: 1,
};
bar:1 is one bit field? what means foo? is the same as
struct empty foo; where struct empty { };
colon is not only reserved to bitfields?

Second (init-2.c):
initializer

struct
{
  int e1, e2;
} v = { e2: 0 };
why not e2=0, colon instead of assign operator?



[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