template<class Base, class Derived, class TypeClass, class LocalData>
class clang::ConcreteTypeLoc< Base, Derived, TypeClass, LocalData >
A metaprogramming base class for TypeLoc classes which correspond to a particular Type subclass.
It is accepted for a single TypeLoc class to correspond to multiple Type classes.
- Template Parameters
-
Base | a class from which to derive |
Derived | the class deriving from this one |
TypeClass | the concrete Type subclass associated with this location type |
LocalData | the structure type of local location data for this type |
TypeLocs with non-constant amounts of local data should override getExtraLocalDataSize(); getExtraLocalData() will then point to this extra memory.
TypeLocs with an inner type should define QualType getInnerType() const and getInnerTypeLoc() will then point to this inner type's location data.
A word about hierarchies: this template is not designed to be derived from multiple times in a hierarchy. It is also not designed to be used for classes where subtypes might provide different amounts of source information. It should be subclassed only at the deepest portion of the hierarchy where all children have identical source information; if that's an abstract type, then further descendents should inherit from InheritingConcreteTypeLoc instead.
Definition at line 356 of file TypeLoc.h.
template<class Base, class Derived, class TypeClass, class LocalData>
Gets a pointer past the Info structure; useful for classes with local data that can't be captured in the Info (e.g.
because it's of variable size).
Definition at line 424 of file TypeLoc.h.