[svn:parrot] r40104 - trunk/include/parrot

NotFound at svn.parrot.org NotFound at svn.parrot.org
Wed Jul 15 13:55:50 UTC 2009


Author: NotFound
Date: Wed Jul 15 13:55:49 2009
New Revision: 40104
URL: https://trac.parrot.org/parrot/changeset/40104

Log:
[cage] add parens to U?INTVAL2PTR macros to prevent precedence problems in corner cases

Modified:
   trunk/include/parrot/parrot.h

Modified: trunk/include/parrot/parrot.h
==============================================================================
--- trunk/include/parrot/parrot.h	Wed Jul 15 13:49:57 2009	(r40103)
+++ trunk/include/parrot/parrot.h	Wed Jul 15 13:55:49 2009	(r40104)
@@ -1,5 +1,5 @@
 /* parrot.h
- *  Copyright (C) 2001-2008, Parrot Foundation.
+ *  Copyright (C) 2001-2009, Parrot Foundation.
  *  SVN Info
  *     $Id$
  *  Overview:
@@ -136,8 +136,8 @@
     A. D. Aug. 6, 2002.
 */
 #if PTR_SIZE == INTVAL_SIZE
-#  define INTVAL2PTR(any, d)    (any)(d)
-#  define UINTVAL2PTR(any, d)    (any)(d)
+#  define INTVAL2PTR(any, d)    ((any)(d))
+#  define UINTVAL2PTR(any, d)    ((any)(d))
 #else
 #  if PTR_SIZE == LONG_SIZE
 #    define INTVAL2PTR(any, d)    ((any)(unsigned long)(d))


More information about the parrot-commits mailing list