Added documentation for the recently-added

addDecl() and makeDeclVisibleInContextInternal()
functions, and made the latter private since it
does not and should not have external clients.

llvm-svn: 142655
This commit is contained in:
Sean Callanan 2011-10-21 16:15:18 +00:00
parent 3d312b175a
commit 715736c007
1 changed files with 18 additions and 4 deletions

View File

@ -1232,6 +1232,14 @@ public:
/// semantic context via makeDeclVisibleInContext.
void addDecl(Decl *D);
/// @brief Add the declaration D into this context, but suppress
/// searches for external declarations with the same name.
///
/// Although analogous in function to addDecl, this removes an
/// important check. This is only useful if the Decl is being
/// added in response to an external search; in all other cases,
/// addDecl() is the right function to use.
/// See the ASTImporter for use cases.
void addDeclInternal(Decl *D);
/// @brief Add the declaration D to this context without modifying
@ -1293,9 +1301,6 @@ public:
/// the declaration chains.
void makeDeclVisibleInContext(NamedDecl *D, bool Recoverable = true);
void makeDeclVisibleInContextInternal(NamedDecl *D,
bool Recoverable = true);
/// udir_iterator - Iterates through the using-directives stored
/// within this context.
typedef UsingDirectiveDecl * const * udir_iterator;
@ -1360,6 +1365,15 @@ public:
private:
void LoadLexicalDeclsFromExternalStorage() const;
/// @brief Makes a declaration visible within this context, but
/// suppresses searches for external declarations with the same
/// name.
///
/// Analogous to makeDeclVisibleInContext, but for the exclusive
/// use of addDeclInternal().
void makeDeclVisibleInContextInternal(NamedDecl *D,
bool Recoverable = true);
friend class DependentDiagnostic;
StoredDeclsMap *CreateStoredDeclsMap(ASTContext &C) const;