[llvm] [llvm] annotate interfaces in llvm/DebugInfo for DLL export (PR #140778)
Andrew Rogers via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 3 10:32:52 PDT 2025
================
@@ -164,8 +170,6 @@ class LLVM_ABI ClassLayout : public UDTLayoutBase {
explicit ClassLayout(const PDBSymbolTypeUDT &UDT);
explicit ClassLayout(std::unique_ptr<PDBSymbolTypeUDT> UDT);
- ClassLayout(ClassLayout &&Other) = default;
----------------
andrurogerz wrote:
The move constructor is implicitly deleted because I deleted the copy constructor in the parent class `UDTLayoutBase` to make the DLL build happy.
Leaving this default declaration in place results in a warning from Clang when building on Linux:
```
/home/user/src/llvm/llvm-project/llvm/include/llvm/DebugInfo/PDB/UDTLayout.h:173:3: warning: explicitly defaulted move constructor is implicitly deleted [-Wdefaulted-function-deleted]
173 | ClassLayout(ClassLayout &&Other) = default;
| ^
/home/user/src/llvm/llvm-project/llvm/include/llvm/DebugInfo/PDB/UDTLayout.h:168:30: note: move constructor of 'ClassLayout' is implicitly deleted because base class 'UDTLayoutBase' has a deleted move constructor
168 | class LLVM_ABI ClassLayout : public UDTLayoutBase {
| ^
/home/user/src/llvm/llvm-project/llvm/include/llvm/DebugInfo/PDB/UDTLayout.h:121:3: note: 'UDTLayoutBase' has been explicitly marked deleted here
121 | UDTLayoutBase(UDTLayoutBase const&) = delete;
| ^
/home/user/src/llvm/llvm-project/llvm/include/llvm/DebugInfo/PDB/UDTLayout.h:173:38: note: replace 'default' with 'delete'
173 | ClassLayout(ClassLayout &&Other) = default;
| ^~~~~~~
| delete
1 warning generated.`
```
https://github.com/llvm/llvm-project/pull/140778
More information about the llvm-commits
mailing list