[PATCH] D77062: [analyzer] Improve zero assumption in CStringChecke::assumeZero

Artem Dergachev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 28 11:00:01 PDT 2020


NoQ added a comment.

Nice, very interesting!

The contract of RegionStore with respect to type punning is that it stores the value //as written//, even if its type doesn't match the storage type, but then it casts the value to the correct type upon reading by invoking `CastRetrievedVal()` on it. That's where the fix should probably be.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D77062/new/

https://reviews.llvm.org/D77062



More information about the cfe-commits mailing list