Eliminate ObjCForwardProtocolDecl, which is redundant now that

ObjCProtocolDecl modules forward declarations properly.

llvm-svn: 147415
This commit is contained in:
Douglas Gregor
2012-01-01 21:23:57 +00:00
parent c51118238c
commit f610267581
31 changed files with 117 additions and 329 deletions

View File

@@ -2375,7 +2375,6 @@ void CodeGenModule::EmitTopLevelDecl(Decl *D) {
// Objective-C Decls
// Forward declarations, no (immediate) code generation.
case Decl::ObjCForwardProtocol:
case Decl::ObjCInterface:
break;
@@ -2386,10 +2385,13 @@ void CodeGenModule::EmitTopLevelDecl(Decl *D) {
break;
}
case Decl::ObjCProtocol:
ObjCRuntime->GenerateProtocol(cast<ObjCProtocolDecl>(D));
case Decl::ObjCProtocol: {
ObjCProtocolDecl *Proto = cast<ObjCProtocolDecl>(D);
if (Proto->isThisDeclarationADefinition())
ObjCRuntime->GenerateProtocol(Proto);
break;
}
case Decl::ObjCCategoryImpl:
// Categories have properties but don't support synthesize so we
// can ignore them here.