Change ConstantArray to 2.5 API.
[oota-llvm.git] / tools / bugpoint / ExtractFunction.cpp
index 41704f9dcab9f11a43cd76273168237921c8a3be..c2159dea4b032c846a400dfef6785a6c3c9be629 100644 (file)
@@ -187,9 +187,9 @@ static Constant *GetTorInit(std::vector<std::pair<Function*, int> > &TorList) {
     std::vector<Constant*> Elts;
     Elts.push_back(ConstantInt::get(Type::Int32Ty, TorList[i].second));
     Elts.push_back(TorList[i].first);
-    ArrayElts.push_back(Context.getConstantStruct(Elts));
+    ArrayElts.push_back(ConstantStruct::get(Elts));
   }
-  return Context.getConstantArray(Context.getArrayType(ArrayElts[0]->getType(), 
+  return ConstantArray::get(Context.getArrayType(ArrayElts[0]->getType(), 
                                            ArrayElts.size()),
                             ArrayElts);
 }