mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-12 01:25:10 +00:00
Change ConstantArray to 2.5 API.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77347 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -288,7 +288,7 @@ void BitcodeReaderValueList::ResolveConstantForwardRefs() {
|
||||
// Make the new constant.
|
||||
Constant *NewC;
|
||||
if (ConstantArray *UserCA = dyn_cast<ConstantArray>(UserC)) {
|
||||
NewC = Context.getConstantArray(UserCA->getType(), &NewOps[0],
|
||||
NewC = ConstantArray::get(UserCA->getType(), &NewOps[0],
|
||||
NewOps.size());
|
||||
} else if (ConstantStruct *UserCS = dyn_cast<ConstantStruct>(UserC)) {
|
||||
NewC = ConstantStruct::get(&NewOps[0], NewOps.size(),
|
||||
@@ -930,7 +930,7 @@ bool BitcodeReader::ParseConstants() {
|
||||
const Type *EltTy = ATy->getElementType();
|
||||
for (unsigned i = 0; i != Size; ++i)
|
||||
Elts.push_back(ValueList.getConstantFwdRef(Record[i], EltTy));
|
||||
V = Context.getConstantArray(ATy, Elts);
|
||||
V = ConstantArray::get(ATy, Elts);
|
||||
} else if (const VectorType *VTy = dyn_cast<VectorType>(CurTy)) {
|
||||
const Type *EltTy = VTy->getElementType();
|
||||
for (unsigned i = 0; i != Size; ++i)
|
||||
@@ -952,7 +952,7 @@ bool BitcodeReader::ParseConstants() {
|
||||
std::vector<Constant*> Elts;
|
||||
for (unsigned i = 0; i != Size; ++i)
|
||||
Elts.push_back(ConstantInt::get(EltTy, Record[i]));
|
||||
V = Context.getConstantArray(ATy, Elts);
|
||||
V = ConstantArray::get(ATy, Elts);
|
||||
break;
|
||||
}
|
||||
case bitc::CST_CODE_CSTRING: { // CSTRING: [values]
|
||||
@@ -967,7 +967,7 @@ bool BitcodeReader::ParseConstants() {
|
||||
for (unsigned i = 0; i != Size; ++i)
|
||||
Elts.push_back(ConstantInt::get(EltTy, Record[i]));
|
||||
Elts.push_back(Context.getNullValue(EltTy));
|
||||
V = Context.getConstantArray(ATy, Elts);
|
||||
V = ConstantArray::get(ATy, Elts);
|
||||
break;
|
||||
}
|
||||
case bitc::CST_CODE_CE_BINOP: { // CE_BINOP: [opcode, opval, opval]
|
||||
|
Reference in New Issue
Block a user