Re: various comments Jussi Piitulainen (17 Nov 2001 14:03 UTC)
Re: various comments Radey Shouman (17 Nov 2001 18:27 UTC)
Re: various comments Jussi Piitulainen (18 Nov 2001 14:50 UTC)
Re: various comments Per Bothner (19 Nov 2001 19:52 UTC)
Re: various comments Jussi Piitulainen (20 Nov 2001 08:14 UTC)
Re: various comments Per Bothner (20 Nov 2001 18:35 UTC)
Re: various comments Jussi Piitulainen (20 Nov 2001 19:20 UTC)
Re: various comments Per Bothner (20 Nov 2001 19:33 UTC)
Re: various comments Jussi Piitulainen (20 Nov 2001 20:14 UTC)
Re: various comments Radey Shouman (21 Nov 2001 03:31 UTC)
Re: various comments Radey Shouman (19 Nov 2001 23:26 UTC)
Re: various comments Jussi Piitulainen (20 Nov 2001 08:43 UTC)
Re: various comments Per Bothner (20 Nov 2001 19:20 UTC)
Re: various comments Jussi Piitulainen (20 Nov 2001 20:02 UTC)
Re: various comments Per Bothner (20 Nov 2001 21:08 UTC)
Re: various comments Radey Shouman (21 Nov 2001 03:58 UTC)
Re: various comments Jussi Piitulainen (21 Nov 2001 16:52 UTC)
Re: various comments Radey Shouman (21 Nov 2001 03:47 UTC)
Vectors as arrays Re: various comments Jussi Piitulainen (20 Nov 2001 18:03 UTC)
Re: Vectors as arrays Re: various comments Radey Shouman (21 Nov 2001 04:09 UTC)

Re: various comments Per Bothner 19 Nov 2001 19:51 UTC

Jussi Piitulainen wrote:

>If both (vector? arr) and (array? arr) yield #t, then (vector-ref arr
>k) must do what (array-ref arr k) does, and so on. To implement that,
>one should first have disjoint types, (r5rs-vector? o) and (array? o),
>and then make (vector? o) be their sum (or (r5rs-vector? o) (array?
>o)), and (vector-ref o k) would dispatch to one of (r5rs-vector-ref o
>k) or (array-ref o k).
>
Not sure what you mean, but it sounds wrong.  Instead we should follow
logic and Common Lisp (or at least let implementations have that option):
(vector? obj) should imply (array? obj).  The reverse would be true if you
take the view that arrays are nested vectors, but that runs into problems in
de-generative cases of a 0-rank array.  It also is difficult to
distinguish a
0*M array from a 0*N array since you can't really distinguish a 0-length
vector each of whose non-existent elements is an M-length vectors from a
0-length vector of N-length vectors.  That is  unless you can associate
"types"
with empty vectors.  Some APL dialects to that, and it gets a little
strange.

    --Per Bothner