summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--clang/include/clang/AST/Decl.h18
-rw-r--r--clang/lib/AST/DeclCXX.cpp12
2 files changed, 15 insertions, 15 deletions
diff --git a/clang/include/clang/AST/Decl.h b/clang/include/clang/AST/Decl.h
index 244a7b8d400..eb45a033698 100644
--- a/clang/include/clang/AST/Decl.h
+++ b/clang/include/clang/AST/Decl.h
@@ -333,8 +333,6 @@ public:
class NamespaceDecl : public NamedDecl, public DeclContext,
public Redeclarable<NamespaceDecl>
{
- virtual void anchor();
-
/// LocStart - The starting location of the source range, pointing
/// to either the namespace or the inline keyword.
SourceLocation LocStart;
@@ -350,18 +348,12 @@ class NamespaceDecl : public NamedDecl, public DeclContext,
NamespaceDecl(DeclContext *DC, bool Inline, SourceLocation StartLoc,
SourceLocation IdLoc, IdentifierInfo *Id,
NamespaceDecl *PrevDecl);
-
+
typedef Redeclarable<NamespaceDecl> redeclarable_base;
- virtual NamespaceDecl *getNextRedeclaration() {
- return RedeclLink.getNext();
- }
- virtual NamespaceDecl *getPreviousDeclImpl() {
- return getPreviousDecl();
- }
- virtual NamespaceDecl *getMostRecentDeclImpl() {
- return getMostRecentDecl();
- }
-
+ virtual NamespaceDecl *getNextRedeclaration();
+ virtual NamespaceDecl *getPreviousDeclImpl();
+ virtual NamespaceDecl *getMostRecentDeclImpl();
+
public:
static NamespaceDecl *Create(ASTContext &C, DeclContext *DC,
bool Inline, SourceLocation StartLoc,
diff --git a/clang/lib/AST/DeclCXX.cpp b/clang/lib/AST/DeclCXX.cpp
index 49cf721579e..5fd52c4243a 100644
--- a/clang/lib/AST/DeclCXX.cpp
+++ b/clang/lib/AST/DeclCXX.cpp
@@ -1914,8 +1914,6 @@ NamespaceDecl *UsingDirectiveDecl::getNominatedNamespace() {
return cast_or_null<NamespaceDecl>(NominatedNamespace);
}
-void NamespaceDecl::anchor() { }
-
NamespaceDecl::NamespaceDecl(DeclContext *DC, bool Inline,
SourceLocation StartLoc,
SourceLocation IdLoc, IdentifierInfo *Id,
@@ -1941,6 +1939,16 @@ NamespaceDecl *NamespaceDecl::CreateDeserialized(ASTContext &C, unsigned ID) {
0, 0);
}
+NamespaceDecl *NamespaceDecl::getNextRedeclaration() {
+ return RedeclLink.getNext();
+}
+NamespaceDecl *NamespaceDecl::getPreviousDeclImpl() {
+ return getPreviousDecl();
+}
+NamespaceDecl *NamespaceDecl::getMostRecentDeclImpl() {
+ return getMostRecentDecl();
+}
+
void NamespaceAliasDecl::anchor() { }
NamespaceAliasDecl *NamespaceAliasDecl::Create(ASTContext &C, DeclContext *DC,
OpenPOWER on IntegriCloud