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

adjustable arrays

    To give another data point to the discussion: in our lisp (Extended
Common Lisp) we have a variety of internal array implementations to
satisify the various combinations of array features the user might
select.   I expect most other implemenations do likewise.   Many of
these internal implementations are adjustable however our lisp will
refuse to adjust any array not explictly specified as adjustable by
the user.   Since we're going to extra work to refuse to do something
that we could easily do, there should be a good reason for it, and 
in our case that reason is portabilty.  If a user wants needs an adjustable
array and doesn't specify it, then he'll find out right away instead
of when he ports his code to another lisp.   

    I don't feel that returning a adjustable array when the user
doesn't ask for one 'is an error'.  When you call 'make-array' you ask
for the minimum set of features you need and the system returns
the best thing it can.   Implementations should be encouraged to return
the best match to the user's request, thus if the user doesn't ask for
an adjustable array, then returning an non-adjustable array is better
than returning an adjustable one, but both are valid.


- John Foderaro
  Franz Inc.