]> granicus.if.org Git - clang/commit
[analyzer] Don't crash if we cache out after making a temporary region.
authorJordan Rose <jordan_rose@apple.com>
Thu, 18 Apr 2013 16:33:40 +0000 (16:33 +0000)
committerJordan Rose <jordan_rose@apple.com>
Thu, 18 Apr 2013 16:33:40 +0000 (16:33 +0000)
commit476f41c4750421a7ead5014e75a0e790ff682754
treee64d0e472e11aaeb0b51098a331ecd46378207a2
parent324645a2cc058a86bc12c6a63a74da2b2590c74f
[analyzer] Don't crash if we cache out after making a temporary region.

A C++ overloaded operator may be implemented as an instance method, and
that instance method may be called on an rvalue object, which has no
associated region. The analyzer handles this by creating a temporary region
just for the evaluation of this call; however, it is possible that /by
creating the region/, the analyzer ends up in a previously-explored state.
In this case we don't need to continue along this path.

This doesn't actually show any behavioral change now, but it starts being
used with the next commit and prevents an assertion failure there.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179766 91177308-0d34-0410-b5e6-96231b3b80d8
lib/StaticAnalyzer/Core/ExprEngine.cpp
test/Analysis/operator-calls.cpp