[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Ongoing work, maps and dictionaries

In discussions just before and during the Scheme Workshop, Anton raised 
the idea of separating the m:1 and m:n (single vs multivalue) 
dictionaries into two types.  This makes a tremendous amount of sense.  
The current draft has this change, with a Map type for 
single-key->single-value collections, and a Dictionary subtype for 
single-key->multiple-value collections.

While correcting this, I made an attempt to rename the bulk operators to 
be more consistent and less confusing.  The current thought is:

*-{operator} - ordinary single instance call
*-{operator}-all - multiple value call 
*-{operator}-from - call requiring another collection as a source
*-{operator}-all-from - multivalue version of above.

For example, dict-delete (deletes one key/value mapping), 
dict-delete-all (deletes all mappings from a key), dict-delete-from 
(deletes one key/value mapping for all keys in a source bag), and 
dict-delete-all-from (deletes all key/value mappings for each key in the 
source bag).

You can view the work-in-progress at sgmiller.org/code/srfi-44.html.  
The concrete collection specification still needs to be updated to match 


Attachment: pgpvXKhCApPOb.pgp
Description: PGP signature