Author: kjs
Date: Sat Dec 27 13:04:45 2008
New Revision: 34445

Modified:
   trunk/compilers/pirc/new/pircompunit.h
   trunk/compilers/pirc/new/piremit.c
   trunk/compilers/pirc/new/pirsymbol.c

Log:
[pirc] no need to store the constant table index in the constant node; it was 
already handled automatically by existing code.

Modified: trunk/compilers/pirc/new/pircompunit.h
==============================================================================
--- trunk/compilers/pirc/new/pircompunit.h      (original)
+++ trunk/compilers/pirc/new/pircompunit.h      Sat Dec 27 13:04:45 2008
@@ -144,7 +144,11 @@
     char const      *name;     /* name of the constant, if declared as a 
constant */
     pir_type         type;     /* type of the constant */
     value            val;      /* value of the constant */
+
+    /* XXX this needed? think not. --kjs 12/27/2008.
     int              const_table_index;
+    */
+
     struct constant *next;
 
 } constant;

Modified: trunk/compilers/pirc/new/piremit.c
==============================================================================
--- trunk/compilers/pirc/new/piremit.c  (original)
+++ trunk/compilers/pirc/new/piremit.c  Sat Dec 27 13:04:45 2008
@@ -416,7 +416,7 @@
 emit_pbc_const(lexer_state * const lexer, constant * const pirconst) {
     switch (pirconst->type) {
         case INT_TYPE:
-            /* XXX ? */
+
             break;
         case NUM_TYPE:
             return add_num_const(lexer->bc, pirconst->val.nval);
@@ -425,7 +425,7 @@
             return add_string_const(lexer->bc, pirconst->val.sval);
 
         case PMC_TYPE:
-            /* XXX ? */
+
             break;
     }
 }

Modified: trunk/compilers/pirc/new/pirsymbol.c
==============================================================================
--- trunk/compilers/pirc/new/pirsymbol.c        (original)
+++ trunk/compilers/pirc/new/pirsymbol.c        Sat Dec 27 13:04:45 2008
@@ -582,7 +582,9 @@
     store_bucket(table, b, hash);
 
     /* add it as a constant in the PBC constant table */
+    /* XXX is this necessary? Seems not. 12/27/2008. --kjs
     c->const_table_index = emit_pbc_const(lexer, c);
+    */
 }
 
 /*

Reply via email to