(bc_emit_bytecode): Cast enum array indices to int.
authorRichard Kenner <kenner@gcc.gnu.org>
Mon, 4 Oct 1993 22:01:55 +0000 (18:01 -0400)
committerRichard Kenner <kenner@gcc.gnu.org>
Mon, 4 Oct 1993 22:01:55 +0000 (18:01 -0400)
From-SVN: r5593

gcc/bc-emit.c

index 5071cf4e940a1ab7cbeae4af10e40a58ebf72359..b5d038c14e09bb9d121187821fbbff49701f187c 100644 (file)
@@ -866,7 +866,7 @@ bc_emit_bytecode (bytecode)
      enum bytecode_opcode bytecode;
 {
   char byte;
-  int npushes = arityvec[bytecode].noutputs - arityvec[bytecode].ninputs;
+  int npushes = arityvec[(int) bytecode].noutputs - arityvec[(int) bytecode].ninputs;
   static int prev_lineno = -1;
 
   byte = bytecode;
@@ -889,9 +889,9 @@ bc_emit_bytecode (bytecode)
 
   bc_emit_bytecode_const (&byte, 1);
 
-  if ((stack_depth -= arityvec[bytecode].ninputs) >= 0)
+  if ((stack_depth -= arityvec[(int) bytecode].ninputs) >= 0)
     {
-      if ((stack_depth += arityvec[bytecode].noutputs) > max_stack_depth)
+      if ((stack_depth += arityvec[(int) bytecode].noutputs) > max_stack_depth)
        max_stack_depth = stack_depth;
     }