http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45923
--- Comment #5 from Benjamin Kosnik <bkoz at gcc dot gnu.org> 2010-11-03 17:37:39 UTC --- Created attachment 22256 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=22256 constexpr diagnostics test case #01 This is a test case that shows locality information for failed constant expressions in a simple class hierarchy. The test case is comprised of a base class with member data, and no constexpr constructor. The error is: %$bin/H-x86_64-gcc-trunk.20101101/bin/g++ -g -std=gnu++0x constexpr-diagnostics-base1.cc constexpr-diagnostics-base1.cc:18:19: error: the type ‘const derived’ of constexpr variable ‘obj’ is not literal The error desired is: %$bin/H-x86_64-gcc-trunk.20101101/bin/g++ -g -std=gnu++0x constexpr-diagnostics-base1.cc constexpr-diagnostics-base1.cc:18:19: error: the type ‘const derived’ of constexpr variable ‘obj’ is not literal constexpr-diagnostics-base1.cc:8: error: base class constructor is not "constexpr"