Interesting. Thanks for the explanation; that was bugging me.
On Thu, May 3, 2018 at 3:37 PM, Shu-Hung You
wrote:
> Looks like the implementation of char-utf-8-length returns values
> fitting the "FSS-UTF (1992) / UTF-8 (1993)" table in
>
Looks like the implementation of char-utf-8-length returns values
fitting the "FSS-UTF (1992) / UTF-8 (1993)" table in
https://en.wikipedia.org/wiki/UTF-8#History. Not sure what's the
standard UTF-8 encoding..
/* racket/src/char.c */
static Scheme_Object *char_utf8_length (int argc, Scheme_Object
I noticed this in the docs and it surprised me:
(char-utf-8-length char) → (integer-in 1 6)
UTF-8 characters are 1-4 bytes, so why isn't it (integer-in 1 4)? I
feel like this is probably obvious but I'm not coming up with the
answer.
--
You received this message because you are subscribed to
3 matches
Mail list logo