================
@@ -1877,6 +1914,33 @@ static bool didPreviousFreeFail(ProgramStateRef State,
   return false;
 }
 
+static void printOwnershipTakesList(raw_ostream &os, CheckerContext &C,
+                                    const Expr *E) {
+  if (const CallExpr *CE = dyn_cast<CallExpr>(E)) {
+    const FunctionDecl *FD = CE->getDirectCallee();
+    if (!FD)
+      return;
+
+    if (FD->hasAttrs()) {
----------------
steakhal wrote:

You could switch this into an early-return to reduce indentation for the rest 
of the code.
Same applies to the `if (const CallExpr *CE = dyn_cast<CallExpr>(E))` a few 
lines above.

https://github.com/llvm/llvm-project/pull/98941
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to