[all-commits] [llvm/llvm-project] c146df: [clang][DebugInfo] Emit DW_AT_deleted on any delet...
Michael Buch via All-commits
all-commits at lists.llvm.org
Tue Jun 20 01:19:53 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c146df9618764d5548c38ce61edc45147094b26f
https://github.com/llvm/llvm-project/commit/c146df9618764d5548c38ce61edc45147094b26f
Author: Michael Buch <michaelbuch12 at gmail.com>
Date: 2023-06-20 (Tue, 20 Jun 2023)
Changed paths:
M clang/lib/CodeGen/CGDebugInfo.cpp
M clang/test/CodeGenCXX/debug-info-deleted.cpp
M llvm/test/DebugInfo/X86/DW_AT_deleted.ll
Log Message:
-----------
[clang][DebugInfo] Emit DW_AT_deleted on any deleted member function
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.
Differential Revision: https://reviews.llvm.org/D153282
More information about the All-commits
mailing list