summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGDecl.cpp
diff options
context:
space:
mode:
authorJay Foad <jay.foad@gmail.com>2011-07-22 08:16:57 +0000
committerJay Foad <jay.foad@gmail.com>2011-07-22 08:16:57 +0000
commit040dd82f4497a1dc00d1b42df39274150c1b8fdb (patch)
tree0c607a36e2f78ed5efabd20675e324bc9109d3e8 /clang/lib/CodeGen/CGDecl.cpp
parent43025a08699db9ca83c4f5a4607e056aab470b04 (diff)
downloadbcm5719-llvm-040dd82f4497a1dc00d1b42df39274150c1b8fdb.tar.gz
bcm5719-llvm-040dd82f4497a1dc00d1b42df39274150c1b8fdb.zip
Convert IRBuilder::CreateGEP and IRBuilder::CreateInBoundsGEP to use
ArrayRef. llvm-svn: 135761
Diffstat (limited to 'clang/lib/CodeGen/CGDecl.cpp')
-rw-r--r--clang/lib/CodeGen/CGDecl.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/clang/lib/CodeGen/CGDecl.cpp b/clang/lib/CodeGen/CGDecl.cpp
index 8093dd00420..b9e4e7dffd1 100644
--- a/clang/lib/CodeGen/CGDecl.cpp
+++ b/clang/lib/CodeGen/CGDecl.cpp
@@ -1268,10 +1268,8 @@ static void emitPartialArrayDestroy(CodeGenFunction &CGF,
llvm::Value *zero = llvm::ConstantInt::get(CGF.SizeTy, arrayDepth+1);
llvm::SmallVector<llvm::Value*,4> gepIndices(arrayDepth, zero);
- begin = CGF.Builder.CreateInBoundsGEP(begin, gepIndices.begin(),
- gepIndices.end(), "pad.arraybegin");
- end = CGF.Builder.CreateInBoundsGEP(end, gepIndices.begin(),
- gepIndices.end(), "pad.arrayend");
+ begin = CGF.Builder.CreateInBoundsGEP(begin, gepIndices, "pad.arraybegin");
+ end = CGF.Builder.CreateInBoundsGEP(end, gepIndices, "pad.arrayend");
}
// Destroy the array. We don't ever need an EH cleanup because we
OpenPOWER on IntegriCloud