]> granicus.if.org Git - clang/commit
[analyzer] Use evalBind for C++ new of scalar types.
authorJordan Rose <jordan_rose@apple.com>
Wed, 27 Mar 2013 18:10:35 +0000 (18:10 +0000)
committerJordan Rose <jordan_rose@apple.com>
Wed, 27 Mar 2013 18:10:35 +0000 (18:10 +0000)
commitb061720ddf88b4a1934dbbb1b874a424716cd7d7
tree5b5b8db5e332edc6870c043d16aede52cdc46798
parent3655119ab1cb7b26926afeeb0f96cb21a21e410a
[analyzer] Use evalBind for C++ new of scalar types.

These types will not have a CXXConstructExpr to do the initialization for
them. Previously we just used a simple call to ProgramState::bindLoc, but
that doesn't trigger proper checker callbacks (like pointer escape).

Found by Anton Yartsev.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178160 91177308-0d34-0410-b5e6-96231b3b80d8
lib/StaticAnalyzer/Core/ExprEngineCXX.cpp
test/Analysis/new.cpp