aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/DeclBase.cpp
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2009-02-16 14:28:33 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2009-02-16 14:28:33 +0000
commit1ad4dd78ec53c24ea9e752b216035d7aa666fe49 (patch)
tree96399a6bfd7972a5c62eaecd47e185880e43c577 /lib/AST/DeclBase.cpp
parent9af5e6737db0af6b9c6a722c55ac43115c14add9 (diff)
Make DeclContexts maintenance a bit easier.
-In DeclNodes.def, only mark as DeclContexts the top classes that directly derive from DeclContext. If the Decl has subclasses, it should be marked with DECL_CONTEXT_BASE. -Use DeclNodes.def to automate the DeclContext::classof and DeclContext::CastTo definitions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64629 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/DeclBase.cpp')
-rw-r--r--lib/AST/DeclBase.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/AST/DeclBase.cpp b/lib/AST/DeclBase.cpp
index 1e3683c857..91f2bf2765 100644
--- a/lib/AST/DeclBase.cpp
+++ b/lib/AST/DeclBase.cpp
@@ -50,7 +50,7 @@ const char *Decl::getDeclKindName() const {
const char *DeclContext::getDeclKindName() const {
switch (DeclKind) {
default: assert(0 && "Declaration context not in DeclNodes.def!");
-#define DECL_CONTEXT(Node) case Decl::Node: return #Node;
+#define DECL(Derived, Base) case Decl::Derived: return #Derived;
#include "clang/AST/DeclNodes.def"
}
}