This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Array Initialization warnings
- From: David Stroupe <dstroupe at keyed-upsoftware dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Sat, 20 Apr 2002 08:17:24 -0500
- Subject: Array Initialization warnings
When I compile this line of code
int JPEG_MRK_NTSC[4][4] =
{
0x01, 0x02, 0x03, 0x04,
0x05, 0x06, 0x07, 0x08,
0x09, 0x0a, 0x0b, 0x0c,
0x0d, 0x0e, 0x0f, 0x00
};
with the -Wall option, I get the following warnings
vis.c:264: warning: missing braces around initializer
vis.c:264: warning: (near initialization for `JPEG_MRK_NTSC[0]')
If I look at the values of the array members during execution, they are
correct.
Is this array really being initialized correctly?
Are the warnings correct?
Is there a way to 'turn off' these particular warnings with a compiler
directive?
TIA
--
Best regards,
David Stroupe
Keyed-Up Software