From 1370a912d0ac99334918bf90f403c318fdee9b09 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Tue, 26 Nov 2013 15:12:20 +0000 Subject: [PATCH] Move these virtual methods out of line. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@195767 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/clang/AST/Decl.h | 18 +++++------------- lib/AST/DeclCXX.cpp | 12 ++++++++++-- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/include/clang/AST/Decl.h b/include/clang/AST/Decl.h index 244a7b8d40..eb45a03369 100644 --- a/include/clang/AST/Decl.h +++ b/include/clang/AST/Decl.h @@ -333,8 +333,6 @@ public: class NamespaceDecl : public NamedDecl, public DeclContext, public Redeclarable { - 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 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/lib/AST/DeclCXX.cpp b/lib/AST/DeclCXX.cpp index 49cf721579..5fd52c4243 100644 --- a/lib/AST/DeclCXX.cpp +++ b/lib/AST/DeclCXX.cpp @@ -1914,8 +1914,6 @@ NamespaceDecl *UsingDirectiveDecl::getNominatedNamespace() { return cast_or_null(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, -- 2.40.0