Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Declare

Name: Anonymous 2010-10-05 2:46

Why is the above legal, but the bottom is not? I'm using GCC 4.5.1.

const char *Array[] = { "asdfas", "sdfasd" };
const char *Array[] = { { -8, 1, 23, 42, -42, 12 }, { 14, 23, 123, -85, 34 } };

Name: Anonymous 2010-10-05 3:36

>>4
Still doesn't compile.

test.c:5:2: warning: braces around scalar initializer
test.c:5:2: warning: (near initialization for 'foo[0]')
test.c:5:2: warning: initialization makes pointer from integer without a cast

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List