http://codereview.chromium.org/115252/diff/1014/10
File src/globals.h (right):

http://codereview.chromium.org/115252/diff/1014/10#newcode92
Line 92: // Fix for Mac OS X defining uintptr_t as "unsigned long":
On 2009/05/13 16:40:59, Dean McNamee wrote:
> I would probably structure this as an if/else with the defines above
(so you
> don't have to undef), and I wouldn't say Fix, just say that OS X
defines it as
> unsigned long.

I sort of like your offline suggestion better about reusing the standard
definitions of PRI[x|d]PTR  from inttypes.h in the definition of
V8PRI[x|d]PTR. Unfortunately we are using V8PRIdPTR to print pointer
differences (32-bit type int) and not pointers (32-bit type long int)
which is what PRIdPTR expects on Mac OS X. So that solution would also
need an exception.

I am standing by "Fix" for the description. Also in my opinion it is
more readable this way because it clearly marks it as an exception
instead of being buried in a series of nested #if.

P.S. We should all be happy that intptr_t is not any longer typedef'd to
"int*" as it used to in early versions of Mac OS X...

http://codereview.chromium.org/115252

--~--~---------~--~----~------------~-------~--~----~
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to