OSDN Git Service

* ggc-simple.c (offsetof): Macro definition moved from here ...
authorphdm <phdm@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 12 May 2000 17:07:03 +0000 (17:07 +0000)
committerphdm <phdm@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 12 May 2000 17:07:03 +0000 (17:07 +0000)
* system.h (offsetof): ... to here.

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

gcc/ChangeLog
gcc/ggc-simple.c
gcc/system.h

index bf19c44..1e338ee 100644 (file)
@@ -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.
index b7b6a66..e4fbddb 100644 (file)
 #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.  */
index 89d389c..86ea5ba 100644 (file)
@@ -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.