mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-19 19:25:40 +00:00
Fix more breakage with string change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10882 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -298,10 +298,10 @@ void BytecodeParser::parseStringConstants(const unsigned char *&Buf,
|
|||||||
std::vector<Constant*> Elements(ATy->getNumElements());
|
std::vector<Constant*> Elements(ATy->getNumElements());
|
||||||
if (ATy->getElementType() == Type::SByteTy)
|
if (ATy->getElementType() == Type::SByteTy)
|
||||||
for (unsigned i = 0, e = ATy->getNumElements(); i != e; ++i)
|
for (unsigned i = 0, e = ATy->getNumElements(); i != e; ++i)
|
||||||
Elements[i] = ConstantSInt::get(Type::SByteTy, Data[i]);
|
Elements[i] = ConstantSInt::get(Type::SByteTy, (signed char)Data[i]);
|
||||||
else
|
else
|
||||||
for (unsigned i = 0, e = ATy->getNumElements(); i != e; ++i)
|
for (unsigned i = 0, e = ATy->getNumElements(); i != e; ++i)
|
||||||
Elements[i] = ConstantUInt::get(Type::UByteTy, Data[i]);
|
Elements[i] = ConstantUInt::get(Type::UByteTy, (unsigned char)Data[i]);
|
||||||
|
|
||||||
// Create the constant, inserting it as needed.
|
// Create the constant, inserting it as needed.
|
||||||
Constant *C = ConstantArray::get(ATy, Elements);
|
Constant *C = ConstantArray::get(ATy, Elements);
|
||||||
|
Reference in New Issue
Block a user