feat: updated engine version to 4.4-rc1
This commit is contained in:
parent
ee00efde1f
commit
21ba8e33af
5459 changed files with 1128836 additions and 198305 deletions
|
|
@ -47,13 +47,13 @@ int32_t UCharsDictionaryMatcher::matches(UText *text, int32_t maxLength, int32_t
|
|||
int32_t *prefix) const {
|
||||
|
||||
UCharsTrie uct(characters);
|
||||
int32_t startingTextIndex = (int32_t)utext_getNativeIndex(text);
|
||||
int32_t startingTextIndex = static_cast<int32_t>(utext_getNativeIndex(text));
|
||||
int32_t wordCount = 0;
|
||||
int32_t codePointsMatched = 0;
|
||||
|
||||
for (UChar32 c = utext_next32(text); c >= 0; c=utext_next32(text)) {
|
||||
UStringTrieResult result = (codePointsMatched == 0) ? uct.first(c) : uct.next(c);
|
||||
int32_t lengthMatched = (int32_t)utext_getNativeIndex(text) - startingTextIndex;
|
||||
int32_t lengthMatched = static_cast<int32_t>(utext_getNativeIndex(text)) - startingTextIndex;
|
||||
codePointsMatched += 1;
|
||||
if (USTRINGTRIE_HAS_VALUE(result)) {
|
||||
if (wordCount < limit) {
|
||||
|
|
@ -101,7 +101,7 @@ UChar32 BytesDictionaryMatcher::transform(UChar32 c) const {
|
|||
if (delta < 0 || 0xFD < delta) {
|
||||
return U_SENTINEL;
|
||||
}
|
||||
return (UChar32)delta;
|
||||
return static_cast<UChar32>(delta);
|
||||
}
|
||||
return c;
|
||||
}
|
||||
|
|
@ -114,13 +114,13 @@ int32_t BytesDictionaryMatcher::matches(UText *text, int32_t maxLength, int32_t
|
|||
int32_t *lengths, int32_t *cpLengths, int32_t *values,
|
||||
int32_t *prefix) const {
|
||||
BytesTrie bt(characters);
|
||||
int32_t startingTextIndex = (int32_t)utext_getNativeIndex(text);
|
||||
int32_t startingTextIndex = static_cast<int32_t>(utext_getNativeIndex(text));
|
||||
int32_t wordCount = 0;
|
||||
int32_t codePointsMatched = 0;
|
||||
|
||||
for (UChar32 c = utext_next32(text); c >= 0; c=utext_next32(text)) {
|
||||
UStringTrieResult result = (codePointsMatched == 0) ? bt.first(transform(c)) : bt.next(transform(c));
|
||||
int32_t lengthMatched = (int32_t)utext_getNativeIndex(text) - startingTextIndex;
|
||||
int32_t lengthMatched = static_cast<int32_t>(utext_getNativeIndex(text)) - startingTextIndex;
|
||||
codePointsMatched += 1;
|
||||
if (USTRINGTRIE_HAS_VALUE(result)) {
|
||||
if (wordCount < limit) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue