================
@@ -160,6 +162,19 @@ class LifetimeChecker {
for (const auto &[PVD, EscapeExpr] : AnnotationWarningsMap)
Reporter->suggestAnnotation(PVD, EscapeExpr);
}
+
+ void inferAnnotations() {
+ /// NOTE: This currently only adds the attribute to the function definition
+ /// being analyzed. For full inter-procedural inference to work reliably
+ /// (e.g., with out-of-order definitions), this attribute would also need
to
+ /// be added to all other redeclarations of the function.
----------------
Xazax-hun wrote:
This is where the Clang static analyzer is doing some ordering over the
function call graph:
https://github.com/llvm/llvm-project/blob/405403c8ed4b2956dc03c270373fac2576a23a65/clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp#L480
https://github.com/llvm/llvm-project/pull/171081
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits