clang API Documentation

Public Member Functions | Static Public Member Functions
clang::ExtQuals Class Reference

#include <Type.h>

Inheritance diagram for clang::ExtQuals:
Inheritance graph
[legend]
Collaboration diagram for clang::ExtQuals:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ExtQuals (const Type *baseType, QualType canon, Qualifiers quals)
Qualifiers getQualifiers () const
bool hasObjCGCAttr () const
Qualifiers::GC getObjCGCAttr () const
bool hasObjCLifetime () const
Qualifiers::ObjCLifetime getObjCLifetime () const
bool hasAddressSpace () const
unsigned getAddressSpace () const
const TypegetBaseType () const
void Profile (llvm::FoldingSetNodeID &ID) const

Static Public Member Functions

static void Profile (llvm::FoldingSetNodeID &ID, const Type *BaseType, Qualifiers Quals)

Detailed Description

ExtQuals - We can encode up to four bits in the low bits of a type pointer, but there are many more type qualifiers that we want to be able to apply to an arbitrary type. Therefore we have this struct, intended to be heap-allocated and used by QualType to store qualifiers.

The current design tags the 'const', 'restrict', and 'volatile' qualifiers in three low bits on the QualType pointer; a fourth bit records whether the pointer is an ExtQuals node. The extended qualifiers (address spaces, Objective-C GC attributes) are much more rare.

Definition at line 1058 of file Type.h.


Constructor & Destructor Documentation

clang::ExtQuals::ExtQuals ( const Type baseType,
QualType  canon,
Qualifiers  quals 
) [inline]

Definition at line 1079 of file Type.h.


Member Function Documentation

Definition at line 1101 of file Type.h.

const Type* clang::ExtQuals::getBaseType ( ) const [inline]

Definition at line 1103 of file Type.h.

Referenced by clang::QualType::split(), and clang::QualifierCollector::strip().

Definition at line 1093 of file Type.h.

Definition at line 1096 of file Type.h.

Definition at line 1090 of file Type.h.

Referenced by clang::QualType::split(), and clang::QualifierCollector::strip().

Definition at line 1100 of file Type.h.

Definition at line 1092 of file Type.h.

Definition at line 1095 of file Type.h.

void clang::ExtQuals::Profile ( llvm::FoldingSetNodeID &  ID) const [inline]

Definition at line 1106 of file Type.h.

static void clang::ExtQuals::Profile ( llvm::FoldingSetNodeID &  ID,
const Type BaseType,
Qualifiers  Quals 
) [inline, static]

The documentation for this class was generated from the following file: