aboutsummaryrefslogtreecommitdiffstats
path: root/lib/AsmParser
diff options
context:
space:
mode:
authorDavid Greene <greened@obbligato.org>2007-09-04 15:46:09 +0000
committerDavid Greene <greened@obbligato.org>2007-09-04 15:46:09 +0000
commit393be88e51bce88754c8b5615e8a295adbdab1e2 (patch)
tree3e79ac89138858c59c1f73af09b64527778ad944 /lib/AsmParser
parent23ca9c580eb8df31bd537a084ed450eca8ebcf58 (diff)
downloadexternal_llvm-393be88e51bce88754c8b5615e8a295adbdab1e2.zip
external_llvm-393be88e51bce88754c8b5615e8a295adbdab1e2.tar.gz
external_llvm-393be88e51bce88754c8b5615e8a295adbdab1e2.tar.bz2
Update GEP constructors to use an iterator interface to fix
GLIBCXX_DEBUG issues. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41697 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AsmParser')
-rw-r--r--lib/AsmParser/llvmAsmParser.y6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/AsmParser/llvmAsmParser.y b/lib/AsmParser/llvmAsmParser.y
index 5570692..93f7a08 100644
--- a/lib/AsmParser/llvmAsmParser.y
+++ b/lib/AsmParser/llvmAsmParser.y
@@ -1886,7 +1886,7 @@ ConstExpr: CastOps '(' ConstVal TO Types ')' {
GEN_ERROR("GetElementPtr requires a pointer operand");
const Type *IdxTy =
- GetElementPtrInst::getIndexedType($3->getType(), &(*$4)[0], $4->size(),
+ GetElementPtrInst::getIndexedType($3->getType(), $4->begin(), $4->end(),
true);
if (!IdxTy)
GEN_ERROR("Index list invalid for constant getelementptr");
@@ -3064,12 +3064,12 @@ MemoryInst : MALLOC Types OptCAlign {
if (!isa<PointerType>($2->get()))
GEN_ERROR("getelementptr insn requires pointer operand");
- if (!GetElementPtrInst::getIndexedType(*$2, &(*$4)[0], $4->size(), true))
+ if (!GetElementPtrInst::getIndexedType(*$2, $4->begin(), $4->end(), true))
GEN_ERROR("Invalid getelementptr indices for type '" +
(*$2)->getDescription()+ "'");
Value* tmpVal = getVal(*$2, $3);
CHECK_FOR_ERROR
- $$ = new GetElementPtrInst(tmpVal, &(*$4)[0], $4->size());
+ $$ = new GetElementPtrInst(tmpVal, $4->begin(), $4->end());
delete $2;
delete $4;
};