[PATCH] D126534: [analyzer] Deadstore static analysis: Fix false positive on C++17 assignments

Fred Tingaud via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri May 27 07:56:11 PDT 2022


frederic-tingaud-sonarsource marked an inline comment as done.
frederic-tingaud-sonarsource added a comment.

Thanks for looking at the PR!

In D126534#3542402 <https://reviews.llvm.org/D126534#3542402>, @steakhal wrote:

> You also mentioned this copy elision, but I don't see anywhere checks for the standard version in code. I would expect that your change should apply only to C++17 and above.

The false-positive due to copy elision in C++17 is the main pain point that this patch fixes, which is why I mention it in the title, but it does in fact also solve other cases for all C++ versions if there are parentheses or casts involved.


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

https://reviews.llvm.org/D126534



More information about the cfe-commits mailing list