class RTTIExtends

Declaration

template <typename ThisT, typename ParentT>
class RTTIExtends { /* full declaration omitted */ };

Description

Inheritance utility for extensible RTTI. Supports single inheritance only: A class can only have one ExtensibleRTTI-parent (i.e. a parent for which the isa < > test will work), though it can have many non-ExtensibleRTTI parents. RTTIExtents uses CRTP so the first template argument to RTTIExtends is the newly introduced type, and the *second* argument is the parent class. class MyType : public RTTIExtends <MyType , RTTIRoot> { public: static char ID; }; class MyDerivedType : public RTTIExtends <MyDerivedType , MyType> { public: static char ID; };

Declared at: llvm/include/llvm/Support/ExtensibleRTTI.h:114

Templates

ThisT
ParentT

Method Overview

  • public static const void * classID()
  • public static bool classof(const llvm::RTTIRoot * R)
  • public const void * dynamicClassID() const
  • public bool isA(const void *const ClassID) const

Methods

static const void* classID()

Declared at: llvm/include/llvm/Support/ExtensibleRTTI.h:119

static bool classof(const llvm::RTTIRoot* R)

Declared at: llvm/include/llvm/Support/ExtensibleRTTI.h:127

Parameters

const llvm::RTTIRoot* R

const void* dynamicClassID() const

Declared at: llvm/include/llvm/Support/ExtensibleRTTI.h:121

bool isA(const void* const ClassID) const

Declared at: llvm/include/llvm/Support/ExtensibleRTTI.h:123

Parameters

const void* const ClassID