aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/RegionStore.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-07-16 00:00:11 +0000
committerTed Kremenek <kremenek@apple.com>2009-07-16 00:00:11 +0000
commit75185b5872a02e1025063dd639236552719ba1d3 (patch)
tree8ee32e234539ef85cb8e35131acf526017cbcb8b /lib/Analysis/RegionStore.cpp
parenta8ded8be82f7d5f5fc93c8626cfa9ca9cee4199e (diff)
Use utility method to create 0-index into ElementRegion.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@75865 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/RegionStore.cpp')
-rw-r--r--lib/Analysis/RegionStore.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Analysis/RegionStore.cpp b/lib/Analysis/RegionStore.cpp
index fa355f551c..af731c78d2 100644
--- a/lib/Analysis/RegionStore.cpp
+++ b/lib/Analysis/RegionStore.cpp
@@ -672,8 +672,8 @@ SVal RegionStoreManager::ArrayToPointer(Loc Array) {
ArrayType *AT = cast<ArrayType>(T);
T = AT->getElementType();
- nonloc::ConcreteInt Idx(getBasicVals().getZeroWithPtrWidth(false));
- ElementRegion* ER = MRMgr.getElementRegion(T, Idx, ArrayR, getContext());
+ SVal ZeroIdx = ValMgr.makeZeroArrayIndex();
+ ElementRegion* ER = MRMgr.getElementRegion(T, ZeroIdx, ArrayR, getContext());
return loc::MemRegionVal(ER);
}