cvsuser     01/12/11 18:12:15

  Modified:    include/parrot key.h
  Log:
  key.c - Removed a few functions, generalized set_element_value and element_value
          to accept KEY_PAIRs from core.ops
  include/parrot/key.h - Modified header.
  core.ops - Modified to accept the new return style.
  
  This is a prelude to adding virtual-table methods to allow hashing &c. Expect at
  least one or two more redesigns before this settles down. However, it still
  passes the original tests.
  
  Revision  Changes    Path
  1.2       +7 -7      parrot/include/parrot/key.h
  
  Index: key.h
  ===================================================================
  RCS file: /cvs/public/parrot/include/parrot/key.h,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -w -r1.1 -r1.2
  --- key.h     11 Dec 2001 04:05:45 -0000      1.1
  +++ key.h     12 Dec 2001 02:12:15 -0000      1.2
  @@ -1,7 +1,7 @@
   /* key.h
    *  Copyright: (When this is determined...it will go here)
    *  CVS Info
  - *     $Id: key.h,v 1.1 2001/12/11 04:05:45 jgoff Exp $
  + *     $Id: key.h,v 1.2 2001/12/12 02:12:15 jgoff Exp $
    *  Overview:
    *     This is the api header for the pmc subsystem
    *  Data Structure and Algorithms:
  @@ -17,6 +17,7 @@
     enum_key_int,
     enum_key_num,
     enum_key_string,
  +  enum_key_pmc,
     enum_key_max
   } KEY_TYPE;
   
  @@ -26,6 +27,7 @@
       INTVAL int_val;
       FLOATVAL num_val;
       STRING* struct_val;
  +    PMC* pmc_val;
     } cache;
   };
   
  @@ -44,12 +46,10 @@
   INTVAL key_size(struct Parrot_Interp *interpreter, KEY *key);
   void key_set_size(struct Parrot_Interp *interpreter, KEY *key, INTVAL size);
   void key_destroy(struct Parrot_Interp *interpreter, KEY *key);
  -INTVAL   key_element_value_i(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index);
  -FLOATVAL key_element_value_n(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index);
  -STRING*  key_element_value_s(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index);
  -void key_set_element_value_i(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index, INTVAL value);
  -void key_set_element_value_n(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index, FLOATVAL value);
  -void key_set_element_value_s(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index, STRING* value);
  +KEY_PAIR* key_element_value_i(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index);
  +KEY_PAIR* key_element_value_s(struct Parrot_Interp *interpreter, KEY *key, STRING* 
index);
  +void key_set_element_value_i(struct Parrot_Interp *interpreter, KEY *key, INTVAL 
index, KEY_PAIR* value);
  +void key_set_element_value_s(struct Parrot_Interp *interpreter, KEY *key, STRING* 
index, KEY_PAIR* value);
   void key_chop(struct Parrot_Interp *interpreter, KEY *key);
   void key_inc(struct Parrot_Interp *interpreter, KEY *key, INTVAL index);
   
  
  
  


Reply via email to