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

Issue: ARRAY-TYPE-ELEMENT-TYPE-SEMANTICS (Version 9)



re: The benefit of UPGRADE-ARRAY-ELEMENT-TYPE--namely, that it doesn't
    CONS as much as the portable definition--seems very small and I don't think
    it outweighs the cost.

No, Larry, the issue isn't that it "doesn't CONS as much", but that it
"doesn't CONS *at all*".  This kind of issue is critical to some vendors,
such as Inference (which is why Joe Ginder was worrying about the
implicit consing in &rest args and in the sequence functions.)

See CLtL, p292, definition of ARRAY-DIMENSION.  Applying the reasoning
that I am now trying to rebut, you would wind up with:

   (defun array-dimension (array axis-number)
     (elt (array-dimensions array) axis-number))

Why do you suppose that CLtL included ARRAY-DIMENSION in the standard?
How about ARRAY-TOTAL-SIZE? and ARRAY-ROW-MAJOR-INDEX?


-- JonL --