We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents e5f9ffc + cae23fd commit 56a525bCopy full SHA for 56a525b
lib/IRGen/GenMeta.cpp
@@ -6939,11 +6939,13 @@ namespace {
6939
}
6940
6941
void addValueWitnessTable() {
6942
+ llvm::Constant* vwtPointer = nullptr;
6943
if (auto cd = Target->getClangDecl())
6944
if (auto rd = dyn_cast<clang::RecordDecl>(cd))
6945
if (rd->isAnonymousStructOrUnion())
- return;
6946
- auto vwtPointer = emitValueWitnessTable(/*relative*/ false).getValue();
+ vwtPointer = llvm::Constant::getNullValue(IGM.WitnessTablePtrTy);
6947
+ if (!vwtPointer)
6948
+ vwtPointer = emitValueWitnessTable(/*relative*/ false).getValue();
6949
B.addSignedPointer(vwtPointer,
6950
IGM.getOptions().PointerAuth.ValueWitnessTable,
6951
PointerAuthEntity());
0 commit comments