]> granicus.if.org Git - clang/commitdiff
Renamed Protocol as TheProtocol so people can use clang header for
authorFariborz Jahanian <fjahanian@apple.com>
Sun, 21 Jun 2009 18:26:03 +0000 (18:26 +0000)
committerFariborz Jahanian <fjahanian@apple.com>
Sun, 21 Jun 2009 18:26:03 +0000 (18:26 +0000)
building obj-c++ clients. "Protocol" is a class name in Cocoa.h

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@73854 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/AST/ExprObjC.h
lib/AST/Expr.cpp

index ef78c4081e346dcc0f89014501bf54556a7d4eb3..e00833b5820e5029dfa545dcc5071e97e9c3e0d5 100644 (file)
@@ -138,20 +138,20 @@ public:
 ///   obj conformsToProtocol:@protocol(foo)]
 /// The return type is "Protocol*".
 class ObjCProtocolExpr : public Expr {    
-  ObjCProtocolDecl *Protocol;    
+  ObjCProtocolDecl *TheProtocol;    
   SourceLocation AtLoc, RParenLoc;
 public:
   ObjCProtocolExpr(QualType T, ObjCProtocolDecl *protocol,
                    SourceLocation at, SourceLocation rp)
-  : Expr(ObjCProtocolExprClass, T), Protocol(protocol),
+  : Expr(ObjCProtocolExprClass, T), TheProtocol(protocol),
     AtLoc(at), RParenLoc(rp) {}
   explicit ObjCProtocolExpr(EmptyShell Empty)
     : Expr(ObjCProtocolExprClass, Empty) {}
 
   ObjCProtocolExpr *Clone(ASTContext &C) const;
   
-  ObjCProtocolDecl *getProtocol() const { return Protocol; }
-  void setProtocol(ObjCProtocolDecl *P) { Protocol = P; }
+  ObjCProtocolDecl *getProtocol() const { return TheProtocol; }
+  void setProtocol(ObjCProtocolDecl *P) { TheProtocol = P; }
     
   SourceLocation getAtLoc() const { return AtLoc; }
   SourceLocation getRParenLoc() const { return RParenLoc; }
index eb4136c2e2a114213f50c0b6c96596062e0f2fc6..4a3ad2641ef4bec9eca0505e6c4c3e171548f8f6 100644 (file)
@@ -1571,7 +1571,7 @@ ObjCSelectorExpr *ObjCSelectorExpr::Clone(ASTContext &C) const {
 }
 
 ObjCProtocolExpr *ObjCProtocolExpr::Clone(ASTContext &C) const {
-  return new (C) ObjCProtocolExpr(getType(), Protocol, AtLoc, RParenLoc);
+  return new (C) ObjCProtocolExpr(getType(), TheProtocol, AtLoc, RParenLoc);
 }
 
 // constructor for class messages.