[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
collection classes
- To: info-dylan@cambridge.apple.com
- Subject: collection classes
- From: Jonathan Bachrach <Jonathan.Bachrach@ircam.fr>
- Date: Fri, 4 Dec 1992 18:12:25 +0100
I've implemented the collection classes and have the following wish list:
NEW <SEQUENCE> GENERIC-FUNCTION'S
 The following function seems indispensible to me:
 (define-generic-function position (sequence element #key test count))
 I suggest adding the following function to the offered set functions:
 (define-generic-function difference (sequence1 sequence2 #key test)) 
 The following insertion function's are very useful for many sequences classes
 (like gap-list's).  It is difficult to write many of the sequence methods 
 because `add' does not specify where the new-element is inserted.
 (define-generic-function insert (sequence new-element insertion-position))
 (define-generic-function insert! (mutable-sequence new-element insertion-position))
 (define-generic-function insert-sequence 
     (sequence insertion-sequence insertion-position))
 (define-generic-function insert-sequence!
     (mutable-sequence insertion-sequence insertion-position))
DESTRUCTIVE <MUTABLE-SEQUENCE> FUNCTIONS
  It seems crucial to be able to destructively concatenate sequences:
  (define-generic-function concatenate! (mutable-sequence #rest rest-sequences))
  I would also like to see the following destructively functions added:
  (define-generic-function choose! (predicate mutable-sequence))
  (define-generic-function choose-by! (predicate test-sequence mutable-value-sequence))
NEW SETTER
  There seems no reason to me why a setter was not provided for `last':
  (define-generic-function (setter last) (new-value mutable-sequence)) 
NEW INIT-KEYWORD FOR <TABLE>
  I would like to see <table> take `test:' as an init-keyword:
  (make <table> #key (test =))
-- jonathan bachrach
IRCAM
31, rue Saint-Merri
F75004 Paris, France
011-33-1-42772492
bachrach@ircam.fr