[PATCH] D46823: [analyzer] const init: handle non-explicit cases more accurately

Rafael Stahl via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon May 28 06:49:00 PDT 2018


r.stahl updated this revision to Diff 148809.
r.stahl added a comment.

Added FIXME tests.

I know my example didn't exercise your scenario, but it was the only one I could think of where returning zero would have been straight up wrong. Note that I default initialized `a` to 3 there, so `sarr` is not just zero-initialized.

I do not have access yet, but applied today!


https://reviews.llvm.org/D46823

Files:
  lib/StaticAnalyzer/Core/RegionStore.cpp
  test/Analysis/initialization.c
  test/Analysis/initialization.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D46823.148809.patch
Type: text/x-patch
Size: 3731 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180528/ea713eb4/attachment-0001.bin>


More information about the cfe-commits mailing list