Hi Jeremie,

Jeremie Courreges-Anglas wrote on Thu, Jun 03, 2021 at 11:17:08PM +0200:
> On Wed, Jun 02 2021, Ingo Schwarze <[email protected]> wrote:

>> I'm also adding a few comments as suggested by jca@.  Parsing of UTF-8
>> is less trivial than one might think, witnessed once again by the fact
>> that i got this code wrong in the first place.

> Thanks for this, though I was mostly interested into a pointer to the
> relevant standard document that was used.

Standards tend to be huge, the manual page is very compact, contains
all the relevant information and already points to the standard for
more details.  So i considered refering to the manual more helpful.

If you see a way to improve the STANDARDS section in the manual page,
you are very welcome.

> Now that the checks match the
> Unicode standard, I'm less confused.  You're now pointing readers to the
> utf8(7) manpage.  Discussion for another diff: should this manpage list
> valid sequences instead of invalid ones?

The idea is that it does both: first it show valid sequences (in the
first table).  Then it explains the constraints, and which bytes are
consequently valid, in the following text.

Finally, it turns the matter around and summarizes by also listing
invalid start bytes and invalid initial pairs.

Showing invalid rather than valid bytes and pairs in the final two
tables seems a good choice to me because there are much fewer invalid
than valid start bytes and initial pairs.

Does that make sense to you, or can you propose a specific diff to
improve the page?

> ok jca@

Thanks for checking the ksh/emacs.c diff and sorry for the ridiculous
delay, it is now finally committed.

Yours,
  Ingo

Reply via email to