[clang] [clang][analyzer] Improved message in uninitialized.Assign at default assignment (PR #208173)

Balázs Benics via cfe-commits cfe-commits at lists.llvm.org
Sat Jul 11 05:04:35 PDT 2026


================
@@ -162,4 +167,11 @@ namespace SynthesizedAssignment {
     clang_analyzer_eval(u.a[2].a == 43); // expected-warning{{TRUE}}
     // expected-note at -1{{TRUE}}
   }
+
+  void testImplicitAssign() {
+    C c1, c2;
+    c1 = c2; // expected-warning at 114{{Value assigned to field 'x' in implicit assignment operator is uninitialized}}
----------------
steakhal wrote:

What would be the blast radius of those changes?

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


More information about the cfe-commits mailing list