1 //===- ClassDefinitionDumper.h - --------------------------------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef LLVM_TOOLS_LLVMPDBDUMP_CLASSDEFINITIONDUMPER_H
11 #define LLVM_TOOLS_LLVMPDBDUMP_CLASSDEFINITIONDUMPER_H
13 #include "llvm/DebugInfo/PDB/PDBSymDumper.h"
14 #include "llvm/DebugInfo/PDB/PDBSymbolFunc.h"
15 #include "llvm/DebugInfo/PDB/PDBSymbolData.h"
19 #include <unordered_map>
25 class ClassDefinitionDumper : public PDBSymDumper {
27 ClassDefinitionDumper(LinePrinter &P);
29 void start(const PDBSymbolTypeUDT &Exe);
31 void dump(const PDBSymbolTypeBaseClass &Symbol) override;
32 void dump(const PDBSymbolData &Symbol) override;
33 void dump(const PDBSymbolTypeEnum &Symbol) override;
34 void dump(const PDBSymbolFunc &Symbol) override;
35 void dump(const PDBSymbolTypeTypedef &Symbol) override;
36 void dump(const PDBSymbolTypeUDT &Symbol) override;
37 void dump(const PDBSymbolTypeVTable &Symbol) override;
44 SymbolGroup(SymbolGroup &&Other) {
45 Functions = std::move(Other.Functions);
46 Data = std::move(Other.Data);
47 Unknown = std::move(Other.Unknown);
50 std::list<std::unique_ptr<PDBSymbolFunc>> Functions;
51 std::list<std::unique_ptr<PDBSymbolData>> Data;
52 std::list<std::unique_ptr<PDBSymbol>> Unknown;
53 SymbolGroup(const SymbolGroup &other) = delete;
54 SymbolGroup &operator=(const SymbolGroup &other) = delete;
56 typedef std::unordered_map<int, SymbolGroup> SymbolGroupByAccess;
58 int dumpAccessGroup(PDB_MemberAccess Access, const SymbolGroup &Group);