diff options
Diffstat (limited to 'src/storage/chewing_large_table2.h')
-rw-r--r-- | src/storage/chewing_large_table2.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/storage/chewing_large_table2.h b/src/storage/chewing_large_table2.h index 0aaddd1..52c5983 100644 --- a/src/storage/chewing_large_table2.h +++ b/src/storage/chewing_large_table2.h @@ -106,7 +106,11 @@ public: int search(/* in */ const ChewingKey keys[], /* out */ PhraseIndexRanges ranges) const { IndexItem item; - compute_chewing_index(keys, item.m_keys, phrase_length); + if (contains_incomplete_pinyin(keys, phrase_length)) { + compute_incomplete_chewing_index(keys, item.m_keys, phrase_length); + } else { + compute_chewing_index(keys, item.m_keys, phrase_length); + } const IndexItem * begin = (IndexItem *) m_chunk.begin(); const IndexItem * end = (IndexItem *) m_chunk.end(); |