This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Patch] Fix PR bootstrap/34144, bootstrap failure with checking disabled.


Andrew Pinski wrote this patch which makes -Wuninitialized diagnostics
non-fatal when assert checking is disabled.

I fixed a couple of minor typos and tested on x86_64-pc-linux-gnu. 
There were no differences between no patch --enable-checking=release and
with patch --disable-checking.

As the patch was approved several time over on gcc@, I have committed it.

2007-12-13  Andrew Pinski  <pinskia@gmail.com>
        David Daney  <ddaney@avtrex.com>

    PR bootstrap/34144
    * system.h: Make -Wuninitialized non-fatal if ASSERT_CHECKING
    is disabled.


Index: system.h
===================================================================
--- system.h	(revision 130907)
+++ system.h	(working copy)
@@ -797,6 +797,11 @@ extern void fancy_abort (const char *, i
 /* Activate -Wcast-qual as a warning (not an error/-Werror).  */
 #if GCC_VERSION >= 4003
 #pragma GCC diagnostic warning "-Wcast-qual"
+/* If asserts are disabled, activate -Wuninitialized as a warning (not
+   an error/-Werror).  */
+#ifndef ASSERT_CHECKING
+#pragma GCC diagnostic warning "-Wuninitialized"
+#endif
 #endif
 
 #endif /* ! GCC_SYSTEM_H */

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]