OSDN Git Service

* inclhack.def: Avoid changing NULL on C++ friendly systems.
authormrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 28 Oct 2004 21:44:31 +0000 (21:44 +0000)
committermrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 28 Oct 2004 21:44:31 +0000 (21:44 +0000)
        * fixincl.x: Regenerate.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@89786 138bc75d-0d04-0410-961f-82ee72b054a4

fixincludes/ChangeLog
fixincludes/fixincl.x
fixincludes/inclhack.def

index defdb65..5161dd6 100644 (file)
@@ -1,3 +1,8 @@
+2004-10-28  Mike Stump  <mrs@apple.com>
+
+       * inclhack.def: Avoid changing NULL on C++ friendly systems.
+       * fixincl.x: Regenerate.
+
 2004-10-27  Geoffrey Keating  <geoffk@apple.com>
 
        * inclhack.def (darwin_gcc4_breakage): New.
 2004-10-27  Geoffrey Keating  <geoffk@apple.com>
 
        * inclhack.def (darwin_gcc4_breakage): New.
index 69098ae..948c727 100644 (file)
@@ -2,11 +2,11 @@
  * 
  * DO NOT EDIT THIS FILE   (fixincl.x)
  * 
  * 
  * DO NOT EDIT THIS FILE   (fixincl.x)
  * 
- * It has been AutoGen-ed  Tuesday October 26, 2004 at 01:55:22 PM PDT
+ * It has been AutoGen-ed  Thursday October 28, 2004 at 01:52:23 PM PDT
  * From the definitions    inclhack.def
  * and the template file   fixincl
  */
  * From the definitions    inclhack.def
  * and the template file   fixincl
  */
-/* DO NOT CVS-MERGE THIS FILE, EITHER Tue Oct 26 13:55:22 PDT 2004
+/* DO NOT CVS-MERGE THIS FILE, EITHER Thu Oct 28 13:52:23 PDT 2004
  *
  * You must regenerate it.  Use the ./genfixes script.
  *
  *
  * You must regenerate it.  Use the ./genfixes script.
  *
@@ -6684,8 +6684,15 @@ tSCC zVoid_NullList[] =
 tSCC zVoid_NullSelect0[] =
        "^#[ \t]*define[ \t]+NULL[ \t]+\\(\\(void[ \t]*\\*\\)0\\)";
 
 tSCC zVoid_NullSelect0[] =
        "^#[ \t]*define[ \t]+NULL[ \t]+\\(\\(void[ \t]*\\*\\)0\\)";
 
-#define    VOID_NULL_TEST_CT  1
+/*
+ *  content bypass pattern - skip fix if pattern found
+ */
+tSCC zVoid_NullBypass0[] =
+       "__cplusplus";
+
+#define    VOID_NULL_TEST_CT  2
 static tTestDesc aVoid_NullTests[] = {
 static tTestDesc aVoid_NullTests[] = {
+  { TT_NEGREP,   zVoid_NullBypass0, (regex_t*)NULL },
   { TT_EGREP,    zVoid_NullSelect0, (regex_t*)NULL }, };
 
 /*
   { TT_EGREP,    zVoid_NullSelect0, (regex_t*)NULL }, };
 
 /*
@@ -7139,7 +7146,7 @@ static const char* apzX11_SprintfPatch[] = {
  *
  *  List of all fixes
  */
  *
  *  List of all fixes
  */
-#define REGEX_COUNT          203
+#define REGEX_COUNT          204
 #define MACH_LIST_SIZE_LIMIT 261
 #define FIX_COUNT            180
 
 #define MACH_LIST_SIZE_LIMIT 261
 #define FIX_COUNT            180
 
index 00c5ae6..084594c 100644 (file)
@@ -3963,6 +3963,8 @@ fix = {
     files     = sys/dir.h;
     files     = sys/param.h;
     files     = sys/types.h;
     files     = sys/dir.h;
     files     = sys/param.h;
     files     = sys/types.h;
+    /* avoid changing C++ friendly NULL */
+    bypass    = __cplusplus;
     select    = "^#[ \t]*define[ \t]+NULL[ \t]+\\(\\(void[ \t]*\\*\\)0\\)";
     c_fix     = format;
     c_fix_arg = "#define NULL 0";
     select    = "^#[ \t]*define[ \t]+NULL[ \t]+\\(\\(void[ \t]*\\*\\)0\\)";
     c_fix     = format;
     c_fix_arg = "#define NULL 0";