19 Jul
2003
19 Jul
'03
4:15 p.m.
On Sat, 19 Jul 2003, Vincent Béron wrote: : That's an easy one. One an Alpha, sizeof(int) != sizeof(foo *). I think : sizeof(int) == 8, while sizeof(foo *) == 4. Other way round. sizeof(int) == 4; sizeof(void *) == 8. : gcc is kind enough to warn you about this potentially nasty situation, : although in these particular cases I don't see how putting the pointer : in something larger will create a problem. Use intptr_t. If that's not available (via autoconf test), typedef intptr_t to be "unsigned long" locally, as "long" is the size of a pointer on all typical ILP32 and LP64 hosts. -- -- Todd Vierling <tv(a)pobox.com>