Re: [HACKERS] Extra Vietnamese unaccent rules - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] Extra Vietnamese unaccent rules
Date
Msg-id 27527.1502917297@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] Extra Vietnamese unaccent rules  (Dang Minh Huong <kakalot49@gmail.com>)
Responses Re: [HACKERS] Extra Vietnamese unaccent rules  (Michael Paquier <michael.paquier@gmail.com>)
List pgsql-hackers
Dang Minh Huong <kakalot49@gmail.com> writes:
> On 2017/07/05 15:28, Michael Paquier wrote:
>> (Surprised to see that generate_unaccent_rules.py is inconsistent on
>> MacOS, runs fine on Linux).

FWIW, I got identical results from running the script on current macOS
(Sierra) and Linux (RHEL6).

>> Testing with characters having two accents, the results are produced
>> as wanted. I am attaching an updated patch with all those
>> simplifications. Thoughts?

> Thanks, so pretty. The patch is fine to me.

Pushed into v11.  I'm not really qualified to review the Python coding
style, but I did fix a typo in a comment.

BTW, while this isn't a reason to delay this patch, I wonder whether
the regression test for unaccent is really adequate.  According to
https://coverage.postgresql.org/contrib/unaccent/unaccent.c.gcov.html
it isn't doing anything to check multicharacter source strings, and
what's considerably more disturbing, it isn't exercising the PG_CATCH
code that's meant to deal with characters outside the current database's
encoding.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: [HACKERS] Function to move the position of a replication slot
Next
From: Tom Lane
Date:
Subject: Re: [HACKERS] Function to move the position of a replication slot