Ah, ok, I started understanding the trade-off.   Let me reiterate,
though this has been obvious to those who understood the issue from the beginning...

(1) We want an efficient way to specify character position in a string. (cursor).
(2) In some implementations it can be as lightweight as fixnum.
(3) Because of 2, we can't simply extend srfi-13 to take cursors as start/end arguments.
(4) So either we need to duplicate most of srfi-13 procedures as string-something/cursor,
or to introduce a new abstraction (span) that embeds a range in a string and duplicate
most of srfi-13 procedures as span-something.
(5) The latter can also eliminate optional argument handling.

If I have to choose from the above options in (4),
I'd still prefer having more procedures on a same kind of objects (string-something/cursor)
rather than having another kind of objects (span) with mostly the same set of procedures.

But fundamentally, I feel both ways are net loss; any addition of string operations
would require addition of their counterpart (or the consistency would somewhat be lost);
it includes any future string-related srfi, and any implementation-specific string operation
extensions.

I'll ponder this more.



On Sun, Dec 6, 2015 at 2:01 PM, John Cowan <xxxxxx@mercury.ccil.org> wrote:
Shiro Kawai scripsit:

> We can't immediately drop string-set!, but we can say mutating a string
> may invalidate certain structures derived from it (e.g. cursors), or,
> "it is an error to mutate a string after it is passed to certain APIs".

That's okay as far as it goes, but we'd also need to say that mutating
a string destroys the integrity of any substrings, unless we are going
to require copy-on-write.  That's way beyond what can be implemented
portably.

> Note that the same loose restrictions are already there, e.g. it would be
> undefined to mutate a string which is used as a key of hash tables.

It might mess up the hash table (and indeed SRFIs 69, 125, and 126 all
tell you that you can't do that), but not the string itself.

--
John Cowan          http://www.ccil.org/~cowan        xxxxxx@ccil.org
To say that Bilbo's breath was taken away is no description at all.  There are
no words left to express his staggerment, since Men changed the language that
they learned of elves in the days when all the world was wonderful. --The Hobbit