Return ConstantVector to 2.5 API.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77366 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson
2009-07-28 21:19:26 +00:00
parent e7c329bf4b
commit af7ec97587
21 changed files with 122 additions and 138 deletions

View File

@@ -294,7 +294,7 @@ void BitcodeReaderValueList::ResolveConstantForwardRefs() {
NewC = ConstantStruct::get(&NewOps[0], NewOps.size(),
UserCS->getType()->isPacked());
} else if (isa<ConstantVector>(UserC)) {
NewC = Context.getConstantVector(&NewOps[0], NewOps.size());
NewC = ConstantVector::get(&NewOps[0], NewOps.size());
} else {
assert(isa<ConstantExpr>(UserC) && "Must be a ConstantExpr.");
NewC = cast<ConstantExpr>(UserC)->getWithOperands(&NewOps[0],
@@ -935,7 +935,7 @@ bool BitcodeReader::ParseConstants() {
const Type *EltTy = VTy->getElementType();
for (unsigned i = 0; i != Size; ++i)
Elts.push_back(ValueList.getConstantFwdRef(Record[i], EltTy));
V = Context.getConstantVector(Elts);
V = ConstantVector::get(Elts);
} else {
V = Context.getUndef(CurTy);
}