[clang] [Clang] Fix nonblocking warning for dependent default arguments (PR #235457)

Chen Miao via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 5 19:01:43 PST 2026


================
@@ -1342,6 +1342,14 @@ class Analyzer {
       return Result;
     }
 
+    bool TraverseParmVarDecl(ParmVarDecl *D) override {
+      // Uninstantiated default arguments are dependent expressions that cannot
+      // be analyzed for function effects without producing incorrect warnings.
+      if (D->hasUninstantiatedDefaultArg())
----------------
ChenMiaoi wrote:

yaha, we happened to point out the same issue.

https://github.com/llvm/llvm-project/pull/235457


More information about the cfe-commits mailing list