Commit 7d71dd92 authored by Adrian Prantl's avatar Adrian Prantl
Browse files

Add RTTI support to the SymbolFile class hierarchy

Differential Revision: https://reviews.llvm.org/D70322
parent 2f95b648
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -33,7 +33,7 @@ namespace lldb_private {
/// implementations of UserExpression - which will be vended through the
/// appropriate TypeSystem.
class UserExpression : public Expression {
  // LLVM RTTI support
  /// LLVM RTTI support.
  static char ID;

public:
+9 −0
Original line number Diff line number Diff line
@@ -33,7 +33,16 @@
namespace lldb_private {

class SymbolFile : public PluginInterface {
  /// LLVM RTTI support.
  static char ID;

public:
  /// LLVM RTTI support.
  /// \{
  virtual bool isA(const void *ClassID) const { return ClassID == &ID; }
  static bool classof(const SymbolFile *obj) { return obj->isA(&ID); }
  /// \}

  // Symbol file ability bits.
  //
  // Each symbol file can claim to support one or more symbol file abilities.
+2 −0
Original line number Diff line number Diff line
@@ -25,6 +25,8 @@ using namespace lldb;
using namespace lldb_private;
using namespace lldb_private::breakpad;

char SymbolFileBreakpad::ID;

class SymbolFileBreakpad::LineIterator {
public:
  // begin iterator for sections of given type
+11 −0
Original line number Diff line number Diff line
@@ -21,7 +21,18 @@ namespace lldb_private {
namespace breakpad {

class SymbolFileBreakpad : public SymbolFile {
  /// LLVM RTTI support.
  static char ID;

public:
  /// LLVM RTTI support.
  /// \{
  bool isA(const void *ClassID) const override {
    return ClassID == &ID || SymbolFile::isA(ClassID);
  }
  static bool classof(const SymbolFile *obj) { return obj->isA(&ID); }
  /// \}

  // Static Functions
  static void Initialize();
  static void Terminate();
+2 −0
Original line number Diff line number Diff line
@@ -94,6 +94,8 @@
using namespace lldb;
using namespace lldb_private;

char SymbolFileDWARF::ID;

// static inline bool
// child_requires_parent_class_union_or_struct_to_be_completed (dw_tag_t tag)
//{
Loading