diff options
Diffstat (limited to 'clang/lib/Analysis/Store.cpp')
-rw-r--r-- | clang/lib/Analysis/Store.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Analysis/Store.cpp b/clang/lib/Analysis/Store.cpp index 56f8a0a70c9..0479c684d71 100644 --- a/clang/lib/Analysis/Store.cpp +++ b/clang/lib/Analysis/Store.cpp @@ -106,6 +106,7 @@ const MemRegion *StoreManager::CastRegion(const MemRegion *R, QualType CastToTy) case MemRegion::FieldRegionKind: case MemRegion::ObjCIvarRegionKind: case MemRegion::VarRegionKind: + case MemRegion::CXXObjectRegionKind: return MakeElementRegion(R, PointeeTy); case MemRegion::ElementRegionKind: { @@ -240,3 +241,8 @@ SVal StoreManager::getLValueCompoundLiteral(const CompoundLiteralExpr* CL, const LocationContext *LC) { return loc::MemRegionVal(MRMgr.getCompoundLiteralRegion(CL, LC)); } + +Loc StoreManager::getThisObject(QualType T) { + const CXXObjectRegion *R = MRMgr.getCXXObjectRegion(T); + return loc::MemRegionVal(R); +} |