[Freeciv-Dev] Re: PATCH: gint/gpointer casting in GTK+ client
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Mon, 8 Oct 2001, Raimar Falke wrote:
> P.S.: How is GINT_TO_POINTER and GPOINTER_TO_INT defined on a alpha?
On an Intel:-
#define GPOINTER_TO_INT(p) ((gint) (p))
#define GINT_TO_POINTER(i) ((gpointer) (i))
On an Alpha:-
#define GPOINTER_TO_INT(p) ((gint) (glong) (p))
#define GINT_TO_POINTER(i) ((gpointer) (glong) (i))
So... it's still not exactly "pretty", but it does at least make
the code a little more portable, and more robust should the GLib/GTK+ guys
change their underlying types.
Ben
--
ben@xxxxxxxxxxxxxxxxxxxxxx http://bellatrix.pcl.ox.ac.uk/~ben/
"He [Professor Moriarty] is the Napoleon of crime."
- 'The Final Problem', Sir Arthur Conan Doyle
|
|