[armedbear-devel] tentative patch: extensible sequences (following the same protocol as SBCL)

Tobias C. Rittweiler tcr at freebits.de
Tue Mar 2 10:27:55 UTC 2010


Alessio Stalla <alessiostalla at gmail.com>
writes:

> Greetings everyone,
>
> I'm happy to announce that I have a preliminary version of
> user-extensible sequences working on ABCL, following the protocol
> proposed and implemented by Christophe Rhodes on SBCL
> ("User-extensible sequences in Common Lisp",
> http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.65.1604&rep=rep1&type=pdf).
> This includes:
>
> - the possibility for the user to write subclasses of CL:SEQUENCE
> - all functions operating on sequences have a corresponding generic
> function in the SEQUENCE package that is called on user-defined
> sequence types, and for which the user can write methods to implement
> his/her custom sequences
> - make-sequence works with user-defined sequences (using
> sequence:make-sequence-like as in SBCL)
> - mop::class-prototype has been added (as a tiny wrapper around
> mop::allocate-instance)
> - iterating over user-defined sequences integrated with LOOP
> (untested, but should work as our loop implementation is derived from
> CMUCL like SBCL's)
> - MAP and MAP-INTO should work unchanged
>
> limitations/things missing wrt. SBCL (that I know of):
>
> - no integration with DOSEQUENCE

I have spent some time on thinking about a good middle layer on top of
sequences and what I came up with so far is at

  http://common-lisp.net/project/sequence-iterators/

It's supposed to hook into extensible sequences where available though I
haven't come around of doing so for sbcl.

So if you're looking for a mid layer, I think cloning those interfaces
might make sense.

  -T.





More information about the armedbear-devel mailing list