aboutsummaryrefslogtreecommitdiff
path: root/src/common/unicode_category.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/unicode_category.c')
-rw-r--r--src/common/unicode_category.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/common/unicode_category.c b/src/common/unicode_category.c
index cec9c0d998f..189cd6eca3c 100644
--- a/src/common/unicode_category.c
+++ b/src/common/unicode_category.c
@@ -28,8 +28,7 @@ unicode_category(pg_wchar ucs)
int mid;
int max = lengthof(unicode_categories) - 1;
- Assert(ucs >= unicode_categories[0].first &&
- ucs <= unicode_categories[max].last);
+ Assert(ucs <= 0x10ffff);
while (max >= min)
{
@@ -42,8 +41,7 @@ unicode_category(pg_wchar ucs)
return unicode_categories[mid].category;
}
- Assert(false);
- return (pg_unicode_category) - 1;
+ return PG_U_UNASSIGNED;
}
/*