diff options
author | Jordan Rose <jordan_rose@apple.com> | 2012-08-15 17:33:34 +0000 |
---|---|---|
committer | Jordan Rose <jordan_rose@apple.com> | 2012-08-15 17:33:34 +0000 |
commit | 9f6441ad92c30028032eb3df6f4a7f2ebe393a68 (patch) | |
tree | c93957af2c6f1a52192b8cede79f5dd4546ee9e3 /lib/StaticAnalyzer/Core/MemRegion.cpp | |
parent | 7bd092b054444e9800e8de1d8d71c408dbdc8ead (diff) |
[analyzer] Only adjust the type of 'this' when we devirtualize a method call.
With reinterpret_cast, we can get completely unrelated types in a region
hierarchy together; this was resulting in CXXBaseObjectRegions being layered
directly on an (untyped) SymbolicRegion, whose symbol was from a completely
different type hierarchy. This was what was causing the internal buildbot to
fail.
Reverts r161911, which merely masked the problem.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161960 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/StaticAnalyzer/Core/MemRegion.cpp')
-rw-r--r-- | lib/StaticAnalyzer/Core/MemRegion.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/StaticAnalyzer/Core/MemRegion.cpp b/lib/StaticAnalyzer/Core/MemRegion.cpp index 4f33bad492..62e602a7e1 100644 --- a/lib/StaticAnalyzer/Core/MemRegion.cpp +++ b/lib/StaticAnalyzer/Core/MemRegion.cpp @@ -1111,7 +1111,7 @@ RegionOffset MemRegion::getAsOffset() const { } const CXXRecordDecl *Child = Ty->getAsCXXRecordDecl(); - if (!Child || !Child->isCompleteDefinition()) { + if (!Child) { // We cannot compute the offset of the base class. SymbolicOffsetBase = R; } |