1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 03:02:36 +01:00

Move part of an if condition into an assertion. NFC.

llvm-svn: 258163
This commit is contained in:
Manuel Jacob 2016-01-19 19:04:49 +00:00
parent 553ef84e85
commit becbd7b6ad

View File

@ -731,8 +731,8 @@ static Constant *SymbolicallyEvaluateGEP(Type *SrcTy, ArrayRef<Constant *> Ops,
Type *ResultTy, const DataLayout &DL,
const TargetLibraryInfo *TLI) {
Constant *Ptr = Ops[0];
if (!Ptr->getType()->getPointerElementType()->isSized() ||
!Ptr->getType()->isPointerTy())
assert(Ptr->getType()->isPointerTy());
if (!Ptr->getType()->getPointerElementType()->isSized())
return nullptr;
Type *IntPtrTy = DL.getIntPtrType(Ptr->getType());