Subject: bug#56323: 29.0.50; [v2] Add new customisable phonetic Tamil input method

From: Visuwesh <[email-masked]>
Date: Sat, 02 Jul 2022 15:03:42 +0530

[சனி ஜூலை 02, 2022] Eli Zaretskii wrote:

>> From: Visuwesh <[email-masked]>
>> Cc: [email-masked]
>> Date: Sat, 02 Jul 2022 14:10:07 +0530
>> 
>> > The only remaining issue, AFAIU, is why string-lessp is not good
>> > enough for sorting within each sub-list.
>> 
>> It is not good enough for each sub-list for the same reason: the order
>> produced by string-lessp is not the same as the actual order.
>
> So, then please explain what should be the "correct" order within each
> sub-list.  Is the correct order within each sub-list in the ascending
> order of the codepoint?  If not, what is the correct order?
>

The correct order is not the ascending order of the codepoint, the
correct order is

க ங ச ஞ ட ண த ந ப ம ய ர ல வ ழ ள ற ன

and their respective codepoints are

2965 2969 2970 2974 2975 2979 2980 2984 2986 2990 2991 2992 2994 2997 2996 2995 2993 2985

>> I will try to explain the situation using the regular English alphabets
>> and the extra letter þ (which was used in place of "th" AFAIU).
>> 
>> The core English alphabets are a-z then we have some extra alphabets
>> like the þ above.  When we have a list containing _both_ a-z and þ, the
>> order produced by string-lessp is wrong.
>> 
>> When I did as you suggested and broke the list into two -- a-z and þ --
>> and sorted the sub-list that only contained a-z with string-lessp, the
>> sorted sub-list was not in the right alphabetical order i.e., instead of
>> "a b c d ..." it was "a c b d ..."
>
> That's not what I see:
>
>   (let ((letters '("a" "b" "r" "x" "z")))
>     (sort letters 'string-lessp))
>    => ("a" "b" "r" "x" "z")
>
> Please show an example where characters a-z are sorted by string-lessp
> in the wrong order.

I didn't mean literally that string-lessp produced the wrong list for
a-z, I tried to draw an analogy with a hypothetical scenario where a-z
sorting did not work with string-lessp.  This hypothetical scenario is
the actual in case of the Tamil consonants.