aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/dump-parse-tree.c
diff options
context:
space:
mode:
authorMatthias Kretz <kretz@kde.org>2021-05-27 17:25:37 +0200
committerJason Merrill <jason@redhat.com>2021-05-27 17:00:38 -0400
commitc33ec196aa713c62d73907dc8f9e57d7ab2e4e4b (patch)
tree375bd623fffa857993da6ea84d2af838d029c2d8 /gcc/fortran/dump-parse-tree.c
parent27e906d5bb2e46e59fe4aa137317f3c8d49ecb44 (diff)
downloadgcc-c33ec196aa713c62d73907dc8f9e57d7ab2e4e4b.zip
gcc-c33ec196aa713c62d73907dc8f9e57d7ab2e4e4b.tar.gz
gcc-c33ec196aa713c62d73907dc8f9e57d7ab2e4e4b.tar.bz2
c++: Output less irrelevant info for function template decl [PR100716]
Ensure dump_template_decl for function templates never prints template parameters after the function name (it did with -fno-pretty-templates) and skip output of irrelevant & confusing "[with T = T]" in dump_substitution. gcc/cp/ChangeLog: PR c++/100716 * error.c (dump_template_bindings): Include code to print "[with" and ']', conditional on whether anything is printed at all. This is tied to whether a semicolon is needed to separate multiple template parameters. If the template argument repeats the template parameter (T = T), then skip the parameter. (dump_substitution): Moved code to print "[with" and ']' to dump_template_bindings. (dump_function_decl): Partial revert of PR50828, which masked TFF_TEMPLATE_NAME for all of dump_function_decl. Now TFF_TEMPLATE_NAME is masked for the scope of the function and only carries through to dump_function_name. (dump_function_name): Avoid calling dump_template_parms if TFF_TEMPLATE_NAME is set. gcc/testsuite/ChangeLog: PR c++/100716 * g++.dg/diagnostic/pr100716.C: New test. * g++.dg/diagnostic/pr100716-1.C: Same test with -fno-pretty-templates.
Diffstat (limited to 'gcc/fortran/dump-parse-tree.c')
0 files changed, 0 insertions, 0 deletions