[PATCH] D153282: [clang][DebugInfo] Emit DW_AT_deleted on any deleted member function
Michael Buch via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jun 19 08:06:07 PDT 2023
Michael137 created this revision.
Michael137 added reviewers: aprantl, dblaikie.
Herald added a project: All.
Michael137 requested review of this revision.
Herald added projects: clang, LLVM.
Herald added subscribers: llvm-commits, cfe-commits.
Currently we emit `DW_AT_deleted` for `deleted` special-member
functions (i.e., ctors/dtors). However, in C++ one can mark any
member function as deleted. This patch expands the set of member
functions for which we emit `DW_AT_deleted`.
The DWARFv5 spec section 5.7.8 says:
<non-normative>
In C++, a member function may be declared as deleted. This prevents the compiler from
generating a default implementation of a special member function such as a constructor
or destructor, and can affect overload resolution when used on other member functions.
</non-normative>
If the member function entry has been declared as deleted, then that entry has a
DW_AT_deleted attribute.
Thus this change is conforming.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D153282
Files:
clang/lib/CodeGen/CGDebugInfo.cpp
clang/test/CodeGenCXX/debug-info-deleted.cpp
llvm/test/DebugInfo/X86/DW_AT_deleted.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D153282.532663.patch
Type: text/x-patch
Size: 6107 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230619/6a8fe102/attachment.bin>
More information about the cfe-commits
mailing list