aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTrevor Saunders <tsaunders@mozilla.com>2014-10-04 13:29:26 +0000
committerTrevor Saunders <tbsaunde@gcc.gnu.org>2014-10-04 13:29:26 +0000
commitbf55b4a0ef1bc41c43e9916ed6ac261b142b5cf8 (patch)
tree6d05f9c2925919286a79aef6047062c1ddef52f2
parent63a496dedb96263534f3eb152d66d59e8f08b125 (diff)
downloadgcc-bf55b4a0ef1bc41c43e9916ed6ac261b142b5cf8.zip
gcc-bf55b4a0ef1bc41c43e9916ed6ac261b142b5cf8.tar.gz
gcc-bf55b4a0ef1bc41c43e9916ed6ac261b142b5cf8.tar.bz2
Fix dupplicate declaration of ggc_realloc in gencondmd
If vec.h is included before ggc.h it forward declares ggc_realloc with defaulted arguments. This means ggc.h can not be included later because it would lead to a second declaration of ggc_realloc with defaulted arguments. In generator programs vec.h can not include ggc.h because it may not exist yet. So generator programs must make sure they include ggc.h before anything that includes vec.h. gcc/ChangeLog: 2014-10-04 Trevor Saunders <tsaunders@mozilla.com> PR pch/63429 * genconditions.c: Directly include ggc.h before rtl.h. From-SVN: r215888
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/genconditions.c1
2 files changed, 6 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 9437414..fc20023 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2014-10-04 Trevor Saunders <tsaunders@mozilla.com>
+
+ PR pch/63429
+ * genconditions.c: Directly include ggc.h before rtl.h.
+
2014-10-03 Jan Hubicka <hubicka@ucw.cz>
* ipa-polymorphic-call.c
diff --git a/gcc/genconditions.c b/gcc/genconditions.c
index 8390797..048a992 100644
--- a/gcc/genconditions.c
+++ b/gcc/genconditions.c
@@ -70,6 +70,7 @@ write_header (void)
#include \"coretypes.h\"\n\
#include \"tm.h\"\n\
#include \"insn-constants.h\"\n\
+#include \"ggc.h\"\n\
#include \"rtl.h\"\n\
#include \"tm_p.h\"\n\
#include \"function.h\"\n\