# ifdef HAVE_UNISTD_H
# include <unistd.h>
# endif /* HAVE_UNISTD_H */
+# ifdef HAVE_STDINT_H
+# include <stdint.h>
+# endif
+# ifdef HAVE_INTTYPES_H
+# include <inttypes.h>
+# endif
#endif /* HAVE_AST */
#ifdef DEBUG
#ifdef offsetof
#undef offsetof
#endif
+#ifdef HAVE_INTPTR_T
+#define offsetof(typ,fld) ((intptr_t)(&(((typ*)0)->fld)))
+#else
#define offsetof(typ,fld) ((int)(&(((typ*)0)->fld)))
+#endif
#define NOTUSED(var) (void) var
#define NILgraph NIL(Agraph_t*)
static void freesym(Dict_t * d, Void_t * obj, Dtdisc_t * disc);
Dtdisc_t AgDataDictDisc = {
- (int) offsetof(Agsym_t, name), /* use symbol name as key */
+ offsetof(Agsym_t, name), /* use symbol name as key */
-1,
- (int) offsetof(Agsym_t, link),
+ offsetof(Agsym_t, link),
NIL(Dtmake_f),
freesym,
NIL(Dtcompar_f),