[cfe-commits] r42535 - in /cfe/trunk: Sema/SemaDecl.cpp include/clang/AST/DeclObjC.h include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h

Fariborz Jahanian fjahanian at apple.com
Tue Oct 2 10:36:55 PDT 2007


Author: fjahanian
Date: Tue Oct  2 12:36:55 2007
New Revision: 42535

URL: http://llvm.org/viewvc/llvm-project?rev=42535&view=rev
Log:
ObjcCategoryDecl Does not subclass from ScopedDecl any more.
Ted may want to take a look at the change I made at 
FGRecStmtDeclVisitor.h.

Modified:
    cfe/trunk/Sema/SemaDecl.cpp
    cfe/trunk/include/clang/AST/DeclObjC.h
    cfe/trunk/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h

Modified: cfe/trunk/Sema/SemaDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Sema/SemaDecl.cpp?rev=42535&r1=42534&r2=42535&view=diff

==============================================================================
--- cfe/trunk/Sema/SemaDecl.cpp (original)
+++ cfe/trunk/Sema/SemaDecl.cpp Tue Oct  2 12:36:55 2007
@@ -1031,7 +1031,7 @@
                       IdentifierInfo **ProtoRefNames, unsigned NumProtoRefs) {
   ObjcCategoryDecl *CDecl;
   ObjcInterfaceDecl* IDecl = getObjCInterfaceDecl(S, ClassName, ClassLoc);
-  CDecl = new ObjcCategoryDecl(AtInterfaceLoc, NumProtoRefs, ClassName);
+  CDecl = new ObjcCategoryDecl(AtInterfaceLoc, NumProtoRefs);
   CDecl->setClassInterface(IDecl);
 
   /// Check that class of this category is already completely declared.

Modified: cfe/trunk/include/clang/AST/DeclObjC.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/DeclObjC.h?rev=42535&r1=42534&r2=42535&view=diff

==============================================================================
--- cfe/trunk/include/clang/AST/DeclObjC.h (original)
+++ cfe/trunk/include/clang/AST/DeclObjC.h Tue Oct  2 12:36:55 2007
@@ -401,7 +401,7 @@
 /// Lisp and Smalltalk. More traditional class-based languages (C++, Java) 
 /// don't support this level of dynamism, which is both powerful and dangerous.
 ///
-class ObjcCategoryDecl : public ScopedDecl { // FIXME: don't subclass from ScopedDecl!
+class ObjcCategoryDecl : public Decl {
   /// Interface belonging to this category
   ObjcInterfaceDecl *ClassInterface;
   
@@ -424,9 +424,8 @@
   ObjcCategoryDecl *NextClassCategory;
 
 public:
-  ObjcCategoryDecl(SourceLocation L, unsigned numRefProtocol, 
-                   IdentifierInfo *Id)
-    : ScopedDecl(ObjcCategory, L, Id, 0),
+  ObjcCategoryDecl(SourceLocation L, unsigned numRefProtocol)
+    : Decl(ObjcCategory),
       ClassInterface(0), ObjcCatName(0),
       CatReferencedProtocols(0), NumCatReferencedProtocols(-1),
       CatInsMethods(0), NumCatInsMethods(-1),

Modified: cfe/trunk/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h?rev=42535&r1=42534&r2=42535&view=diff

==============================================================================
--- cfe/trunk/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h (original)
+++ cfe/trunk/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h Tue Oct  2 12:36:55 2007
@@ -66,7 +66,6 @@
         DISPATCH_CASE(ObjcInterface,ObjcInterfaceDecl)
         DISPATCH_CASE(ObjcClass,ObjcClassDecl)
         DISPATCH_CASE(ObjcProtocol,ObjcProtocolDecl)
-        DISPATCH_CASE(ObjcCategory,ObjcCategoryDecl)
       default:
         assert(false && "Subtype of ScopedDecl not handled.");
     }





More information about the cfe-commits mailing list