This patch introduces a new class to keep track of class implementation info. It also adds more
semantic checks for class and protocol declarations. Test cases are good indications of kind of
checking being done in this patch.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@42311 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Sema/Sema.h b/Sema/Sema.h
index d99b1fc..0891c66 100644
--- a/Sema/Sema.h
+++ b/Sema/Sema.h
@@ -352,13 +352,15 @@
SourceLocation RParenLoc);
// Objective-C declarations.
- virtual DeclTy *ObjcStartClassInterface(SourceLocation AtInterafceLoc,
+ virtual DeclTy *ObjcStartClassInterface(Scope* S,
+ SourceLocation AtInterafceLoc,
IdentifierInfo *ClassName, SourceLocation ClassLoc,
IdentifierInfo *SuperName, SourceLocation SuperLoc,
IdentifierInfo **ProtocolNames, unsigned NumProtocols,
AttributeList *AttrList);
- virtual DeclTy *ObjcStartProtoInterface(SourceLocation AtProtoInterfaceLoc,
+ virtual DeclTy *ObjcStartProtoInterface(Scope* S,
+ SourceLocation AtProtoInterfaceLoc,
IdentifierInfo *ProtocolName, SourceLocation ProtocolLoc,
IdentifierInfo **ProtoRefNames, unsigned NumProtoRefs);
@@ -367,6 +369,12 @@
IdentifierInfo *CategoryName, SourceLocation CategoryLoc,
IdentifierInfo **ProtoRefNames, unsigned NumProtoRefs);
+ virtual DeclTy *ObjcStartClassImplementation(Scope* S,
+ SourceLocation AtClassImplLoc,
+ IdentifierInfo *ClassName, SourceLocation ClassLoc,
+ IdentifierInfo *SuperClassname,
+ SourceLocation SuperClassLoc);
+
virtual DeclTy *ObjcClassDeclaration(Scope *S, SourceLocation AtClassLoc,
IdentifierInfo **IdentList,
unsigned NumElts);