clang API Documentation
#include <DeclContextInternals.h>

Public Types | |
| typedef SmallVector< NamedDecl *, 4 > | DeclsTy |
| DeclsTy - When in vector form, this is what the Data pointer points to. | |
Public Member Functions | |
| StoredDeclsList () | |
| StoredDeclsList (const StoredDeclsList &RHS) | |
| ~StoredDeclsList () | |
| StoredDeclsList & | operator= (const StoredDeclsList &RHS) |
| bool | isNull () const |
| NamedDecl * | getAsDecl () const |
| DeclsTy * | getAsVector () const |
| void | setOnlyValue (NamedDecl *ND) |
| void | remove (NamedDecl *D) |
| DeclContext::lookup_result | getLookupResult () |
| bool | HandleRedeclaration (NamedDecl *D) |
| void | AddSubsequentDecl (NamedDecl *D) |
Public Attributes | |
| llvm::PointerUnion< NamedDecl *, DeclsTy * > | Data |
| The stored data, which will be either a pointer to a NamedDecl, or a pointer to a vector. | |
StoredDeclsList - This is an array of decls optimized a common case of only containing one entry.
Definition at line 31 of file DeclContextInternals.h.
| typedef SmallVector<NamedDecl *, 4> clang::StoredDeclsList::DeclsTy |
DeclsTy - When in vector form, this is what the Data pointer points to.
Definition at line 34 of file DeclContextInternals.h.
| clang::StoredDeclsList::StoredDeclsList | ( | ) | [inline] |
Definition at line 41 of file DeclContextInternals.h.
| clang::StoredDeclsList::StoredDeclsList | ( | const StoredDeclsList & | RHS | ) | [inline] |
Definition at line 43 of file DeclContextInternals.h.
References Data, and getAsVector().
| clang::StoredDeclsList::~StoredDeclsList | ( | ) | [inline] |
Definition at line 48 of file DeclContextInternals.h.
References getAsVector().
| void clang::StoredDeclsList::AddSubsequentDecl | ( | NamedDecl * | D | ) | [inline] |
AddSubsequentDecl - This is called on the second and later decl when it is not a redeclaration to merge it into the appropriate place in our list.
Definition at line 151 of file DeclContextInternals.h.
References Data, getAsDecl(), getAsVector(), clang::Decl::getIdentifierNamespace(), clang::Decl::hasTagIdentifierNamespace(), and clang::Decl::IDNS_Using.
Referenced by clang::ExternalASTSource::SetExternalVisibleDeclsForName().
| NamedDecl* clang::StoredDeclsList::getAsDecl | ( | ) | const [inline] |
Definition at line 65 of file DeclContextInternals.h.
References Data.
Referenced by AddSubsequentDecl(), getLookupResult(), HandleRedeclaration(), and remove().
| DeclsTy* clang::StoredDeclsList::getAsVector | ( | ) | const [inline] |
Definition at line 69 of file DeclContextInternals.h.
References Data.
Referenced by AddSubsequentDecl(), getLookupResult(), HandleRedeclaration(), operator=(), remove(), setOnlyValue(), StoredDeclsList(), and ~StoredDeclsList().
| DeclContext::lookup_result clang::StoredDeclsList::getLookupResult | ( | ) | [inline] |
getLookupResult - Return an array of all the decls that this list represents.
Definition at line 102 of file DeclContextInternals.h.
References Data, getAsDecl(), getAsVector(), and isNull().
Referenced by clang::ExternalASTSource::SetExternalVisibleDeclsForName().
| bool clang::StoredDeclsList::HandleRedeclaration | ( | NamedDecl * | D | ) | [inline] |
HandleRedeclaration - If this is a redeclaration of an existing decl, replace the old one with D and return true. Otherwise return false.
Definition at line 125 of file DeclContextInternals.h.
References clang::NamedDecl::declarationReplaces(), getAsDecl(), getAsVector(), and setOnlyValue().
| bool clang::StoredDeclsList::isNull | ( | ) | const [inline] |
Definition at line 63 of file DeclContextInternals.h.
References Data.
Referenced by getLookupResult(), remove(), clang::ExternalASTSource::SetExternalVisibleDeclsForName(), and clang::ExternalASTSource::SetNoExternalVisibleDeclsForName().
| StoredDeclsList& clang::StoredDeclsList::operator= | ( | const StoredDeclsList & | RHS | ) | [inline] |
Definition at line 54 of file DeclContextInternals.h.
References Data, and getAsVector().
| void clang::StoredDeclsList::remove | ( | NamedDecl * | D | ) | [inline] |
Definition at line 82 of file DeclContextInternals.h.
References Data, getAsDecl(), getAsVector(), and isNull().
| void clang::StoredDeclsList::setOnlyValue | ( | NamedDecl * | ND | ) | [inline] |
Definition at line 73 of file DeclContextInternals.h.
References Data, and getAsVector().
Referenced by HandleRedeclaration(), and clang::ExternalASTSource::SetExternalVisibleDeclsForName().
| llvm::PointerUnion<NamedDecl *, DeclsTy *> clang::StoredDeclsList::Data |
The stored data, which will be either a pointer to a NamedDecl, or a pointer to a vector.
Definition at line 38 of file DeclContextInternals.h.
Referenced by AddSubsequentDecl(), getAsDecl(), getAsVector(), getLookupResult(), isNull(), operator=(), remove(), setOnlyValue(), and StoredDeclsList().