summaryrefslogtreecommitdiffstats
path: root/llvm/lib/DebugInfo/PDB/UDTLayout.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/DebugInfo/PDB/UDTLayout.cpp')
-rw-r--r--llvm/lib/DebugInfo/PDB/UDTLayout.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/llvm/lib/DebugInfo/PDB/UDTLayout.cpp b/llvm/lib/DebugInfo/PDB/UDTLayout.cpp
index 71443fe7587..525913c1865 100644
--- a/llvm/lib/DebugInfo/PDB/UDTLayout.cpp
+++ b/llvm/lib/DebugInfo/PDB/UDTLayout.cpp
@@ -89,7 +89,8 @@ VTableLayoutItem::VTableLayoutItem(const UDTLayoutBase &Parent,
VTableType->getPointeeType())) {
VTableFuncs.resize(Shape->getCount());
- auto ParentFunctions = Parent.getSymbol().findAllChildren<PDBSymbolFunc>();
+ auto ParentFunctions =
+ Parent.getSymbolBase().findAllChildren<PDBSymbolFunc>();
while (auto Func = ParentFunctions->getNext()) {
if (Func->isVirtual()) {
uint32_t Index = Func->getVirtualBaseOffset();
@@ -109,15 +110,19 @@ VTableLayoutItem::VTableLayoutItem(const UDTLayoutBase &Parent,
UDTLayoutBase::UDTLayoutBase(const PDBSymbol &Symbol, const std::string &Name,
uint32_t Size)
- : Symbol(Symbol), Name(Name), SizeOf(Size) {
+ : SymbolBase(Symbol), Name(Name), SizeOf(Size) {
UsedBytes.resize(Size);
ChildrenPerByte.resize(Size);
initializeChildren(Symbol);
}
+ClassLayout::ClassLayout(const PDBSymbolTypeUDT &UDT)
+ : UDTLayoutBase(UDT, UDT.getName(), UDT.getLength()), UDT(UDT) {}
+
ClassLayout::ClassLayout(std::unique_ptr<PDBSymbolTypeUDT> UDT)
- : UDTLayoutBase(*UDT, UDT->getName(), UDT->getLength()),
- Type(std::move(UDT)) {}
+ : ClassLayout(*UDT) {
+ OwnedStorage = std::move(UDT);
+}
BaseClassLayout::BaseClassLayout(const UDTLayoutBase &Parent,
std::unique_ptr<PDBSymbolTypeBaseClass> Base)
OpenPOWER on IntegriCloud