1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-04 20:11:56 +03:00

Remove lc_collate_is_c().

Instead just look up the collation and check collate_is_c field.

Author: Andreas Karlsson
Discussion: https://postgr.es/m/60929555-4709-40a7-b136-bcb44cff5a3c@proxel.se
This commit is contained in:
Jeff Davis
2024-09-04 12:30:14 -07:00
parent 83eb481d52
commit 06421b0843
8 changed files with 35 additions and 73 deletions

View File

@@ -4646,6 +4646,7 @@ static char *
convert_string_datum(Datum value, Oid typid, Oid collid, bool *failure)
{
char *val;
pg_locale_t mylocale;
switch (typid)
{
@@ -4671,9 +4672,10 @@ convert_string_datum(Datum value, Oid typid, Oid collid, bool *failure)
return NULL;
}
if (!lc_collate_is_c(collid))
mylocale = pg_newlocale_from_collation(collid);
if (!mylocale->collate_is_c)
{
pg_locale_t mylocale = pg_newlocale_from_collation(collid);
char *xfrmstr;
size_t xfrmlen;
size_t xfrmlen2 PG_USED_FOR_ASSERTS_ONLY;