Changes between Version 5 and Version 6 of TablesCowan


Ignore:
Timestamp:
08/27/10 12:50:41 (7 years ago)
Author:
cowan
Comment:

Proofreading

Legend:

Unmodified
Added
Removed
Modified
  • TablesCowan

    v5 v6  
    2828Creates a new table and populates it with the associations based on the successive ''key'' and ''value'' arguments.  The implementation may take the arguments into account in deciding what kind of table to create, but should not assume that no other types of keys or values will ever exist.   (Not in SRFI-69) 
    2929 
    30 `(list->table` `''alist'' . `''args''`)` 
     30`(alist->table `''alist''` . `''args''`)` 
    3131 
    3232Creates a new table as if by invoking `(make-table . `''args''`)` which maps the car of every element in ''alist'' to the cdr of the same element.  If some key occurs multiple times in alist, the value in the first association will take precedence over later ones.  (SRFI-69 `alist->hash-table`) 
     
    6060Returns a list of the keys in ''table''. The order of the keys is unspecified.  (SRFI-69 `hash-table-keys`) 
    6161 
    62 `(table-values`''table''`)` 
     62`(table-values `''table''`)` 
    6363 
    6464Returns a list of the values in ''table''. The order of the keys is unspecified, and may be inconsistent with the results of `table-keys`.  (SRFI-69 `hash-table-values`) 
     
    8888== Iterators == 
    8989 
    90 `(table-map `''table''` `''procedure'' . `''args''`)` 
     90`(table-map `''table''` `''procedure''` . `''args''`)` 
    9191 
    92 Returns a new table as if by invoking `(make-table . `''args''`).  The new table is the result of mapping ''procedure'', which takes two arguments, over ''table''.  It is applied to the key and value of each association in ''table'', and returns two values, the key and value to be placed in the new table.  f the table is mutated while `table-map` is running, the behavior is unpredictable.  (Not in SRFI-69) 
     92Returns a new table as if by invoking `(make-table . `''args''`)`.  The new table is the result of mapping ''procedure'', which takes two arguments, over ''table''.  It is applied to the key and value of each association in ''table'', and returns two values, the key and value to be placed in the new table.  If the table is mutated while `table-map` is running, the behavior is unpredictable.  (Not in SRFI-69) 
    9393 
    9494`(table-for-each `''table''` `''procedure''`)` 
     
    9696The same as `table-map`, except that no new table is constructed; returns undefined values.  If the table is mutated while `table-for-each` is running, the behavior is unpredictable.  (SRFI-69 `hash-table-walk`) 
    9797 
    98 `(table->list `''table''`)` 
     98`(table->alist `''table''`)` 
    9999 
    100 Returns an association list such that the car of each element is a key in ''table'' and the corresponding cdr of is the value associated to the key.  The order of the elements is unspecified.  (SRFI-69 `hash-table->alist`) 
     100Returns an association list such that the car of each element is a key in ''table'' and the corresponding cdr of the element is the value associated to the key.  The order of the elements is unspecified.  (SRFI-69 `hash-table->alist`) 
     101