http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51906
--- Comment #28 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-01-31 01:15:00 UTC --- You need to use g++ (not gcc) to compile C++ code, and you need to use -std=c++0x to compile C++11 code. GCC 4.2 doesn't support -std=c++0x so there's no point trying that.