>>>>> "J" == J A Magallon <J.A.> writes:
J> Problem is that named initializers '.xx =' are ISO C99, so
J> problably they are not supported in gcc till 3.0...the old way
J> is working with older compilers.
I actually tried it :). gcc 2.95 supports named initializers as well:
$ cat a.c
struct foo {
int x;
int y;
};
struct foo bar = {
.y = 2,
.x = 1
};
int main() {
printf("%d\n", bar.x);
return 0;
}
$ gcc a.c
$ ./a.out
1
$ gcc --version
2.95.2
Best,
Roland
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Fri May 31 2002 - 22:00:22 EST