On Fri, Nov 27, 2009 at 09:04:27AM -0600, Peter Karman wrote: > Not sure that this merits a JIRA ticket, but this little patch quiets a gcc > warning:
> #elif (SIZEOF_PTR == 8) > - size_t address = self; > + size_t address = (size_t)self; Hmm, is that 100% right? The existing code is definitely wrong and needs fixing, but I can never remember all the ways that pointer-to-integer and integer-to-pointer conversion can go screwy. There are some really weird truncation effects on some systems. Probably what we ought to do is rely on macros *every* time we need to convert between integers and pointers. The conversion macros would be implemented in Charmonizer and would get thorough testing. There's already a PTR2I64 macro in Charmonizer/Probe/Integers, but we probably need a larger menu: PTR2I64 PTR2U64 PTR2I32 PTR2U32 PTR2SIZET Marvin Humphrey
