Use offsetof instead of __builtin_offsetof, for icc's sake. Proposed by

* glib/gmacros.h (G_STRUCT_OFFSETOF): Use offsetof instead of
        __builtin_offsetof, for icc's sake. Proposed by Hrvoje Niksic.



svn path=/trunk/; revision=7811
This commit is contained in:
Matthias Clasen 2009-01-18 01:03:00 +00:00
parent 3e9aa9229e
commit ed6c7f0e32
2 changed files with 8 additions and 1 deletions

View File

@ -1,3 +1,10 @@
2009-01-17 Matthias Clasen <mclasen@redhat.com>
Bug 567838 G_STRUCT_OFFSETOF fails to compile under icc 9.1
* glib/gmacros.h (G_STRUCT_OFFSETOF): Use offsetof instead of
__builtin_offsetof, for icc's sake. Proposed by Hrvoje Niksic.
2009-01-13 Matthias Clasen <mclasen@redhat.com>
Bug 564728 Add function to decode base64 encoded data in place

View File

@ -216,7 +216,7 @@
#if defined(__GNUC__) && __GNUC__ >= 4
# define G_STRUCT_OFFSET(struct_type, member) \
((glong) __builtin_offsetof (struct_type, member))
((glong) offsetof (struct_type, member))
#else
# define G_STRUCT_OFFSET(struct_type, member) \
((glong) ((guint8*) &((struct_type*) 0)->member))