Given the following code: template<int (&p)(int, int)> struct X { }; int f(int, int) { } void g(X<f>) { }
GCC produces the mangled name: _Z1g1XILZ1fiiEE for the function 'g'. However, the correct mangled name is: _Z1g1XIL_Z1fiiEE GCC is missing the '_' prior to the 'Z' in the mangled name of the template argument 'f'. -- Summary: Incorrect mangled name for function as template argument Product: gcc Version: 4.3.3 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: dgregor at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39208