diff options
| author | Zhongxing Xu <xuzhongxing@gmail.com> | 2009-06-22 08:36:10 +0000 |
|---|---|---|
| committer | Zhongxing Xu <xuzhongxing@gmail.com> | 2009-06-22 08:36:10 +0000 |
| commit | 8077d7eb153f936f67532b8644aac90cd2aa4a80 (patch) | |
| tree | f8a2af1f979ba57f2b037161a71e131d620ff0e6 | |
| parent | 376c6f16de2d6a8eaea540f828fdfcef3d20f8ea (diff) | |
| download | bcm5719-llvm-8077d7eb153f936f67532b8644aac90cd2aa4a80.tar.gz bcm5719-llvm-8077d7eb153f936f67532b8644aac90cd2aa4a80.zip | |
Allow CodeTextRegion to be cast to 'void *'.
llvm-svn: 73880
| -rw-r--r-- | clang/lib/Analysis/RegionStore.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/lib/Analysis/RegionStore.cpp b/clang/lib/Analysis/RegionStore.cpp index 5f2b8f809de..427c2318001 100644 --- a/clang/lib/Analysis/RegionStore.cpp +++ b/clang/lib/Analysis/RegionStore.cpp @@ -676,7 +676,9 @@ RegionStoreManager::CastRegion(const GRState *state, const MemRegion* R, // CodeTextRegion should be cast to only function pointer type. if (isa<CodeTextRegion>(R)) { - assert(CastToTy->isFunctionPointerType() || CastToTy->isBlockPointerType()); + assert(CastToTy->isFunctionPointerType() || CastToTy->isBlockPointerType() + || (CastToTy->isPointerType() + && CastToTy->getAsPointerType()->getPointeeType()->isVoidType())); return CastResult(state, R); } |

