Control ctype behavior internally with a method table.
authorJeff Davis <jdavis@postgresql.org>
Tue, 1 Jul 2025 14:42:39 +0000 (07:42 -0700)
committerJeff Davis <jdavis@postgresql.org>
Tue, 1 Jul 2025 14:44:47 +0000 (07:44 -0700)
commit5a38104b364234615c780656a8b2424f96ed9efa
tree3bdd0dc7532db1cfa646d5397b2bf095ef3d9e98
parentd81dcc8d6243054e3bde40c6fb2b2a0be4b19da6
Control ctype behavior internally with a method table.

Previously, pattern matching and case mapping behavior branched based
on the provider. Refactor to use a method table, which is less
error-prone.

This is also a step toward multiple provider versions, which we may
want to support in the future.

Reviewed-by: Andreas Karlsson <andreas@proxel.se>
Reviewed-by: Peter Eisentraut <peter@eisentraut.org>
Discussion: http://postgr.es/m/2830211e1b6e6a2e26d845780b03e125281ea17b.camel%40j-davis.com
src/backend/regex/regc_pg_locale.c
src/backend/utils/adt/like.c
src/backend/utils/adt/like_support.c
src/backend/utils/adt/pg_locale.c
src/backend/utils/adt/pg_locale_builtin.c
src/backend/utils/adt/pg_locale_icu.c
src/backend/utils/adt/pg_locale_libc.c
src/include/utils/pg_locale.h
src/tools/pgindent/typedefs.list