diff options
| author | Jeff Davis | 2024-03-07 19:15:06 +0000 |
|---|---|---|
| committer | Jeff Davis | 2024-03-07 19:15:06 +0000 |
| commit | 5c40364dd6d9c6a260c8965dffe2e066642d6f79 (patch) | |
| tree | 229ba6adf17935fe7f54f6cca3c3856267302d15 /src/common/wchar.c | |
| parent | 6d470211e54f7a617783b99b27c9d8056a890a57 (diff) | |
Unicode case mapping tables and functions.
Implements Unicode simple case mapping, in which all code points map
to exactly one other code point unconditionally.
These tables are generated from UnicodeData.txt, which is already
being used by other infrastructure in src/common/unicode. The tables
are checked into the source tree, so they only need to be regenerated
when we update the Unicode version.
In preparation for the builtin collation provider, and possibly useful
for other callers.
Discussion: https://postgr.es/m/ff4c2f2f9c8fc7ca27c1c24ae37ecaeaeaff6b53.camel%40j-davis.com
Reviewed-by: Peter Eisentraut, Daniel Verite, Jeremy Schneider
Diffstat (limited to 'src/common/wchar.c')
| -rw-r--r-- | src/common/wchar.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/wchar.c b/src/common/wchar.c index 7e7a7507d5c..a238c0106c6 100644 --- a/src/common/wchar.c +++ b/src/common/wchar.c @@ -477,8 +477,8 @@ pg_utf2wchar_with_len(const unsigned char *from, pg_wchar *to, int len) /* - * Map a Unicode code point to UTF-8. utf8string must have 4 bytes of - * space allocated. + * Map a Unicode code point to UTF-8. utf8string must have at least + * unicode_utf8len(c) bytes available. */ unsigned char * unicode_to_utf8(pg_wchar c, unsigned char *utf8string) |
