diff options
author | Thomas Munro <tmunro@postgresql.org> | 2023-07-09 11:55:03 +1200 |
---|---|---|
committer | Thomas Munro <tmunro@postgresql.org> | 2023-07-09 11:55:18 +1200 |
commit | 8d9a9f034e925568342c7ccfd8d351a3cd20e7f3 (patch) | |
tree | 83a10a9ce2044e613c66dc8cd5275840f9629ced /src/backend/utils/adt/like_support.c | |
parent | e9f15bc9db7564a29460d089c0917590bc13fffc (diff) | |
download | postgresql-8d9a9f034e925568342c7ccfd8d351a3cd20e7f3.tar.gz postgresql-8d9a9f034e925568342c7ccfd8d351a3cd20e7f3.zip |
All supported systems have locale_t.
locale_t is defined by POSIX.1-2008 and SUSv4, and available on all
targeted systems. For Windows, win32_port.h redirects to a partial
implementation called _locale_t. We can now remove a lot of
compile-time tests for HAVE_LOCALE_T, and associated comments and dead
code branches that were needed for older computers.
Since configure + MinGW builds didn't detect locale_t but now we assume
that all systems have it, further inconsistencies among the 3 Windows build
systems were revealed. With this commit, we no longer define
HAVE_WCSTOMBS_L and HAVE_MBSTOWCS_L on any Windows build system, but
we have logic to deal with that so that replacements are available where
appropriate.
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Tristan Partin <tristan@neon.tech>
Reviewed-by: Peter Eisentraut <peter@eisentraut.org>
Discussion: https://postgr.es/m/CA%2BhUKGLg7_T2GKwZFAkEf0V7vbnur-NfCjZPKZb%3DZfAXSV1ORw%40mail.gmail.com
Diffstat (limited to 'src/backend/utils/adt/like_support.c')
-rw-r--r-- | src/backend/utils/adt/like_support.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/src/backend/utils/adt/like_support.c b/src/backend/utils/adt/like_support.c index 9b603d42f3d..34e1b709ae9 100644 --- a/src/backend/utils/adt/like_support.c +++ b/src/backend/utils/adt/like_support.c @@ -1509,10 +1509,8 @@ pattern_char_isalpha(char c, bool is_multibyte, else if (locale && locale->provider == COLLPROVIDER_ICU) return IS_HIGHBIT_SET(c) || (c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z'); -#ifdef HAVE_LOCALE_T else if (locale && locale->provider == COLLPROVIDER_LIBC) return isalpha_l((unsigned char) c, locale->info.lt); -#endif else return isalpha((unsigned char) c); } |