Re: [whatwg/encoding] index-jis0208.txt should be JIS X 0208 and add another index file (#47)

> So, for example, the index pointer for code point 0x2170 is 8634, not 10716. Then the EUC-JP encoder will set 'lead = 252' and 'trail = 241'.

Ah, in fact that happens to be true for all indices >= 8836. Sorry, that wasn't obvious to me. So, there is no bug.

How about adding a comment/note in EUC-JP decoder, step 7: "Note: If pointer is non-null, it is necessarily < 8836, due to the nature of the table."

Likewise in ISO-2022-JP encoder, step 9: "Note: If pointer is non-null, it is necessarily < 8836, due to the nature of the table."

Such comments would translate into an assertion when implementors translate the algorithm into a particular implementation language.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/encoding/issues/47#issuecomment-251343454

Received on Tuesday, 4 October 2016 09:47:56 UTC