The following invalid code snippet triggers a broken diagnostic since GCC 3.4.2:
====================================================================== template<int> struct A; template<template<typename> class B> A<B<int>::x> operator() (); ====================================================================== bug.cc:3: error: `A<#`bound_template_template_parm' not supported by pp_cxx_unqualified_id#::x> operator()()' must be a nonstatic member function A similar error message is generated by the following code snippet since GCC 3.4.0: ====================================================================== template<template<typename> class T> void foo(int, T<int>::x); ====================================================================== bug.cc:1: error: `#`bound_template_template_parm' not supported by dump_decl#<declaration error>::x' is not a type bug.cc:1: error: ISO C++ forbids declaration of `parameter' with no type -- Summary: Broken diagnostics: 'bound_template_template_parm' not supported by pp_cxx_unqualified_id/dump_decl Product: gcc Version: 4.3.0 Status: UNCONFIRMED Keywords: diagnostic, monitored Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: reichelt at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33210