<div dir="ltr"><div class="gmail_default" style="font-family:arial,sans-serif">Exactly the way we did it in Plan 9, and published in the paper cited earlier. In fact, it's possible the library work was done as early as 1989, but I'm not sure. Certainly by 1990.</div><div class="gmail_default" style="font-family:arial,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,sans-serif">-rob</div><div class="gmail_default" style="font-family:arial,sans-serif"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Mar 20, 2023 at 6:55 PM <<a href="mailto:arnold@skeeve.com">arnold@skeeve.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Rob.<br>
<br>
Rob Pike <<a href="mailto:robpike@gmail.com" target="_blank">robpike@gmail.com</a>> wrote:<br>
<br>
> (Speaking of design by committee, the multibyte stuff in C89 was atrocious,<br>
> and I heard was done in committee to get someone, perhaps the Japanese, to<br>
> sign off.)<br>
<br>
It's not lovely, but I wouldn't call it atrocious. It gets the job<br>
done; code using it can handle multibyte encodings while being totally<br>
character-set agnostic.  I speak from experience, gawk does this.<br>
(I use the "restartable" routins - mbrlen() and so on.)<br>
<br>
I understand that Unicode + UTF-8 solve the issue completely. But I'd<br>
like to ask, in all seriousness and so that I can learn, given the world<br>
as it was in 1989, how would you solve the problem? If you had designed<br>
the C level routines, what would they have looked like?<br>
<br>
Thanks,<br>
<br>
Arnold<br>
</blockquote></div>