summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2011-11-09 10:33:22 +0800
committerPeng Wu <alexepico@gmail.com>2011-11-09 10:33:22 +0800
commit4fbe19e5eaeb4d1bdb509daafeedbf923438b1b7 (patch)
tree9a7e81b11b467a05c95e2df9a388f49deba3171c /scripts
parentc389ac98652ac83bb3bbc16368fee799df3aef29 (diff)
downloadlibpinyin-4fbe19e5eaeb4d1bdb509daafeedbf923438b1b7.tar.gz
libpinyin-4fbe19e5eaeb4d1bdb509daafeedbf923438b1b7.tar.xz
libpinyin-4fbe19e5eaeb4d1bdb509daafeedbf923438b1b7.zip
fixes pinyin parser table compile
Diffstat (limited to 'scripts')
-rw-r--r--scripts/pinyin_parser_table.h.in4
-rw-r--r--scripts/pinyintable.py2
2 files changed, 5 insertions, 1 deletions
diff --git a/scripts/pinyin_parser_table.h.in b/scripts/pinyin_parser_table.h.in
index efd27cd..ae8093d 100644
--- a/scripts/pinyin_parser_table.h.in
+++ b/scripts/pinyin_parser_table.h.in
@@ -4,6 +4,8 @@
#ifndef PINYIN_PARSER_TABLE_H
#define PINYIN_PARSER_TABLE_H
+namespace pinyin{
+
const pinyin_index_item_t pinyin_index[] = {
@PINYIN_INDEX@
};
@@ -24,4 +26,6 @@ const resplit_table_item_t resplit_table[] = {
@RESPLIT_TABLE@
};
+};
+
#endif
diff --git a/scripts/pinyintable.py b/scripts/pinyintable.py
index 603159e..a825fea 100644
--- a/scripts/pinyintable.py
+++ b/scripts/pinyintable.py
@@ -117,7 +117,7 @@ def get_shengmu_chewing(shengmu):
initial = chewing_key
else:
initial = 'PINYIN_{0}'.format(shengmu.upper())
- return initial, "CHEWING_ZREO_MIDDLE", "CHEWING_ZERO_FINAL"
+ return initial, "CHEWING_ZERO_MIDDLE", "CHEWING_ZERO_FINAL"
def gen_shengmu():
#generate all shengmu