pgsql: Teach regular expression operators to honor collations.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Teach regular expression operators to honor collations.
Date: 2011-04-10 22:03:42
Message-ID: E1Q92jO-0003FR-BL@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Teach regular expression operators to honor collations.

This involves getting the character classification and case-folding
functions in the regex library to use the collations infrastructure.
Most of this work had been done already in connection with the upper/lower
and LIKE logic, so it was a simple matter of transposition.

While at it, split out these functions into a separate source file
regc_pg_locale.c, so that they can be correctly labeled with the Postgres
project's license rather than the Scriptics license. These functions are
100% Postgres-written code whereas what remains in regc_locale.c is still
mostly not ours, so lumping them both under the same copyright notice was
getting more and more misleading.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/1e16a8107db9a50435b39e09c6f9c52c45e63e1a

Modified Files
--------------
doc/src/sgml/charset.sgml | 33 +-
src/backend/libpq/hba.c | 3 +-
src/backend/regex/Makefile | 3 +-
src/backend/regex/regc_locale.c | 165 ------
src/backend/regex/regc_pg_locale.c | 649 ++++++++++++++++++++++
src/backend/regex/regcomp.c | 12 +-
src/backend/regex/regexec.c | 3 +
src/backend/tsearch/spell.c | 5 +-
src/backend/utils/adt/regexp.c | 42 ++-
src/include/regex/regex.h | 4 +-
src/test/regress/expected/collate.linux.utf8.out | 74 +++
src/test/regress/sql/collate.linux.utf8.sql | 18 +
12 files changed, 819 insertions(+), 192 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2011-04-10 22:07:35 Re: pgsql: Adjust regression tests on cube and ECPG for MinGW 64 bit compil
Previous Message Andrew Dunstan 2011-04-10 21:06:03 pgsql: Adjust regression tests on cube and ECPG for MinGW 64 bit compil