Update the stdlib to use Unicode 15 data

This commit is contained in:
Alejandro Alonso
2023-03-29 10:18:16 -07:00
parent e78cf220c5
commit f16f0c3c23
59 changed files with 224760 additions and 48866 deletions

View File

@@ -24,7 +24,7 @@ __swift_uint8_t _swift_stdlib_getWordBreakProperty(__swift_uint32_t scalar) {
swift::swift_abortDisabledUnicodeSupport();
#else
auto low = 0;
auto high = 1086 - 1;
auto high = WORD_BREAK_DATA_COUNT - 1;
while (high >= low) {
auto idx = low + (high - low) / 2;
@@ -52,8 +52,8 @@ __swift_uint8_t _swift_stdlib_getWordBreakProperty(__swift_uint32_t scalar) {
}
}
// If we made it out here, then our scalar was not found in the grapheme
// array (this occurs when a scalar doesn't map to any grapheme break
// If we made it out here, then our scalar was not found in the word
// array (this occurs when a scalar doesn't map to any word break
// property). Return the max value here to indicate .any.
return std::numeric_limits<__swift_uint8_t>::max();
#endif