Fix variable type
Change-Id: Ifbee00119ff9801d480ca97bf2aedbb25be25bf4
diff --git a/native/jni/src/bigram_dictionary.cpp b/native/jni/src/bigram_dictionary.cpp
index 3eea51a..dade4f1 100644
--- a/native/jni/src/bigram_dictionary.cpp
+++ b/native/jni/src/bigram_dictionary.cpp
@@ -113,7 +113,7 @@
}
// If still no bigrams, we really don't have them!
if (0 == pos) return 0;
- int bigramFlags;
+ uint8_t bigramFlags;
int bigramCount = 0;
do {
bigramFlags = BinaryFormat::getFlagsAndForwardPointer(root, &pos);
@@ -153,7 +153,7 @@
forceLowerCaseSearch);
if (NOT_VALID_WORD == pos) return 0;
- const int flags = BinaryFormat::getFlagsAndForwardPointer(root, &pos);
+ const uint8_t flags = BinaryFormat::getFlagsAndForwardPointer(root, &pos);
if (0 == (flags & BinaryFormat::FLAG_HAS_BIGRAMS)) return 0;
if (0 == (flags & BinaryFormat::FLAG_HAS_MULTIPLE_CHARS)) {
BinaryFormat::getCodePointAndForwardPointer(root, &pos);
@@ -179,7 +179,7 @@
}
if (0 == pos) return;
- int bigramFlags;
+ uint8_t bigramFlags;
do {
bigramFlags = BinaryFormat::getFlagsAndForwardPointer(root, &pos);
const int frequency = BinaryFormat::MASK_ATTRIBUTE_FREQUENCY & bigramFlags;
@@ -215,7 +215,7 @@
int nextWordPos = BinaryFormat::getTerminalPosition(root, word2, length2,
false /* forceLowerCaseSearch */);
if (NOT_VALID_WORD == nextWordPos) return false;
- int bigramFlags;
+ uint8_t bigramFlags;
do {
bigramFlags = BinaryFormat::getFlagsAndForwardPointer(root, &pos);
const int bigramPos = BinaryFormat::getAttributeAddressAndForwardPointer(root, bigramFlags,