diff options
author | aoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-08-12 07:11:50 +0000 |
---|---|---|
committer | aoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-08-12 07:11:50 +0000 |
commit | 832d369da187f1ff8e59e714720c336cb80f7b49 (patch) | |
tree | 471d9088fd063b9813bc17c068db09d41e6775d3 /include/dwarf2.h | |
parent | 1289a281c150d8a88226bfbf99eca43420dbbd76 (diff) | |
download | gcc-832d369da187f1ff8e59e714720c336cb80f7b49.tar.gz |
[PR63240] generate debug info for defaulted member functions
This implements <http://dwarfstd.org/ShowIssue.php?issue=141215.3>, a
proposal already accepted for inclusion in DWARF-5, but using
DW_AT_GNU_defaulted instead of DW_AT_defaulted as the attribute name,
because the attribute id for DW_AT_defaulted is not yet publicly
available.
for include/ChangeLog
PR debug/63240
* dwarf2.def (DW_AT_deleted, DW_AT_defaulted): New.
* dwarf2.h (enu dwarf_defaulted_attribute): New.
for gcc/ChangeLog
PR debug/63240
* langhooks-def.h
(LANG_HOOKS_FUNCTION_DECL_EXPLICIT_P): Const_tree-ify.
(LANG_HOOKS_FUNCTION_DECL_DELETED_P): Likewise.
(LANG_HOOKS_FUNCTION_DECL_DEFAULTED): Set default.
(LANG_HOOKS_DECLS): Add it.
* langhooks.h (struct lang_hooks_for_decls): Add
function_decl_defaulted. Const_tree-ify
function_decl_explicit_p and function_decl_deleted_p.
* dwarf2out.c (gen_subprogram_die): Add DW_AT_defaulted
attribute. Add DW_AT_deleted instead of DW_AT_GNU_deleted,
also at strict DWARF v5.
for gcc/cp/ChangeLog
PR debug/63240
* cp-objcp-common.c (cp_function_decl_defaulted): New.
(cp_function_decl_explicit_p): Const_tree-ify.
(cp_function_decl_deleted_p): Likewise.
* cp-objcp-common.h (cp_function_decl_defaulted): Declare.
(cp_function_decl_explicit_p): Const_tree-ify.
(cp_function_decl_deleted_p): Likewise.
(LANG_HOOKS_FUNCTION_DECL_DEFAULTED): Redefine.
for gcc/testsuite/ChangeLog
PR debug/63240
* g++.dg/debug/dwarf2/defaulted-member-function-1.C: New.
* g++.dg/debug/dwarf2/defaulted-member-function-2.C: New.
* g++.dg/debug/dwarf2/defaulted-member-function-3.C: New.
* g++.dg/debug/dwarf2/deleted-member-function.C: Expect
DW_AT_deleted.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@239403 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'include/dwarf2.h')
-rw-r--r-- | include/dwarf2.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/dwarf2.h b/include/dwarf2.h index 1a145aa48f7..d166a965db5 100644 --- a/include/dwarf2.h +++ b/include/dwarf2.h @@ -342,6 +342,14 @@ enum dwarf_macinfo_record_type DW_MACINFO_vendor_ext = 255 }; +/* DW_TAG_GNU_defaulted/DW_TAG_defaulted attributes. */ +enum dwarf_defaulted_attribute + { + DW_DEFAULTED_no = 0x00, + DW_DEFAULTED_in_class = 0x01, + DW_DEFAULTED_out_of_class = 0x02 + }; + /* Names and codes for new style macro information. */ enum dwarf_macro_record_type { |