http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49181
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-06-01 19:08:45 UTC --- Another "Error reporting routines re-entered" ICE, I think this code worked a few days ago, using the 4.7-20110528 snapshot, but fails with trunk #include <memory> namespace std { template<typename _OuterAlloc, typename... _InnerAllocs> class scoped_allocator_adaptor : public _OuterAlloc { typedef allocator_traits<_OuterAlloc> __traits; template<typename _Outer, typename... _Inner> friend class scoped_allocator_adaptor; public: typedef _OuterAlloc outer_allocator_type; typedef typename __traits::size_type size_type; typedef typename __traits::pointer pointer; typedef typename __traits::const_void_pointer const_void_pointer; outer_allocator_type& outer_allocator() noexcept; pointer allocate(size_type __n, const_void_pointer __hint) { return __traits::allocate(outer_allocator(), __n, __hint); } }; } typedef std::allocator<int> salloc; namespace std { template class scoped_allocator_adaptor<salloc>; } In file included from /home/redi/gcc/4.x/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/memory:65:0, from ice.cc:1: Internal compiler error: Error reporting routines re-entered. Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions.