forked from OSchip/llvm-project
fix a bug in the 1 index GEP handling code
llvm-svn: 21670
This commit is contained in:
parent
38cabd7265
commit
c22333348e
|
@ -728,7 +728,7 @@ const Type* GetElementPtrInst::getIndexedType(const Type *Ptr, Value *Idx) {
|
|||
// Check the pointer index.
|
||||
if (!PTy->indexValid(Idx)) return 0;
|
||||
|
||||
return PTy;
|
||||
return PTy->getElementType();
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
|
Loading…
Reference in New Issue