[-Wcalled-once-parameter] Fix false positives for cleanup attr
Cleanup attribute allows users to attach a destructor-like functions to variable declarations to be called whenever they leave the scope. The logic of such functions is not supported by the Clang's CFG and is too hard to be reasoned about. In order to avoid false positives in this situation, we assume that we didn't see ALL of the executtion paths of the function and, thus, can warn only about multiple call violation. rdar://74441906 Differential Revision: https://reviews.llvm.org/D98694
Loading
Please register or sign in to comment