http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57452
--- Comment #3 from Balaji V. Iyer <bviyer at gmail dot com> --- Hi H. J., Yes, there is a bug in this test case. I have fixed it and it was approved for trunk and is already checked in. To answer your 2nd question, the compiler cannot check for out of bounds error in array notation for cases like this. That responsibility rests on the user. The compiler should compile fine without any warnings/errors. Thanks, Balaji V. Iyer.