[clang] Fix: Issue #165239 — resolve -Wuninitialized warnings (PR #166991)
Yanzuo Liu via cfe-commits
cfe-commits at lists.llvm.org
Sat Nov 8 05:26:29 PST 2025
================
@@ -414,6 +414,13 @@ Improvements to Clang's diagnostics
- Clang now emits a diagnostic in case `vector_size` or `ext_vector_type`
attributes are used with a negative size (#GH165463).
+- Fixed: ``-Wuninitialized`` now emits a warning for uninitialized fixed-size local arrays. For example:
+
+ .. code-block:: c
+
+ int arr[4];
+ int x = arr[2]; // warning: variable 'arr' is uninitialized when used here (#GH165239)
----------------
zwuis wrote:
Reference the issue in text, not in code blocks.
https://github.com/llvm/llvm-project/pull/166991
More information about the cfe-commits
mailing list