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]

Re: [RFH] Uninitialized warning as error is disabled on the trunk


This fixes a bug reported by Andrew Pinski on the gcc list.
> http://gcc.gnu.org/ml/gcc/2008-03/msg01058.html
There is a typo in system.h that prevents -Wuninitialized warnings from being turned into an error when assert checking is enabled. I already fixed the C++ front end bug that prevent Andrew from fixing this earlier.


This was tested with an x86-linux bootstrap and make check. There were no regressions. I have checked it in.

This might expose bugs in other ports, but if so it shouldn't be too hard to fix them.

Jim
2008-04-11  James E. Wilson  <wilson@tuliptree.org>

	* system.h: Change ASSERT_CHECKING to ENABLE_ASSERT_CHECKING.

Index: system.h
===================================================================
--- system.h	(revision 134215)
+++ system.h	(working copy)
@@ -802,7 +802,7 @@ extern void fancy_abort (const char *, i
 #pragma GCC diagnostic warning "-Wcast-qual"
 /* If asserts are disabled, activate -Wuninitialized as a warning (not
    an error/-Werror).  */
-#ifndef ASSERT_CHECKING
+#ifndef ENABLE_ASSERT_CHECKING
 #pragma GCC diagnostic warning "-Wuninitialized"
 #endif
 #endif

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