[clang] [analyzer] Fix a crash from element region construction during `ArrayInitLoopExpr` analysis (PR #113570)
Balazs Benics via cfe-commits
cfe-commits at lists.llvm.org
Fri Oct 25 10:19:20 PDT 2024
================
@@ -330,3 +330,41 @@ void no_crash() {
}
} // namespace crash
+
+namespace array_subscript_initializer {
+struct S {
+ int x;
+};
+
+void no_crash() {
+ S arr[][2] = {{1, 2}};
+
+ const auto [a, b] = arr[0]; // no-crash
----------------
steakhal wrote:
My bad. Im too tired now.
https://github.com/llvm/llvm-project/pull/113570
More information about the cfe-commits
mailing list