summaryrefslogtreecommitdiffstats
path: root/src/storage/phonetic_key_matrix.cpp
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2016-05-19 16:15:02 +0800
committerPeng Wu <alexepico@gmail.com>2016-05-19 16:15:02 +0800
commita3d54898d4a86260bcd242bc68f361e7de614a36 (patch)
treea11634ccb9066e05f02867b61cf8ab7e457d4cb5 /src/storage/phonetic_key_matrix.cpp
parente3fd3425a8402752f8b3bbef8bf1784e970a8712 (diff)
downloadlibpinyin-a3d54898d4a86260bcd242bc68f361e7de614a36.tar.gz
libpinyin-a3d54898d4a86260bcd242bc68f361e7de614a36.tar.xz
libpinyin-a3d54898d4a86260bcd242bc68f361e7de614a36.zip
update get_items method
Diffstat (limited to 'src/storage/phonetic_key_matrix.cpp')
-rw-r--r--src/storage/phonetic_key_matrix.cpp5
1 files changed, 0 insertions, 5 deletions
diff --git a/src/storage/phonetic_key_matrix.cpp b/src/storage/phonetic_key_matrix.cpp
index 150ba5d..61554fb 100644
--- a/src/storage/phonetic_key_matrix.cpp
+++ b/src/storage/phonetic_key_matrix.cpp
@@ -83,7 +83,6 @@ bool fuzzy_syllable_step(pinyin_option_t options,
for (size_t index = 0; index < length; ++index) {
/* for pinyin initials. */
matrix->get_items(index, keys, key_rests);
- assert(keys->len == key_rests->len);
if (0 == keys->len)
continue;
@@ -125,7 +124,6 @@ bool fuzzy_syllable_step(pinyin_option_t options,
/* for pinyin finals. */
matrix->get_items(index, keys, key_rests);
- assert(keys->len == key_rests->len);
assert(0 != keys->len);
for (i = 0; i < keys->len; ++i) {
@@ -170,7 +168,6 @@ bool dump_phonetic_key_matrix(PhoneticKeyMatrix * matrix) {
for (size_t index = 0; index < length; ++index) {
matrix->get_items(index, keys, key_rests);
- assert(keys->len == key_rests->len);
if (0 == keys->len)
continue;
@@ -218,7 +215,6 @@ int search_matrix_recur(GArray * cached_keys,
GArray * key_rests = g_array_new(TRUE, TRUE, sizeof(ChewingKeyRest));
matrix->get_items(start, keys, key_rests);
- assert(keys->len == key_rests->len);
/* assume pinyin parsers will filter invalid keys. */
assert(0 != keys->len);
@@ -254,7 +250,6 @@ int search_matrix(FacadeChewingTable2 * table,
GArray * key_rests = g_array_new(TRUE, TRUE, sizeof(ChewingKeyRest));
matrix->get_items(start, keys, key_rests);
- assert(keys->len == key_rests->len);
const size_t len = keys->len;
g_array_free(keys, TRUE);