[EMAIL PROTECTED] (Steven M. Schweda) writes: > #define PTR_FORMAT(p) 2 * sizeof (void *), (unsigned long) (p) > > No bets, but you might try something like: > > #define PTR_FORMAT(p) ((int)(2 * sizeof (void *))), (unsigned long) (p)
You are right; I'll make this change, thanks. > Note that, as portable code goes, this isn't very. Assuming that an > "unsigned long" is the same size (or at least as large) as a pointer is > an invitation to trouble. The code only uses that for printing the pointer's value (only used for debugging), and even so it carefully casts the pointer to unsigned long, to avoid a mismatch between pointer size and %lx. > (And using format "lx" as the nearby comment suggests is also likely > to cause trouble when this coincidence fails.) The only trouble will be misprinted pointers.
