[Bug c++/100716] member function template parameter not printed in candidate list

2021-05-25 Thread kretz at kde dot org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100716

--- Comment #2 from Matthias Kretz (Vir)  ---
I'd like to revise my opinion above. dump_template_decl should never print the
template parameter list of functions. I.e. it should be 'template f()'
not 'template f()'. Because it's also declared without the template
parameter list, independent of whether the template parameter is deducible from
the function arguments or not. That means the -fno-pretty-templates output
needs to be fixed and the 'T = T' part needs to disappear.

[Bug c++/100716] member function template parameter not printed in candidate list

2021-05-21 Thread kretz at kde dot org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100716

--- Comment #1 from Matthias Kretz (Vir)  ---
With -fno-pretty-templates both test cases do print the  template_parms.
That's because in dump_function_decl, without flag_pretty_templates, t isn't
generalized and thus is not considered a primary template. And
dump_template_parms only returns early if primary is true.