]> git.ipfire.org Git - thirdparty/gcc.git/commit
dwarf: emit DW_AT_name for DW_TAG_GNU_formal_parameter_pack [PR70536]
authorEd Catmur <ed@catmur.uk>
Sat, 4 Feb 2023 16:50:33 +0000 (17:50 +0100)
committerJason Merrill <jason@redhat.com>
Thu, 13 Feb 2025 21:54:01 +0000 (22:54 +0100)
commit53e1686e6e0c3e809384e6fcf5eed46f37bc296b
tree90e7854ec4511f332d48a26645b21274dca7c0a5
parent4e7f74225116e76caa65c5ce2815c2714343dfbc
dwarf: emit DW_AT_name for DW_TAG_GNU_formal_parameter_pack [PR70536]

Per https://wiki.dwarfstd.org/C++0x_Variadic_templates.md
DW_TAG_GNU_formal_parameter_pack should have a DW_AT_name:

17$:      DW_TAG_formal_parameter_pack
              DW_AT_name("args")
18$:          DW_TAG_formal_parameter
                  ! no DW_AT_name attribute
                  DW_AT_type(reference to 13$)
(...)

PR c++/70536

gcc/ChangeLog:

* dwarf2out.cc (gen_formal_parameter_pack_die): Add name attr.

gcc/testsuite/ChangeLog:

* g++.dg/debug/dwarf2/template-func-params-7.C: Check for pack names.

Co-authored-by: Jason Merrill <jason@redhat.com>
gcc/dwarf2out.cc
gcc/testsuite/g++.dg/debug/dwarf2/template-func-params-7.C