Rename Action::ParseRecordBody() to ProcessFieldDecls(), and add a visibility argument.

Remove Action::ObjcAddVisibilityToIvars(). No need for an extra API when it is trivial to add this info to the previous hook.

In general, I want to start migrating away from having Actions prefixed with "Parse" (which is confusing, since the Action API doesn't do any parsing, per se).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@41973 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Sema/Sema.h b/Sema/Sema.h
index 2b50f5e..a9e33f4 100644
--- a/Sema/Sema.h
+++ b/Sema/Sema.h
@@ -155,8 +155,11 @@
                            SourceLocation NameLoc, AttributeList *Attr);
   virtual DeclTy *ParseField(Scope *S, DeclTy *TagDecl,SourceLocation DeclStart,
                              Declarator &D, ExprTy *BitfieldWidth);
-  virtual void ParseRecordBody(SourceLocation RecLoc, DeclTy *TagDecl,
-                               DeclTy **Fields, unsigned NumFields);
+                                      
+  // This is used for both record definitions and ObjC interface declarations.
+  virtual void ProcessFieldDecls(SourceLocation RecLoc, DeclTy *TagDecl,
+                                 DeclTy **Fields, unsigned NumFields,
+                                 tok::ObjCKeywordKind *visibility = 0);
   virtual DeclTy *ParseEnumConstant(Scope *S, DeclTy *EnumDecl,
                                     DeclTy *LastEnumConstant,
                                     SourceLocation IdLoc, IdentifierInfo *Id,
@@ -368,10 +371,6 @@
   virtual DeclTy *ObjcBuildMethodDeclaration(SourceLocation MethodLoc, 
  	     	    tok::TokenKind MethodType, TypeTy *ReturnType,
      		    IdentifierInfo *SelectorName, AttributeList *AttrList);
-                                      
-  virtual void ObjcAddVisibilityToIvars(DeclTy *ClassDec, DeclTy **Ivar,
-				        unsigned numIvars,
-                                        tok::ObjCKeywordKind *visibility);
 private:
   // UsualUnaryConversions - promotes integers (C99 6.3.1.1p2) and converts
   // functions and arrays to their respective pointers (C99 6.3.2.1).