[svn:parrot] r44268 - trunk/src/pmc

chromatic at svn.parrot.org chromatic at svn.parrot.org
Sun Feb 21 04:06:27 UTC 2010


Author: chromatic
Date: Sun Feb 21 04:06:26 2010
New Revision: 44268
URL: https://trac.parrot.org/parrot/changeset/44268

Log:
[PMC] Added a cast to get_integer_keyed_int() in Opcode PMC to avoid signedness
comparison compiler warning.

Modified:
   trunk/src/pmc/opcode.pmc

Modified: trunk/src/pmc/opcode.pmc
==============================================================================
--- trunk/src/pmc/opcode.pmc	Sun Feb 21 04:06:12 2010	(r44267)
+++ trunk/src/pmc/opcode.pmc	Sun Feb 21 04:06:26 2010	(r44268)
@@ -90,10 +90,9 @@
 
     VTABLE INTVAL get_integer_keyed_int(INTVAL i) {
         Parrot_Opcode_attributes * const attrs = PARROT_OPCODE(SELF);
-        INTVAL type = i < attrs->info->op_count - 1 ?
-            attrs->info->types[i] :
-            -1;
-        return type;
+        return i < attrs->info->op_count - 1
+               ? (INTVAL)attrs->info->types[i]
+               : -1;
     }
 }
 


More information about the parrot-commits mailing list