aboutsummaryrefslogtreecommitdiff
path: root/lib/Checker/BasicStore.cpp
diff options
context:
space:
mode:
authorZhongxing Xu <xuzhongxing@gmail.com>2010-08-11 06:10:55 +0000
committerZhongxing Xu <xuzhongxing@gmail.com>2010-08-11 06:10:55 +0000
commit018220c343c103b7dfaa117a7a474c7a7fd6d068 (patch)
tree40dc57713cecb35317bb9b28a17941d07803c716 /lib/Checker/BasicStore.cpp
parent18451ea83a4ec5a61816c20dc03f2ed8648600d1 (diff)
MemRegion can refer to ASTContext without external help.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110784 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Checker/BasicStore.cpp')
-rw-r--r--lib/Checker/BasicStore.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Checker/BasicStore.cpp b/lib/Checker/BasicStore.cpp
index db2e3edb3e..7d01c9e110 100644
--- a/lib/Checker/BasicStore.cpp
+++ b/lib/Checker/BasicStore.cpp
@@ -236,7 +236,7 @@ Store BasicStoreManager::Bind(Store store, Loc loc, SVal V) {
if (isa<Loc>(V) || isa<nonloc::LocAsInteger>(V))
if (const ElementRegion *ER = dyn_cast<ElementRegion>(R)) {
// FIXME: Should check for index 0.
- QualType T = ER->getLocationType(C);
+ QualType T = ER->getLocationType();
if (isHigherOrderRawPtr(T, C))
R = ER->getSuperRegion();
@@ -249,7 +249,7 @@ Store BasicStoreManager::Bind(Store store, Loc loc, SVal V) {
// Do not bind to arrays. We need to explicitly check for this so that
// we do not encounter any weirdness of trying to load/store from arrays.
- if (TyR->isBoundable() && TyR->getValueType(C)->isArrayType())
+ if (TyR->isBoundable() && TyR->getValueType()->isArrayType())
return store;
if (nonloc::LocAsInteger *X = dyn_cast<nonloc::LocAsInteger>(&V)) {
@@ -259,7 +259,7 @@ Store BasicStoreManager::Bind(Store store, Loc loc, SVal V) {
// a pointer. We may wish to flag a type error here if the types
// are incompatible. This may also cause lots of breakage
// elsewhere. Food for thought.
- if (TyR->isBoundable() && Loc::IsLocType(TyR->getValueType(C)))
+ if (TyR->isBoundable() && Loc::IsLocType(TyR->getValueType()))
V = X->getLoc();
}
@@ -580,7 +580,7 @@ Store BasicStoreManager::InvalidateRegion(Store store,
}
}
- QualType T = cast<TypedRegion>(R)->getValueType(R->getContext());
+ QualType T = cast<TypedRegion>(R)->getValueType();
SVal V = ValMgr.getConjuredSymbolVal(R, E, T, Count);
return Bind(store, loc::MemRegionVal(R), V);
}