diff options
| author | Zhongxing Xu <xuzhongxing@gmail.com> | 2009-05-11 14:28:14 +0000 |
|---|---|---|
| committer | Zhongxing Xu <xuzhongxing@gmail.com> | 2009-05-11 14:28:14 +0000 |
| commit | 52091db11f1ad24427b833720457f56798319fdc (patch) | |
| tree | ccb6542543f5b2047942dcef4de42703d420aade /clang/lib/Analysis/CFRefCount.cpp | |
| parent | c012656266b7c582076fa49ae94b96bbbe6a4adc (diff) | |
| download | bcm5719-llvm-52091db11f1ad24427b833720457f56798319fdc.tar.gz bcm5719-llvm-52091db11f1ad24427b833720457f56798319fdc.zip | |
TypedRegion is a too general assumption. Usually we only want to invalidate
the VarRegion as a super region of an ElementRegion.
llvm-svn: 71431
Diffstat (limited to 'clang/lib/Analysis/CFRefCount.cpp')
| -rw-r--r-- | clang/lib/Analysis/CFRefCount.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/Analysis/CFRefCount.cpp b/clang/lib/Analysis/CFRefCount.cpp index 4b254e07d59..d3702ec8eb7 100644 --- a/clang/lib/Analysis/CFRefCount.cpp +++ b/clang/lib/Analysis/CFRefCount.cpp @@ -2660,7 +2660,7 @@ void CFRefCount::EvalSummary(ExplodedNodeSet<GRState>& Dst, if (R) { // Are we dealing with an ElementRegion? If the element type is // a basic integer type (e.g., char, int) and the underying region - // is also typed then strip off the ElementRegion. + // is a variable region then strip off the ElementRegion. // FIXME: We really need to think about this for the general case // as sometimes we are reasoning about arrays and other times // about (char*), etc., is just a form of passing raw bytes. @@ -2674,8 +2674,8 @@ void CFRefCount::EvalSummary(ExplodedNodeSet<GRState>& Dst, // still allowing us to do checker-specific logic (e.g., // invalidating reference counts), probably via callbacks. if (ER->getElementType()->isIntegralType()) - if (const TypedRegion *superReg = - dyn_cast<TypedRegion>(ER->getSuperRegion())) + if (const VarRegion *superReg = + dyn_cast<VarRegion>(ER->getSuperRegion())) R = superReg; // FIXME: What about layers of ElementRegions? } |

