From eedae34d203bc1a07a1d09f7876661649538462a Mon Sep 17 00:00:00 2001 From: Peng Wu Date: Tue, 28 Jun 2016 10:47:54 +0800 Subject: fixes compile --- src/storage/pinyin_phrase3.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/storage') diff --git a/src/storage/pinyin_phrase3.h b/src/storage/pinyin_phrase3.h index 76e8a04..19d56d8 100644 --- a/src/storage/pinyin_phrase3.h +++ b/src/storage/pinyin_phrase3.h @@ -22,9 +22,9 @@ #ifndef PINYIN_PHRASE3_H #define PINYIN_PHRASE3_H +#include #include "novel_types.h" #include "chewing_key.h" -#include /* All compare function should be symmetric for the lhs and rhs operands. URL: http://en.cppreference.com/w/cpp/algorithm/equal_range . */ @@ -172,8 +172,10 @@ inline void compute_incomplete_chewing_index(const ChewingKey * in_keys, ChewingKey * out_keys, int phrase_length) { for (int i = 0; i < phrase_length; ++i) { - ChewingKey key; - key.m_initial = in_keys[i].m_initial; + ChewingKey key = in_keys[i]; + key.m_middle = CHEWING_ZERO_MIDDLE; + key.m_final = CHEWING_ZERO_FINAL; + key.m_tone = CHEWING_ZERO_TONE; out_keys[i] = key; } } -- cgit