[PATCH] D96090: [analyzer] Replace StoreManager::CastRetrievedVal with SValBuilder::evalCast

Denys Petrov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 4 16:11:55 PST 2021


ASDenysPetrov created this revision.
ASDenysPetrov added reviewers: NoQ, steakhal, xazax.hun.
ASDenysPetrov added a project: clang.
Herald added subscribers: nullptr.cpp, martong, Charusso, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware.
ASDenysPetrov requested review of this revision.
Herald added a subscriber: cfe-commits.

Move logic from CastRetrievedVal to evalCast and replace CastRetrievedVal with evalCast. Also we need to move guts from SimpleSValBuilder::dispatchCast inside evalCast. Now evalCast operates in two modes:

- without passing last parameter it works like previous dispatchCast
- with passing last parameter it stays as is.

This patch ideally shall not change any behavior. (Should we mark it as [NFC]?)

This is an intermediate revision for D89055 <https://reviews.llvm.org/D89055>.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D96090

Files:
  clang/include/clang/StaticAnalyzer/Core/PathSensitive/SValBuilder.h
  clang/include/clang/StaticAnalyzer/Core/PathSensitive/Store.h
  clang/lib/StaticAnalyzer/Core/RegionStore.cpp
  clang/lib/StaticAnalyzer/Core/SValBuilder.cpp
  clang/lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp
  clang/lib/StaticAnalyzer/Core/Store.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D96090.321602.patch
Type: text/x-patch
Size: 12064 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210205/50417032/attachment-0001.bin>


More information about the cfe-commits mailing list