Marc Nieper-Wißkirchen scripsit:
> As an analogue, consider `#(1 2)' and `(vector 1 2)'. The literal is
> immutable, the vector returned by the procedure application is
> mutable. However, there is no predicate distinguishing between the
> two cases.
That's because implementations are not required to make a distinction
between the two, and some do not. Chicken and Chibi, for example, have
only mutable versions of either strings or vectors. *Users* must make
the distinction in portable code, but that's a different matter.
As far as I can tell, implementations like Chibi, where the internal
representation is UTF-8 and no mutable/immutable distinction is
made, can't implement SRFI 140 without changing that, because SRFI
140 guarantees that string operations on literal strings are O(1).
That seems to me to be a high barrier to the adoption of SRFI 140,
and the chief reason why SRFI 140 is not just a blanket rename of
SRFI 135.
--
John Cowan http://www.ccil.org/~cowan xxxxxx@ccil.org
MEET US AT POINT ORANGE AT MIDNIGHT BRING YOUR DUCK OR PREPARE TO FACE WUGGUMS