Patch to support Gnu runtime's typed selectors.
Patch by David Chisnall.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@71023 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/CGObjCRuntime.h b/lib/CodeGen/CGObjCRuntime.h
index ada4495..55d94a0 100644
--- a/lib/CodeGen/CGObjCRuntime.h
+++ b/lib/CodeGen/CGObjCRuntime.h
@@ -17,6 +17,7 @@
 #define CLANG_CODEGEN_OBCJRUNTIME_H
 #include "clang/Basic/IdentifierTable.h" // Selector
 #include "llvm/ADT/SmallVector.h"
+#include "clang/AST/DeclObjC.h"
 #include <string>
 
 #include "CGBuilder.h"
@@ -100,6 +101,10 @@
   virtual llvm::Value *GetSelector(CGBuilderTy &Builder,
                                    Selector Sel) = 0;
 
+  /// Get a typed selector.  
+  virtual llvm::Value *GetSelector(CGBuilderTy &Builder,
+                                   const ObjCMethodDecl *Method) = 0;
+
   /// Generate a constant string object.
   virtual llvm::Constant *GenerateConstantString(const ObjCStringLiteral *) = 0;
 
@@ -110,14 +115,15 @@
   /// Generate a class stucture for this class.
   virtual void GenerateClass(const ObjCImplementationDecl *OID) = 0;
   
-  /// Generate an Objective-C message send operation.
+  /// Generate an Objective-C message send operation. 
   virtual CodeGen::RValue 
   GenerateMessageSend(CodeGen::CodeGenFunction &CGF,
                       QualType ResultType,
                       Selector Sel,
                       llvm::Value *Receiver,
                       bool IsClassMessage,
-                      const CallArgList &CallArgs) = 0;
+                      const CallArgList &CallArgs,
+                      const ObjCMethodDecl *Method=0) = 0;
 
   /// Generate an Objective-C message send operation to the super
   /// class initiated in a method for Class and with the given Self