summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/Sema.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-03-01 00:56:52 +0000
committerChris Lattner <sabre@nondot.org>2009-03-01 00:56:52 +0000
commit9ef10f4638bce8c83cf08454bcbea036094ac465 (patch)
treecfc071852d17ca88a023c7f9ef82960436d397eb /clang/lib/Sema/Sema.h
parent89d856e9e00101e552c89bcb30549099db6a0009 (diff)
downloadbcm5719-llvm-9ef10f4638bce8c83cf08454bcbea036094ac465.tar.gz
bcm5719-llvm-9ef10f4638bce8c83cf08454bcbea036094ac465.zip
"This patch uses the new ObjCImplDecl class to merge Sema::ImplMethodsVsClassMethods and Sema::ImplCategoryMethodsVsIntfMethods methods.
And now, when clang check a class implementation to find unimplemented methods, it also checks all methods from the class extensions (unnamed categories). There is also a test case to check this warning. This patch contains also a minor update for ObjCImplDecl . getNameAsCString and getNameAsString now returns an empty string instead of crashing for unnamed categories." Patch by Jean-Daniel Dupas! llvm-svn: 65744
Diffstat (limited to 'clang/lib/Sema/Sema.h')
-rw-r--r--clang/lib/Sema/Sema.h14
1 files changed, 6 insertions, 8 deletions
diff --git a/clang/lib/Sema/Sema.h b/clang/lib/Sema/Sema.h
index 3e9d07aefb6..6e0b935b88a 100644
--- a/clang/lib/Sema/Sema.h
+++ b/clang/lib/Sema/Sema.h
@@ -68,6 +68,7 @@ namespace clang {
class ObjCInterfaceDecl;
class ObjCCompatibleAliasDecl;
class ObjCProtocolDecl;
+ class ObjCImplDecl;
class ObjCImplementationDecl;
class ObjCCategoryImplDecl;
class ObjCCategoryDecl;
@@ -930,14 +931,11 @@ public:
SourceLocation Loc);
/// ImplMethodsVsClassMethods - This is main routine to warn if any method
- /// remains unimplemented in the @implementation class.
- void ImplMethodsVsClassMethods(ObjCImplementationDecl* IMPDecl,
- ObjCInterfaceDecl* IDecl);
-
- /// ImplCategoryMethodsVsIntfMethods - Checks that methods declared in the
- /// category interface is implemented in the category @implementation.
- void ImplCategoryMethodsVsIntfMethods(ObjCCategoryImplDecl *CatImplDecl,
- ObjCCategoryDecl *CatClassDecl);
+ /// remains unimplemented in the class or category @implementation.
+ void ImplMethodsVsClassMethods(ObjCImplDecl* IMPDecl,
+ ObjCContainerDecl* IDecl,
+ bool IncompleteImpl = false);
+
/// MatchTwoMethodDeclarations - Checks if two methods' type match and returns
/// true, or false, accordingly.
bool MatchTwoMethodDeclarations(const ObjCMethodDecl *Method,
OpenPOWER on IntegriCloud