diff options
author | Craig Topper <craig.topper@gmail.com> | 2014-05-27 02:45:47 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2014-05-27 02:45:47 +0000 |
commit | 1843a2095a5509f59f7108b17ab817b92e55c6eb (patch) | |
tree | 9ed7a259162848318872a9fb37a7d50ba56d0e8d /lib/StaticAnalyzer/Core/Store.cpp | |
parent | 9d0a0d8e196610bb7fef57a5fa034b2f628f870f (diff) | |
download | clang-1843a2095a5509f59f7108b17ab817b92e55c6eb.tar.gz |
[C++11] Use 'nullptr'. StaticAnalyzer edition.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@209642 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/StaticAnalyzer/Core/Store.cpp')
-rw-r--r-- | lib/StaticAnalyzer/Core/Store.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/StaticAnalyzer/Core/Store.cpp b/lib/StaticAnalyzer/Core/Store.cpp index 0beb9dbbc5..e38be3e0b7 100644 --- a/lib/StaticAnalyzer/Core/Store.cpp +++ b/lib/StaticAnalyzer/Core/Store.cpp @@ -88,7 +88,7 @@ const MemRegion *StoreManager::castRegion(const MemRegion *R, QualType CastToTy) // We don't know what to make of it. Return a NULL region, which // will be interpretted as UnknownVal. - return NULL; + return nullptr; } // Now assume we are casting from pointer to pointer. Other cases should @@ -166,7 +166,7 @@ const MemRegion *StoreManager::castRegion(const MemRegion *R, QualType CastToTy) // If we cannot compute a raw offset, throw up our hands and return // a NULL MemRegion*. if (!baseR) - return NULL; + return nullptr; CharUnits off = rawOff.getOffset(); @@ -193,7 +193,7 @@ const MemRegion *StoreManager::castRegion(const MemRegion *R, QualType CastToTy) // Compute the index for the new ElementRegion. int64_t newIndex = 0; - const MemRegion *newSuperR = 0; + const MemRegion *newSuperR = nullptr; // We can only compute sizeof(PointeeTy) if it is a complete type. if (IsCompleteType(Ctx, PointeeTy)) { @@ -300,7 +300,7 @@ static const CXXRecordDecl *getCXXRecordType(const MemRegion *MR) { return TVR->getValueType()->getAsCXXRecordDecl(); if (const SymbolicRegion *SR = dyn_cast<SymbolicRegion>(MR)) return SR->getSymbol()->getType()->getPointeeCXXRecordDecl(); - return 0; + return nullptr; } SVal StoreManager::evalDynamicCast(SVal Base, QualType TargetType, @@ -401,7 +401,7 @@ SVal StoreManager::getLValueFieldOrIvar(const Decl *D, SVal Base) { return Base; Loc BaseL = Base.castAs<Loc>(); - const MemRegion* BaseR = 0; + const MemRegion* BaseR = nullptr; switch (BaseL.getSubKind()) { case loc::MemRegionKind: |