[EMAIL PROTECTED] scripsit:

> Are you suggesting that indexes represent code points rather than code 
> units? 

That is what R5.92RS prescribes, and I think appropriately.

> Have you? And do you think UTF-8/UTF-16 implementations should be
> *required* to do that?

If they claim to implement R6RS, then yes.  But there is no requirement
that R6RS implementations use UTF-8 or UTF-16 internally.

> (Obviously, then, string-length would have to return the number of
> code points rather than the number of code units.)

Just so.

> Note: Perhaps a solution is to have two variants of the procs, one for 
> code points and one for code units. The code units variants would 
> guarantee O(1) and the code point ones wouldn't.

In R5.92RS, Scheme characters are codepoints (or more precisely scalar
values), not code units.

-- 
John Cowan  [EMAIL PROTECTED]  http://www.ccil.org/~cowan
Thor Heyerdahl recounts his attempt to prove Rudyard Kipling's theory
that the mongoose first came to India on a raft from Polynesia.
        --blurb for Rikki-Kon-Tiki-Tavi

_______________________________________________
r6rs-discuss mailing list
[email protected]
http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss

Reply via email to