]> granicus.if.org Git - clang/commit
Change ObjCInterfaceDecl to inherit from NamedDecl (not TypeDecl). While ObjCInterfac...
authorSteve Naroff <snaroff@apple.com>
Wed, 2 Apr 2008 18:30:49 +0000 (18:30 +0000)
committerSteve Naroff <snaroff@apple.com>
Wed, 2 Apr 2008 18:30:49 +0000 (18:30 +0000)
commit3110251f13981689f384eb3c0aba2afffea18d9d
tree7deff2f30e1588968d248f507ad6564f33a7ecb3
parent5744dc294e2d658a904e6bb258c0875fbac0d4a1
Change ObjCInterfaceDecl to inherit from NamedDecl (not TypeDecl). While ObjCInterfaceDecl is arguably a TypeDecl, it isn't a ScopedDecl. Since TypeDecl's are scoped, it makes sense to simply treat them as NamedDecl's. I could have fiddled a bit more with the hierarchy (in terms of creating a non-scoped TypeDecl), however this probably isn't worth the effort.

I also finished unifying access to scope decl change by converting Sema::getObjCInterfaceDecl() to use Sema::LookupDecl(). This is much cleaner now:-)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49107 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/Decl.h
include/clang/AST/DeclObjC.h
include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h
lib/Sema/Sema.h
lib/Sema/SemaDecl.cpp
lib/Sema/SemaDeclObjC.cpp
test/Sema/check-dup-objc-decls-1.m