mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-26 23:24:34 +00:00
fix a bug in the 1 index GEP handling code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21670 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -728,7 +728,7 @@ const Type* GetElementPtrInst::getIndexedType(const Type *Ptr, Value *Idx) {
|
|||||||
// Check the pointer index.
|
// Check the pointer index.
|
||||||
if (!PTy->indexValid(Idx)) return 0;
|
if (!PTy->indexValid(Idx)) return 0;
|
||||||
|
|
||||||
return PTy;
|
return PTy->getElementType();
|
||||||
}
|
}
|
||||||
|
|
||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
|
Reference in New Issue
Block a user