[analyzer][NFC] Add tests for D132236
authorTomasz Kamiński <tomasz.kamiński@sonarsource.com>
Mon, 3 Oct 2022 13:14:04 +0000 (15:14 +0200)
committerTomasz Kamiński <tomasz.kamiński@sonarsource.com>
Mon, 3 Oct 2022 13:42:38 +0000 (15:42 +0200)
commit73716baa30ebc75783d2902e12accea35dec193a
tree42a0fae52acd138a716265729d8fdd988c0c9783
parent772fb97c0b9bbc5fff2f5a2d45f959a66d5e5b6e
[analyzer][NFC] Add tests for D132236

D132236 would have introduced regressions in the symbol lifetime
handling. However, the testsuite did not catch this, so here we have
some tests, which would have break if D132236 had landed.

This patch addresses the comment https://reviews.llvm.org/D132236#3753238

Co-authored-by: Balazs Benics <balazs.benics@sonarsource.com>
Reviewed By: martong

Differential Revision: https://reviews.llvm.org/D134941
clang/test/Analysis/NewDeleteLeaks.cpp
clang/test/Analysis/symbol-reaper-lambda.cpp [new file with mode: 0644]
clang/test/Analysis/trivial-copy-struct.cpp