http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53545
Bug #: 53545 Summary: g++ 4.70 --std=c++11 generates no object file, issues no errors Classification: Unclassified Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: squidbidn...@yahoo.com Created attachment 27534 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=27534 Self-contained test case .cpp When I compile the attached, self-contained test-case source file testScratch.cpp, g++ does not generate an output .obj file. If I comment out lines 45-47 of testScratch.cpp, compilation is successful, and the .obj file is generated as expected. My compilation command is: g++ -o testScratch.obj -O2 -Wall -std=c++11 -c testScratch.cpp -fno-strict-aliasing -Wextra (I've also tried without the -O2 optimization option, with the same results) I am using the Mingw-builds distribution at http://code.google.com/p/mingw-builds/downloads/detail?name=x86_64-mingw32-gcc-4.7.0-release-c%2Cc%2B%2B%2Cfortran-sjlj.zip to cross-compile to Windows 7, 64-bit, running on the same. The output of g++ -v is: Using built-in specs. COLLECT_GCC=e:\stdalone\mingw\bin\g++.exe COLLECT_LTO_WRAPPER=e:/stdalone/mingw/bin/../libexec/gcc/x86_64-w64-mingw32/4.7.0/lto-wrapper.exe Target: x86_64-w64-mingw32 Configured with: ../../mingw-src/gcc-4.7.0/configure --host=x86_64-w64-mingw32 --build=x86_64-w64-mingw32 --target=x86_64-w64-mingw32 --enable-targets=all --enable-multilib --prefix=/./mingw-x64 --with-sysroot=/./mingw-x64 --with-tune=generic --enable-languages=c,c++,lto,fortran --enable-libstdcxx-time=yes --with-host-libstdcxx='-static -lstdc++' --enable-shared --enable-static --enable-threads=posix --enable-libgomp --enable-lto --enable-graphite --enable-cloog-backend=isl --enable-checking=release --enable-fully-dynamic-string --enable-version-specific-runtime-libs --enable-sjlj-exceptions --disable-libstdcxx-pch --disable-libstdcxx-debug --disable-debug --disable-bootstrap --disable-rpath --disable-win32-registry --disable-nls --disable-werror --disable-symvers --with-libiconv --with-gmp=/./mingw-libs-x64 --with-mpfr=/./mingw-libs-x64 --with-mpc=/./mingw-libs-x64 --with-ppl=/./mingw-libs-x64 --with-cloog=/./mingw-libs-x64 --with-pkgversion='niXman\'\''s build' --with-bugurl=http://code.google.com/p/mingw-builds/issues/list CFLAGS='-O3 -pipe -fomit-frame-pointer -momit-leaf-frame-pointer -I/./mingw-libs-x64/include' CXXFLAGS='-O3 -pipe -fomit-frame-pointer -momit-leaf-frame-pointer' CPPFLAGS= LDFLAGS='-pipe -s -L/./mingw-libs-x64/lib' Thread model: posix gcc version 4.7.0 (niXman's build)