Change references to the Method class to be references to the Function
class.  The Method class is obsolete (renamed) and all references to it
are being converted over to Function.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2144 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Transforms/HoistPHIConstants.cpp b/lib/Transforms/HoistPHIConstants.cpp
index f20de1c..26cf5ca 100644
--- a/lib/Transforms/HoistPHIConstants.cpp
+++ b/lib/Transforms/HoistPHIConstants.cpp
@@ -10,7 +10,7 @@
 #include "llvm/iPHINode.h"
 #include "llvm/iOther.h"
 #include "llvm/BasicBlock.h"
-#include "llvm/Method.h"
+#include "llvm/Function.h"
 #include "llvm/Pass.h"
 #include <map>
 #include <vector>
@@ -42,11 +42,11 @@
 // Entry point for normalizing constant args in PHIs
 //---------------------------------------------------------------------------
 
-static bool doHoistPHIConstants(Method *M) {
+static bool doHoistPHIConstants(Function *M) {
   CachedCopyMap Cache;
   bool Changed = false;
   
-  for (Method::iterator BI = M->begin(), BE = M->end(); BI != BE; ++BI) {
+  for (Function::iterator BI = M->begin(), BE = M->end(); BI != BE; ++BI) {
     std::vector<PHINode*> phis;          // normalizing invalidates BB iterator
       
     for (BasicBlock::iterator II = (*BI)->begin(); II != (*BI)->end(); ++II) {
@@ -75,7 +75,7 @@
 
 namespace {
   struct HoistPHIConstants : public MethodPass {
-    virtual bool runOnMethod(Method *M) { return doHoistPHIConstants(M); }
+    virtual bool runOnMethod(Function *F) { return doHoistPHIConstants(F); }
   };
 }