1
0
mirror of https://github.com/c64scene-ar/llvm-6502.git synced 2025-04-22 15:39:28 +00:00

Fix this code for hosts where std::vector doesn't have .data().

Use &Ops[0] instead, which is safe since Ops will never be empty here.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72368 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Dan Gohman 2009-05-24 19:02:45 +00:00
parent 14fba294e1
commit fb5a3419f3

@ -351,7 +351,7 @@ Value *SCEVExpander::visitAddExpr(const SCEVAddExpr *S) {
if (SE.TD)
if (const PointerType *PTy = dyn_cast<PointerType>(V->getType())) {
const std::vector<SCEVHandle> &Ops = S->getOperands();
return expandAddToGEP(Ops.data(), Ops.data() + Ops.size() - 1,
return expandAddToGEP(&Ops[0], &Ops[Ops.size() - 1],
PTy, Ty, V);
}