aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe De Muyter <phdm@macqel.be>2000-05-12 19:07:03 +0200
committerPhilippe De Muyter <phdm@gcc.gnu.org>2000-05-12 17:07:03 +0000
commitc0dbdfbbb30a9d60df636582724f0737cd906aa3 (patch)
tree1a717beae0227f632b4cb3b6671bb714610b3690
parent67384dfba3f4dec04aea2ca1195786c1f1575320 (diff)
downloadgcc-c0dbdfbbb30a9d60df636582724f0737cd906aa3.zip
gcc-c0dbdfbbb30a9d60df636582724f0737cd906aa3.tar.gz
gcc-c0dbdfbbb30a9d60df636582724f0737cd906aa3.tar.bz2
ggc-simple.c (offsetof): Macro definition moved from here ...
* ggc-simple.c (offsetof): Macro definition moved from here ... * system.h (offsetof): ... to here. From-SVN: r33879
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/ggc-simple.c4
-rw-r--r--gcc/system.h4
3 files changed, 9 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index bf19c44..1e338ee 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+Fri May 12 19:03:58 2000 Philippe De Muyter <phdm@macqel.be>
+
+ * ggc-simple.c (offsetof): Macro fallback definition moved from here ..
+ * system.h (offsetof): ... to here.
+
2000-05-12 Richard Henderson <rth@cygnus.com>
* Makefile.in (final.o): Depend on BASIC_BLOCK_H.
diff --git a/gcc/ggc-simple.c b/gcc/ggc-simple.c
index b7b6a66..e4fbddb 100644
--- a/gcc/ggc-simple.c
+++ b/gcc/ggc-simple.c
@@ -28,10 +28,6 @@
#include "ggc.h"
#include "timevar.h"
-#ifndef offsetof
-#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
-#endif
-
/* Debugging flags. */
/* Zap memory before freeing to catch dangling pointers. */
diff --git a/gcc/system.h b/gcc/system.h
index 89d389c..86ea5ba 100644
--- a/gcc/system.h
+++ b/gcc/system.h
@@ -50,6 +50,10 @@ Boston, MA 02111-1307, USA. */
#define NULL 0
#endif
+#ifndef offsetof
+#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
+#endif
+
/* The compiler is not a multi-threaded application and therefore we
do not have to use the locking functions.