[Fix][-Wunsafe-buffer-usage] Add a new `forEachDescendant` matcher that skips callabl...
authorziqingluo-90 <ziqing@udel.edu>
Fri, 6 Jan 2023 22:29:19 +0000 (14:29 -0800)
committerziqingluo-90 <ziqing@udel.edu>
Fri, 6 Jan 2023 22:38:12 +0000 (14:38 -0800)
commit5be422b49288d7b9394312ad5ccba1fef42116e6
tree874e3b20f924d580145a8a59226e6974c7007442
parent0995a31e5d72384a1e07d09c8a5367c9d0805d2d
[Fix][-Wunsafe-buffer-usage] Add a new `forEachDescendant` matcher that skips callable declarations

The original patch does include a `new` statement without a matching
`delete`, causing Sanitizer warnings in
https://lab.llvm.org/buildbot/#/builders/5/builds/30522/steps/13/logs/stdio.

This commit is a fix to it.

Differential Revision: https://reviews.llvm.org/D138329
clang/lib/Analysis/UnsafeBufferUsage.cpp