Merge lp:~cosmos-door/ubuntu/utopic/libkkc/fix-1374949 into lp:ubuntu/utopic/libkkc
- Utopic (14.10)
- fix-1374949
- Merge into utopic
Proposed by
Mitsuya Shibata
Status: | Rejected | ||||
---|---|---|---|---|---|
Rejected by: | Daniel Holbach | ||||
Proposed branch: | lp:~cosmos-door/ubuntu/utopic/libkkc/fix-1374949 | ||||
Merge into: | lp:ubuntu/utopic/libkkc | ||||
Diff against target: |
38502 lines (+13373/-11917) 163 files modified
ChangeLog (+220/-0) Makefile.am (+2/-2) Makefile.in (+2/-2) README (+2/-2) aclocal.m4 (+98/-98) configure (+22/-22) configure.ac (+5/-5) data/Makefile.am (+2/-2) data/Makefile.in (+2/-2) data/rules/Makefile.am (+2/-2) data/rules/Makefile.in (+2/-2) data/rules/README.rules (+2/-2) data/rules/default/rom-kana/default.json (+5/-0) data/templates/Makefile.am (+2/-2) data/templates/Makefile.in (+2/-2) data/templates/libkkc-data/Makefile.am (+2/-2) data/templates/libkkc-data/configure.ac.in (+2/-2) data/templates/libkkc-data/data/Makefile.am (+2/-2) data/templates/libkkc-data/data/models/Makefile.sorted2 (+2/-2) data/templates/libkkc-data/data/models/Makefile.sorted3 (+2/-2) data/templates/libkkc-data/tools/Makefile.am (+2/-2) data/templates/libkkc-data/tools/genfilter.py (+2/-2) data/templates/libkkc-data/tools/sortlm.py (+2/-2) debian/changelog (+7/-0) debian/control (+3/-2) docs/Makefile.am (+1/-1) docs/Makefile.in (+1/-1) libkkc/Kkc-1.0.gir (+2/-2) libkkc/Makefile.am (+3/-3) libkkc/Makefile.in (+3/-3) libkkc/bigram-decoder.c (+962/-1005) libkkc/bigram-decoder.vala (+9/-13) libkkc/bloom-filter.c (+36/-34) libkkc/bloom-filter.vala (+2/-2) libkkc/candidate-list.c (+198/-208) libkkc/candidate-list.vala (+3/-3) libkkc/candidate.c (+4/-6) libkkc/candidate.vala (+2/-2) libkkc/context.c (+11/-13) libkkc/context.vala (+2/-2) libkkc/convert-segment-state-handler.c (+39/-41) libkkc/convert-segment-state-handler.vala (+2/-2) libkkc/convert-sentence-state-handler.c (+77/-87) libkkc/convert-sentence-state-handler.vala (+2/-2) libkkc/decoder.c (+5/-5) libkkc/decoder.vala (+2/-2) libkkc/dictionary-list.c (+23/-27) libkkc/dictionary-list.vala (+2/-2) libkkc/dictionary.c (+405/-161) libkkc/dictionary.vala (+2/-2) libkkc/encoding.c (+74/-55) libkkc/encoding.vala (+2/-2) libkkc/expression.c (+262/-278) libkkc/expression.vala (+3/-3) libkkc/initial-state-handler.c (+546/-574) libkkc/initial-state-handler.vala (+2/-2) libkkc/key-event-filter.c (+21/-23) libkkc/key-event-filter.vala (+2/-2) libkkc/key-event.c (+688/-458) libkkc/key-event.vala (+2/-2) libkkc/keymap.c (+136/-154) libkkc/keymap.vala (+15/-21) libkkc/keysyms.c (+3/-3) libkkc/keysyms.vala (+2/-2) libkkc/kkc-1.0.deps (+1/-2) libkkc/kkc-1.0.pc.in (+3/-3) libkkc/kkc-1.0.vapi (+1/-1) libkkc/kkc-internals-1.0.vapi (+1/-1) libkkc/kkc.c (+3/-3) libkkc/kkc.vala (+2/-2) libkkc/language-model-utils.c (+3/-3) libkkc/language-model-utils.vala (+2/-2) libkkc/language-model.c (+30/-18) libkkc/language-model.vala (+2/-2) libkkc/libkkc-internals.h (+1/-1) libkkc/libkkc.h (+1/-1) libkkc/map-file.c (+34/-38) libkkc/map-file.vala (+3/-3) libkkc/metadata-file.c (+7/-7) libkkc/metadata-file.vala (+2/-2) libkkc/nicola.c (+306/-325) libkkc/nicola.vala (+4/-4) libkkc/numeric-template.c (+202/-204) libkkc/numeric-template.vala (+2/-2) libkkc/rom-kana-utils.c (+482/-260) libkkc/rom-kana-utils.vala (+2/-2) libkkc/rom-kana.c (+731/-677) libkkc/rom-kana.vala (+13/-5) libkkc/rule.c (+386/-416) libkkc/rule.vala (+21/-25) libkkc/segment-dictionary.c (+3/-3) libkkc/segment-dictionary.vala (+2/-2) libkkc/segment-list.c (+5/-5) libkkc/segment-list.vala (+2/-2) libkkc/segment.c (+3/-3) libkkc/segment.vala (+2/-2) libkkc/sentence-dictionary.c (+3/-3) libkkc/sentence-dictionary.vala (+2/-2) libkkc/sorted-bigram-language-model.c (+191/-173) libkkc/sorted-bigram-language-model.vala (+2/-2) libkkc/sorted-trigram-language-model.c (+126/-118) libkkc/sorted-trigram-language-model.vala (+2/-2) libkkc/state.c (+1548/-1368) libkkc/state.vala (+3/-3) libkkc/system-segment-dictionary.c (+426/-423) libkkc/system-segment-dictionary.vala (+2/-2) libkkc/template.c (+23/-27) libkkc/template.vala (+2/-2) libkkc/text-bigram-language-model.c (+409/-421) libkkc/text-bigram-language-model.vala (+2/-2) libkkc/text-trigram-language-model.c (+4/-4) libkkc/text-trigram-language-model.vala (+2/-2) libkkc/trellis-node.c (+10/-9) libkkc/trellis-node.vala (+2/-2) libkkc/trigram-decoder.c (+357/-378) libkkc/trigram-decoder.vala (+4/-5) libkkc/user-dictionary.c (+31/-22) libkkc/user-dictionary.vala (+2/-2) libkkc/user-rule.c (+95/-97) libkkc/user-segment-dictionary.c (+214/-177) libkkc/user-segment-dictionary.vala (+4/-4) libkkc/user-sentence-dictionary.c (+688/-415) libkkc/user-sentence-dictionary.vala (+4/-4) libkkc/utils.c (+226/-246) libkkc/utils.vala (+2/-2) m4/libtool.m4 (+2/-2) marisa-glib/Makefile.am (+2/-2) marisa-glib/Makefile.in (+2/-2) po/ja.po (+87/-67) tests/Makefile.am (+2/-2) tests/Makefile.in (+123/-123) tests/candidate-list.c (+6/-5) tests/candidate.c (+5/-4) tests/context.c (+986/-924) tests/conversions-initial.json (+3/-1) tests/decoder.c (+16/-15) tests/dictionary-list.c (+103/-98) tests/encoding.c (+27/-19) tests/expression.c (+5/-4) tests/key-event.c (+19/-18) tests/keymap.c (+75/-77) tests/language-model.c (+13/-12) tests/lib/kkc-test.vapi (+1/-1) tests/lib/libkkc-test.h (+1/-1) tests/lib/test-case.c (+59/-60) tests/lib/test-utils.c (+157/-138) tests/lib/test-utils.vala (+3/-0) tests/metadata-file.c (+29/-21) tests/rom-kana.c (+10/-9) tests/rule.c (+13/-12) tests/segment-list.c (+5/-4) tests/segment.c (+5/-4) tests/state.c (+6/-5) tests/system-dictionary.c (+65/-57) tests/template.c (+5/-4) tests/trellis-node.c (+6/-5) tests/user-dictionary.c (+503/-480) tests/user-rule.c (+104/-94) tools/Makefile.am (+2/-2) tools/Makefile.in (+2/-2) tools/kkc-package-data.in (+2/-2) tools/kkc.c (+317/-325) tools/kkc.vala (+2/-2) |
||||
To merge this branch: | bzr merge lp:~cosmos-door/ubuntu/utopic/libkkc/fix-1374949 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Mitsuya Shibata (community) | Disapprove | ||
Ubuntu Development Team | Pending | ||
Review via email: mp+236732@code.launchpad.net |
Commit message
Description of the change
* New upsteam release
* Change Build-Depends from libgee-dev to libgee-0.8-dev
To post a comment you must log in.
Revision history for this message
Mitsuya Shibata (cosmos-door) : | # |
review:
Disapprove
Unmerged revisions
- 5. By Mitsuya Shibata
-
Change Build-Depends from libgee-dev to libgee-0.8-dev (LP: #1374949)
- 4. By Mitsuya Shibata
-
Import upstream version 0.3.4
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'ChangeLog' | |||
2 | --- ChangeLog 2014-06-15 23:27:57 +0000 | |||
3 | +++ ChangeLog 2014-10-01 15:12:30 +0000 | |||
4 | @@ -1,3 +1,223 @@ | |||
5 | 1 | commit 4ffd6c8331d4575678aca7cad7c5e839d7dbd736 | ||
6 | 2 | Author: Daiki Ueno <ueno@unixuser.org> | ||
7 | 3 | Date: Mon Jul 7 13:09:45 2014 +0900 | ||
8 | 4 | |||
9 | 5 | Revert "build: Switch from intltool to gettext" | ||
10 | 6 | |||
11 | 7 | This reverts commit 25e166bda1f6308a9b4f26268791d55781112620. | ||
12 | 8 | The required gettext version 0.19.1 is not yet available on many | ||
13 | 9 | systems. | ||
14 | 10 | |||
15 | 11 | configure.ac | 3 +-- | ||
16 | 12 | po/Makevars | 72 | ||
17 | 13 | ------------------------------------------------------------ | ||
18 | 14 | 2 files changed, 1 insertion(+), 74 deletions(-) | ||
19 | 15 | |||
20 | 16 | commit 784377b6c2aa7e78e193b4c4a7ebde9e1a5aeba3 | ||
21 | 17 | Author: Daiki Ueno <ueno@unixuser.org> | ||
22 | 18 | Date: Mon Jul 7 13:06:29 2014 +0900 | ||
23 | 19 | |||
24 | 20 | Bump version to 0.3.4 | ||
25 | 21 | |||
26 | 22 | configure.ac | 2 +- | ||
27 | 23 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
28 | 24 | |||
29 | 25 | commit 3cff841d1fb430fcb30236e20e7ec84214f2d9c1 | ||
30 | 26 | Author: Daiki Ueno <ueno@unixuser.org> | ||
31 | 27 | Date: Mon Jul 7 13:05:36 2014 +0900 | ||
32 | 28 | |||
33 | 29 | Update copyright year | ||
34 | 30 | |||
35 | 31 | Makefile.am | 4 ++-- | ||
36 | 32 | README | 4 ++-- | ||
37 | 33 | configure.ac | 4 ++-- | ||
38 | 34 | data/Makefile.am | 4 ++-- | ||
39 | 35 | data/rules/Makefile.am | 4 ++-- | ||
40 | 36 | data/rules/README.rules | 4 ++-- | ||
41 | 37 | data/templates/Makefile.am | 4 ++-- | ||
42 | 38 | data/templates/libkkc-data/Makefile.am | 4 ++-- | ||
43 | 39 | data/templates/libkkc-data/configure.ac.in | 4 ++-- | ||
44 | 40 | data/templates/libkkc-data/data/Makefile.am | 4 ++-- | ||
45 | 41 | data/templates/libkkc-data/data/models/Makefile.sorted2 | 4 ++-- | ||
46 | 42 | data/templates/libkkc-data/data/models/Makefile.sorted3 | 4 ++-- | ||
47 | 43 | data/templates/libkkc-data/tools/Makefile.am | 4 ++-- | ||
48 | 44 | data/templates/libkkc-data/tools/genfilter.py | 4 ++-- | ||
49 | 45 | data/templates/libkkc-data/tools/sortlm.py | 4 ++-- | ||
50 | 46 | libkkc/Makefile.am | 4 ++-- | ||
51 | 47 | libkkc/bigram-decoder.vala | 4 ++-- | ||
52 | 48 | libkkc/bloom-filter.vala | 4 ++-- | ||
53 | 49 | libkkc/candidate-list.vala | 4 ++-- | ||
54 | 50 | libkkc/candidate.vala | 4 ++-- | ||
55 | 51 | libkkc/context.vala | 4 ++-- | ||
56 | 52 | libkkc/convert-segment-state-handler.vala | 4 ++-- | ||
57 | 53 | libkkc/convert-sentence-state-handler.vala | 4 ++-- | ||
58 | 54 | libkkc/decoder.vala | 4 ++-- | ||
59 | 55 | libkkc/dictionary-list.vala | 4 ++-- | ||
60 | 56 | libkkc/dictionary.vala | 4 ++-- | ||
61 | 57 | libkkc/encoding.vala | 4 ++-- | ||
62 | 58 | libkkc/expression.vala | 4 ++-- | ||
63 | 59 | libkkc/initial-state-handler.vala | 4 ++-- | ||
64 | 60 | libkkc/key-event-filter.vala | 4 ++-- | ||
65 | 61 | libkkc/key-event.vala | 4 ++-- | ||
66 | 62 | libkkc/keymap.vala | 4 ++-- | ||
67 | 63 | libkkc/keysyms.vala | 4 ++-- | ||
68 | 64 | libkkc/kkc-1.0.pc.in | 4 ++-- | ||
69 | 65 | libkkc/kkc.vala | 4 ++-- | ||
70 | 66 | libkkc/language-model-utils.vala | 4 ++-- | ||
71 | 67 | libkkc/language-model.vala | 4 ++-- | ||
72 | 68 | libkkc/map-file.vala | 4 ++-- | ||
73 | 69 | libkkc/metadata-file.vala | 4 ++-- | ||
74 | 70 | libkkc/nicola.vala | 4 ++-- | ||
75 | 71 | libkkc/numeric-template.vala | 4 ++-- | ||
76 | 72 | libkkc/rom-kana-utils.vala | 4 ++-- | ||
77 | 73 | libkkc/rom-kana.vala | 4 ++-- | ||
78 | 74 | libkkc/rule.vala | 4 ++-- | ||
79 | 75 | libkkc/segment-dictionary.vala | 4 ++-- | ||
80 | 76 | libkkc/segment-list.vala | 4 ++-- | ||
81 | 77 | libkkc/segment.vala | 4 ++-- | ||
82 | 78 | libkkc/sentence-dictionary.vala | 4 ++-- | ||
83 | 79 | libkkc/sorted-bigram-language-model.vala | 4 ++-- | ||
84 | 80 | libkkc/sorted-trigram-language-model.vala | 4 ++-- | ||
85 | 81 | libkkc/state.vala | 4 ++-- | ||
86 | 82 | libkkc/system-segment-dictionary.vala | 4 ++-- | ||
87 | 83 | libkkc/template.vala | 4 ++-- | ||
88 | 84 | libkkc/text-bigram-language-model.vala | 4 ++-- | ||
89 | 85 | libkkc/text-trigram-language-model.vala | 4 ++-- | ||
90 | 86 | libkkc/trellis-node.vala | 4 ++-- | ||
91 | 87 | libkkc/trigram-decoder.vala | 4 ++-- | ||
92 | 88 | libkkc/user-dictionary.vala | 4 ++-- | ||
93 | 89 | libkkc/user-segment-dictionary.vala | 4 ++-- | ||
94 | 90 | libkkc/user-sentence-dictionary.vala | 4 ++-- | ||
95 | 91 | libkkc/utils.vala | 4 ++-- | ||
96 | 92 | marisa-glib/Makefile.am | 4 ++-- | ||
97 | 93 | tests/Makefile.am | 4 ++-- | ||
98 | 94 | tools/Makefile.am | 4 ++-- | ||
99 | 95 | tools/kkc-package-data.in | 4 ++-- | ||
100 | 96 | tools/kkc.vala | 4 ++-- | ||
101 | 97 | 66 files changed, 132 insertions(+), 132 deletions(-) | ||
102 | 98 | |||
103 | 99 | commit 025d2fb3bf7e05bd7367d459bbf0557d5e929eab | ||
104 | 100 | Author: Daiki Ueno <ueno@unixuser.org> | ||
105 | 101 | Date: Mon Jun 16 12:18:40 2014 +0900 | ||
106 | 102 | |||
107 | 103 | Update translations | ||
108 | 104 | |||
109 | 105 | po/ja.po | 8 +++++++- | ||
110 | 106 | 1 file changed, 7 insertions(+), 1 deletion(-) | ||
111 | 107 | |||
112 | 108 | commit 95ecc6d8a21814a093e013c60e370ac49407013a | ||
113 | 109 | Author: Daiki Ueno <ueno@unixuser.org> | ||
114 | 110 | Date: Mon Jun 16 12:13:19 2014 +0900 | ||
115 | 111 | |||
116 | 112 | Update translations | ||
117 | 113 | |||
118 | 114 | po/ja.po | 148 | ||
119 | 115 | ++++++++++++++++++++++++++++++++++----------------------------- | ||
120 | 116 | 1 file changed, 81 insertions(+), 67 deletions(-) | ||
121 | 117 | |||
122 | 118 | commit 25e166bda1f6308a9b4f26268791d55781112620 | ||
123 | 119 | Author: Daiki Ueno <ueno@unixuser.org> | ||
124 | 120 | Date: Mon Jun 16 12:10:51 2014 +0900 | ||
125 | 121 | |||
126 | 122 | build: Switch from intltool to gettext | ||
127 | 123 | |||
128 | 124 | configure.ac | 3 ++- | ||
129 | 125 | po/Makevars | 72 | ||
130 | 126 | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | ||
131 | 127 | 2 files changed, 74 insertions(+), 1 deletion(-) | ||
132 | 128 | |||
133 | 129 | commit e5a21c69386a1c6681d63f5201fde2230a51f27a | ||
134 | 130 | Author: Daiki Ueno <ueno@unixuser.org> | ||
135 | 131 | Date: Mon Jun 16 12:00:41 2014 +0900 | ||
136 | 132 | |||
137 | 133 | Fix dependencies | ||
138 | 134 | |||
139 | 135 | Can't make json-glib-1.0 and gee-0.8 optional, since some classes | ||
140 | 136 | provide | ||
141 | 137 | API using it for performance reason. | ||
142 | 138 | |||
143 | 139 | libkkc/kkc-1.0.deps | 1 + | ||
144 | 140 | libkkc/kkc-1.0.pc.in | 3 +-- | ||
145 | 141 | 2 files changed, 2 insertions(+), 2 deletions(-) | ||
146 | 142 | |||
147 | 143 | commit 82ab9a22f97852fcc096347a663b3ea3b95626a8 | ||
148 | 144 | Author: Daiki Ueno <ueno@unixuser.org> | ||
149 | 145 | Date: Mon Jun 16 11:27:23 2014 +0900 | ||
150 | 146 | |||
151 | 147 | Fix package dependencies | ||
152 | 148 | |||
153 | 149 | libkkc/kkc-1.0.deps | 2 -- | ||
154 | 150 | libkkc/kkc-1.0.pc.in | 4 ++-- | ||
155 | 151 | 2 files changed, 2 insertions(+), 4 deletions(-) | ||
156 | 152 | |||
157 | 153 | commit baf68310e26cd090b6b5d7b4604cb4fcd5e5ca4f | ||
158 | 154 | Author: Daiki Ueno <ueno@unixuser.org> | ||
159 | 155 | Date: Mon Jun 16 11:17:36 2014 +0900 | ||
160 | 156 | |||
161 | 157 | Fix HashSet name clash between Vala 0.26 glib-2.0.vapi and | ||
162 | 158 | gee-0.8.vapi | ||
163 | 159 | |||
164 | 160 | libkkc/bigram-decoder.vala | 2 +- | ||
165 | 161 | libkkc/candidate-list.vala | 2 +- | ||
166 | 162 | libkkc/map-file.vala | 2 +- | ||
167 | 163 | libkkc/rule.vala | 2 +- | ||
168 | 164 | libkkc/trigram-decoder.vala | 4 ++-- | ||
169 | 165 | 5 files changed, 6 insertions(+), 6 deletions(-) | ||
170 | 166 | |||
171 | 167 | commit ebc714b954a7798646371eb3fd6fe4e51638f329 | ||
172 | 168 | Author: Daiki Ueno <ueno@unixuser.org> | ||
173 | 169 | Date: Mon Jun 16 11:12:50 2014 +0900 | ||
174 | 170 | |||
175 | 171 | Port to libgee 0.8 API | ||
176 | 172 | |||
177 | 173 | configure.ac | 4 ++-- | ||
178 | 174 | libkkc/Makefile.am | 2 +- | ||
179 | 175 | libkkc/bigram-decoder.vala | 12 ++++------- | ||
180 | 176 | libkkc/expression.vala | 2 +- | ||
181 | 177 | libkkc/keymap.vala | 32 ++++++++++++----------------- | ||
182 | 178 | libkkc/kkc-1.0.pc.in | 2 +- | ||
183 | 179 | libkkc/nicola.vala | 4 ++-- | ||
184 | 180 | libkkc/rule.vala | 40 | ||
185 | 181 | ++++++++++++++++-------------------- | ||
186 | 182 | libkkc/state.vala | 2 +- | ||
187 | 183 | libkkc/trigram-decoder.vala | 3 +-- | ||
188 | 184 | libkkc/user-segment-dictionary.vala | 4 ++-- | ||
189 | 185 | libkkc/user-sentence-dictionary.vala | 4 ++-- | ||
190 | 186 | 12 files changed, 48 insertions(+), 63 deletions(-) | ||
191 | 187 | |||
192 | 188 | commit 8a5366c976b0399a69e6b9f622ad29f987c8a52e | ||
193 | 189 | Author: Daiki Ueno <ueno@unixuser.org> | ||
194 | 190 | Date: Mon Jun 16 10:50:34 2014 +0900 | ||
195 | 191 | |||
196 | 192 | kkc-1.0.pc: Mark libgee and json-glib as private dependency | ||
197 | 193 | |||
198 | 194 | libkkc/kkc-1.0.pc.in | 3 ++- | ||
199 | 195 | 1 file changed, 2 insertions(+), 1 deletion(-) | ||
200 | 196 | |||
201 | 197 | commit 72a596d438f5ede05c59d733a05ba566a1259bcd | ||
202 | 198 | Author: Daiki Ueno <ueno@unixuser.org> | ||
203 | 199 | Date: Tue May 13 16:30:46 2014 +0900 | ||
204 | 200 | |||
205 | 201 | rom-kana: Retain partial input when "convert-*" commands are called | ||
206 | 202 | |||
207 | 203 | Suggested by Masafumi Miura. | ||
208 | 204 | |||
209 | 205 | libkkc/rom-kana.vala | 14 +++++++++++--- | ||
210 | 206 | tests/conversions-initial.json | 4 +++- | ||
211 | 207 | tests/lib/test-utils.vala | 3 +++ | ||
212 | 208 | 3 files changed, 17 insertions(+), 4 deletions(-) | ||
213 | 209 | |||
214 | 210 | commit 5f38726532b8790e1320e1b35bc326439ef9cdb0 | ||
215 | 211 | Author: Daiki Ueno <ueno@unixuser.org> | ||
216 | 212 | Date: Tue May 13 12:04:27 2014 +0900 | ||
217 | 213 | |||
218 | 214 | rom-kana: Assign "ly<X>" to HIRAGANA SMALL LETTER <X> | ||
219 | 215 | |||
220 | 216 | Suggested by Masafumi Miura. | ||
221 | 217 | |||
222 | 218 | data/rules/default/rom-kana/default.json | 5 +++++ | ||
223 | 219 | 1 file changed, 5 insertions(+) | ||
224 | 220 | |||
225 | 1 | commit 4859e8ab00b215d1cf6830a31cbb1abe8c0f06b1 | 221 | commit 4859e8ab00b215d1cf6830a31cbb1abe8c0f06b1 |
226 | 2 | Author: Daiki Ueno <ueno@unixuser.org> | 222 | Author: Daiki Ueno <ueno@unixuser.org> |
227 | 3 | Date: Tue Apr 1 18:17:33 2014 +0900 | 223 | Date: Tue Apr 1 18:17:33 2014 +0900 |
228 | 4 | 224 | ||
229 | === modified file 'Makefile.am' | |||
230 | --- Makefile.am 2014-02-26 22:51:39 +0000 | |||
231 | +++ Makefile.am 2014-10-01 15:12:30 +0000 | |||
232 | @@ -1,5 +1,5 @@ | |||
235 | 1 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
236 | 2 | # Copyright (C) 2011-2013 Red Hat, Inc. | 2 | # Copyright (C) 2011-2014 Red Hat, Inc. |
237 | 3 | 3 | ||
238 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
239 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
240 | 6 | 6 | ||
241 | === modified file 'Makefile.in' | |||
242 | --- Makefile.in 2014-02-26 22:51:39 +0000 | |||
243 | +++ Makefile.in 2014-10-01 15:12:30 +0000 | |||
244 | @@ -14,8 +14,8 @@ | |||
245 | 14 | 14 | ||
246 | 15 | @SET_MAKE@ | 15 | @SET_MAKE@ |
247 | 16 | 16 | ||
250 | 17 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 17 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
251 | 18 | # Copyright (C) 2011-2013 Red Hat, Inc. | 18 | # Copyright (C) 2011-2014 Red Hat, Inc. |
252 | 19 | 19 | ||
253 | 20 | # This program is free software: you can redistribute it and/or modify | 20 | # This program is free software: you can redistribute it and/or modify |
254 | 21 | # it under the terms of the GNU General Public License as published by | 21 | # it under the terms of the GNU General Public License as published by |
255 | 22 | 22 | ||
256 | === modified file 'README' | |||
257 | --- README 2014-02-26 22:51:39 +0000 | |||
258 | +++ README 2014-10-01 15:12:30 +0000 | |||
259 | @@ -46,8 +46,8 @@ | |||
260 | 46 | 46 | ||
261 | 47 | GPLv3+ | 47 | GPLv3+ |
262 | 48 | 48 | ||
265 | 49 | Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 49 | Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
266 | 50 | Copyright (C) 2011-2013 Red Hat, Inc. | 50 | Copyright (C) 2011-2014 Red Hat, Inc. |
267 | 51 | 51 | ||
268 | 52 | This file is free software; as a special exception the author gives | 52 | This file is free software; as a special exception the author gives |
269 | 53 | unlimited permission to copy and/or distribute it, with or without | 53 | unlimited permission to copy and/or distribute it, with or without |
270 | 54 | 54 | ||
271 | === modified file 'aclocal.m4' | |||
272 | --- aclocal.m4 2014-06-15 23:27:57 +0000 | |||
273 | +++ aclocal.m4 2014-10-01 15:12:30 +0000 | |||
274 | @@ -20,105 +20,8 @@ | |||
275 | 20 | If you have problems, you may need to regenerate the build system entirely. | 20 | If you have problems, you may need to regenerate the build system entirely. |
276 | 21 | To do so, use the procedure documented by the package, typically 'autoreconf'.])]) | 21 | To do so, use the procedure documented by the package, typically 'autoreconf'.])]) |
277 | 22 | 22 | ||
278 | 23 | dnl -*- mode: autoconf -*- | ||
279 | 24 | dnl Copyright 2009 Johan Dahlin | ||
280 | 25 | dnl | ||
281 | 26 | dnl This file is free software; the author(s) gives unlimited | ||
282 | 27 | dnl permission to copy and/or distribute it, with or without | ||
283 | 28 | dnl modifications, as long as this notice is preserved. | ||
284 | 29 | dnl | ||
285 | 30 | |||
286 | 31 | # serial 1 | ||
287 | 32 | |||
288 | 33 | m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL], | ||
289 | 34 | [ | ||
290 | 35 | AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first | ||
291 | 36 | AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first | ||
292 | 37 | AC_BEFORE([LT_INIT],[$0])dnl setup libtool first | ||
293 | 38 | |||
294 | 39 | dnl enable/disable introspection | ||
295 | 40 | m4_if([$2], [require], | ||
296 | 41 | [dnl | ||
297 | 42 | enable_introspection=yes | ||
298 | 43 | ],[dnl | ||
299 | 44 | AC_ARG_ENABLE(introspection, | ||
300 | 45 | AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]], | ||
301 | 46 | [Enable introspection for this build]),, | ||
302 | 47 | [enable_introspection=auto]) | ||
303 | 48 | ])dnl | ||
304 | 49 | |||
305 | 50 | AC_MSG_CHECKING([for gobject-introspection]) | ||
306 | 51 | |||
307 | 52 | dnl presence/version checking | ||
308 | 53 | AS_CASE([$enable_introspection], | ||
309 | 54 | [no], [dnl | ||
310 | 55 | found_introspection="no (disabled, use --enable-introspection to enable)" | ||
311 | 56 | ],dnl | ||
312 | 57 | [yes],[dnl | ||
313 | 58 | PKG_CHECK_EXISTS([gobject-introspection-1.0],, | ||
314 | 59 | AC_MSG_ERROR([gobject-introspection-1.0 is not installed])) | ||
315 | 60 | PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], | ||
316 | 61 | found_introspection=yes, | ||
317 | 62 | AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME])) | ||
318 | 63 | ],dnl | ||
319 | 64 | [auto],[dnl | ||
320 | 65 | PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no) | ||
321 | 66 | dnl Canonicalize enable_introspection | ||
322 | 67 | enable_introspection=$found_introspection | ||
323 | 68 | ],dnl | ||
324 | 69 | [dnl | ||
325 | 70 | AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@]) | ||
326 | 71 | ])dnl | ||
327 | 72 | |||
328 | 73 | AC_MSG_RESULT([$found_introspection]) | ||
329 | 74 | |||
330 | 75 | INTROSPECTION_SCANNER= | ||
331 | 76 | INTROSPECTION_COMPILER= | ||
332 | 77 | INTROSPECTION_GENERATE= | ||
333 | 78 | INTROSPECTION_GIRDIR= | ||
334 | 79 | INTROSPECTION_TYPELIBDIR= | ||
335 | 80 | if test "x$found_introspection" = "xyes"; then | ||
336 | 81 | INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0` | ||
337 | 82 | INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0` | ||
338 | 83 | INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0` | ||
339 | 84 | INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0` | ||
340 | 85 | INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)" | ||
341 | 86 | INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0` | ||
342 | 87 | INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0` | ||
343 | 88 | INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection | ||
344 | 89 | fi | ||
345 | 90 | AC_SUBST(INTROSPECTION_SCANNER) | ||
346 | 91 | AC_SUBST(INTROSPECTION_COMPILER) | ||
347 | 92 | AC_SUBST(INTROSPECTION_GENERATE) | ||
348 | 93 | AC_SUBST(INTROSPECTION_GIRDIR) | ||
349 | 94 | AC_SUBST(INTROSPECTION_TYPELIBDIR) | ||
350 | 95 | AC_SUBST(INTROSPECTION_CFLAGS) | ||
351 | 96 | AC_SUBST(INTROSPECTION_LIBS) | ||
352 | 97 | AC_SUBST(INTROSPECTION_MAKEFILE) | ||
353 | 98 | |||
354 | 99 | AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes") | ||
355 | 100 | ]) | ||
356 | 101 | |||
357 | 102 | |||
358 | 103 | dnl Usage: | ||
359 | 104 | dnl GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version]) | ||
360 | 105 | |||
361 | 106 | AC_DEFUN([GOBJECT_INTROSPECTION_CHECK], | ||
362 | 107 | [ | ||
363 | 108 | _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1]) | ||
364 | 109 | ]) | ||
365 | 110 | |||
366 | 111 | dnl Usage: | ||
367 | 112 | dnl GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version]) | ||
368 | 113 | |||
369 | 114 | |||
370 | 115 | AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE], | ||
371 | 116 | [ | ||
372 | 117 | _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require]) | ||
373 | 118 | ]) | ||
374 | 119 | |||
375 | 120 | # nls.m4 serial 5 (gettext-0.18) | 23 | # nls.m4 serial 5 (gettext-0.18) |
377 | 121 | dnl Copyright (C) 1995-2003, 2005-2006, 2008-2013 Free Software Foundation, | 24 | dnl Copyright (C) 1995-2003, 2005-2006, 2008-2014 Free Software Foundation, |
378 | 122 | dnl Inc. | 25 | dnl Inc. |
379 | 123 | dnl This file is free software; the Free Software Foundation | 26 | dnl This file is free software; the Free Software Foundation |
380 | 124 | dnl gives unlimited permission to copy and/or distribute it, | 27 | dnl gives unlimited permission to copy and/or distribute it, |
381 | @@ -365,6 +268,103 @@ | |||
382 | 365 | AS_VAR_IF([$1], [""], [$5], [$4])dnl | 268 | AS_VAR_IF([$1], [""], [$5], [$4])dnl |
383 | 366 | ])# PKG_CHECK_VAR | 269 | ])# PKG_CHECK_VAR |
384 | 367 | 270 | ||
385 | 271 | dnl -*- mode: autoconf -*- | ||
386 | 272 | dnl Copyright 2009 Johan Dahlin | ||
387 | 273 | dnl | ||
388 | 274 | dnl This file is free software; the author(s) gives unlimited | ||
389 | 275 | dnl permission to copy and/or distribute it, with or without | ||
390 | 276 | dnl modifications, as long as this notice is preserved. | ||
391 | 277 | dnl | ||
392 | 278 | |||
393 | 279 | # serial 1 | ||
394 | 280 | |||
395 | 281 | m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL], | ||
396 | 282 | [ | ||
397 | 283 | AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first | ||
398 | 284 | AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first | ||
399 | 285 | AC_BEFORE([LT_INIT],[$0])dnl setup libtool first | ||
400 | 286 | |||
401 | 287 | dnl enable/disable introspection | ||
402 | 288 | m4_if([$2], [require], | ||
403 | 289 | [dnl | ||
404 | 290 | enable_introspection=yes | ||
405 | 291 | ],[dnl | ||
406 | 292 | AC_ARG_ENABLE(introspection, | ||
407 | 293 | AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]], | ||
408 | 294 | [Enable introspection for this build]),, | ||
409 | 295 | [enable_introspection=auto]) | ||
410 | 296 | ])dnl | ||
411 | 297 | |||
412 | 298 | AC_MSG_CHECKING([for gobject-introspection]) | ||
413 | 299 | |||
414 | 300 | dnl presence/version checking | ||
415 | 301 | AS_CASE([$enable_introspection], | ||
416 | 302 | [no], [dnl | ||
417 | 303 | found_introspection="no (disabled, use --enable-introspection to enable)" | ||
418 | 304 | ],dnl | ||
419 | 305 | [yes],[dnl | ||
420 | 306 | PKG_CHECK_EXISTS([gobject-introspection-1.0],, | ||
421 | 307 | AC_MSG_ERROR([gobject-introspection-1.0 is not installed])) | ||
422 | 308 | PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], | ||
423 | 309 | found_introspection=yes, | ||
424 | 310 | AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME])) | ||
425 | 311 | ],dnl | ||
426 | 312 | [auto],[dnl | ||
427 | 313 | PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no) | ||
428 | 314 | dnl Canonicalize enable_introspection | ||
429 | 315 | enable_introspection=$found_introspection | ||
430 | 316 | ],dnl | ||
431 | 317 | [dnl | ||
432 | 318 | AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@]) | ||
433 | 319 | ])dnl | ||
434 | 320 | |||
435 | 321 | AC_MSG_RESULT([$found_introspection]) | ||
436 | 322 | |||
437 | 323 | INTROSPECTION_SCANNER= | ||
438 | 324 | INTROSPECTION_COMPILER= | ||
439 | 325 | INTROSPECTION_GENERATE= | ||
440 | 326 | INTROSPECTION_GIRDIR= | ||
441 | 327 | INTROSPECTION_TYPELIBDIR= | ||
442 | 328 | if test "x$found_introspection" = "xyes"; then | ||
443 | 329 | INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0` | ||
444 | 330 | INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0` | ||
445 | 331 | INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0` | ||
446 | 332 | INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0` | ||
447 | 333 | INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)" | ||
448 | 334 | INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0` | ||
449 | 335 | INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0` | ||
450 | 336 | INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection | ||
451 | 337 | fi | ||
452 | 338 | AC_SUBST(INTROSPECTION_SCANNER) | ||
453 | 339 | AC_SUBST(INTROSPECTION_COMPILER) | ||
454 | 340 | AC_SUBST(INTROSPECTION_GENERATE) | ||
455 | 341 | AC_SUBST(INTROSPECTION_GIRDIR) | ||
456 | 342 | AC_SUBST(INTROSPECTION_TYPELIBDIR) | ||
457 | 343 | AC_SUBST(INTROSPECTION_CFLAGS) | ||
458 | 344 | AC_SUBST(INTROSPECTION_LIBS) | ||
459 | 345 | AC_SUBST(INTROSPECTION_MAKEFILE) | ||
460 | 346 | |||
461 | 347 | AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes") | ||
462 | 348 | ]) | ||
463 | 349 | |||
464 | 350 | |||
465 | 351 | dnl Usage: | ||
466 | 352 | dnl GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version]) | ||
467 | 353 | |||
468 | 354 | AC_DEFUN([GOBJECT_INTROSPECTION_CHECK], | ||
469 | 355 | [ | ||
470 | 356 | _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1]) | ||
471 | 357 | ]) | ||
472 | 358 | |||
473 | 359 | dnl Usage: | ||
474 | 360 | dnl GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version]) | ||
475 | 361 | |||
476 | 362 | |||
477 | 363 | AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE], | ||
478 | 364 | [ | ||
479 | 365 | _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require]) | ||
480 | 366 | ]) | ||
481 | 367 | |||
482 | 368 | dnl vapigen.m4 | 368 | dnl vapigen.m4 |
483 | 369 | dnl | 369 | dnl |
484 | 370 | dnl Copyright 2012 Evan Nemerson | 370 | dnl Copyright 2012 Evan Nemerson |
485 | 371 | 371 | ||
486 | === modified file 'configure' | |||
487 | --- configure 2014-06-15 23:27:57 +0000 | |||
488 | +++ configure 2014-10-01 15:12:30 +0000 | |||
489 | @@ -1,6 +1,6 @@ | |||
490 | 1 | #! /bin/sh | 1 | #! /bin/sh |
491 | 2 | # Guess values for system-dependent variables and create Makefiles. | 2 | # Guess values for system-dependent variables and create Makefiles. |
493 | 3 | # Generated by GNU Autoconf 2.69 for libkkc 0.3.3. | 3 | # Generated by GNU Autoconf 2.69 for libkkc 0.3.4. |
494 | 4 | # | 4 | # |
495 | 5 | # Report bugs to <ueno@gnu.org>. | 5 | # Report bugs to <ueno@gnu.org>. |
496 | 6 | # | 6 | # |
497 | @@ -649,8 +649,8 @@ | |||
498 | 649 | # Identity of this package. | 649 | # Identity of this package. |
499 | 650 | PACKAGE_NAME='libkkc' | 650 | PACKAGE_NAME='libkkc' |
500 | 651 | PACKAGE_TARNAME='libkkc' | 651 | PACKAGE_TARNAME='libkkc' |
503 | 652 | PACKAGE_VERSION='0.3.3' | 652 | PACKAGE_VERSION='0.3.4' |
504 | 653 | PACKAGE_STRING='libkkc 0.3.3' | 653 | PACKAGE_STRING='libkkc 0.3.4' |
505 | 654 | PACKAGE_BUGREPORT='ueno@gnu.org' | 654 | PACKAGE_BUGREPORT='ueno@gnu.org' |
506 | 655 | PACKAGE_URL='' | 655 | PACKAGE_URL='' |
507 | 656 | 656 | ||
508 | @@ -1501,7 +1501,7 @@ | |||
509 | 1501 | # Omit some internal or obsolete options to make the list less imposing. | 1501 | # Omit some internal or obsolete options to make the list less imposing. |
510 | 1502 | # This message is too long to be a string in the A/UX 3.1 sh. | 1502 | # This message is too long to be a string in the A/UX 3.1 sh. |
511 | 1503 | cat <<_ACEOF | 1503 | cat <<_ACEOF |
513 | 1504 | \`configure' configures libkkc 0.3.3 to adapt to many kinds of systems. | 1504 | \`configure' configures libkkc 0.3.4 to adapt to many kinds of systems. |
514 | 1505 | 1505 | ||
515 | 1506 | Usage: $0 [OPTION]... [VAR=VALUE]... | 1506 | Usage: $0 [OPTION]... [VAR=VALUE]... |
516 | 1507 | 1507 | ||
517 | @@ -1571,7 +1571,7 @@ | |||
518 | 1571 | 1571 | ||
519 | 1572 | if test -n "$ac_init_help"; then | 1572 | if test -n "$ac_init_help"; then |
520 | 1573 | case $ac_init_help in | 1573 | case $ac_init_help in |
522 | 1574 | short | recursive ) echo "Configuration of libkkc 0.3.3:";; | 1574 | short | recursive ) echo "Configuration of libkkc 0.3.4:";; |
523 | 1575 | esac | 1575 | esac |
524 | 1576 | cat <<\_ACEOF | 1576 | cat <<\_ACEOF |
525 | 1577 | 1577 | ||
526 | @@ -1712,7 +1712,7 @@ | |||
527 | 1712 | test -n "$ac_init_help" && exit $ac_status | 1712 | test -n "$ac_init_help" && exit $ac_status |
528 | 1713 | if $ac_init_version; then | 1713 | if $ac_init_version; then |
529 | 1714 | cat <<\_ACEOF | 1714 | cat <<\_ACEOF |
531 | 1715 | libkkc configure 0.3.3 | 1715 | libkkc configure 0.3.4 |
532 | 1716 | generated by GNU Autoconf 2.69 | 1716 | generated by GNU Autoconf 2.69 |
533 | 1717 | 1717 | ||
534 | 1718 | Copyright (C) 2012 Free Software Foundation, Inc. | 1718 | Copyright (C) 2012 Free Software Foundation, Inc. |
535 | @@ -2202,7 +2202,7 @@ | |||
536 | 2202 | This file contains any messages produced by compilers while | 2202 | This file contains any messages produced by compilers while |
537 | 2203 | running configure, to aid debugging if configure makes a mistake. | 2203 | running configure, to aid debugging if configure makes a mistake. |
538 | 2204 | 2204 | ||
540 | 2205 | It was created by libkkc $as_me 0.3.3, which was | 2205 | It was created by libkkc $as_me 0.3.4, which was |
541 | 2206 | generated by GNU Autoconf 2.69. Invocation command line was | 2206 | generated by GNU Autoconf 2.69. Invocation command line was |
542 | 2207 | 2207 | ||
543 | 2208 | $ $0 $@ | 2208 | $ $0 $@ |
544 | @@ -3080,7 +3080,7 @@ | |||
545 | 3080 | 3080 | ||
546 | 3081 | # Define the identity of the package. | 3081 | # Define the identity of the package. |
547 | 3082 | PACKAGE='libkkc' | 3082 | PACKAGE='libkkc' |
549 | 3083 | VERSION='0.3.3' | 3083 | VERSION='0.3.4' |
550 | 3084 | 3084 | ||
551 | 3085 | 3085 | ||
552 | 3086 | cat >>confdefs.h <<_ACEOF | 3086 | cat >>confdefs.h <<_ACEOF |
553 | @@ -9390,10 +9390,10 @@ | |||
554 | 9390 | x86_64-*linux*) | 9390 | x86_64-*linux*) |
555 | 9391 | LD="${LD-ld} -m elf_i386" | 9391 | LD="${LD-ld} -m elf_i386" |
556 | 9392 | ;; | 9392 | ;; |
558 | 9393 | powerpcle-*linux*) | 9393 | powerpc64le-*linux*) |
559 | 9394 | LD="${LD-ld} -m elf32lppclinux" | 9394 | LD="${LD-ld} -m elf32lppclinux" |
560 | 9395 | ;; | 9395 | ;; |
562 | 9396 | powerpc-*linux*) | 9396 | powerpc64-*linux*) |
563 | 9397 | LD="${LD-ld} -m elf32ppclinux" | 9397 | LD="${LD-ld} -m elf32ppclinux" |
564 | 9398 | ;; | 9398 | ;; |
565 | 9399 | s390x-*linux*) | 9399 | s390x-*linux*) |
566 | @@ -17679,12 +17679,12 @@ | |||
567 | 17679 | pkg_cv_GEE_CFLAGS="$GEE_CFLAGS" | 17679 | pkg_cv_GEE_CFLAGS="$GEE_CFLAGS" |
568 | 17680 | elif test -n "$PKG_CONFIG"; then | 17680 | elif test -n "$PKG_CONFIG"; then |
569 | 17681 | if test -n "$PKG_CONFIG" && \ | 17681 | if test -n "$PKG_CONFIG" && \ |
572 | 17682 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gee-1.0\""; } >&5 | 17682 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gee-0.8\""; } >&5 |
573 | 17683 | ($PKG_CONFIG --exists --print-errors "gee-1.0") 2>&5 | 17683 | ($PKG_CONFIG --exists --print-errors "gee-0.8") 2>&5 |
574 | 17684 | ac_status=$? | 17684 | ac_status=$? |
575 | 17685 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | 17685 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
576 | 17686 | test $ac_status = 0; }; then | 17686 | test $ac_status = 0; }; then |
578 | 17687 | pkg_cv_GEE_CFLAGS=`$PKG_CONFIG --cflags "gee-1.0" 2>/dev/null` | 17687 | pkg_cv_GEE_CFLAGS=`$PKG_CONFIG --cflags "gee-0.8" 2>/dev/null` |
579 | 17688 | test "x$?" != "x0" && pkg_failed=yes | 17688 | test "x$?" != "x0" && pkg_failed=yes |
580 | 17689 | else | 17689 | else |
581 | 17690 | pkg_failed=yes | 17690 | pkg_failed=yes |
582 | @@ -17696,12 +17696,12 @@ | |||
583 | 17696 | pkg_cv_GEE_LIBS="$GEE_LIBS" | 17696 | pkg_cv_GEE_LIBS="$GEE_LIBS" |
584 | 17697 | elif test -n "$PKG_CONFIG"; then | 17697 | elif test -n "$PKG_CONFIG"; then |
585 | 17698 | if test -n "$PKG_CONFIG" && \ | 17698 | if test -n "$PKG_CONFIG" && \ |
588 | 17699 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gee-1.0\""; } >&5 | 17699 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gee-0.8\""; } >&5 |
589 | 17700 | ($PKG_CONFIG --exists --print-errors "gee-1.0") 2>&5 | 17700 | ($PKG_CONFIG --exists --print-errors "gee-0.8") 2>&5 |
590 | 17701 | ac_status=$? | 17701 | ac_status=$? |
591 | 17702 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | 17702 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
592 | 17703 | test $ac_status = 0; }; then | 17703 | test $ac_status = 0; }; then |
594 | 17704 | pkg_cv_GEE_LIBS=`$PKG_CONFIG --libs "gee-1.0" 2>/dev/null` | 17704 | pkg_cv_GEE_LIBS=`$PKG_CONFIG --libs "gee-0.8" 2>/dev/null` |
595 | 17705 | test "x$?" != "x0" && pkg_failed=yes | 17705 | test "x$?" != "x0" && pkg_failed=yes |
596 | 17706 | else | 17706 | else |
597 | 17707 | pkg_failed=yes | 17707 | pkg_failed=yes |
598 | @@ -17722,18 +17722,18 @@ | |||
599 | 17722 | _pkg_short_errors_supported=no | 17722 | _pkg_short_errors_supported=no |
600 | 17723 | fi | 17723 | fi |
601 | 17724 | if test $_pkg_short_errors_supported = yes; then | 17724 | if test $_pkg_short_errors_supported = yes; then |
603 | 17725 | GEE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gee-1.0" 2>&1` | 17725 | GEE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gee-0.8" 2>&1` |
604 | 17726 | else | 17726 | else |
606 | 17727 | GEE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gee-1.0" 2>&1` | 17727 | GEE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gee-0.8" 2>&1` |
607 | 17728 | fi | 17728 | fi |
608 | 17729 | # Put the nasty error message in config.log where it belongs | 17729 | # Put the nasty error message in config.log where it belongs |
609 | 17730 | echo "$GEE_PKG_ERRORS" >&5 | 17730 | echo "$GEE_PKG_ERRORS" >&5 |
610 | 17731 | 17731 | ||
612 | 17732 | as_fn_error $? "can't find gee-1.0" "$LINENO" 5 | 17732 | as_fn_error $? "can't find gee-0.8" "$LINENO" 5 |
613 | 17733 | elif test $pkg_failed = untried; then | 17733 | elif test $pkg_failed = untried; then |
614 | 17734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | 17734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
615 | 17735 | $as_echo "no" >&6; } | 17735 | $as_echo "no" >&6; } |
617 | 17736 | as_fn_error $? "can't find gee-1.0" "$LINENO" 5 | 17736 | as_fn_error $? "can't find gee-0.8" "$LINENO" 5 |
618 | 17737 | else | 17737 | else |
619 | 17738 | GEE_CFLAGS=$pkg_cv_GEE_CFLAGS | 17738 | GEE_CFLAGS=$pkg_cv_GEE_CFLAGS |
620 | 17739 | GEE_LIBS=$pkg_cv_GEE_LIBS | 17739 | GEE_LIBS=$pkg_cv_GEE_LIBS |
621 | @@ -19222,7 +19222,7 @@ | |||
622 | 19222 | # report actual input values of CONFIG_FILES etc. instead of their | 19222 | # report actual input values of CONFIG_FILES etc. instead of their |
623 | 19223 | # values after options handling. | 19223 | # values after options handling. |
624 | 19224 | ac_log=" | 19224 | ac_log=" |
626 | 19225 | This file was extended by libkkc $as_me 0.3.3, which was | 19225 | This file was extended by libkkc $as_me 0.3.4, which was |
627 | 19226 | generated by GNU Autoconf 2.69. Invocation command line was | 19226 | generated by GNU Autoconf 2.69. Invocation command line was |
628 | 19227 | 19227 | ||
629 | 19228 | CONFIG_FILES = $CONFIG_FILES | 19228 | CONFIG_FILES = $CONFIG_FILES |
630 | @@ -19288,7 +19288,7 @@ | |||
631 | 19288 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | 19288 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
632 | 19289 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" | 19289 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
633 | 19290 | ac_cs_version="\\ | 19290 | ac_cs_version="\\ |
635 | 19291 | libkkc config.status 0.3.3 | 19291 | libkkc config.status 0.3.4 |
636 | 19292 | configured by $0, generated by GNU Autoconf 2.69, | 19292 | configured by $0, generated by GNU Autoconf 2.69, |
637 | 19293 | with options \\"\$ac_cs_config\\" | 19293 | with options \\"\$ac_cs_config\\" |
638 | 19294 | 19294 | ||
639 | 19295 | 19295 | ||
640 | === modified file 'configure.ac' | |||
641 | --- configure.ac 2014-06-15 23:27:57 +0000 | |||
642 | +++ configure.ac 2014-10-01 15:12:30 +0000 | |||
643 | @@ -1,5 +1,5 @@ | |||
646 | 1 | # Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
647 | 2 | # Copyright (C) 2012-2013 Red Hat, Inc. | 2 | # Copyright (C) 2012-2014 Red Hat, Inc. |
648 | 3 | 3 | ||
649 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
650 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
651 | @@ -17,7 +17,7 @@ | |||
652 | 17 | AC_PREREQ(2.63) | 17 | AC_PREREQ(2.63) |
653 | 18 | AC_CONFIG_MACRO_DIR([m4]) | 18 | AC_CONFIG_MACRO_DIR([m4]) |
654 | 19 | 19 | ||
656 | 20 | AC_INIT([libkkc], [0.3.3], [ueno@gnu.org]) | 20 | AC_INIT([libkkc], [0.3.4], [ueno@gnu.org]) |
657 | 21 | 21 | ||
658 | 22 | KKC_API_VERSION=1.0 | 22 | KKC_API_VERSION=1.0 |
659 | 23 | KKC_API_MAJOR_VERSION=1 | 23 | KKC_API_MAJOR_VERSION=1 |
660 | @@ -75,8 +75,8 @@ | |||
661 | 75 | [AC_MSG_ERROR([can't find gio-2.0])]) | 75 | [AC_MSG_ERROR([can't find gio-2.0])]) |
662 | 76 | 76 | ||
663 | 77 | # check gee | 77 | # check gee |
666 | 78 | PKG_CHECK_MODULES([GEE], [gee-1.0], , | 78 | PKG_CHECK_MODULES([GEE], [gee-0.8], , |
667 | 79 | [AC_MSG_ERROR([can't find gee-1.0])]) | 79 | [AC_MSG_ERROR([can't find gee-0.8])]) |
668 | 80 | 80 | ||
669 | 81 | # check json-glib | 81 | # check json-glib |
670 | 82 | PKG_CHECK_MODULES([JSON_GLIB], [json-glib-1.0], , | 82 | PKG_CHECK_MODULES([JSON_GLIB], [json-glib-1.0], , |
671 | 83 | 83 | ||
672 | === modified file 'data/Makefile.am' | |||
673 | --- data/Makefile.am 2014-02-26 22:51:39 +0000 | |||
674 | +++ data/Makefile.am 2014-10-01 15:12:30 +0000 | |||
675 | @@ -1,5 +1,5 @@ | |||
678 | 1 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
679 | 2 | # Copyright (C) 2011-2013 Red Hat, Inc. | 2 | # Copyright (C) 2011-2014 Red Hat, Inc. |
680 | 3 | 3 | ||
681 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
682 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
683 | 6 | 6 | ||
684 | === modified file 'data/Makefile.in' | |||
685 | --- data/Makefile.in 2014-02-26 22:51:39 +0000 | |||
686 | +++ data/Makefile.in 2014-10-01 15:12:30 +0000 | |||
687 | @@ -14,8 +14,8 @@ | |||
688 | 14 | 14 | ||
689 | 15 | @SET_MAKE@ | 15 | @SET_MAKE@ |
690 | 16 | 16 | ||
693 | 17 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 17 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
694 | 18 | # Copyright (C) 2011-2013 Red Hat, Inc. | 18 | # Copyright (C) 2011-2014 Red Hat, Inc. |
695 | 19 | 19 | ||
696 | 20 | # This program is free software: you can redistribute it and/or modify | 20 | # This program is free software: you can redistribute it and/or modify |
697 | 21 | # it under the terms of the GNU General Public License as published by | 21 | # it under the terms of the GNU General Public License as published by |
698 | 22 | 22 | ||
699 | === modified file 'data/rules/Makefile.am' | |||
700 | --- data/rules/Makefile.am 2014-02-26 22:51:39 +0000 | |||
701 | +++ data/rules/Makefile.am 2014-10-01 15:12:30 +0000 | |||
702 | @@ -1,5 +1,5 @@ | |||
705 | 1 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
706 | 2 | # Copyright (C) 2011-2013 Red Hat, Inc. | 2 | # Copyright (C) 2011-2014 Red Hat, Inc. |
707 | 3 | 3 | ||
708 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
709 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
710 | 6 | 6 | ||
711 | === modified file 'data/rules/Makefile.in' | |||
712 | --- data/rules/Makefile.in 2014-02-26 22:51:39 +0000 | |||
713 | +++ data/rules/Makefile.in 2014-10-01 15:12:30 +0000 | |||
714 | @@ -14,8 +14,8 @@ | |||
715 | 14 | 14 | ||
716 | 15 | @SET_MAKE@ | 15 | @SET_MAKE@ |
717 | 16 | 16 | ||
720 | 17 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 17 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
721 | 18 | # Copyright (C) 2011-2013 Red Hat, Inc. | 18 | # Copyright (C) 2011-2014 Red Hat, Inc. |
722 | 19 | 19 | ||
723 | 20 | # This program is free software: you can redistribute it and/or modify | 20 | # This program is free software: you can redistribute it and/or modify |
724 | 21 | # it under the terms of the GNU General Public License as published by | 21 | # it under the terms of the GNU General Public License as published by |
725 | 22 | 22 | ||
726 | === modified file 'data/rules/README.rules' | |||
727 | --- data/rules/README.rules 2014-02-26 22:51:39 +0000 | |||
728 | +++ data/rules/README.rules 2014-10-01 15:12:30 +0000 | |||
729 | @@ -161,8 +161,8 @@ | |||
730 | 161 | for "xka" and "b.", and removes a mapping "dha" from the current map | 161 | for "xka" and "b.", and removes a mapping "dha" from the current map |
731 | 162 | file. | 162 | file. |
732 | 163 | 163 | ||
735 | 164 | Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 164 | Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
736 | 165 | Copyright (C) 2011-2013 Red Hat, Inc. | 165 | Copyright (C) 2011-2014 Red Hat, Inc. |
737 | 166 | 166 | ||
738 | 167 | This file is free software; as a special exception the author gives | 167 | This file is free software; as a special exception the author gives |
739 | 168 | unlimited permission to copy and/or distribute it, with or without | 168 | unlimited permission to copy and/or distribute it, with or without |
740 | 169 | 169 | ||
741 | === modified file 'data/rules/default/rom-kana/default.json' | |||
742 | --- data/rules/default/rom-kana/default.json 2014-02-26 22:51:39 +0000 | |||
743 | +++ data/rules/default/rom-kana/default.json 2014-10-01 15:12:30 +0000 | |||
744 | @@ -97,6 +97,11 @@ | |||
745 | 97 | "lu": ["", "ぅ"], | 97 | "lu": ["", "ぅ"], |
746 | 98 | "le": ["", "ぇ"], | 98 | "le": ["", "ぇ"], |
747 | 99 | "lo": ["", "ぉ"], | 99 | "lo": ["", "ぉ"], |
748 | 100 | "lya": ["", "ゃ"], | ||
749 | 101 | "lyi": ["", "ぃ"], | ||
750 | 102 | "lyu": ["", "ゅ"], | ||
751 | 103 | "lye": ["", "ぇ"], | ||
752 | 104 | "lyo": ["", "ょ"], | ||
753 | 100 | "kya": ["", "きゃ" ], | 105 | "kya": ["", "きゃ" ], |
754 | 101 | "kye": ["", "きぇ" ], | 106 | "kye": ["", "きぇ" ], |
755 | 102 | "kyi": ["", "きぃ" ], | 107 | "kyi": ["", "きぃ" ], |
756 | 103 | 108 | ||
757 | === modified file 'data/templates/Makefile.am' | |||
758 | --- data/templates/Makefile.am 2014-02-26 22:51:39 +0000 | |||
759 | +++ data/templates/Makefile.am 2014-10-01 15:12:30 +0000 | |||
760 | @@ -1,5 +1,5 @@ | |||
763 | 1 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
764 | 2 | # Copyright (C) 2011-2013 Red Hat, Inc. | 2 | # Copyright (C) 2011-2014 Red Hat, Inc. |
765 | 3 | 3 | ||
766 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
767 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
768 | 6 | 6 | ||
769 | === modified file 'data/templates/Makefile.in' | |||
770 | --- data/templates/Makefile.in 2014-02-26 22:51:39 +0000 | |||
771 | +++ data/templates/Makefile.in 2014-10-01 15:12:30 +0000 | |||
772 | @@ -14,8 +14,8 @@ | |||
773 | 14 | 14 | ||
774 | 15 | @SET_MAKE@ | 15 | @SET_MAKE@ |
775 | 16 | 16 | ||
778 | 17 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 17 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
779 | 18 | # Copyright (C) 2011-2013 Red Hat, Inc. | 18 | # Copyright (C) 2011-2014 Red Hat, Inc. |
780 | 19 | 19 | ||
781 | 20 | # This program is free software: you can redistribute it and/or modify | 20 | # This program is free software: you can redistribute it and/or modify |
782 | 21 | # it under the terms of the GNU General Public License as published by | 21 | # it under the terms of the GNU General Public License as published by |
783 | 22 | 22 | ||
784 | === modified file 'data/templates/libkkc-data/Makefile.am' | |||
785 | --- data/templates/libkkc-data/Makefile.am 2014-02-26 22:51:39 +0000 | |||
786 | +++ data/templates/libkkc-data/Makefile.am 2014-10-01 15:12:30 +0000 | |||
787 | @@ -1,5 +1,5 @@ | |||
790 | 1 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
791 | 2 | # Copyright (C) 2011-2013 Red Hat, Inc. | 2 | # Copyright (C) 2011-2014 Red Hat, Inc. |
792 | 3 | 3 | ||
793 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
794 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
795 | 6 | 6 | ||
796 | === modified file 'data/templates/libkkc-data/configure.ac.in' | |||
797 | --- data/templates/libkkc-data/configure.ac.in 2014-02-26 22:51:39 +0000 | |||
798 | +++ data/templates/libkkc-data/configure.ac.in 2014-10-01 15:12:30 +0000 | |||
799 | @@ -1,5 +1,5 @@ | |||
802 | 1 | # Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
803 | 2 | # Copyright (C) 2012-2013 Red Hat, Inc. | 2 | # Copyright (C) 2012-2014 Red Hat, Inc. |
804 | 3 | 3 | ||
805 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
806 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
807 | 6 | 6 | ||
808 | === modified file 'data/templates/libkkc-data/data/Makefile.am' | |||
809 | --- data/templates/libkkc-data/data/Makefile.am 2014-02-26 22:51:39 +0000 | |||
810 | +++ data/templates/libkkc-data/data/Makefile.am 2014-10-01 15:12:30 +0000 | |||
811 | @@ -1,5 +1,5 @@ | |||
814 | 1 | # Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
815 | 2 | # Copyright (C) 2012-2013 Red Hat, Inc. | 2 | # Copyright (C) 2012-2014 Red Hat, Inc. |
816 | 3 | 3 | ||
817 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
818 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
819 | 6 | 6 | ||
820 | === modified file 'data/templates/libkkc-data/data/models/Makefile.sorted2' | |||
821 | --- data/templates/libkkc-data/data/models/Makefile.sorted2 2014-02-26 22:51:39 +0000 | |||
822 | +++ data/templates/libkkc-data/data/models/Makefile.sorted2 2014-10-01 15:12:30 +0000 | |||
823 | @@ -1,5 +1,5 @@ | |||
826 | 1 | # Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
827 | 2 | # Copyright (C) 2012-2013 Red Hat, Inc. | 2 | # Copyright (C) 2012-2014 Red Hat, Inc. |
828 | 3 | 3 | ||
829 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
830 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
831 | 6 | 6 | ||
832 | === modified file 'data/templates/libkkc-data/data/models/Makefile.sorted3' | |||
833 | --- data/templates/libkkc-data/data/models/Makefile.sorted3 2014-02-26 22:51:39 +0000 | |||
834 | +++ data/templates/libkkc-data/data/models/Makefile.sorted3 2014-10-01 15:12:30 +0000 | |||
835 | @@ -1,5 +1,5 @@ | |||
838 | 1 | # Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
839 | 2 | # Copyright (C) 2012-2013 Red Hat, Inc. | 2 | # Copyright (C) 2012-2014 Red Hat, Inc. |
840 | 3 | 3 | ||
841 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
842 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
843 | 6 | 6 | ||
844 | === modified file 'data/templates/libkkc-data/tools/Makefile.am' | |||
845 | --- data/templates/libkkc-data/tools/Makefile.am 2014-02-26 22:51:39 +0000 | |||
846 | +++ data/templates/libkkc-data/tools/Makefile.am 2014-10-01 15:12:30 +0000 | |||
847 | @@ -1,5 +1,5 @@ | |||
850 | 1 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
851 | 2 | # Copyright (C) 2011-2013 Red Hat, Inc. | 2 | # Copyright (C) 2011-2014 Red Hat, Inc. |
852 | 3 | 3 | ||
853 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
854 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
855 | 6 | 6 | ||
856 | === modified file 'data/templates/libkkc-data/tools/genfilter.py' | |||
857 | --- data/templates/libkkc-data/tools/genfilter.py 2014-02-26 22:51:39 +0000 | |||
858 | +++ data/templates/libkkc-data/tools/genfilter.py 2014-10-01 15:12:30 +0000 | |||
859 | @@ -1,7 +1,7 @@ | |||
860 | 1 | #!/usr/bin/python | 1 | #!/usr/bin/python |
861 | 2 | 2 | ||
864 | 3 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 3 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
865 | 4 | # Copyright (C) 2011-2013 Red Hat, Inc. | 4 | # Copyright (C) 2011-2014 Red Hat, Inc. |
866 | 5 | 5 | ||
867 | 6 | # This program is free software: you can redistribute it and/or modify | 6 | # This program is free software: you can redistribute it and/or modify |
868 | 7 | # it under the terms of the GNU General Public License as published by | 7 | # it under the terms of the GNU General Public License as published by |
869 | 8 | 8 | ||
870 | === modified file 'data/templates/libkkc-data/tools/sortlm.py' | |||
871 | --- data/templates/libkkc-data/tools/sortlm.py 2014-02-26 22:51:39 +0000 | |||
872 | +++ data/templates/libkkc-data/tools/sortlm.py 2014-10-01 15:12:30 +0000 | |||
873 | @@ -1,7 +1,7 @@ | |||
874 | 1 | #!/usr/bin/python | 1 | #!/usr/bin/python |
875 | 2 | 2 | ||
878 | 3 | # Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 3 | # Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
879 | 4 | # Copyright (C) 2011-2013 Red Hat, Inc. | 4 | # Copyright (C) 2011-2014 Red Hat, Inc. |
880 | 5 | 5 | ||
881 | 6 | # This program is free software: you can redistribute it and/or modify | 6 | # This program is free software: you can redistribute it and/or modify |
882 | 7 | # it under the terms of the GNU General Public License as published by | 7 | # it under the terms of the GNU General Public License as published by |
883 | 8 | 8 | ||
884 | === modified file 'debian/changelog' | |||
885 | --- debian/changelog 2014-06-15 23:27:57 +0000 | |||
886 | +++ debian/changelog 2014-10-01 15:12:30 +0000 | |||
887 | @@ -1,3 +1,10 @@ | |||
888 | 1 | libkkc (0.3.4-0ubuntu1) utopic; urgency=medium | ||
889 | 2 | |||
890 | 3 | * New upstream release. | ||
891 | 4 | * Change Build-Depends from libgee-dev to libgee-0.8-dev (LP: #1374949) | ||
892 | 5 | |||
893 | 6 | -- Mitsuya Shibata <mty.shibata@gmail.com> Wed, 01 Oct 2014 23:33:01 +0900 | ||
894 | 7 | |||
895 | 1 | libkkc (0.3.3-1) unstable; urgency=medium | 8 | libkkc (0.3.3-1) unstable; urgency=medium |
896 | 2 | 9 | ||
897 | 3 | * New upstream release. | 10 | * New upstream release. |
898 | 4 | 11 | ||
899 | === modified file 'debian/control' | |||
900 | --- debian/control 2014-06-15 23:27:57 +0000 | |||
901 | +++ debian/control 2014-10-01 15:12:30 +0000 | |||
902 | @@ -1,13 +1,14 @@ | |||
903 | 1 | Source: libkkc | 1 | Source: libkkc |
904 | 2 | Priority: extra | 2 | Priority: extra |
906 | 3 | Maintainer: IME Packaging Team <pkg-ime-devel@lists.alioth.debian.org> | 3 | Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com> |
907 | 4 | XSBC-Original-Maintainer: IME Packaging Team <pkg-ime-devel@lists.alioth.debian.org> | ||
908 | 4 | Uploaders: Mitsuya Shibata <mty.shibata@gmail.com>, | 5 | Uploaders: Mitsuya Shibata <mty.shibata@gmail.com>, |
909 | 5 | Osamu Aoki <osamu@debian.org> | 6 | Osamu Aoki <osamu@debian.org> |
910 | 6 | Build-Depends: dh-autoreconf, | 7 | Build-Depends: dh-autoreconf, |
911 | 7 | debhelper (>= 9), | 8 | debhelper (>= 9), |
912 | 8 | gobject-introspection, | 9 | gobject-introspection, |
913 | 9 | intltool, | 10 | intltool, |
915 | 10 | libgee-dev, | 11 | libgee-0.8-dev, |
916 | 11 | libgirepository1.0-dev, | 12 | libgirepository1.0-dev, |
917 | 12 | libglib2.0-dev, | 13 | libglib2.0-dev, |
918 | 13 | libjson-glib-dev, | 14 | libjson-glib-dev, |
919 | 14 | 15 | ||
920 | === modified file 'docs/Makefile.am' | |||
921 | --- docs/Makefile.am 2014-06-15 23:27:57 +0000 | |||
922 | +++ docs/Makefile.am 2014-10-01 15:12:30 +0000 | |||
923 | @@ -53,7 +53,7 @@ | |||
924 | 53 | config \ | 53 | config \ |
925 | 54 | glib-2.0 \ | 54 | glib-2.0 \ |
926 | 55 | gio-2.0 \ | 55 | gio-2.0 \ |
928 | 56 | gee-1.0 \ | 56 | gee-0.8 \ |
929 | 57 | posix \ | 57 | posix \ |
930 | 58 | json-glib-1.0 \ | 58 | json-glib-1.0 \ |
931 | 59 | marisa-glib \ | 59 | marisa-glib \ |
932 | 60 | 60 | ||
933 | === modified file 'docs/Makefile.in' | |||
934 | --- docs/Makefile.in 2014-06-15 23:27:57 +0000 | |||
935 | +++ docs/Makefile.in 2014-10-01 15:12:30 +0000 | |||
936 | @@ -385,7 +385,7 @@ | |||
937 | 385 | config \ | 385 | config \ |
938 | 386 | glib-2.0 \ | 386 | glib-2.0 \ |
939 | 387 | gio-2.0 \ | 387 | gio-2.0 \ |
941 | 388 | gee-1.0 \ | 388 | gee-0.8 \ |
942 | 389 | posix \ | 389 | posix \ |
943 | 390 | json-glib-1.0 \ | 390 | json-glib-1.0 \ |
944 | 391 | marisa-glib \ | 391 | marisa-glib \ |
945 | 392 | 392 | ||
946 | === modified file 'libkkc/Kkc-1.0.gir' | |||
947 | --- libkkc/Kkc-1.0.gir 2014-06-15 23:27:57 +0000 | |||
948 | +++ libkkc/Kkc-1.0.gir 2014-10-01 15:12:30 +0000 | |||
949 | @@ -3,7 +3,7 @@ | |||
950 | 3 | <include name="GObject" version="2.0"/> | 3 | <include name="GObject" version="2.0"/> |
951 | 4 | <include name="Gio" version="2.0"/> | 4 | <include name="Gio" version="2.0"/> |
952 | 5 | <include name="Json" version="1.0"/> | 5 | <include name="Json" version="1.0"/> |
954 | 6 | <include name="Gee" version="1.0"/> | 6 | <include name="Gee" version="0.8"/> |
955 | 7 | <package name="kkc-1.0"/> | 7 | <package name="kkc-1.0"/> |
956 | 8 | <c:include name="libkkc/libkkc.h"/> | 8 | <c:include name="libkkc/libkkc.h"/> |
957 | 9 | <namespace name="Kkc" version="1.0" c:prefix="Kkc"> | 9 | <namespace name="Kkc" version="1.0" c:prefix="Kkc"> |
958 | @@ -8592,7 +8592,7 @@ | |||
959 | 8592 | <parameter name="type" transfer-ownership="none" allow-none="1"> | 8592 | <parameter name="type" transfer-ownership="none" allow-none="1"> |
960 | 8593 | <type name="GObject.Type" c:type="GType*"/> | 8593 | <type name="GObject.Type" c:type="GType*"/> |
961 | 8594 | </parameter> | 8594 | </parameter> |
963 | 8595 | <parameter name="callback" transfer-ownership="none" closure="2"> | 8595 | <parameter name="callback" transfer-ownership="none" closure="2" scope="call"> |
964 | 8596 | <type name="Kkc.DictionaryListDictionaryCallback" c:type="KkcDictionaryListDictionaryCallback"/> | 8596 | <type name="Kkc.DictionaryListDictionaryCallback" c:type="KkcDictionaryListDictionaryCallback"/> |
965 | 8597 | </parameter> | 8597 | </parameter> |
966 | 8598 | <parameter name="callback_target" transfer-ownership="none" allow-none="1"> | 8598 | <parameter name="callback_target" transfer-ownership="none" allow-none="1"> |
967 | 8599 | 8599 | ||
968 | === modified file 'libkkc/Makefile.am' | |||
969 | --- libkkc/Makefile.am 2014-06-15 23:27:57 +0000 | |||
970 | +++ libkkc/Makefile.am 2014-10-01 15:12:30 +0000 | |||
971 | @@ -1,5 +1,5 @@ | |||
974 | 1 | # Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 1 | # Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
975 | 2 | # Copyright (C) 2012-2013 Red Hat, Inc. | 2 | # Copyright (C) 2012-2014 Red Hat, Inc. |
976 | 3 | 3 | ||
977 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
978 | 5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
979 | @@ -31,7 +31,7 @@ | |||
980 | 31 | --pkg keysyms \ | 31 | --pkg keysyms \ |
981 | 32 | --pkg glib-2.0 \ | 32 | --pkg glib-2.0 \ |
982 | 33 | --pkg gio-2.0 \ | 33 | --pkg gio-2.0 \ |
984 | 34 | --pkg gee-1.0 \ | 34 | --pkg gee-0.8 \ |
985 | 35 | --pkg json-glib-1.0 \ | 35 | --pkg json-glib-1.0 \ |
986 | 36 | --pkg marisa-glib \ | 36 | --pkg marisa-glib \ |
987 | 37 | --internal-vapi kkc-internals-@KKC_API_VERSION@.vapi \ | 37 | --internal-vapi kkc-internals-@KKC_API_VERSION@.vapi \ |
988 | 38 | 38 | ||
989 | === modified file 'libkkc/Makefile.in' | |||
990 | --- libkkc/Makefile.in 2014-06-15 23:27:57 +0000 | |||
991 | +++ libkkc/Makefile.in 2014-10-01 15:12:30 +0000 | |||
992 | @@ -14,8 +14,8 @@ | |||
993 | 14 | 14 | ||
994 | 15 | @SET_MAKE@ | 15 | @SET_MAKE@ |
995 | 16 | 16 | ||
998 | 17 | # Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 17 | # Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
999 | 18 | # Copyright (C) 2012-2013 Red Hat, Inc. | 18 | # Copyright (C) 2012-2014 Red Hat, Inc. |
1000 | 19 | 19 | ||
1001 | 20 | # This program is free software: you can redistribute it and/or modify | 20 | # This program is free software: you can redistribute it and/or modify |
1002 | 21 | # it under the terms of the GNU General Public License as published by | 21 | # it under the terms of the GNU General Public License as published by |
1003 | @@ -485,7 +485,7 @@ | |||
1004 | 485 | --pkg keysyms \ | 485 | --pkg keysyms \ |
1005 | 486 | --pkg glib-2.0 \ | 486 | --pkg glib-2.0 \ |
1006 | 487 | --pkg gio-2.0 \ | 487 | --pkg gio-2.0 \ |
1008 | 488 | --pkg gee-1.0 \ | 488 | --pkg gee-0.8 \ |
1009 | 489 | --pkg json-glib-1.0 \ | 489 | --pkg json-glib-1.0 \ |
1010 | 490 | --pkg marisa-glib \ | 490 | --pkg marisa-glib \ |
1011 | 491 | --internal-vapi kkc-internals-@KKC_API_VERSION@.vapi \ | 491 | --internal-vapi kkc-internals-@KKC_API_VERSION@.vapi \ |
1012 | 492 | 492 | ||
1013 | === modified file 'libkkc/bigram-decoder.c' | |||
1014 | --- libkkc/bigram-decoder.c 2014-06-15 23:27:57 +0000 | |||
1015 | +++ libkkc/bigram-decoder.c 2014-10-01 15:12:30 +0000 | |||
1016 | @@ -1,9 +1,9 @@ | |||
1018 | 1 | /* bigram-decoder.c generated by valac 0.22.1, the Vala compiler | 1 | /* bigram-decoder.c generated by valac 0.24.0.131-42e78, the Vala compiler |
1019 | 2 | * generated from bigram-decoder.vala, do not modify */ | 2 | * generated from bigram-decoder.vala, do not modify */ |
1020 | 3 | 3 | ||
1021 | 4 | /* | 4 | /* |
1024 | 5 | * Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
1025 | 6 | * Copyright (C) 2012-2013 Red Hat, Inc. | 6 | * Copyright (C) 2012-2014 Red Hat, Inc. |
1026 | 7 | * | 7 | * |
1027 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
1028 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
1029 | @@ -290,6 +290,7 @@ | |||
1030 | 290 | KkcSegment* kkc_segment_construct (GType object_type, const gchar* input, const gchar* output); | 290 | KkcSegment* kkc_segment_construct (GType object_type, const gchar* input, const gchar* output); |
1031 | 291 | static gboolean _kkc_language_model_entry_equal (const KkcLanguageModelEntry* s1, const KkcLanguageModelEntry* s2); | 291 | static gboolean _kkc_language_model_entry_equal (const KkcLanguageModelEntry* s1, const KkcLanguageModelEntry* s2); |
1032 | 292 | static gint kkc_bigram_decoder_compare_nbest_node (KkcNbestNode* a, KkcNbestNode* b); | 292 | static gint kkc_bigram_decoder_compare_nbest_node (KkcNbestNode* a, KkcNbestNode* b); |
1033 | 293 | static gint _kkc_bigram_decoder_compare_nbest_node_gcompare_data_func (gconstpointer a, gconstpointer b, gpointer self); | ||
1034 | 293 | static gchar* kkc_bigram_decoder_concat_nbest_node_outputs (KkcBigramDecoder* self, KkcNbestNode* nbest_node); | 294 | static gchar* kkc_bigram_decoder_concat_nbest_node_outputs (KkcBigramDecoder* self, KkcNbestNode* nbest_node); |
1035 | 294 | guint kkc_trellis_node_get_endpos (KkcTrellisNode* self); | 295 | guint kkc_trellis_node_get_endpos (KkcTrellisNode* self); |
1036 | 295 | const gchar* kkc_trellis_node_get_output (KkcTrellisNode* self); | 296 | const gchar* kkc_trellis_node_get_output (KkcTrellisNode* self); |
1037 | @@ -438,15 +439,13 @@ | |||
1038 | 438 | 439 | ||
1039 | 439 | static void kkc_nbest_node_class_init (KkcNbestNodeClass * klass) { | 440 | static void kkc_nbest_node_class_init (KkcNbestNodeClass * klass) { |
1040 | 440 | kkc_nbest_node_parent_class = g_type_class_peek_parent (klass); | 441 | kkc_nbest_node_parent_class = g_type_class_peek_parent (klass); |
1042 | 441 | KKC_NBEST_NODE_CLASS (klass)->finalize = kkc_nbest_node_finalize; | 442 | ((KkcNbestNodeClass *) klass)->finalize = kkc_nbest_node_finalize; |
1043 | 442 | } | 443 | } |
1044 | 443 | 444 | ||
1045 | 444 | 445 | ||
1046 | 445 | static void kkc_nbest_node_instance_init (KkcNbestNode * self) { | 446 | static void kkc_nbest_node_instance_init (KkcNbestNode * self) { |
1047 | 446 | gdouble _tmp0_ = 0.0; | ||
1048 | 447 | self->gn = 0.0; | 447 | self->gn = 0.0; |
1051 | 448 | _tmp0_ = DBL_MAX; | 448 | self->fn = DBL_MAX; |
1050 | 449 | self->fn = _tmp0_; | ||
1052 | 450 | self->ref_count = 1; | 449 | self->ref_count = 1; |
1053 | 451 | } | 450 | } |
1054 | 452 | 451 | ||
1055 | @@ -454,6 +453,7 @@ | |||
1056 | 454 | static void kkc_nbest_node_finalize (KkcNbestNode* obj) { | 453 | static void kkc_nbest_node_finalize (KkcNbestNode* obj) { |
1057 | 455 | KkcNbestNode * self; | 454 | KkcNbestNode * self; |
1058 | 456 | self = G_TYPE_CHECK_INSTANCE_CAST (obj, KKC_TYPE_NBEST_NODE, KkcNbestNode); | 455 | self = G_TYPE_CHECK_INSTANCE_CAST (obj, KKC_TYPE_NBEST_NODE, KkcNbestNode); |
1059 | 456 | g_signal_handlers_destroy (self); | ||
1060 | 457 | _kkc_trellis_node_unref0 (self->node); | 457 | _kkc_trellis_node_unref0 (self->node); |
1061 | 458 | _kkc_nbest_node_unref0 (self->next); | 458 | _kkc_nbest_node_unref0 (self->next); |
1062 | 459 | } | 459 | } |
1063 | @@ -498,27 +498,23 @@ | |||
1064 | 498 | gint _tmp1_ = 0; | 498 | gint _tmp1_ = 0; |
1065 | 499 | gint* _tmp2_ = NULL; | 499 | gint* _tmp2_ = NULL; |
1066 | 500 | gint _tmp2__length1 = 0; | 500 | gint _tmp2__length1 = 0; |
1073 | 501 | gdouble _tmp3_ = 0.0; | 501 | gint _tmp3_ = 0; |
1074 | 502 | gdouble _tmp4_ = 0.0; | 502 | KkcSegment** _tmp4_ = NULL; |
1075 | 503 | gint _tmp5_ = 0; | 503 | KkcSegment** _tmp5_ = NULL; |
1076 | 504 | KkcSegment** _tmp6_ = NULL; | 504 | gint _tmp5__length1 = 0; |
1071 | 505 | KkcSegment** _tmp7_ = NULL; | ||
1072 | 506 | gint _tmp7__length1 = 0; | ||
1077 | 507 | self = (KkcBigramDecoder*) base; | 505 | self = (KkcBigramDecoder*) base; |
1078 | 508 | g_return_val_if_fail (input != NULL, NULL); | 506 | g_return_val_if_fail (input != NULL, NULL); |
1079 | 509 | _tmp0_ = input; | 507 | _tmp0_ = input; |
1080 | 510 | _tmp1_ = nbest; | 508 | _tmp1_ = nbest; |
1081 | 511 | _tmp2_ = constraint; | 509 | _tmp2_ = constraint; |
1082 | 512 | _tmp2__length1 = constraint_length1; | 510 | _tmp2__length1 = constraint_length1; |
1088 | 513 | _tmp3_ = DBL_MAX; | 511 | _tmp4_ = kkc_decoder_decode_with_costs ((KkcDecoder*) self, _tmp0_, _tmp1_, _tmp2_, _tmp2__length1, DBL_MAX, -DBL_MAX, &_tmp3_); |
1089 | 514 | _tmp4_ = DBL_MAX; | 512 | _tmp5_ = _tmp4_; |
1090 | 515 | _tmp6_ = kkc_decoder_decode_with_costs ((KkcDecoder*) self, _tmp0_, _tmp1_, _tmp2_, _tmp2__length1, _tmp3_, -_tmp4_, &_tmp5_); | 513 | _tmp5__length1 = _tmp3_; |
1086 | 516 | _tmp7_ = _tmp6_; | ||
1087 | 517 | _tmp7__length1 = _tmp5_; | ||
1091 | 518 | if (result_length1) { | 514 | if (result_length1) { |
1093 | 519 | *result_length1 = _tmp7__length1; | 515 | *result_length1 = _tmp5__length1; |
1094 | 520 | } | 516 | } |
1096 | 521 | result = _tmp7_; | 517 | result = _tmp5_; |
1097 | 522 | return result; | 518 | return result; |
1098 | 523 | } | 519 | } |
1099 | 524 | 520 | ||
1100 | @@ -552,8 +548,8 @@ | |||
1101 | 552 | KkcSegment** _tmp14_ = NULL; | 548 | KkcSegment** _tmp14_ = NULL; |
1102 | 553 | gint segments_length1 = 0; | 549 | gint segments_length1 = 0; |
1103 | 554 | gint _segments_size_ = 0; | 550 | gint _segments_size_ = 0; |
1106 | 555 | KkcSegment** _tmp23_ = NULL; | 551 | KkcSegment** _tmp22_ = NULL; |
1107 | 556 | gint _tmp23__length1 = 0; | 552 | gint _tmp22__length1 = 0; |
1108 | 557 | self = (KkcBigramDecoder*) base; | 553 | self = (KkcBigramDecoder*) base; |
1109 | 558 | g_return_val_if_fail (input != NULL, NULL); | 554 | g_return_val_if_fail (input != NULL, NULL); |
1110 | 559 | _tmp0_ = input; | 555 | _tmp0_ = input; |
1111 | @@ -589,41 +585,39 @@ | |||
1112 | 589 | gboolean _tmp15_ = FALSE; | 585 | gboolean _tmp15_ = FALSE; |
1113 | 590 | _tmp15_ = TRUE; | 586 | _tmp15_ = TRUE; |
1114 | 591 | while (TRUE) { | 587 | while (TRUE) { |
1117 | 592 | gboolean _tmp16_ = FALSE; | 588 | gint _tmp17_ = 0; |
1118 | 593 | gint _tmp18_ = 0; | 589 | GeeArrayList** _tmp18_ = NULL; |
1119 | 590 | gint _tmp18__length1 = 0; | ||
1120 | 594 | GeeArrayList** _tmp19_ = NULL; | 591 | GeeArrayList** _tmp19_ = NULL; |
1121 | 595 | gint _tmp19__length1 = 0; | 592 | gint _tmp19__length1 = 0; |
1131 | 596 | GeeArrayList** _tmp20_ = NULL; | 593 | gint _tmp20_ = 0; |
1132 | 597 | gint _tmp20__length1 = 0; | 594 | GeeArrayList* _tmp21_ = NULL; |
1133 | 598 | gint _tmp21_ = 0; | 595 | if (!_tmp15_) { |
1134 | 599 | GeeArrayList* _tmp22_ = NULL; | 596 | gint _tmp16_ = 0; |
1135 | 600 | _tmp16_ = _tmp15_; | 597 | _tmp16_ = i; |
1136 | 601 | if (!_tmp16_) { | 598 | i = _tmp16_ + 1; |
1128 | 602 | gint _tmp17_ = 0; | ||
1129 | 603 | _tmp17_ = i; | ||
1130 | 604 | i = _tmp17_ + 1; | ||
1137 | 605 | } | 599 | } |
1138 | 606 | _tmp15_ = FALSE; | 600 | _tmp15_ = FALSE; |
1140 | 607 | _tmp18_ = i; | 601 | _tmp17_ = i; |
1141 | 602 | _tmp18_ = trellis; | ||
1142 | 603 | _tmp18__length1 = trellis_length1; | ||
1143 | 604 | if (!(_tmp17_ < _tmp18__length1)) { | ||
1144 | 605 | break; | ||
1145 | 606 | } | ||
1146 | 608 | _tmp19_ = trellis; | 607 | _tmp19_ = trellis; |
1147 | 609 | _tmp19__length1 = trellis_length1; | 608 | _tmp19__length1 = trellis_length1; |
1156 | 610 | if (!(_tmp18_ < _tmp19__length1)) { | 609 | _tmp20_ = i; |
1157 | 611 | break; | 610 | _tmp21_ = _tmp19_[_tmp20_]; |
1158 | 612 | } | 611 | gee_abstract_collection_clear ((GeeAbstractCollection*) _tmp21_); |
1151 | 613 | _tmp20_ = trellis; | ||
1152 | 614 | _tmp20__length1 = trellis_length1; | ||
1153 | 615 | _tmp21_ = i; | ||
1154 | 616 | _tmp22_ = _tmp20_[_tmp21_]; | ||
1155 | 617 | gee_abstract_collection_clear ((GeeAbstractCollection*) _tmp22_); | ||
1159 | 618 | } | 612 | } |
1160 | 619 | } | 613 | } |
1161 | 620 | } | 614 | } |
1164 | 621 | _tmp23_ = segments; | 615 | _tmp22_ = segments; |
1165 | 622 | _tmp23__length1 = segments_length1; | 616 | _tmp22__length1 = segments_length1; |
1166 | 623 | if (result_length1) { | 617 | if (result_length1) { |
1168 | 624 | *result_length1 = _tmp23__length1; | 618 | *result_length1 = _tmp22__length1; |
1169 | 625 | } | 619 | } |
1171 | 626 | result = _tmp23_; | 620 | result = _tmp22_; |
1172 | 627 | trellis = (_vala_array_free (trellis, trellis_length1, (GDestroyNotify) g_object_unref), NULL); | 621 | trellis = (_vala_array_free (trellis, trellis_length1, (GDestroyNotify) g_object_unref), NULL); |
1173 | 628 | return result; | 622 | return result; |
1174 | 629 | } | 623 | } |
1175 | @@ -674,15 +668,14 @@ | |||
1176 | 674 | glong string_length = 0L; | 668 | glong string_length = 0L; |
1177 | 675 | gboolean _tmp0_ = FALSE; | 669 | gboolean _tmp0_ = FALSE; |
1178 | 676 | glong _tmp1_ = 0L; | 670 | glong _tmp1_ = 0L; |
1182 | 677 | gboolean _tmp3_ = FALSE; | 671 | glong _tmp8_ = 0L; |
1183 | 678 | glong _tmp9_ = 0L; | 672 | glong _tmp14_ = 0L; |
1184 | 679 | glong _tmp15_ = 0L; | 673 | glong _tmp17_ = 0L; |
1185 | 680 | glong _tmp18_ = 0L; | 674 | glong _tmp18_ = 0L; |
1186 | 681 | glong _tmp19_ = 0L; | 675 | glong _tmp19_ = 0L; |
1187 | 682 | glong _tmp20_ = 0L; | 676 | glong _tmp20_ = 0L; |
1188 | 683 | glong _tmp21_ = 0L; | 677 | glong _tmp21_ = 0L; |
1191 | 684 | glong _tmp22_ = 0L; | 678 | gchar* _tmp22_ = NULL; |
1190 | 685 | gchar* _tmp23_ = NULL; | ||
1192 | 686 | g_return_val_if_fail (self != NULL, NULL); | 679 | g_return_val_if_fail (self != NULL, NULL); |
1193 | 687 | _tmp1_ = offset; | 680 | _tmp1_ = offset; |
1194 | 688 | if (_tmp1_ >= ((glong) 0)) { | 681 | if (_tmp1_ >= ((glong) 0)) { |
1195 | @@ -692,55 +685,54 @@ | |||
1196 | 692 | } else { | 685 | } else { |
1197 | 693 | _tmp0_ = FALSE; | 686 | _tmp0_ = FALSE; |
1198 | 694 | } | 687 | } |
1201 | 695 | _tmp3_ = _tmp0_; | 688 | if (_tmp0_) { |
1202 | 696 | if (_tmp3_) { | 689 | glong _tmp3_ = 0L; |
1203 | 697 | glong _tmp4_ = 0L; | 690 | glong _tmp4_ = 0L; |
1204 | 698 | glong _tmp5_ = 0L; | 691 | glong _tmp5_ = 0L; |
1210 | 699 | glong _tmp6_ = 0L; | 692 | _tmp3_ = offset; |
1211 | 700 | _tmp4_ = offset; | 693 | _tmp4_ = len; |
1212 | 701 | _tmp5_ = len; | 694 | _tmp5_ = string_strnlen ((gchar*) self, _tmp3_ + _tmp4_); |
1213 | 702 | _tmp6_ = string_strnlen ((gchar*) self, _tmp4_ + _tmp5_); | 695 | string_length = _tmp5_; |
1209 | 703 | string_length = _tmp6_; | ||
1214 | 704 | } else { | 696 | } else { |
1215 | 697 | gint _tmp6_ = 0; | ||
1216 | 705 | gint _tmp7_ = 0; | 698 | gint _tmp7_ = 0; |
1221 | 706 | gint _tmp8_ = 0; | 699 | _tmp6_ = strlen (self); |
1222 | 707 | _tmp7_ = strlen (self); | 700 | _tmp7_ = _tmp6_; |
1223 | 708 | _tmp8_ = _tmp7_; | 701 | string_length = (glong) _tmp7_; |
1220 | 709 | string_length = (glong) _tmp8_; | ||
1224 | 710 | } | 702 | } |
1227 | 711 | _tmp9_ = offset; | 703 | _tmp8_ = offset; |
1228 | 712 | if (_tmp9_ < ((glong) 0)) { | 704 | if (_tmp8_ < ((glong) 0)) { |
1229 | 705 | glong _tmp9_ = 0L; | ||
1230 | 713 | glong _tmp10_ = 0L; | 706 | glong _tmp10_ = 0L; |
1231 | 714 | glong _tmp11_ = 0L; | 707 | glong _tmp11_ = 0L; |
1232 | 708 | _tmp9_ = string_length; | ||
1233 | 709 | _tmp10_ = offset; | ||
1234 | 710 | offset = _tmp9_ + _tmp10_; | ||
1235 | 711 | _tmp11_ = offset; | ||
1236 | 712 | g_return_val_if_fail (_tmp11_ >= ((glong) 0), NULL); | ||
1237 | 713 | } else { | ||
1238 | 715 | glong _tmp12_ = 0L; | 714 | glong _tmp12_ = 0L; |
1242 | 716 | _tmp10_ = string_length; | 715 | glong _tmp13_ = 0L; |
1240 | 717 | _tmp11_ = offset; | ||
1241 | 718 | offset = _tmp10_ + _tmp11_; | ||
1243 | 719 | _tmp12_ = offset; | 716 | _tmp12_ = offset; |
1251 | 720 | g_return_val_if_fail (_tmp12_ >= ((glong) 0), NULL); | 717 | _tmp13_ = string_length; |
1252 | 721 | } else { | 718 | g_return_val_if_fail (_tmp12_ <= _tmp13_, NULL); |
1246 | 722 | glong _tmp13_ = 0L; | ||
1247 | 723 | glong _tmp14_ = 0L; | ||
1248 | 724 | _tmp13_ = offset; | ||
1249 | 725 | _tmp14_ = string_length; | ||
1250 | 726 | g_return_val_if_fail (_tmp13_ <= _tmp14_, NULL); | ||
1253 | 727 | } | 719 | } |
1256 | 728 | _tmp15_ = len; | 720 | _tmp14_ = len; |
1257 | 729 | if (_tmp15_ < ((glong) 0)) { | 721 | if (_tmp14_ < ((glong) 0)) { |
1258 | 722 | glong _tmp15_ = 0L; | ||
1259 | 730 | glong _tmp16_ = 0L; | 723 | glong _tmp16_ = 0L; |
1264 | 731 | glong _tmp17_ = 0L; | 724 | _tmp15_ = string_length; |
1265 | 732 | _tmp16_ = string_length; | 725 | _tmp16_ = offset; |
1266 | 733 | _tmp17_ = offset; | 726 | len = _tmp15_ - _tmp16_; |
1263 | 734 | len = _tmp16_ - _tmp17_; | ||
1267 | 735 | } | 727 | } |
1276 | 736 | _tmp18_ = offset; | 728 | _tmp17_ = offset; |
1277 | 737 | _tmp19_ = len; | 729 | _tmp18_ = len; |
1278 | 738 | _tmp20_ = string_length; | 730 | _tmp19_ = string_length; |
1279 | 739 | g_return_val_if_fail ((_tmp18_ + _tmp19_) <= _tmp20_, NULL); | 731 | g_return_val_if_fail ((_tmp17_ + _tmp18_) <= _tmp19_, NULL); |
1280 | 740 | _tmp21_ = offset; | 732 | _tmp20_ = offset; |
1281 | 741 | _tmp22_ = len; | 733 | _tmp21_ = len; |
1282 | 742 | _tmp23_ = g_strndup (((gchar*) self) + _tmp21_, (gsize) _tmp22_); | 734 | _tmp22_ = g_strndup (((gchar*) self) + _tmp20_, (gsize) _tmp21_); |
1283 | 743 | result = _tmp23_; | 735 | result = _tmp22_; |
1284 | 744 | return result; | 736 | return result; |
1285 | 745 | } | 737 | } |
1286 | 746 | 738 | ||
1287 | @@ -755,145 +747,139 @@ | |||
1288 | 755 | gboolean _tmp0_ = FALSE; | 747 | gboolean _tmp0_ = FALSE; |
1289 | 756 | _tmp0_ = TRUE; | 748 | _tmp0_ = TRUE; |
1290 | 757 | while (TRUE) { | 749 | while (TRUE) { |
1300 | 758 | gboolean _tmp1_ = FALSE; | 750 | gint _tmp2_ = 0; |
1301 | 759 | gint _tmp3_ = 0; | 751 | GeeArrayList** _tmp3_ = NULL; |
1302 | 760 | GeeArrayList** _tmp4_ = NULL; | 752 | gint _tmp3__length1 = 0; |
1303 | 761 | gint _tmp4__length1 = 0; | 753 | if (!_tmp0_) { |
1304 | 762 | _tmp1_ = _tmp0_; | 754 | gint _tmp1_ = 0; |
1305 | 763 | if (!_tmp1_) { | 755 | _tmp1_ = i; |
1306 | 764 | gint _tmp2_ = 0; | 756 | i = _tmp1_ + 1; |
1298 | 765 | _tmp2_ = i; | ||
1299 | 766 | i = _tmp2_ + 1; | ||
1307 | 767 | } | 757 | } |
1308 | 768 | _tmp0_ = FALSE; | 758 | _tmp0_ = FALSE; |
1313 | 769 | _tmp3_ = i; | 759 | _tmp2_ = i; |
1314 | 770 | _tmp4_ = trellis; | 760 | _tmp3_ = trellis; |
1315 | 771 | _tmp4__length1 = trellis_length1; | 761 | _tmp3__length1 = trellis_length1; |
1316 | 772 | if (!(_tmp3_ < _tmp4__length1)) { | 762 | if (!(_tmp2_ < _tmp3__length1)) { |
1317 | 773 | break; | 763 | break; |
1318 | 774 | } | 764 | } |
1319 | 775 | { | 765 | { |
1320 | 776 | gint j = 0; | 766 | gint j = 0; |
1324 | 777 | gint _tmp5_ = 0; | 767 | gint _tmp4_ = 0; |
1325 | 778 | _tmp5_ = i; | 768 | _tmp4_ = i; |
1326 | 779 | j = _tmp5_; | 769 | j = _tmp4_; |
1327 | 780 | { | 770 | { |
1330 | 781 | gboolean _tmp6_ = FALSE; | 771 | gboolean _tmp5_ = FALSE; |
1331 | 782 | _tmp6_ = TRUE; | 772 | _tmp5_ = TRUE; |
1332 | 783 | while (TRUE) { | 773 | while (TRUE) { |
1333 | 784 | gboolean _tmp7_ = FALSE; | 774 | gboolean _tmp7_ = FALSE; |
1342 | 785 | gboolean _tmp9_ = FALSE; | 775 | gint _tmp8_ = 0; |
1343 | 786 | gint _tmp10_ = 0; | 776 | GeeArrayList** _tmp9_ = NULL; |
1344 | 787 | GeeArrayList** _tmp11_ = NULL; | 777 | gint _tmp9__length1 = 0; |
1345 | 788 | gint _tmp11__length1 = 0; | 778 | gint* _tmp15_ = NULL; |
1346 | 789 | gboolean _tmp17_ = FALSE; | 779 | gint _tmp15__length1 = 0; |
1347 | 790 | gint* _tmp18_ = NULL; | 780 | gint _tmp16_ = 0; |
1348 | 791 | gint _tmp18__length1 = 0; | 781 | gint _tmp17_ = 0; |
1349 | 792 | gint _tmp19_ = 0; | 782 | gboolean _tmp18_ = FALSE; |
1350 | 783 | glong offset = 0L; | ||
1351 | 784 | const gchar* _tmp19_ = NULL; | ||
1352 | 793 | gint _tmp20_ = 0; | 785 | gint _tmp20_ = 0; |
1355 | 794 | gboolean _tmp21_ = FALSE; | 786 | gint _tmp21_ = 0; |
1356 | 795 | glong offset = 0L; | 787 | glong length = 0L; |
1357 | 796 | const gchar* _tmp22_ = NULL; | 788 | const gchar* _tmp22_ = NULL; |
1358 | 797 | gint _tmp23_ = 0; | 789 | gint _tmp23_ = 0; |
1359 | 798 | gint _tmp24_ = 0; | 790 | gint _tmp24_ = 0; |
1364 | 799 | glong length = 0L; | 791 | glong _tmp25_ = 0L; |
1365 | 800 | const gchar* _tmp25_ = NULL; | 792 | gchar* _input = NULL; |
1366 | 801 | gint _tmp26_ = 0; | 793 | const gchar* _tmp26_ = NULL; |
1367 | 802 | gint _tmp27_ = 0; | 794 | glong _tmp27_ = 0L; |
1368 | 803 | glong _tmp28_ = 0L; | 795 | glong _tmp28_ = 0L; |
1374 | 804 | gchar* _input = NULL; | 796 | gchar* _tmp29_ = NULL; |
1370 | 805 | const gchar* _tmp29_ = NULL; | ||
1371 | 806 | glong _tmp30_ = 0L; | ||
1372 | 807 | glong _tmp31_ = 0L; | ||
1373 | 808 | gchar* _tmp32_ = NULL; | ||
1375 | 809 | KkcLanguageModelEntry entry = {0}; | 797 | KkcLanguageModelEntry entry = {0}; |
1381 | 810 | const gchar* _tmp33_ = NULL; | 798 | const gchar* _tmp30_ = NULL; |
1382 | 811 | gchar* _tmp34_ = NULL; | 799 | gchar* _tmp31_ = NULL; |
1383 | 812 | const gchar* _tmp35_ = NULL; | 800 | const gchar* _tmp32_ = NULL; |
1384 | 813 | gchar* _tmp36_ = NULL; | 801 | gchar* _tmp33_ = NULL; |
1385 | 814 | KkcLanguageModelEntry _tmp37_ = {0}; | 802 | KkcLanguageModelEntry _tmp34_ = {0}; |
1386 | 815 | KkcUnigramTrellisNode* node = NULL; | 803 | KkcUnigramTrellisNode* node = NULL; |
1388 | 816 | KkcLanguageModelEntry _tmp38_ = {0}; | 804 | KkcLanguageModelEntry _tmp35_ = {0}; |
1389 | 805 | gint _tmp36_ = 0; | ||
1390 | 806 | KkcUnigramTrellisNode* _tmp37_ = NULL; | ||
1391 | 807 | GeeArrayList** _tmp38_ = NULL; | ||
1392 | 808 | gint _tmp38__length1 = 0; | ||
1393 | 817 | gint _tmp39_ = 0; | 809 | gint _tmp39_ = 0; |
1401 | 818 | KkcUnigramTrellisNode* _tmp40_ = NULL; | 810 | GeeArrayList* _tmp40_ = NULL; |
1402 | 819 | GeeArrayList** _tmp41_ = NULL; | 811 | KkcUnigramTrellisNode* _tmp41_ = NULL; |
1403 | 820 | gint _tmp41__length1 = 0; | 812 | if (!_tmp5_) { |
1404 | 821 | gint _tmp42_ = 0; | 813 | gint _tmp6_ = 0; |
1405 | 822 | GeeArrayList* _tmp43_ = NULL; | 814 | _tmp6_ = j; |
1406 | 823 | KkcUnigramTrellisNode* _tmp44_ = NULL; | 815 | j = _tmp6_ + 1; |
1407 | 824 | _tmp7_ = _tmp6_; | 816 | } |
1408 | 817 | _tmp5_ = FALSE; | ||
1409 | 818 | _tmp8_ = j; | ||
1410 | 819 | _tmp9_ = trellis; | ||
1411 | 820 | _tmp9__length1 = trellis_length1; | ||
1412 | 821 | if (_tmp8_ < _tmp9__length1) { | ||
1413 | 822 | GeeArrayList** _tmp10_ = NULL; | ||
1414 | 823 | gint _tmp10__length1 = 0; | ||
1415 | 824 | gint _tmp11_ = 0; | ||
1416 | 825 | GeeArrayList* _tmp12_ = NULL; | ||
1417 | 826 | gboolean _tmp13_ = FALSE; | ||
1418 | 827 | gboolean _tmp14_ = FALSE; | ||
1419 | 828 | _tmp10_ = trellis; | ||
1420 | 829 | _tmp10__length1 = trellis_length1; | ||
1421 | 830 | _tmp11_ = j; | ||
1422 | 831 | _tmp12_ = _tmp10_[_tmp11_]; | ||
1423 | 832 | _tmp13_ = gee_collection_get_is_empty ((GeeCollection*) _tmp12_); | ||
1424 | 833 | _tmp14_ = _tmp13_; | ||
1425 | 834 | _tmp7_ = _tmp14_; | ||
1426 | 835 | } else { | ||
1427 | 836 | _tmp7_ = FALSE; | ||
1428 | 837 | } | ||
1429 | 825 | if (!_tmp7_) { | 838 | if (!_tmp7_) { |
1430 | 826 | gint _tmp8_ = 0; | ||
1431 | 827 | _tmp8_ = j; | ||
1432 | 828 | j = _tmp8_ + 1; | ||
1433 | 829 | } | ||
1434 | 830 | _tmp6_ = FALSE; | ||
1435 | 831 | _tmp10_ = j; | ||
1436 | 832 | _tmp11_ = trellis; | ||
1437 | 833 | _tmp11__length1 = trellis_length1; | ||
1438 | 834 | if (_tmp10_ < _tmp11__length1) { | ||
1439 | 835 | GeeArrayList** _tmp12_ = NULL; | ||
1440 | 836 | gint _tmp12__length1 = 0; | ||
1441 | 837 | gint _tmp13_ = 0; | ||
1442 | 838 | GeeArrayList* _tmp14_ = NULL; | ||
1443 | 839 | gboolean _tmp15_ = FALSE; | ||
1444 | 840 | gboolean _tmp16_ = FALSE; | ||
1445 | 841 | _tmp12_ = trellis; | ||
1446 | 842 | _tmp12__length1 = trellis_length1; | ||
1447 | 843 | _tmp13_ = j; | ||
1448 | 844 | _tmp14_ = _tmp12_[_tmp13_]; | ||
1449 | 845 | _tmp15_ = gee_abstract_collection_get_is_empty ((GeeAbstractCollection*) _tmp14_); | ||
1450 | 846 | _tmp16_ = _tmp15_; | ||
1451 | 847 | _tmp9_ = _tmp16_; | ||
1452 | 848 | } else { | ||
1453 | 849 | _tmp9_ = FALSE; | ||
1454 | 850 | } | ||
1455 | 851 | _tmp17_ = _tmp9_; | ||
1456 | 852 | if (!_tmp17_) { | ||
1457 | 853 | break; | 839 | break; |
1458 | 854 | } | 840 | } |
1465 | 855 | _tmp18_ = constraint; | 841 | _tmp15_ = constraint; |
1466 | 856 | _tmp18__length1 = constraint_length1; | 842 | _tmp15__length1 = constraint_length1; |
1467 | 857 | _tmp19_ = i; | 843 | _tmp16_ = i; |
1468 | 858 | _tmp20_ = j; | 844 | _tmp17_ = j; |
1469 | 859 | _tmp21_ = kkc_bigram_decoder_check_overlaps (self, _tmp18_, _tmp18__length1, _tmp19_, _tmp20_); | 845 | _tmp18_ = kkc_bigram_decoder_check_overlaps (self, _tmp15_, _tmp15__length1, _tmp16_, _tmp17_); |
1470 | 860 | if (!_tmp21_) { | 846 | if (!_tmp18_) { |
1471 | 861 | continue; | 847 | continue; |
1472 | 862 | } | 848 | } |
1473 | 849 | _tmp19_ = input; | ||
1474 | 850 | _tmp20_ = i; | ||
1475 | 851 | _tmp21_ = string_index_of_nth_char (_tmp19_, (glong) (_tmp20_ - 1)); | ||
1476 | 852 | offset = (glong) _tmp21_; | ||
1477 | 863 | _tmp22_ = input; | 853 | _tmp22_ = input; |
1502 | 864 | _tmp23_ = i; | 854 | _tmp23_ = j; |
1503 | 865 | _tmp24_ = string_index_of_nth_char (_tmp22_, (glong) (_tmp23_ - 1)); | 855 | _tmp24_ = string_index_of_nth_char (_tmp22_, (glong) _tmp23_); |
1504 | 866 | offset = (glong) _tmp24_; | 856 | _tmp25_ = offset; |
1505 | 867 | _tmp25_ = input; | 857 | length = _tmp24_ - _tmp25_; |
1506 | 868 | _tmp26_ = j; | 858 | _tmp26_ = input; |
1507 | 869 | _tmp27_ = string_index_of_nth_char (_tmp25_, (glong) _tmp26_); | 859 | _tmp27_ = offset; |
1508 | 870 | _tmp28_ = offset; | 860 | _tmp28_ = length; |
1509 | 871 | length = _tmp27_ - _tmp28_; | 861 | _tmp29_ = string_substring (_tmp26_, _tmp27_, _tmp28_); |
1510 | 872 | _tmp29_ = input; | 862 | _input = _tmp29_; |
1511 | 873 | _tmp30_ = offset; | 863 | _tmp30_ = _input; |
1512 | 874 | _tmp31_ = length; | 864 | _tmp31_ = g_strdup (_tmp30_); |
1513 | 875 | _tmp32_ = string_substring (_tmp29_, _tmp30_, _tmp31_); | 865 | _tmp32_ = _input; |
1514 | 876 | _input = _tmp32_; | 866 | _tmp33_ = g_strdup (_tmp32_); |
1515 | 877 | _tmp33_ = _input; | 867 | _g_free0 (_tmp34_.input); |
1516 | 878 | _tmp34_ = g_strdup (_tmp33_); | 868 | _tmp34_.input = _tmp31_; |
1517 | 879 | _tmp35_ = _input; | 869 | _g_free0 (_tmp34_.output); |
1518 | 880 | _tmp36_ = g_strdup (_tmp35_); | 870 | _tmp34_.output = _tmp33_; |
1519 | 881 | _g_free0 (_tmp37_.input); | 871 | _tmp34_.id = (guint) 2; |
1520 | 882 | _tmp37_.input = _tmp34_; | 872 | entry = _tmp34_; |
1521 | 883 | _g_free0 (_tmp37_.output); | 873 | _tmp35_ = entry; |
1522 | 884 | _tmp37_.output = _tmp36_; | 874 | _tmp36_ = j; |
1523 | 885 | _tmp37_.id = (guint) 2; | 875 | _tmp37_ = kkc_unigram_trellis_node_new (&_tmp35_, (guint) _tmp36_); |
1524 | 886 | entry = _tmp37_; | 876 | node = _tmp37_; |
1525 | 887 | _tmp38_ = entry; | 877 | _tmp38_ = trellis; |
1526 | 878 | _tmp38__length1 = trellis_length1; | ||
1527 | 888 | _tmp39_ = j; | 879 | _tmp39_ = j; |
1536 | 889 | _tmp40_ = kkc_unigram_trellis_node_new (&_tmp38_, (guint) _tmp39_); | 880 | _tmp40_ = _tmp38_[_tmp39_]; |
1537 | 890 | node = _tmp40_; | 881 | _tmp41_ = node; |
1538 | 891 | _tmp41_ = trellis; | 882 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp40_, (KkcTrellisNode*) _tmp41_); |
1531 | 892 | _tmp41__length1 = trellis_length1; | ||
1532 | 893 | _tmp42_ = j; | ||
1533 | 894 | _tmp43_ = _tmp41_[_tmp42_]; | ||
1534 | 895 | _tmp44_ = node; | ||
1535 | 896 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp43_, (KkcTrellisNode*) _tmp44_); | ||
1539 | 897 | _kkc_trellis_node_unref0 (node); | 883 | _kkc_trellis_node_unref0 (node); |
1540 | 898 | kkc_language_model_entry_destroy (&entry); | 884 | kkc_language_model_entry_destroy (&entry); |
1541 | 899 | _g_free0 (_input); | 885 | _g_free0 (_input); |
1542 | @@ -917,29 +903,29 @@ | |||
1543 | 917 | gint trellis_length1 = 0; | 903 | gint trellis_length1 = 0; |
1544 | 918 | gint _trellis_size_ = 0; | 904 | gint _trellis_size_ = 0; |
1545 | 919 | KkcUnigramTrellisNode* bos_node = NULL; | 905 | KkcUnigramTrellisNode* bos_node = NULL; |
1546 | 906 | KkcBigramLanguageModel* _tmp12_ = NULL; | ||
1547 | 920 | KkcBigramLanguageModel* _tmp13_ = NULL; | 907 | KkcBigramLanguageModel* _tmp13_ = NULL; |
1549 | 921 | KkcBigramLanguageModel* _tmp14_ = NULL; | 908 | KkcLanguageModelEntry _tmp14_ = {0}; |
1550 | 922 | KkcLanguageModelEntry _tmp15_ = {0}; | 909 | KkcLanguageModelEntry _tmp15_ = {0}; |
1557 | 923 | KkcLanguageModelEntry _tmp16_ = {0}; | 910 | KkcUnigramTrellisNode* _tmp16_ = NULL; |
1558 | 924 | KkcUnigramTrellisNode* _tmp17_ = NULL; | 911 | GeeArrayList** _tmp17_ = NULL; |
1559 | 925 | GeeArrayList** _tmp18_ = NULL; | 912 | gint _tmp17__length1 = 0; |
1560 | 926 | gint _tmp18__length1 = 0; | 913 | GeeArrayList* _tmp18_ = NULL; |
1561 | 927 | GeeArrayList* _tmp19_ = NULL; | 914 | KkcUnigramTrellisNode* _tmp19_ = NULL; |
1556 | 928 | KkcUnigramTrellisNode* _tmp20_ = NULL; | ||
1562 | 929 | KkcUnigramTrellisNode* eos_node = NULL; | 915 | KkcUnigramTrellisNode* eos_node = NULL; |
1563 | 916 | KkcBigramLanguageModel* _tmp20_ = NULL; | ||
1564 | 930 | KkcBigramLanguageModel* _tmp21_ = NULL; | 917 | KkcBigramLanguageModel* _tmp21_ = NULL; |
1566 | 931 | KkcBigramLanguageModel* _tmp22_ = NULL; | 918 | KkcLanguageModelEntry _tmp22_ = {0}; |
1567 | 932 | KkcLanguageModelEntry _tmp23_ = {0}; | 919 | KkcLanguageModelEntry _tmp23_ = {0}; |
1578 | 933 | KkcLanguageModelEntry _tmp24_ = {0}; | 920 | gint _tmp24_ = 0; |
1579 | 934 | gint _tmp25_ = 0; | 921 | KkcUnigramTrellisNode* _tmp25_ = NULL; |
1580 | 935 | KkcUnigramTrellisNode* _tmp26_ = NULL; | 922 | GeeArrayList** _tmp26_ = NULL; |
1581 | 936 | GeeArrayList** _tmp27_ = NULL; | 923 | gint _tmp26__length1 = 0; |
1582 | 937 | gint _tmp27__length1 = 0; | 924 | gint _tmp27_ = 0; |
1583 | 938 | gint _tmp28_ = 0; | 925 | GeeArrayList* _tmp28_ = NULL; |
1584 | 939 | GeeArrayList* _tmp29_ = NULL; | 926 | KkcUnigramTrellisNode* _tmp29_ = NULL; |
1585 | 940 | KkcUnigramTrellisNode* _tmp30_ = NULL; | 927 | GeeArrayList** _tmp66_ = NULL; |
1586 | 941 | GeeArrayList** _tmp68_ = NULL; | 928 | gint _tmp66__length1 = 0; |
1577 | 942 | gint _tmp68__length1 = 0; | ||
1587 | 943 | g_return_val_if_fail (self != NULL, NULL); | 929 | g_return_val_if_fail (self != NULL, NULL); |
1588 | 944 | g_return_val_if_fail (input != NULL, NULL); | 930 | g_return_val_if_fail (input != NULL, NULL); |
1589 | 945 | _tmp0_ = input; | 931 | _tmp0_ = input; |
1590 | @@ -957,176 +943,172 @@ | |||
1591 | 957 | gboolean _tmp4_ = FALSE; | 943 | gboolean _tmp4_ = FALSE; |
1592 | 958 | _tmp4_ = TRUE; | 944 | _tmp4_ = TRUE; |
1593 | 959 | while (TRUE) { | 945 | while (TRUE) { |
1596 | 960 | gboolean _tmp5_ = FALSE; | 946 | gint _tmp6_ = 0; |
1597 | 961 | gint _tmp7_ = 0; | 947 | GeeArrayList** _tmp7_ = NULL; |
1598 | 948 | gint _tmp7__length1 = 0; | ||
1599 | 962 | GeeArrayList** _tmp8_ = NULL; | 949 | GeeArrayList** _tmp8_ = NULL; |
1600 | 963 | gint _tmp8__length1 = 0; | 950 | gint _tmp8__length1 = 0; |
1604 | 964 | GeeArrayList** _tmp9_ = NULL; | 951 | gint _tmp9_ = 0; |
1605 | 965 | gint _tmp9__length1 = 0; | 952 | GeeArrayList* _tmp10_ = NULL; |
1603 | 966 | gint _tmp10_ = 0; | ||
1606 | 967 | GeeArrayList* _tmp11_ = NULL; | 953 | GeeArrayList* _tmp11_ = NULL; |
1613 | 968 | GeeArrayList* _tmp12_ = NULL; | 954 | if (!_tmp4_) { |
1614 | 969 | _tmp5_ = _tmp4_; | 955 | gint _tmp5_ = 0; |
1615 | 970 | if (!_tmp5_) { | 956 | _tmp5_ = i; |
1616 | 971 | gint _tmp6_ = 0; | 957 | i = _tmp5_ + 1; |
1611 | 972 | _tmp6_ = i; | ||
1612 | 973 | i = _tmp6_ + 1; | ||
1617 | 974 | } | 958 | } |
1618 | 975 | _tmp4_ = FALSE; | 959 | _tmp4_ = FALSE; |
1620 | 976 | _tmp7_ = i; | 960 | _tmp6_ = i; |
1621 | 961 | _tmp7_ = trellis; | ||
1622 | 962 | _tmp7__length1 = trellis_length1; | ||
1623 | 963 | if (!(_tmp6_ < _tmp7__length1)) { | ||
1624 | 964 | break; | ||
1625 | 965 | } | ||
1626 | 977 | _tmp8_ = trellis; | 966 | _tmp8_ = trellis; |
1627 | 978 | _tmp8__length1 = trellis_length1; | 967 | _tmp8__length1 = trellis_length1; |
1638 | 979 | if (!(_tmp7_ < _tmp8__length1)) { | 968 | _tmp9_ = i; |
1639 | 980 | break; | 969 | _tmp10_ = gee_array_list_new (KKC_TYPE_TRELLIS_NODE, (GBoxedCopyFunc) kkc_trellis_node_ref, kkc_trellis_node_unref, NULL, NULL, NULL); |
1640 | 981 | } | 970 | _g_object_unref0 (_tmp8_[_tmp9_]); |
1641 | 982 | _tmp9_ = trellis; | 971 | _tmp8_[_tmp9_] = _tmp10_; |
1642 | 983 | _tmp9__length1 = trellis_length1; | 972 | _tmp11_ = _tmp8_[_tmp9_]; |
1633 | 984 | _tmp10_ = i; | ||
1634 | 985 | _tmp11_ = gee_array_list_new (KKC_TYPE_TRELLIS_NODE, (GBoxedCopyFunc) kkc_trellis_node_ref, kkc_trellis_node_unref, NULL); | ||
1635 | 986 | _g_object_unref0 (_tmp9_[_tmp10_]); | ||
1636 | 987 | _tmp9_[_tmp10_] = _tmp11_; | ||
1637 | 988 | _tmp12_ = _tmp9_[_tmp10_]; | ||
1643 | 989 | } | 973 | } |
1644 | 990 | } | 974 | } |
1645 | 991 | } | 975 | } |
1670 | 992 | _tmp13_ = kkc_bigram_decoder_get_model (self); | 976 | _tmp12_ = kkc_bigram_decoder_get_model (self); |
1671 | 993 | _tmp14_ = _tmp13_; | 977 | _tmp13_ = _tmp12_; |
1672 | 994 | kkc_language_model_get_bos ((KkcLanguageModel*) _tmp14_, &_tmp15_); | 978 | kkc_language_model_get_bos ((KkcLanguageModel*) _tmp13_, &_tmp14_); |
1673 | 995 | _tmp16_ = _tmp15_; | 979 | _tmp15_ = _tmp14_; |
1674 | 996 | _tmp17_ = kkc_unigram_trellis_node_new (&_tmp16_, (guint) 1); | 980 | _tmp16_ = kkc_unigram_trellis_node_new (&_tmp15_, (guint) 1); |
1675 | 997 | bos_node = _tmp17_; | 981 | bos_node = _tmp16_; |
1676 | 998 | _tmp18_ = trellis; | 982 | _tmp17_ = trellis; |
1677 | 999 | _tmp18__length1 = trellis_length1; | 983 | _tmp17__length1 = trellis_length1; |
1678 | 1000 | _tmp19_ = _tmp18_[0]; | 984 | _tmp18_ = _tmp17_[0]; |
1679 | 1001 | _tmp20_ = bos_node; | 985 | _tmp19_ = bos_node; |
1680 | 1002 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp19_, (KkcTrellisNode*) _tmp20_); | 986 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp18_, (KkcTrellisNode*) _tmp19_); |
1681 | 1003 | _tmp21_ = kkc_bigram_decoder_get_model (self); | 987 | _tmp20_ = kkc_bigram_decoder_get_model (self); |
1682 | 1004 | _tmp22_ = _tmp21_; | 988 | _tmp21_ = _tmp20_; |
1683 | 1005 | kkc_language_model_get_eos ((KkcLanguageModel*) _tmp22_, &_tmp23_); | 989 | kkc_language_model_get_eos ((KkcLanguageModel*) _tmp21_, &_tmp22_); |
1684 | 1006 | _tmp24_ = _tmp23_; | 990 | _tmp23_ = _tmp22_; |
1685 | 1007 | _tmp25_ = length; | 991 | _tmp24_ = length; |
1686 | 1008 | _tmp26_ = kkc_unigram_trellis_node_new (&_tmp24_, (guint) (_tmp25_ + 1)); | 992 | _tmp25_ = kkc_unigram_trellis_node_new (&_tmp23_, (guint) (_tmp24_ + 1)); |
1687 | 1009 | eos_node = _tmp26_; | 993 | eos_node = _tmp25_; |
1688 | 1010 | _tmp27_ = trellis; | 994 | _tmp26_ = trellis; |
1689 | 1011 | _tmp27__length1 = trellis_length1; | 995 | _tmp26__length1 = trellis_length1; |
1690 | 1012 | _tmp28_ = length; | 996 | _tmp27_ = length; |
1691 | 1013 | _tmp29_ = _tmp27_[_tmp28_ + 1]; | 997 | _tmp28_ = _tmp26_[_tmp27_ + 1]; |
1692 | 1014 | _tmp30_ = eos_node; | 998 | _tmp29_ = eos_node; |
1693 | 1015 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp29_, (KkcTrellisNode*) _tmp30_); | 999 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp28_, (KkcTrellisNode*) _tmp29_); |
1694 | 1016 | { | 1000 | { |
1695 | 1017 | gint i = 0; | 1001 | gint i = 0; |
1696 | 1018 | i = 0; | 1002 | i = 0; |
1697 | 1019 | { | 1003 | { |
1700 | 1020 | gboolean _tmp31_ = FALSE; | 1004 | gboolean _tmp30_ = FALSE; |
1701 | 1021 | _tmp31_ = TRUE; | 1005 | _tmp30_ = TRUE; |
1702 | 1022 | while (TRUE) { | 1006 | while (TRUE) { |
1705 | 1023 | gboolean _tmp32_ = FALSE; | 1007 | gint _tmp32_ = 0; |
1706 | 1024 | gint _tmp34_ = 0; | 1008 | gint _tmp33_ = 0; |
1707 | 1009 | glong byte_offset = 0L; | ||
1708 | 1010 | const gchar* _tmp34_ = NULL; | ||
1709 | 1025 | gint _tmp35_ = 0; | 1011 | gint _tmp35_ = 0; |
1714 | 1026 | glong byte_offset = 0L; | 1012 | gint _tmp36_ = 0; |
1711 | 1027 | const gchar* _tmp36_ = NULL; | ||
1712 | 1028 | gint _tmp37_ = 0; | ||
1713 | 1029 | gint _tmp38_ = 0; | ||
1715 | 1030 | gchar* _input = NULL; | 1013 | gchar* _input = NULL; |
1719 | 1031 | const gchar* _tmp39_ = NULL; | 1014 | const gchar* _tmp37_ = NULL; |
1720 | 1032 | glong _tmp40_ = 0L; | 1015 | glong _tmp38_ = 0L; |
1721 | 1033 | gchar* _tmp41_ = NULL; | 1016 | gchar* _tmp39_ = NULL; |
1722 | 1034 | GeeCollection* entries = NULL; | 1017 | GeeCollection* entries = NULL; |
1732 | 1035 | KkcBigramLanguageModel* _tmp42_ = NULL; | 1018 | KkcBigramLanguageModel* _tmp40_ = NULL; |
1733 | 1036 | KkcBigramLanguageModel* _tmp43_ = NULL; | 1019 | KkcBigramLanguageModel* _tmp41_ = NULL; |
1734 | 1037 | const gchar* _tmp44_ = NULL; | 1020 | const gchar* _tmp42_ = NULL; |
1735 | 1038 | GeeCollection* _tmp45_ = NULL; | 1021 | GeeCollection* _tmp43_ = NULL; |
1736 | 1039 | _tmp32_ = _tmp31_; | 1022 | if (!_tmp30_) { |
1737 | 1040 | if (!_tmp32_) { | 1023 | gint _tmp31_ = 0; |
1738 | 1041 | gint _tmp33_ = 0; | 1024 | _tmp31_ = i; |
1739 | 1042 | _tmp33_ = i; | 1025 | i = _tmp31_ + 1; |
1731 | 1043 | i = _tmp33_ + 1; | ||
1740 | 1044 | } | 1026 | } |
1745 | 1045 | _tmp31_ = FALSE; | 1027 | _tmp30_ = FALSE; |
1746 | 1046 | _tmp34_ = i; | 1028 | _tmp32_ = i; |
1747 | 1047 | _tmp35_ = length; | 1029 | _tmp33_ = length; |
1748 | 1048 | if (!(_tmp34_ < _tmp35_)) { | 1030 | if (!(_tmp32_ < _tmp33_)) { |
1749 | 1049 | break; | 1031 | break; |
1750 | 1050 | } | 1032 | } |
1764 | 1051 | _tmp36_ = input; | 1033 | _tmp34_ = input; |
1765 | 1052 | _tmp37_ = i; | 1034 | _tmp35_ = i; |
1766 | 1053 | _tmp38_ = string_index_of_nth_char (_tmp36_, (glong) _tmp37_); | 1035 | _tmp36_ = string_index_of_nth_char (_tmp34_, (glong) _tmp35_); |
1767 | 1054 | byte_offset = (glong) _tmp38_; | 1036 | byte_offset = (glong) _tmp36_; |
1768 | 1055 | _tmp39_ = input; | 1037 | _tmp37_ = input; |
1769 | 1056 | _tmp40_ = byte_offset; | 1038 | _tmp38_ = byte_offset; |
1770 | 1057 | _tmp41_ = string_substring (_tmp39_, _tmp40_, (glong) (-1)); | 1039 | _tmp39_ = string_substring (_tmp37_, _tmp38_, (glong) (-1)); |
1771 | 1058 | _input = _tmp41_; | 1040 | _input = _tmp39_; |
1772 | 1059 | _tmp42_ = kkc_bigram_decoder_get_model (self); | 1041 | _tmp40_ = kkc_bigram_decoder_get_model (self); |
1773 | 1060 | _tmp43_ = _tmp42_; | 1042 | _tmp41_ = _tmp40_; |
1774 | 1061 | _tmp44_ = _input; | 1043 | _tmp42_ = _input; |
1775 | 1062 | _tmp45_ = kkc_language_model_entries ((KkcLanguageModel*) _tmp43_, _tmp44_); | 1044 | _tmp43_ = kkc_language_model_entries ((KkcLanguageModel*) _tmp41_, _tmp42_); |
1776 | 1063 | entries = _tmp45_; | 1045 | entries = _tmp43_; |
1777 | 1064 | { | 1046 | { |
1778 | 1065 | GeeIterator* _entry_it = NULL; | 1047 | GeeIterator* _entry_it = NULL; |
1784 | 1066 | GeeCollection* _tmp46_ = NULL; | 1048 | GeeCollection* _tmp44_ = NULL; |
1785 | 1067 | GeeIterator* _tmp47_ = NULL; | 1049 | GeeIterator* _tmp45_ = NULL; |
1786 | 1068 | _tmp46_ = entries; | 1050 | _tmp44_ = entries; |
1787 | 1069 | _tmp47_ = gee_iterable_iterator ((GeeIterable*) _tmp46_); | 1051 | _tmp45_ = gee_iterable_iterator ((GeeIterable*) _tmp44_); |
1788 | 1070 | _entry_it = _tmp47_; | 1052 | _entry_it = _tmp45_; |
1789 | 1071 | while (TRUE) { | 1053 | while (TRUE) { |
1790 | 1054 | GeeIterator* _tmp46_ = NULL; | ||
1791 | 1055 | gboolean _tmp47_ = FALSE; | ||
1792 | 1056 | KkcLanguageModelEntry* entry = NULL; | ||
1793 | 1072 | GeeIterator* _tmp48_ = NULL; | 1057 | GeeIterator* _tmp48_ = NULL; |
1798 | 1073 | gboolean _tmp49_ = FALSE; | 1058 | gpointer _tmp49_ = NULL; |
1795 | 1074 | KkcLanguageModelEntry* entry = NULL; | ||
1796 | 1075 | GeeIterator* _tmp50_ = NULL; | ||
1797 | 1076 | gpointer _tmp51_ = NULL; | ||
1799 | 1077 | gint j = 0; | 1059 | gint j = 0; |
1803 | 1078 | gint _tmp52_ = 0; | 1060 | gint _tmp50_ = 0; |
1804 | 1079 | KkcLanguageModelEntry* _tmp53_ = NULL; | 1061 | KkcLanguageModelEntry* _tmp51_ = NULL; |
1805 | 1080 | const gchar* _tmp54_ = NULL; | 1062 | const gchar* _tmp52_ = NULL; |
1806 | 1063 | gint _tmp53_ = 0; | ||
1807 | 1064 | gint* _tmp54_ = NULL; | ||
1808 | 1065 | gint _tmp54__length1 = 0; | ||
1809 | 1081 | gint _tmp55_ = 0; | 1066 | gint _tmp55_ = 0; |
1815 | 1082 | gint* _tmp56_ = NULL; | 1067 | gint _tmp56_ = 0; |
1816 | 1083 | gint _tmp56__length1 = 0; | 1068 | gboolean _tmp57_ = FALSE; |
1812 | 1084 | gint _tmp57_ = 0; | ||
1813 | 1085 | gint _tmp58_ = 0; | ||
1814 | 1086 | gboolean _tmp59_ = FALSE; | ||
1817 | 1087 | KkcUnigramTrellisNode* node = NULL; | 1069 | KkcUnigramTrellisNode* node = NULL; |
1827 | 1088 | KkcLanguageModelEntry* _tmp60_ = NULL; | 1070 | KkcLanguageModelEntry* _tmp58_ = NULL; |
1828 | 1089 | gint _tmp61_ = 0; | 1071 | gint _tmp59_ = 0; |
1829 | 1090 | KkcLanguageModelEntry _tmp62_ = {0}; | 1072 | KkcLanguageModelEntry _tmp60_ = {0}; |
1830 | 1091 | KkcUnigramTrellisNode* _tmp63_ = NULL; | 1073 | KkcUnigramTrellisNode* _tmp61_ = NULL; |
1831 | 1092 | GeeArrayList** _tmp64_ = NULL; | 1074 | GeeArrayList** _tmp62_ = NULL; |
1832 | 1093 | gint _tmp64__length1 = 0; | 1075 | gint _tmp62__length1 = 0; |
1833 | 1094 | gint _tmp65_ = 0; | 1076 | gint _tmp63_ = 0; |
1834 | 1095 | GeeArrayList* _tmp66_ = NULL; | 1077 | GeeArrayList* _tmp64_ = NULL; |
1835 | 1096 | KkcUnigramTrellisNode* _tmp67_ = NULL; | 1078 | KkcUnigramTrellisNode* _tmp65_ = NULL; |
1836 | 1079 | _tmp46_ = _entry_it; | ||
1837 | 1080 | _tmp47_ = gee_iterator_next (_tmp46_); | ||
1838 | 1081 | if (!_tmp47_) { | ||
1839 | 1082 | break; | ||
1840 | 1083 | } | ||
1841 | 1097 | _tmp48_ = _entry_it; | 1084 | _tmp48_ = _entry_it; |
1860 | 1098 | _tmp49_ = gee_iterator_next (_tmp48_); | 1085 | _tmp49_ = gee_iterator_get (_tmp48_); |
1861 | 1099 | if (!_tmp49_) { | 1086 | entry = (KkcLanguageModelEntry*) _tmp49_; |
1862 | 1100 | break; | 1087 | _tmp50_ = i; |
1863 | 1101 | } | 1088 | _tmp51_ = entry; |
1864 | 1102 | _tmp50_ = _entry_it; | 1089 | _tmp52_ = (*_tmp51_).input; |
1865 | 1103 | _tmp51_ = gee_iterator_get (_tmp50_); | 1090 | _tmp53_ = g_utf8_strlen (_tmp52_, (gssize) (-1)); |
1866 | 1104 | entry = (KkcLanguageModelEntry*) _tmp51_; | 1091 | j = _tmp50_ + _tmp53_; |
1867 | 1105 | _tmp52_ = i; | 1092 | _tmp54_ = constraint; |
1868 | 1106 | _tmp53_ = entry; | 1093 | _tmp54__length1 = constraint_length1; |
1869 | 1107 | _tmp54_ = (*_tmp53_).input; | 1094 | _tmp55_ = i; |
1870 | 1108 | _tmp55_ = g_utf8_strlen (_tmp54_, (gssize) (-1)); | 1095 | _tmp56_ = j; |
1871 | 1109 | j = _tmp52_ + _tmp55_; | 1096 | _tmp57_ = kkc_bigram_decoder_check_constraint (self, _tmp54_, _tmp54__length1, _tmp55_, _tmp56_); |
1872 | 1110 | _tmp56_ = constraint; | 1097 | if (!_tmp57_) { |
1855 | 1111 | _tmp56__length1 = constraint_length1; | ||
1856 | 1112 | _tmp57_ = i; | ||
1857 | 1113 | _tmp58_ = j; | ||
1858 | 1114 | _tmp59_ = kkc_bigram_decoder_check_constraint (self, _tmp56_, _tmp56__length1, _tmp57_, _tmp58_); | ||
1859 | 1115 | if (!_tmp59_) { | ||
1873 | 1116 | _kkc_language_model_entry_free0 (entry); | 1098 | _kkc_language_model_entry_free0 (entry); |
1874 | 1117 | continue; | 1099 | continue; |
1875 | 1118 | } | 1100 | } |
1887 | 1119 | _tmp60_ = entry; | 1101 | _tmp58_ = entry; |
1888 | 1120 | _tmp61_ = j; | 1102 | _tmp59_ = j; |
1889 | 1121 | _tmp62_ = *_tmp60_; | 1103 | _tmp60_ = *_tmp58_; |
1890 | 1122 | _tmp63_ = kkc_unigram_trellis_node_new (&_tmp62_, (guint) _tmp61_); | 1104 | _tmp61_ = kkc_unigram_trellis_node_new (&_tmp60_, (guint) _tmp59_); |
1891 | 1123 | node = _tmp63_; | 1105 | node = _tmp61_; |
1892 | 1124 | _tmp64_ = trellis; | 1106 | _tmp62_ = trellis; |
1893 | 1125 | _tmp64__length1 = trellis_length1; | 1107 | _tmp62__length1 = trellis_length1; |
1894 | 1126 | _tmp65_ = j; | 1108 | _tmp63_ = j; |
1895 | 1127 | _tmp66_ = _tmp64_[_tmp65_]; | 1109 | _tmp64_ = _tmp62_[_tmp63_]; |
1896 | 1128 | _tmp67_ = node; | 1110 | _tmp65_ = node; |
1897 | 1129 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp66_, (KkcTrellisNode*) _tmp67_); | 1111 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp64_, (KkcTrellisNode*) _tmp65_); |
1898 | 1130 | _kkc_trellis_node_unref0 (node); | 1112 | _kkc_trellis_node_unref0 (node); |
1899 | 1131 | _kkc_language_model_entry_free0 (entry); | 1113 | _kkc_language_model_entry_free0 (entry); |
1900 | 1132 | } | 1114 | } |
1901 | @@ -1137,12 +1119,12 @@ | |||
1902 | 1137 | } | 1119 | } |
1903 | 1138 | } | 1120 | } |
1904 | 1139 | } | 1121 | } |
1907 | 1140 | _tmp68_ = trellis; | 1122 | _tmp66_ = trellis; |
1908 | 1141 | _tmp68__length1 = trellis_length1; | 1123 | _tmp66__length1 = trellis_length1; |
1909 | 1142 | if (result_length1) { | 1124 | if (result_length1) { |
1911 | 1143 | *result_length1 = _tmp68__length1; | 1125 | *result_length1 = _tmp66__length1; |
1912 | 1144 | } | 1126 | } |
1914 | 1145 | result = _tmp68_; | 1127 | result = _tmp66_; |
1915 | 1146 | _kkc_trellis_node_unref0 (eos_node); | 1128 | _kkc_trellis_node_unref0 (eos_node); |
1916 | 1147 | _kkc_trellis_node_unref0 (bos_node); | 1129 | _kkc_trellis_node_unref0 (bos_node); |
1917 | 1148 | return result; | 1130 | return result; |
1918 | @@ -1154,8 +1136,8 @@ | |||
1919 | 1154 | gint last_c = 0; | 1136 | gint last_c = 0; |
1920 | 1155 | gint* _tmp0_ = NULL; | 1137 | gint* _tmp0_ = NULL; |
1921 | 1156 | gint _tmp0__length1 = 0; | 1138 | gint _tmp0__length1 = 0; |
1922 | 1139 | gint _tmp7_ = 0; | ||
1923 | 1157 | gint _tmp8_ = 0; | 1140 | gint _tmp8_ = 0; |
1924 | 1158 | gint _tmp9_ = 0; | ||
1925 | 1159 | g_return_val_if_fail (self != NULL, FALSE); | 1141 | g_return_val_if_fail (self != NULL, FALSE); |
1926 | 1160 | last_c = 0; | 1142 | last_c = 0; |
1927 | 1161 | _tmp0_ = constraint; | 1143 | _tmp0_ = constraint; |
1928 | @@ -1174,8 +1156,7 @@ | |||
1929 | 1174 | gboolean _tmp1_ = FALSE; | 1156 | gboolean _tmp1_ = FALSE; |
1930 | 1175 | gint _tmp2_ = 0; | 1157 | gint _tmp2_ = 0; |
1931 | 1176 | gint _tmp3_ = 0; | 1158 | gint _tmp3_ = 0; |
1934 | 1177 | gboolean _tmp6_ = FALSE; | 1159 | gint _tmp6_ = 0; |
1933 | 1178 | gint _tmp7_ = 0; | ||
1935 | 1179 | _tmp2_ = i; | 1160 | _tmp2_ = i; |
1936 | 1180 | _tmp3_ = last_c; | 1161 | _tmp3_ = last_c; |
1937 | 1181 | if (_tmp2_ == _tmp3_) { | 1162 | if (_tmp2_ == _tmp3_) { |
1938 | @@ -1187,19 +1168,18 @@ | |||
1939 | 1187 | } else { | 1168 | } else { |
1940 | 1188 | _tmp1_ = FALSE; | 1169 | _tmp1_ = FALSE; |
1941 | 1189 | } | 1170 | } |
1944 | 1190 | _tmp6_ = _tmp1_; | 1171 | if (_tmp1_) { |
1943 | 1191 | if (_tmp6_) { | ||
1945 | 1192 | result = TRUE; | 1172 | result = TRUE; |
1946 | 1193 | return result; | 1173 | return result; |
1947 | 1194 | } | 1174 | } |
1950 | 1195 | _tmp7_ = c; | 1175 | _tmp6_ = c; |
1951 | 1196 | last_c = _tmp7_; | 1176 | last_c = _tmp6_; |
1952 | 1197 | } | 1177 | } |
1953 | 1198 | } | 1178 | } |
1954 | 1199 | } | 1179 | } |
1958 | 1200 | _tmp8_ = i; | 1180 | _tmp7_ = i; |
1959 | 1201 | _tmp9_ = last_c; | 1181 | _tmp8_ = last_c; |
1960 | 1202 | result = _tmp8_ >= _tmp9_; | 1182 | result = _tmp7_ >= _tmp8_; |
1961 | 1203 | return result; | 1183 | return result; |
1962 | 1204 | } | 1184 | } |
1963 | 1205 | 1185 | ||
1964 | @@ -1209,8 +1189,8 @@ | |||
1965 | 1209 | gint last_c = 0; | 1189 | gint last_c = 0; |
1966 | 1210 | gint* _tmp0_ = NULL; | 1190 | gint* _tmp0_ = NULL; |
1967 | 1211 | gint _tmp0__length1 = 0; | 1191 | gint _tmp0__length1 = 0; |
1970 | 1212 | gint _tmp16_ = 0; | 1192 | gint _tmp13_ = 0; |
1971 | 1213 | gint _tmp17_ = 0; | 1193 | gint _tmp14_ = 0; |
1972 | 1214 | g_return_val_if_fail (self != NULL, FALSE); | 1194 | g_return_val_if_fail (self != NULL, FALSE); |
1973 | 1215 | last_c = 0; | 1195 | last_c = 0; |
1974 | 1216 | _tmp0_ = constraint; | 1196 | _tmp0_ = constraint; |
1975 | @@ -1230,9 +1210,7 @@ | |||
1976 | 1230 | gboolean _tmp2_ = FALSE; | 1210 | gboolean _tmp2_ = FALSE; |
1977 | 1231 | gint _tmp3_ = 0; | 1211 | gint _tmp3_ = 0; |
1978 | 1232 | gint _tmp4_ = 0; | 1212 | gint _tmp4_ = 0; |
1982 | 1233 | gboolean _tmp7_ = FALSE; | 1213 | gint _tmp12_ = 0; |
1980 | 1234 | gboolean _tmp14_ = FALSE; | ||
1981 | 1235 | gint _tmp15_ = 0; | ||
1983 | 1236 | _tmp3_ = last_c; | 1214 | _tmp3_ = last_c; |
1984 | 1237 | _tmp4_ = i; | 1215 | _tmp4_ = i; |
1985 | 1238 | if (_tmp3_ <= _tmp4_) { | 1216 | if (_tmp3_ <= _tmp4_) { |
1986 | @@ -1244,41 +1222,37 @@ | |||
1987 | 1244 | } else { | 1222 | } else { |
1988 | 1245 | _tmp2_ = FALSE; | 1223 | _tmp2_ = FALSE; |
1989 | 1246 | } | 1224 | } |
1993 | 1247 | _tmp7_ = _tmp2_; | 1225 | if (_tmp2_) { |
1994 | 1248 | if (_tmp7_) { | 1226 | gboolean _tmp7_ = FALSE; |
1995 | 1249 | gboolean _tmp8_ = FALSE; | 1227 | gint _tmp8_ = 0; |
1996 | 1250 | gint _tmp9_ = 0; | 1228 | gint _tmp9_ = 0; |
2002 | 1251 | gint _tmp10_ = 0; | 1229 | _tmp8_ = last_c; |
2003 | 1252 | gboolean _tmp13_ = FALSE; | 1230 | _tmp9_ = j; |
2004 | 1253 | _tmp9_ = last_c; | 1231 | if (_tmp8_ <= _tmp9_) { |
2005 | 1254 | _tmp10_ = j; | 1232 | gint _tmp10_ = 0; |
2001 | 1255 | if (_tmp9_ <= _tmp10_) { | ||
2006 | 1256 | gint _tmp11_ = 0; | 1233 | gint _tmp11_ = 0; |
2011 | 1257 | gint _tmp12_ = 0; | 1234 | _tmp10_ = j; |
2012 | 1258 | _tmp11_ = j; | 1235 | _tmp11_ = c; |
2013 | 1259 | _tmp12_ = c; | 1236 | _tmp7_ = _tmp10_ <= _tmp11_; |
2010 | 1260 | _tmp8_ = _tmp11_ <= _tmp12_; | ||
2014 | 1261 | } else { | 1237 | } else { |
2016 | 1262 | _tmp8_ = FALSE; | 1238 | _tmp7_ = FALSE; |
2017 | 1263 | } | 1239 | } |
2020 | 1264 | _tmp13_ = _tmp8_; | 1240 | _tmp1_ = _tmp7_; |
2019 | 1265 | _tmp1_ = _tmp13_; | ||
2021 | 1266 | } else { | 1241 | } else { |
2022 | 1267 | _tmp1_ = FALSE; | 1242 | _tmp1_ = FALSE; |
2023 | 1268 | } | 1243 | } |
2026 | 1269 | _tmp14_ = _tmp1_; | 1244 | if (_tmp1_) { |
2025 | 1270 | if (_tmp14_) { | ||
2027 | 1271 | result = TRUE; | 1245 | result = TRUE; |
2028 | 1272 | return result; | 1246 | return result; |
2029 | 1273 | } | 1247 | } |
2032 | 1274 | _tmp15_ = c; | 1248 | _tmp12_ = c; |
2033 | 1275 | last_c = _tmp15_; | 1249 | last_c = _tmp12_; |
2034 | 1276 | } | 1250 | } |
2035 | 1277 | } | 1251 | } |
2036 | 1278 | } | 1252 | } |
2040 | 1279 | _tmp16_ = i; | 1253 | _tmp13_ = i; |
2041 | 1280 | _tmp17_ = last_c; | 1254 | _tmp14_ = last_c; |
2042 | 1281 | result = _tmp16_ >= _tmp17_; | 1255 | result = _tmp13_ >= _tmp14_; |
2043 | 1282 | return result; | 1256 | return result; |
2044 | 1283 | } | 1257 | } |
2045 | 1284 | 1258 | ||
2046 | @@ -1298,191 +1272,187 @@ | |||
2047 | 1298 | gboolean _tmp0_ = FALSE; | 1272 | gboolean _tmp0_ = FALSE; |
2048 | 1299 | _tmp0_ = TRUE; | 1273 | _tmp0_ = TRUE; |
2049 | 1300 | while (TRUE) { | 1274 | while (TRUE) { |
2059 | 1301 | gboolean _tmp1_ = FALSE; | 1275 | gint _tmp2_ = 0; |
2060 | 1302 | gint _tmp3_ = 0; | 1276 | GeeArrayList** _tmp3_ = NULL; |
2061 | 1303 | GeeArrayList** _tmp4_ = NULL; | 1277 | gint _tmp3__length1 = 0; |
2062 | 1304 | gint _tmp4__length1 = 0; | 1278 | if (!_tmp0_) { |
2063 | 1305 | _tmp1_ = _tmp0_; | 1279 | gint _tmp1_ = 0; |
2064 | 1306 | if (!_tmp1_) { | 1280 | _tmp1_ = i; |
2065 | 1307 | gint _tmp2_ = 0; | 1281 | i = _tmp1_ + 1; |
2057 | 1308 | _tmp2_ = i; | ||
2058 | 1309 | i = _tmp2_ + 1; | ||
2066 | 1310 | } | 1282 | } |
2067 | 1311 | _tmp0_ = FALSE; | 1283 | _tmp0_ = FALSE; |
2072 | 1312 | _tmp3_ = i; | 1284 | _tmp2_ = i; |
2073 | 1313 | _tmp4_ = trellis; | 1285 | _tmp3_ = trellis; |
2074 | 1314 | _tmp4__length1 = trellis_length1; | 1286 | _tmp3__length1 = trellis_length1; |
2075 | 1315 | if (!(_tmp3_ < _tmp4__length1)) { | 1287 | if (!(_tmp2_ < _tmp3__length1)) { |
2076 | 1316 | break; | 1288 | break; |
2077 | 1317 | } | 1289 | } |
2078 | 1318 | { | 1290 | { |
2079 | 1319 | GeeArrayList* _node_list = NULL; | 1291 | GeeArrayList* _node_list = NULL; |
2083 | 1320 | GeeArrayList** _tmp5_ = NULL; | 1292 | GeeArrayList** _tmp4_ = NULL; |
2084 | 1321 | gint _tmp5__length1 = 0; | 1293 | gint _tmp4__length1 = 0; |
2085 | 1322 | gint _tmp6_ = 0; | 1294 | gint _tmp5_ = 0; |
2086 | 1295 | GeeArrayList* _tmp6_ = NULL; | ||
2087 | 1323 | GeeArrayList* _tmp7_ = NULL; | 1296 | GeeArrayList* _tmp7_ = NULL; |
2088 | 1297 | gint _node_size = 0; | ||
2089 | 1324 | GeeArrayList* _tmp8_ = NULL; | 1298 | GeeArrayList* _tmp8_ = NULL; |
2092 | 1325 | gint _node_size = 0; | 1299 | gint _tmp9_ = 0; |
2091 | 1326 | GeeArrayList* _tmp9_ = NULL; | ||
2093 | 1327 | gint _tmp10_ = 0; | 1300 | gint _tmp10_ = 0; |
2094 | 1328 | gint _tmp11_ = 0; | ||
2095 | 1329 | gint _node_index = 0; | 1301 | gint _node_index = 0; |
2106 | 1330 | _tmp5_ = trellis; | 1302 | _tmp4_ = trellis; |
2107 | 1331 | _tmp5__length1 = trellis_length1; | 1303 | _tmp4__length1 = trellis_length1; |
2108 | 1332 | _tmp6_ = i; | 1304 | _tmp5_ = i; |
2109 | 1333 | _tmp7_ = _tmp5_[_tmp6_]; | 1305 | _tmp6_ = _tmp4_[_tmp5_]; |
2110 | 1334 | _tmp8_ = _g_object_ref0 (_tmp7_); | 1306 | _tmp7_ = _g_object_ref0 (_tmp6_); |
2111 | 1335 | _node_list = _tmp8_; | 1307 | _node_list = _tmp7_; |
2112 | 1336 | _tmp9_ = _node_list; | 1308 | _tmp8_ = _node_list; |
2113 | 1337 | _tmp10_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp9_); | 1309 | _tmp9_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp8_); |
2114 | 1338 | _tmp11_ = _tmp10_; | 1310 | _tmp10_ = _tmp9_; |
2115 | 1339 | _node_size = _tmp11_; | 1311 | _node_size = _tmp10_; |
2116 | 1340 | _node_index = -1; | 1312 | _node_index = -1; |
2117 | 1341 | while (TRUE) { | 1313 | while (TRUE) { |
2118 | 1314 | gint _tmp11_ = 0; | ||
2119 | 1342 | gint _tmp12_ = 0; | 1315 | gint _tmp12_ = 0; |
2120 | 1343 | gint _tmp13_ = 0; | 1316 | gint _tmp13_ = 0; |
2121 | 1344 | gint _tmp14_ = 0; | ||
2122 | 1345 | KkcTrellisNode* node = NULL; | 1317 | KkcTrellisNode* node = NULL; |
2126 | 1346 | GeeArrayList* _tmp15_ = NULL; | 1318 | GeeArrayList* _tmp14_ = NULL; |
2127 | 1347 | gint _tmp16_ = 0; | 1319 | gint _tmp15_ = 0; |
2128 | 1348 | gpointer _tmp17_ = NULL; | 1320 | gpointer _tmp16_ = NULL; |
2129 | 1349 | gint j = 0; | 1321 | gint j = 0; |
2132 | 1350 | gint _tmp18_ = 0; | 1322 | gint _tmp17_ = 0; |
2133 | 1351 | KkcTrellisNode* _tmp19_ = NULL; | 1323 | KkcTrellisNode* _tmp18_ = NULL; |
2134 | 1324 | guint _tmp19_ = 0U; | ||
2135 | 1352 | guint _tmp20_ = 0U; | 1325 | guint _tmp20_ = 0U; |
2138 | 1353 | guint _tmp21_ = 0U; | 1326 | gint _tmp21_ = 0; |
2137 | 1354 | gint _tmp22_ = 0; | ||
2139 | 1355 | gdouble max_cost = 0.0; | 1327 | gdouble max_cost = 0.0; |
2140 | 1356 | gdouble _tmp23_ = 0.0; | ||
2141 | 1357 | KkcTrellisNode* max_pnode = NULL; | 1328 | KkcTrellisNode* max_pnode = NULL; |
2143 | 1358 | KkcTrellisNode* _tmp48_ = NULL; | 1329 | KkcTrellisNode* _tmp46_ = NULL; |
2144 | 1330 | KkcTrellisNode* _tmp51_ = NULL; | ||
2145 | 1331 | gdouble _tmp52_ = 0.0; | ||
2146 | 1359 | KkcTrellisNode* _tmp53_ = NULL; | 1332 | KkcTrellisNode* _tmp53_ = NULL; |
2148 | 1360 | gdouble _tmp54_ = 0.0; | 1333 | KkcTrellisNode* _tmp54_ = NULL; |
2149 | 1361 | KkcTrellisNode* _tmp55_ = NULL; | 1334 | KkcTrellisNode* _tmp55_ = NULL; |
2152 | 1362 | KkcTrellisNode* _tmp56_ = NULL; | 1335 | _tmp11_ = _node_index; |
2153 | 1363 | KkcTrellisNode* _tmp57_ = NULL; | 1336 | _node_index = _tmp11_ + 1; |
2154 | 1364 | _tmp12_ = _node_index; | 1337 | _tmp12_ = _node_index; |
2159 | 1365 | _node_index = _tmp12_ + 1; | 1338 | _tmp13_ = _node_size; |
2160 | 1366 | _tmp13_ = _node_index; | 1339 | if (!(_tmp12_ < _tmp13_)) { |
2157 | 1367 | _tmp14_ = _node_size; | ||
2158 | 1368 | if (!(_tmp13_ < _tmp14_)) { | ||
2161 | 1369 | break; | 1340 | break; |
2162 | 1370 | } | 1341 | } |
2174 | 1371 | _tmp15_ = _node_list; | 1342 | _tmp14_ = _node_list; |
2175 | 1372 | _tmp16_ = _node_index; | 1343 | _tmp15_ = _node_index; |
2176 | 1373 | _tmp17_ = gee_abstract_list_get ((GeeAbstractList*) _tmp15_, _tmp16_); | 1344 | _tmp16_ = gee_abstract_list_get ((GeeAbstractList*) _tmp14_, _tmp15_); |
2177 | 1374 | node = (KkcTrellisNode*) _tmp17_; | 1345 | node = (KkcTrellisNode*) _tmp16_; |
2178 | 1375 | _tmp18_ = i; | 1346 | _tmp17_ = i; |
2179 | 1376 | _tmp19_ = node; | 1347 | _tmp18_ = node; |
2180 | 1377 | _tmp20_ = kkc_trellis_node_get_length (_tmp19_); | 1348 | _tmp19_ = kkc_trellis_node_get_length (_tmp18_); |
2181 | 1378 | _tmp21_ = _tmp20_; | 1349 | _tmp20_ = _tmp19_; |
2182 | 1379 | j = _tmp18_ - ((gint) _tmp21_); | 1350 | j = _tmp17_ - ((gint) _tmp20_); |
2183 | 1380 | _tmp22_ = j; | 1351 | _tmp21_ = j; |
2184 | 1381 | if (_tmp22_ < 0) { | 1352 | if (_tmp21_ < 0) { |
2185 | 1382 | _kkc_trellis_node_unref0 (node); | 1353 | _kkc_trellis_node_unref0 (node); |
2186 | 1383 | continue; | 1354 | continue; |
2187 | 1384 | } | 1355 | } |
2190 | 1385 | _tmp23_ = DBL_MAX; | 1356 | max_cost = -DBL_MAX; |
2189 | 1386 | max_cost = -_tmp23_; | ||
2191 | 1387 | max_pnode = NULL; | 1357 | max_pnode = NULL; |
2192 | 1388 | { | 1358 | { |
2193 | 1389 | GeeArrayList* _pnode_list = NULL; | 1359 | GeeArrayList* _pnode_list = NULL; |
2197 | 1390 | GeeArrayList** _tmp24_ = NULL; | 1360 | GeeArrayList** _tmp22_ = NULL; |
2198 | 1391 | gint _tmp24__length1 = 0; | 1361 | gint _tmp22__length1 = 0; |
2199 | 1392 | gint _tmp25_ = 0; | 1362 | gint _tmp23_ = 0; |
2200 | 1363 | GeeArrayList* _tmp24_ = NULL; | ||
2201 | 1364 | GeeArrayList* _tmp25_ = NULL; | ||
2202 | 1365 | gint _pnode_size = 0; | ||
2203 | 1393 | GeeArrayList* _tmp26_ = NULL; | 1366 | GeeArrayList* _tmp26_ = NULL; |
2209 | 1394 | GeeArrayList* _tmp27_ = NULL; | 1367 | gint _tmp27_ = 0; |
2210 | 1395 | gint _pnode_size = 0; | 1368 | gint _tmp28_ = 0; |
2206 | 1396 | GeeArrayList* _tmp28_ = NULL; | ||
2207 | 1397 | gint _tmp29_ = 0; | ||
2208 | 1398 | gint _tmp30_ = 0; | ||
2211 | 1399 | gint _pnode_index = 0; | 1369 | gint _pnode_index = 0; |
2222 | 1400 | _tmp24_ = trellis; | 1370 | _tmp22_ = trellis; |
2223 | 1401 | _tmp24__length1 = trellis_length1; | 1371 | _tmp22__length1 = trellis_length1; |
2224 | 1402 | _tmp25_ = j; | 1372 | _tmp23_ = j; |
2225 | 1403 | _tmp26_ = _tmp24_[_tmp25_]; | 1373 | _tmp24_ = _tmp22_[_tmp23_]; |
2226 | 1404 | _tmp27_ = _g_object_ref0 (_tmp26_); | 1374 | _tmp25_ = _g_object_ref0 (_tmp24_); |
2227 | 1405 | _pnode_list = _tmp27_; | 1375 | _pnode_list = _tmp25_; |
2228 | 1406 | _tmp28_ = _pnode_list; | 1376 | _tmp26_ = _pnode_list; |
2229 | 1407 | _tmp29_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp28_); | 1377 | _tmp27_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp26_); |
2230 | 1408 | _tmp30_ = _tmp29_; | 1378 | _tmp28_ = _tmp27_; |
2231 | 1409 | _pnode_size = _tmp30_; | 1379 | _pnode_size = _tmp28_; |
2232 | 1410 | _pnode_index = -1; | 1380 | _pnode_index = -1; |
2233 | 1411 | while (TRUE) { | 1381 | while (TRUE) { |
2234 | 1382 | gint _tmp29_ = 0; | ||
2235 | 1383 | gint _tmp30_ = 0; | ||
2236 | 1412 | gint _tmp31_ = 0; | 1384 | gint _tmp31_ = 0; |
2238 | 1413 | gint _tmp32_ = 0; | 1385 | KkcTrellisNode* pnode = NULL; |
2239 | 1386 | GeeArrayList* _tmp32_ = NULL; | ||
2240 | 1414 | gint _tmp33_ = 0; | 1387 | gint _tmp33_ = 0; |
2245 | 1415 | KkcTrellisNode* pnode = NULL; | 1388 | gpointer _tmp34_ = NULL; |
2242 | 1416 | GeeArrayList* _tmp34_ = NULL; | ||
2243 | 1417 | gint _tmp35_ = 0; | ||
2244 | 1418 | gpointer _tmp36_ = NULL; | ||
2246 | 1419 | gdouble cost = 0.0; | 1389 | gdouble cost = 0.0; |
2247 | 1390 | KkcTrellisNode* _tmp35_ = NULL; | ||
2248 | 1391 | gdouble _tmp36_ = 0.0; | ||
2249 | 1420 | KkcTrellisNode* _tmp37_ = NULL; | 1392 | KkcTrellisNode* _tmp37_ = NULL; |
2254 | 1421 | gdouble _tmp38_ = 0.0; | 1393 | KkcTrellisNode* _tmp38_ = NULL; |
2255 | 1422 | KkcTrellisNode* _tmp39_ = NULL; | 1394 | gint _tmp39_ = 0; |
2256 | 1423 | KkcTrellisNode* _tmp40_ = NULL; | 1395 | gdouble _tmp40_ = 0.0; |
2257 | 1424 | gint _tmp41_ = 0; | 1396 | gdouble _tmp41_ = 0.0; |
2258 | 1425 | gdouble _tmp42_ = 0.0; | 1397 | gdouble _tmp42_ = 0.0; |
2266 | 1426 | gdouble _tmp43_ = 0.0; | 1398 | _tmp29_ = _pnode_index; |
2267 | 1427 | gdouble _tmp44_ = 0.0; | 1399 | _pnode_index = _tmp29_ + 1; |
2268 | 1428 | _tmp31_ = _pnode_index; | 1400 | _tmp30_ = _pnode_index; |
2269 | 1429 | _pnode_index = _tmp31_ + 1; | 1401 | _tmp31_ = _pnode_size; |
2270 | 1430 | _tmp32_ = _pnode_index; | 1402 | if (!(_tmp30_ < _tmp31_)) { |
2264 | 1431 | _tmp33_ = _pnode_size; | ||
2265 | 1432 | if (!(_tmp32_ < _tmp33_)) { | ||
2271 | 1433 | break; | 1403 | break; |
2272 | 1434 | } | 1404 | } |
2277 | 1435 | _tmp34_ = _pnode_list; | 1405 | _tmp32_ = _pnode_list; |
2278 | 1436 | _tmp35_ = _pnode_index; | 1406 | _tmp33_ = _pnode_index; |
2279 | 1437 | _tmp36_ = gee_abstract_list_get ((GeeAbstractList*) _tmp34_, _tmp35_); | 1407 | _tmp34_ = gee_abstract_list_get ((GeeAbstractList*) _tmp32_, _tmp33_); |
2280 | 1438 | pnode = (KkcTrellisNode*) _tmp36_; | 1408 | pnode = (KkcTrellisNode*) _tmp34_; |
2281 | 1409 | _tmp35_ = pnode; | ||
2282 | 1410 | _tmp36_ = _tmp35_->cumulative_cost; | ||
2283 | 1439 | _tmp37_ = pnode; | 1411 | _tmp37_ = pnode; |
2298 | 1440 | _tmp38_ = _tmp37_->cumulative_cost; | 1412 | _tmp38_ = node; |
2299 | 1441 | _tmp39_ = pnode; | 1413 | _tmp39_ = j; |
2300 | 1442 | _tmp40_ = node; | 1414 | _tmp40_ = kkc_bigram_decoder_path_cost (self, _tmp37_, _tmp38_, _tmp39_); |
2301 | 1443 | _tmp41_ = j; | 1415 | cost = _tmp36_ + _tmp40_; |
2302 | 1444 | _tmp42_ = kkc_bigram_decoder_path_cost (self, _tmp39_, _tmp40_, _tmp41_); | 1416 | _tmp41_ = cost; |
2303 | 1445 | cost = _tmp38_ + _tmp42_; | 1417 | _tmp42_ = max_cost; |
2304 | 1446 | _tmp43_ = cost; | 1418 | if (_tmp41_ > _tmp42_) { |
2305 | 1447 | _tmp44_ = max_cost; | 1419 | KkcTrellisNode* _tmp43_ = NULL; |
2306 | 1448 | if (_tmp43_ > _tmp44_) { | 1420 | KkcTrellisNode* _tmp44_ = NULL; |
2307 | 1449 | KkcTrellisNode* _tmp45_ = NULL; | 1421 | gdouble _tmp45_ = 0.0; |
2308 | 1450 | KkcTrellisNode* _tmp46_ = NULL; | 1422 | _tmp43_ = pnode; |
2309 | 1451 | gdouble _tmp47_ = 0.0; | 1423 | _tmp44_ = _kkc_trellis_node_ref0 (_tmp43_); |
2296 | 1452 | _tmp45_ = pnode; | ||
2297 | 1453 | _tmp46_ = _kkc_trellis_node_ref0 (_tmp45_); | ||
2310 | 1454 | _kkc_trellis_node_unref0 (max_pnode); | 1424 | _kkc_trellis_node_unref0 (max_pnode); |
2314 | 1455 | max_pnode = _tmp46_; | 1425 | max_pnode = _tmp44_; |
2315 | 1456 | _tmp47_ = cost; | 1426 | _tmp45_ = cost; |
2316 | 1457 | max_cost = _tmp47_; | 1427 | max_cost = _tmp45_; |
2317 | 1458 | } | 1428 | } |
2318 | 1459 | _kkc_trellis_node_unref0 (pnode); | 1429 | _kkc_trellis_node_unref0 (pnode); |
2319 | 1460 | } | 1430 | } |
2320 | 1461 | _g_object_unref0 (_pnode_list); | 1431 | _g_object_unref0 (_pnode_list); |
2321 | 1462 | } | 1432 | } |
2334 | 1463 | _tmp48_ = max_pnode; | 1433 | _tmp46_ = max_pnode; |
2335 | 1464 | if (_tmp48_ == NULL) { | 1434 | if (_tmp46_ == NULL) { |
2336 | 1465 | GeeArrayList** _tmp49_ = NULL; | 1435 | GeeArrayList** _tmp47_ = NULL; |
2337 | 1466 | gint _tmp49__length1 = 0; | 1436 | gint _tmp47__length1 = 0; |
2338 | 1467 | gint _tmp50_ = 0; | 1437 | gint _tmp48_ = 0; |
2339 | 1468 | GeeArrayList* _tmp51_ = NULL; | 1438 | GeeArrayList* _tmp49_ = NULL; |
2340 | 1469 | gpointer _tmp52_ = NULL; | 1439 | gpointer _tmp50_ = NULL; |
2341 | 1470 | _tmp49_ = trellis; | 1440 | _tmp47_ = trellis; |
2342 | 1471 | _tmp49__length1 = trellis_length1; | 1441 | _tmp47__length1 = trellis_length1; |
2343 | 1472 | _tmp50_ = i; | 1442 | _tmp48_ = i; |
2344 | 1473 | _tmp51_ = _tmp49_[_tmp50_]; | 1443 | _tmp49_ = _tmp47_[_tmp48_]; |
2345 | 1474 | _tmp52_ = gee_abstract_list_get ((GeeAbstractList*) _tmp51_, 0); | 1444 | _tmp50_ = gee_abstract_list_get ((GeeAbstractList*) _tmp49_, 0); |
2346 | 1475 | _kkc_trellis_node_unref0 (max_pnode); | 1445 | _kkc_trellis_node_unref0 (max_pnode); |
2348 | 1476 | max_pnode = (KkcTrellisNode*) _tmp52_; | 1446 | max_pnode = (KkcTrellisNode*) _tmp50_; |
2349 | 1477 | } | 1447 | } |
2350 | 1448 | _tmp51_ = node; | ||
2351 | 1449 | _tmp52_ = max_cost; | ||
2352 | 1450 | _tmp51_->cumulative_cost = _tmp52_; | ||
2353 | 1478 | _tmp53_ = node; | 1451 | _tmp53_ = node; |
2361 | 1479 | _tmp54_ = max_cost; | 1452 | _tmp54_ = max_pnode; |
2362 | 1480 | _tmp53_->cumulative_cost = _tmp54_; | 1453 | _tmp55_ = _kkc_trellis_node_ref0 (_tmp54_); |
2363 | 1481 | _tmp55_ = node; | 1454 | _kkc_trellis_node_unref0 (_tmp53_->previous); |
2364 | 1482 | _tmp56_ = max_pnode; | 1455 | _tmp53_->previous = _tmp55_; |
2358 | 1483 | _tmp57_ = _kkc_trellis_node_ref0 (_tmp56_); | ||
2359 | 1484 | _kkc_trellis_node_unref0 (_tmp55_->previous); | ||
2360 | 1485 | _tmp55_->previous = _tmp57_; | ||
2365 | 1486 | _kkc_trellis_node_unref0 (max_pnode); | 1456 | _kkc_trellis_node_unref0 (max_pnode); |
2366 | 1487 | _kkc_trellis_node_unref0 (node); | 1457 | _kkc_trellis_node_unref0 (node); |
2367 | 1488 | } | 1458 | } |
2368 | @@ -1504,16 +1474,15 @@ | |||
2369 | 1504 | KkcUnigramTrellisNode* _tmp3_ = NULL; | 1474 | KkcUnigramTrellisNode* _tmp3_ = NULL; |
2370 | 1505 | gboolean _tmp4_ = FALSE; | 1475 | gboolean _tmp4_ = FALSE; |
2371 | 1506 | KkcUnigramTrellisNode* _tmp5_ = NULL; | 1476 | KkcUnigramTrellisNode* _tmp5_ = NULL; |
2373 | 1507 | gboolean _tmp7_ = FALSE; | 1477 | KkcBigramLanguageModel* _tmp7_ = NULL; |
2374 | 1508 | KkcBigramLanguageModel* _tmp8_ = NULL; | 1478 | KkcBigramLanguageModel* _tmp8_ = NULL; |
2377 | 1509 | KkcBigramLanguageModel* _tmp9_ = NULL; | 1479 | KkcUnigramTrellisNode* _tmp9_ = NULL; |
2378 | 1510 | KkcUnigramTrellisNode* _tmp10_ = NULL; | 1480 | KkcLanguageModelEntry _tmp10_ = {0}; |
2379 | 1511 | KkcLanguageModelEntry _tmp11_ = {0}; | 1481 | KkcLanguageModelEntry _tmp11_ = {0}; |
2382 | 1512 | KkcLanguageModelEntry _tmp12_ = {0}; | 1482 | KkcUnigramTrellisNode* _tmp12_ = NULL; |
2383 | 1513 | KkcUnigramTrellisNode* _tmp13_ = NULL; | 1483 | KkcLanguageModelEntry _tmp13_ = {0}; |
2384 | 1514 | KkcLanguageModelEntry _tmp14_ = {0}; | 1484 | KkcLanguageModelEntry _tmp14_ = {0}; |
2387 | 1515 | KkcLanguageModelEntry _tmp15_ = {0}; | 1485 | gdouble _tmp15_ = 0.0; |
2386 | 1516 | gdouble _tmp16_ = 0.0; | ||
2388 | 1517 | g_return_val_if_fail (pnode != NULL, 0.0); | 1486 | g_return_val_if_fail (pnode != NULL, 0.0); |
2389 | 1518 | g_return_val_if_fail (node != NULL, 0.0); | 1487 | g_return_val_if_fail (node != NULL, 0.0); |
2390 | 1519 | _tmp0_ = pnode; | 1488 | _tmp0_ = pnode; |
2391 | @@ -1530,18 +1499,17 @@ | |||
2392 | 1530 | } else { | 1499 | } else { |
2393 | 1531 | _tmp4_ = FALSE; | 1500 | _tmp4_ = FALSE; |
2394 | 1532 | } | 1501 | } |
2407 | 1533 | _tmp7_ = _tmp4_; | 1502 | _vala_assert (_tmp4_, "upnode != null && unode != null"); |
2408 | 1534 | _vala_assert (_tmp7_, "upnode != null && unode != null"); | 1503 | _tmp7_ = kkc_bigram_decoder_get_model (self); |
2409 | 1535 | _tmp8_ = kkc_bigram_decoder_get_model (self); | 1504 | _tmp8_ = _tmp7_; |
2410 | 1536 | _tmp9_ = _tmp8_; | 1505 | _tmp9_ = upnode; |
2411 | 1537 | _tmp10_ = upnode; | 1506 | kkc_unigram_trellis_node_get_entry (_tmp9_, &_tmp10_); |
2412 | 1538 | kkc_unigram_trellis_node_get_entry (_tmp10_, &_tmp11_); | 1507 | _tmp11_ = _tmp10_; |
2413 | 1539 | _tmp12_ = _tmp11_; | 1508 | _tmp12_ = unode; |
2414 | 1540 | _tmp13_ = unode; | 1509 | kkc_unigram_trellis_node_get_entry (_tmp12_, &_tmp13_); |
2415 | 1541 | kkc_unigram_trellis_node_get_entry (_tmp13_, &_tmp14_); | 1510 | _tmp14_ = _tmp13_; |
2416 | 1542 | _tmp15_ = _tmp14_; | 1511 | _tmp15_ = kkc_bigram_language_model_bigram_backoff_cost (_tmp8_, &_tmp11_, &_tmp14_); |
2417 | 1543 | _tmp16_ = kkc_bigram_language_model_bigram_backoff_cost (_tmp9_, &_tmp12_, &_tmp15_); | 1512 | result = _tmp15_; |
2406 | 1544 | result = _tmp16_; | ||
2418 | 1545 | _kkc_trellis_node_unref0 (unode); | 1513 | _kkc_trellis_node_unref0 (unode); |
2419 | 1546 | _kkc_trellis_node_unref0 (upnode); | 1514 | _kkc_trellis_node_unref0 (upnode); |
2420 | 1547 | return result; | 1515 | return result; |
2421 | @@ -1566,113 +1534,109 @@ | |||
2422 | 1566 | gboolean _tmp0_ = FALSE; | 1534 | gboolean _tmp0_ = FALSE; |
2423 | 1567 | _tmp0_ = TRUE; | 1535 | _tmp0_ = TRUE; |
2424 | 1568 | while (TRUE) { | 1536 | while (TRUE) { |
2426 | 1569 | gboolean _tmp1_ = FALSE; | 1537 | KkcNbestNode* _tmp3_ = NULL; |
2427 | 1570 | KkcNbestNode* _tmp4_ = NULL; | 1538 | KkcNbestNode* _tmp4_ = NULL; |
2431 | 1571 | KkcNbestNode* _tmp5_ = NULL; | 1539 | if (!_tmp0_) { |
2432 | 1572 | _tmp1_ = _tmp0_; | 1540 | KkcNbestNode* _tmp1_ = NULL; |
2430 | 1573 | if (!_tmp1_) { | ||
2433 | 1574 | KkcNbestNode* _tmp2_ = NULL; | 1541 | KkcNbestNode* _tmp2_ = NULL; |
2438 | 1575 | KkcNbestNode* _tmp3_ = NULL; | 1542 | _tmp1_ = nbest_node; |
2439 | 1576 | _tmp2_ = nbest_node; | 1543 | _tmp2_ = _tmp1_->next; |
2440 | 1577 | _tmp3_ = _tmp2_->next; | 1544 | nbest_node = _tmp2_; |
2437 | 1578 | nbest_node = _tmp3_; | ||
2441 | 1579 | } | 1545 | } |
2442 | 1580 | _tmp0_ = FALSE; | 1546 | _tmp0_ = FALSE; |
2446 | 1581 | _tmp4_ = nbest_node; | 1547 | _tmp3_ = nbest_node; |
2447 | 1582 | _tmp5_ = _tmp4_->next; | 1548 | _tmp4_ = _tmp3_->next; |
2448 | 1583 | if (!(_tmp5_ != NULL)) { | 1549 | if (!(_tmp4_ != NULL)) { |
2449 | 1584 | break; | 1550 | break; |
2450 | 1585 | } | 1551 | } |
2451 | 1586 | { | 1552 | { |
2452 | 1587 | gint i = 0; | 1553 | gint i = 0; |
2453 | 1588 | i = 0; | 1554 | i = 0; |
2454 | 1589 | { | 1555 | { |
2457 | 1590 | gboolean _tmp6_ = FALSE; | 1556 | gboolean _tmp5_ = FALSE; |
2458 | 1591 | _tmp6_ = TRUE; | 1557 | _tmp5_ = TRUE; |
2459 | 1592 | while (TRUE) { | 1558 | while (TRUE) { |
2468 | 1593 | gboolean _tmp7_ = FALSE; | 1559 | gint _tmp7_ = 0; |
2469 | 1594 | gint _tmp9_ = 0; | 1560 | KkcNbestNode* _tmp8_ = NULL; |
2470 | 1595 | KkcNbestNode* _tmp10_ = NULL; | 1561 | KkcTrellisNode* _tmp9_ = NULL; |
2471 | 1596 | KkcTrellisNode* _tmp11_ = NULL; | 1562 | KkcLanguageModelEntry* _tmp10_ = NULL; |
2472 | 1597 | KkcLanguageModelEntry* _tmp12_ = NULL; | 1563 | gint _tmp10__length1 = 0; |
2473 | 1598 | gint _tmp12__length1 = 0; | 1564 | KkcLanguageModelEntry* _tmp11_ = NULL; |
2474 | 1599 | KkcLanguageModelEntry* _tmp13_ = NULL; | 1565 | gint _tmp11__length1 = 0; |
2467 | 1600 | gint _tmp13__length1 = 0; | ||
2475 | 1601 | KkcLanguageModelEntry entry = {0}; | 1566 | KkcLanguageModelEntry entry = {0}; |
2483 | 1602 | KkcNbestNode* _tmp14_ = NULL; | 1567 | KkcNbestNode* _tmp12_ = NULL; |
2484 | 1603 | KkcTrellisNode* _tmp15_ = NULL; | 1568 | KkcTrellisNode* _tmp13_ = NULL; |
2485 | 1604 | KkcLanguageModelEntry* _tmp16_ = NULL; | 1569 | KkcLanguageModelEntry* _tmp14_ = NULL; |
2486 | 1605 | gint _tmp16__length1 = 0; | 1570 | gint _tmp14__length1 = 0; |
2487 | 1606 | KkcLanguageModelEntry* _tmp17_ = NULL; | 1571 | KkcLanguageModelEntry* _tmp15_ = NULL; |
2488 | 1607 | gint _tmp17__length1 = 0; | 1572 | gint _tmp15__length1 = 0; |
2489 | 1608 | gint _tmp18_ = 0; | 1573 | gint _tmp16_ = 0; |
2490 | 1574 | KkcLanguageModelEntry _tmp17_ = {0}; | ||
2491 | 1575 | KkcLanguageModelEntry _tmp18_ = {0}; | ||
2492 | 1576 | KkcSegment* segment = NULL; | ||
2493 | 1609 | KkcLanguageModelEntry _tmp19_ = {0}; | 1577 | KkcLanguageModelEntry _tmp19_ = {0}; |
2496 | 1610 | KkcLanguageModelEntry _tmp20_ = {0}; | 1578 | const gchar* _tmp20_ = NULL; |
2495 | 1611 | KkcSegment* segment = NULL; | ||
2497 | 1612 | KkcLanguageModelEntry _tmp21_ = {0}; | 1579 | KkcLanguageModelEntry _tmp21_ = {0}; |
2498 | 1613 | const gchar* _tmp22_ = NULL; | 1580 | const gchar* _tmp22_ = NULL; |
2511 | 1614 | KkcLanguageModelEntry _tmp23_ = {0}; | 1581 | KkcSegment* _tmp23_ = NULL; |
2512 | 1615 | const gchar* _tmp24_ = NULL; | 1582 | KkcSegment* _tmp24_ = NULL; |
2513 | 1616 | KkcSegment* _tmp25_ = NULL; | 1583 | KkcSegment* _tmp27_ = NULL; |
2514 | 1617 | KkcSegment* _tmp26_ = NULL; | 1584 | KkcSegment* _tmp31_ = NULL; |
2515 | 1618 | KkcSegment* _tmp29_ = NULL; | 1585 | KkcSegment* _tmp32_ = NULL; |
2516 | 1619 | KkcSegment* _tmp33_ = NULL; | 1586 | if (!_tmp5_) { |
2517 | 1620 | KkcSegment* _tmp34_ = NULL; | 1587 | gint _tmp6_ = 0; |
2518 | 1621 | _tmp7_ = _tmp6_; | 1588 | _tmp6_ = i; |
2519 | 1622 | if (!_tmp7_) { | 1589 | i = _tmp6_ + 1; |
2508 | 1623 | gint _tmp8_ = 0; | ||
2509 | 1624 | _tmp8_ = i; | ||
2510 | 1625 | i = _tmp8_ + 1; | ||
2520 | 1626 | } | 1590 | } |
2529 | 1627 | _tmp6_ = FALSE; | 1591 | _tmp5_ = FALSE; |
2530 | 1628 | _tmp9_ = i; | 1592 | _tmp7_ = i; |
2531 | 1629 | _tmp10_ = nbest_node; | 1593 | _tmp8_ = nbest_node; |
2532 | 1630 | _tmp11_ = _tmp10_->node; | 1594 | _tmp9_ = _tmp8_->node; |
2533 | 1631 | _tmp12_ = kkc_trellis_node_get_entries (_tmp11_, &_tmp12__length1); | 1595 | _tmp10_ = kkc_trellis_node_get_entries (_tmp9_, &_tmp10__length1); |
2534 | 1632 | _tmp13_ = _tmp12_; | 1596 | _tmp11_ = _tmp10_; |
2535 | 1633 | _tmp13__length1 = _tmp12__length1; | 1597 | _tmp11__length1 = _tmp10__length1; |
2536 | 1634 | if (!(_tmp9_ < _tmp13__length1)) { | 1598 | if (!(_tmp7_ < _tmp11__length1)) { |
2537 | 1635 | break; | 1599 | break; |
2538 | 1636 | } | 1600 | } |
2548 | 1637 | _tmp14_ = nbest_node; | 1601 | _tmp12_ = nbest_node; |
2549 | 1638 | _tmp15_ = _tmp14_->node; | 1602 | _tmp13_ = _tmp12_->node; |
2550 | 1639 | _tmp16_ = kkc_trellis_node_get_entries (_tmp15_, &_tmp16__length1); | 1603 | _tmp14_ = kkc_trellis_node_get_entries (_tmp13_, &_tmp14__length1); |
2551 | 1640 | _tmp17_ = _tmp16_; | 1604 | _tmp15_ = _tmp14_; |
2552 | 1641 | _tmp17__length1 = _tmp16__length1; | 1605 | _tmp15__length1 = _tmp14__length1; |
2553 | 1642 | _tmp18_ = i; | 1606 | _tmp16_ = i; |
2554 | 1643 | _tmp19_ = _tmp17_[_tmp18_]; | 1607 | _tmp17_ = _tmp15_[_tmp16_]; |
2555 | 1644 | kkc_language_model_entry_copy (&_tmp19_, &_tmp20_); | 1608 | kkc_language_model_entry_copy (&_tmp17_, &_tmp18_); |
2556 | 1645 | entry = _tmp20_; | 1609 | entry = _tmp18_; |
2557 | 1610 | _tmp19_ = entry; | ||
2558 | 1611 | _tmp20_ = _tmp19_.input; | ||
2559 | 1646 | _tmp21_ = entry; | 1612 | _tmp21_ = entry; |
2568 | 1647 | _tmp22_ = _tmp21_.input; | 1613 | _tmp22_ = _tmp21_.output; |
2569 | 1648 | _tmp23_ = entry; | 1614 | _tmp23_ = kkc_segment_new (_tmp20_, _tmp22_); |
2570 | 1649 | _tmp24_ = _tmp23_.output; | 1615 | segment = _tmp23_; |
2571 | 1650 | _tmp25_ = kkc_segment_new (_tmp22_, _tmp24_); | 1616 | _tmp24_ = start_segment; |
2572 | 1651 | segment = _tmp25_; | 1617 | if (_tmp24_ == NULL) { |
2573 | 1652 | _tmp26_ = start_segment; | 1618 | KkcSegment* _tmp25_ = NULL; |
2574 | 1653 | if (_tmp26_ == NULL) { | 1619 | KkcSegment* _tmp26_ = NULL; |
2575 | 1654 | KkcSegment* _tmp27_ = NULL; | 1620 | _tmp25_ = segment; |
2576 | 1621 | _tmp26_ = _g_object_ref0 (_tmp25_); | ||
2577 | 1622 | _g_object_unref0 (start_segment); | ||
2578 | 1623 | start_segment = _tmp26_; | ||
2579 | 1624 | } | ||
2580 | 1625 | _tmp27_ = previous_segment; | ||
2581 | 1626 | if (_tmp27_ != NULL) { | ||
2582 | 1655 | KkcSegment* _tmp28_ = NULL; | 1627 | KkcSegment* _tmp28_ = NULL; |
2590 | 1656 | _tmp27_ = segment; | 1628 | KkcSegment* _tmp29_ = NULL; |
2584 | 1657 | _tmp28_ = _g_object_ref0 (_tmp27_); | ||
2585 | 1658 | _g_object_unref0 (start_segment); | ||
2586 | 1659 | start_segment = _tmp28_; | ||
2587 | 1660 | } | ||
2588 | 1661 | _tmp29_ = previous_segment; | ||
2589 | 1662 | if (_tmp29_ != NULL) { | ||
2591 | 1663 | KkcSegment* _tmp30_ = NULL; | 1629 | KkcSegment* _tmp30_ = NULL; |
2599 | 1664 | KkcSegment* _tmp31_ = NULL; | 1630 | _tmp28_ = previous_segment; |
2600 | 1665 | KkcSegment* _tmp32_ = NULL; | 1631 | _tmp29_ = segment; |
2601 | 1666 | _tmp30_ = previous_segment; | 1632 | _tmp30_ = _g_object_ref0 (_tmp29_); |
2602 | 1667 | _tmp31_ = segment; | 1633 | _g_object_unref0 (_tmp28_->next); |
2603 | 1668 | _tmp32_ = _g_object_ref0 (_tmp31_); | 1634 | _tmp28_->next = _tmp30_; |
2597 | 1669 | _g_object_unref0 (_tmp30_->next); | ||
2598 | 1670 | _tmp30_->next = _tmp32_; | ||
2604 | 1671 | } | 1635 | } |
2607 | 1672 | _tmp33_ = segment; | 1636 | _tmp31_ = segment; |
2608 | 1673 | _tmp34_ = _g_object_ref0 (_tmp33_); | 1637 | _tmp32_ = _g_object_ref0 (_tmp31_); |
2609 | 1674 | _g_object_unref0 (previous_segment); | 1638 | _g_object_unref0 (previous_segment); |
2611 | 1675 | previous_segment = _tmp34_; | 1639 | previous_segment = _tmp32_; |
2612 | 1676 | _g_object_unref0 (segment); | 1640 | _g_object_unref0 (segment); |
2613 | 1677 | kkc_language_model_entry_destroy (&entry); | 1641 | kkc_language_model_entry_destroy (&entry); |
2614 | 1678 | } | 1642 | } |
2615 | @@ -1709,6 +1673,13 @@ | |||
2616 | 1709 | } | 1673 | } |
2617 | 1710 | 1674 | ||
2618 | 1711 | 1675 | ||
2619 | 1676 | static gint _kkc_bigram_decoder_compare_nbest_node_gcompare_data_func (gconstpointer a, gconstpointer b, gpointer self) { | ||
2620 | 1677 | gint result; | ||
2621 | 1678 | result = kkc_bigram_decoder_compare_nbest_node ((KkcNbestNode*) a, (KkcNbestNode*) b); | ||
2622 | 1679 | return result; | ||
2623 | 1680 | } | ||
2624 | 1681 | |||
2625 | 1682 | |||
2626 | 1712 | static gpointer _kkc_nbest_node_ref0 (gpointer self) { | 1683 | static gpointer _kkc_nbest_node_ref0 (gpointer self) { |
2627 | 1713 | return self ? kkc_nbest_node_ref (self) : NULL; | 1684 | return self ? kkc_nbest_node_ref (self) : NULL; |
2628 | 1714 | } | 1685 | } |
2629 | @@ -1730,32 +1701,28 @@ | |||
2630 | 1730 | gpointer _tmp6_ = NULL; | 1701 | gpointer _tmp6_ = NULL; |
2631 | 1731 | gint _tmp7_ = 0; | 1702 | gint _tmp7_ = 0; |
2632 | 1732 | GeeHashMap* trellis_nbest_map = NULL; | 1703 | GeeHashMap* trellis_nbest_map = NULL; |
2636 | 1733 | GHashFunc _tmp49_ = NULL; | 1704 | GeeHashMap* _tmp47_ = NULL; |
2634 | 1734 | GEqualFunc _tmp50_ = NULL; | ||
2635 | 1735 | GeeHashMap* _tmp51_ = NULL; | ||
2637 | 1736 | GeePriorityQueue* open_list = NULL; | 1705 | GeePriorityQueue* open_list = NULL; |
2639 | 1737 | GeePriorityQueue* _tmp52_ = NULL; | 1706 | GeePriorityQueue* _tmp48_ = NULL; |
2640 | 1738 | GeePriorityQueue* close_list = NULL; | 1707 | GeePriorityQueue* close_list = NULL; |
2642 | 1739 | GeePriorityQueue* _tmp53_ = NULL; | 1708 | GeePriorityQueue* _tmp49_ = NULL; |
2643 | 1740 | GeeHashSet* duplicates = NULL; | 1709 | GeeHashSet* duplicates = NULL; |
2647 | 1741 | GHashFunc _tmp54_ = NULL; | 1710 | GeeHashSet* _tmp50_ = NULL; |
2645 | 1742 | GEqualFunc _tmp55_ = NULL; | ||
2646 | 1743 | GeeHashSet* _tmp56_ = NULL; | ||
2648 | 1744 | KkcNbestNode* eos_nbest_node = NULL; | 1711 | KkcNbestNode* eos_nbest_node = NULL; |
2656 | 1745 | KkcTrellisNode* _tmp57_ = NULL; | 1712 | KkcTrellisNode* _tmp51_ = NULL; |
2657 | 1746 | KkcNbestNode* _tmp58_ = NULL; | 1713 | KkcNbestNode* _tmp52_ = NULL; |
2658 | 1747 | GeeHashMap* _tmp59_ = NULL; | 1714 | GeeHashMap* _tmp53_ = NULL; |
2659 | 1748 | KkcTrellisNode* _tmp60_ = NULL; | 1715 | KkcTrellisNode* _tmp54_ = NULL; |
2660 | 1749 | KkcNbestNode* _tmp61_ = NULL; | 1716 | KkcNbestNode* _tmp55_ = NULL; |
2661 | 1750 | GeePriorityQueue* _tmp62_ = NULL; | 1717 | GeePriorityQueue* _tmp56_ = NULL; |
2662 | 1751 | KkcNbestNode* _tmp63_ = NULL; | 1718 | KkcNbestNode* _tmp57_ = NULL; |
2663 | 1752 | GeeArrayList* segments = NULL; | 1719 | GeeArrayList* segments = NULL; |
2670 | 1753 | GeeArrayList* _tmp151_ = NULL; | 1720 | GeeArrayList* _tmp144_ = NULL; |
2671 | 1754 | GeeArrayList* _tmp163_ = NULL; | 1721 | GeeArrayList* _tmp156_ = NULL; |
2672 | 1755 | gint _tmp164_ = 0; | 1722 | gint _tmp157_ = 0; |
2673 | 1756 | gpointer* _tmp165_ = NULL; | 1723 | gpointer* _tmp158_ = NULL; |
2674 | 1757 | KkcSegment** _tmp166_ = NULL; | 1724 | KkcSegment** _tmp159_ = NULL; |
2675 | 1758 | gint _tmp166__length1 = 0; | 1725 | gint _tmp159__length1 = 0; |
2676 | 1759 | g_return_val_if_fail (self != NULL, NULL); | 1726 | g_return_val_if_fail (self != NULL, NULL); |
2677 | 1760 | _tmp0_ = trellis; | 1727 | _tmp0_ = trellis; |
2678 | 1761 | _tmp0__length1 = trellis_length1; | 1728 | _tmp0__length1 = trellis_length1; |
2679 | @@ -1773,11 +1740,11 @@ | |||
2680 | 1773 | if (_tmp7_ == 1) { | 1740 | if (_tmp7_ == 1) { |
2681 | 1774 | KkcSegment* segment = NULL; | 1741 | KkcSegment* segment = NULL; |
2682 | 1775 | KkcSegment* next_segment = NULL; | 1742 | KkcSegment* next_segment = NULL; |
2688 | 1776 | KkcSegment* _tmp45_ = NULL; | 1743 | KkcSegment* _tmp43_ = NULL; |
2689 | 1777 | KkcSegment* _tmp46_ = NULL; | 1744 | KkcSegment* _tmp44_ = NULL; |
2690 | 1778 | KkcSegment** _tmp47_ = NULL; | 1745 | KkcSegment** _tmp45_ = NULL; |
2691 | 1779 | KkcSegment** _tmp48_ = NULL; | 1746 | KkcSegment** _tmp46_ = NULL; |
2692 | 1780 | gint _tmp48__length1 = 0; | 1747 | gint _tmp46__length1 = 0; |
2693 | 1781 | segment = NULL; | 1748 | segment = NULL; |
2694 | 1782 | next_segment = NULL; | 1749 | next_segment = NULL; |
2695 | 1783 | { | 1750 | { |
2696 | @@ -1793,110 +1760,106 @@ | |||
2697 | 1793 | gboolean _tmp11_ = FALSE; | 1760 | gboolean _tmp11_ = FALSE; |
2698 | 1794 | _tmp11_ = TRUE; | 1761 | _tmp11_ = TRUE; |
2699 | 1795 | while (TRUE) { | 1762 | while (TRUE) { |
2704 | 1796 | gboolean _tmp12_ = FALSE; | 1763 | KkcTrellisNode* _tmp15_ = NULL; |
2705 | 1797 | KkcTrellisNode* _tmp16_ = NULL; | 1764 | if (!_tmp11_) { |
2706 | 1798 | _tmp12_ = _tmp11_; | 1765 | KkcTrellisNode* _tmp12_ = NULL; |
2703 | 1799 | if (!_tmp12_) { | ||
2707 | 1800 | KkcTrellisNode* _tmp13_ = NULL; | 1766 | KkcTrellisNode* _tmp13_ = NULL; |
2708 | 1801 | KkcTrellisNode* _tmp14_ = NULL; | 1767 | KkcTrellisNode* _tmp14_ = NULL; |
2713 | 1802 | KkcTrellisNode* _tmp15_ = NULL; | 1768 | _tmp12_ = node; |
2714 | 1803 | _tmp13_ = node; | 1769 | _tmp13_ = _tmp12_->previous; |
2715 | 1804 | _tmp14_ = _tmp13_->previous; | 1770 | _tmp14_ = _kkc_trellis_node_ref0 (_tmp13_); |
2712 | 1805 | _tmp15_ = _kkc_trellis_node_ref0 (_tmp14_); | ||
2716 | 1806 | _kkc_trellis_node_unref0 (node); | 1771 | _kkc_trellis_node_unref0 (node); |
2718 | 1807 | node = _tmp15_; | 1772 | node = _tmp14_; |
2719 | 1808 | } | 1773 | } |
2720 | 1809 | _tmp11_ = FALSE; | 1774 | _tmp11_ = FALSE; |
2723 | 1810 | _tmp16_ = node; | 1775 | _tmp15_ = node; |
2724 | 1811 | if (!(_tmp16_ != NULL)) { | 1776 | if (!(_tmp15_ != NULL)) { |
2725 | 1812 | break; | 1777 | break; |
2726 | 1813 | } | 1778 | } |
2727 | 1814 | { | 1779 | { |
2728 | 1815 | gint i = 0; | 1780 | gint i = 0; |
2730 | 1816 | KkcTrellisNode* _tmp17_ = NULL; | 1781 | KkcTrellisNode* _tmp16_ = NULL; |
2731 | 1782 | KkcLanguageModelEntry* _tmp17_ = NULL; | ||
2732 | 1783 | gint _tmp17__length1 = 0; | ||
2733 | 1817 | KkcLanguageModelEntry* _tmp18_ = NULL; | 1784 | KkcLanguageModelEntry* _tmp18_ = NULL; |
2734 | 1818 | gint _tmp18__length1 = 0; | 1785 | gint _tmp18__length1 = 0; |
2742 | 1819 | KkcLanguageModelEntry* _tmp19_ = NULL; | 1786 | _tmp16_ = node; |
2743 | 1820 | gint _tmp19__length1 = 0; | 1787 | _tmp17_ = kkc_trellis_node_get_entries (_tmp16_, &_tmp17__length1); |
2744 | 1821 | _tmp17_ = node; | 1788 | _tmp18_ = _tmp17_; |
2745 | 1822 | _tmp18_ = kkc_trellis_node_get_entries (_tmp17_, &_tmp18__length1); | 1789 | _tmp18__length1 = _tmp17__length1; |
2746 | 1823 | _tmp19_ = _tmp18_; | 1790 | i = _tmp18__length1 - 1; |
2740 | 1824 | _tmp19__length1 = _tmp18__length1; | ||
2741 | 1825 | i = _tmp19__length1 - 1; | ||
2747 | 1826 | { | 1791 | { |
2750 | 1827 | gboolean _tmp20_ = FALSE; | 1792 | gboolean _tmp19_ = FALSE; |
2751 | 1828 | _tmp20_ = TRUE; | 1793 | _tmp19_ = TRUE; |
2752 | 1829 | while (TRUE) { | 1794 | while (TRUE) { |
2755 | 1830 | gboolean _tmp21_ = FALSE; | 1795 | gint _tmp21_ = 0; |
2754 | 1831 | gint _tmp23_ = 0; | ||
2756 | 1832 | KkcLanguageModelEntry entry = {0}; | 1796 | KkcLanguageModelEntry entry = {0}; |
2763 | 1833 | KkcTrellisNode* _tmp24_ = NULL; | 1797 | KkcTrellisNode* _tmp22_ = NULL; |
2764 | 1834 | KkcLanguageModelEntry* _tmp25_ = NULL; | 1798 | KkcLanguageModelEntry* _tmp23_ = NULL; |
2765 | 1835 | gint _tmp25__length1 = 0; | 1799 | gint _tmp23__length1 = 0; |
2766 | 1836 | KkcLanguageModelEntry* _tmp26_ = NULL; | 1800 | KkcLanguageModelEntry* _tmp24_ = NULL; |
2767 | 1837 | gint _tmp26__length1 = 0; | 1801 | gint _tmp24__length1 = 0; |
2768 | 1838 | gint _tmp27_ = 0; | 1802 | gint _tmp25_ = 0; |
2769 | 1803 | KkcLanguageModelEntry _tmp26_ = {0}; | ||
2770 | 1804 | KkcLanguageModelEntry _tmp27_ = {0}; | ||
2771 | 1839 | KkcLanguageModelEntry _tmp28_ = {0}; | 1805 | KkcLanguageModelEntry _tmp28_ = {0}; |
2776 | 1840 | KkcLanguageModelEntry _tmp29_ = {0}; | 1806 | KkcBigramLanguageModel* _tmp29_ = NULL; |
2777 | 1841 | KkcLanguageModelEntry _tmp30_ = {0}; | 1807 | KkcBigramLanguageModel* _tmp30_ = NULL; |
2778 | 1842 | KkcBigramLanguageModel* _tmp31_ = NULL; | 1808 | KkcLanguageModelEntry _tmp31_ = {0}; |
2779 | 1843 | KkcBigramLanguageModel* _tmp32_ = NULL; | 1809 | KkcLanguageModelEntry _tmp32_ = {0}; |
2780 | 1844 | KkcLanguageModelEntry _tmp33_ = {0}; | 1810 | KkcLanguageModelEntry _tmp33_ = {0}; |
2782 | 1845 | KkcLanguageModelEntry _tmp34_ = {0}; | 1811 | const gchar* _tmp34_ = NULL; |
2783 | 1846 | KkcLanguageModelEntry _tmp35_ = {0}; | 1812 | KkcLanguageModelEntry _tmp35_ = {0}; |
2784 | 1847 | const gchar* _tmp36_ = NULL; | 1813 | const gchar* _tmp36_ = NULL; |
2787 | 1848 | KkcLanguageModelEntry _tmp37_ = {0}; | 1814 | KkcSegment* _tmp37_ = NULL; |
2788 | 1849 | const gchar* _tmp38_ = NULL; | 1815 | KkcSegment* _tmp38_ = NULL; |
2789 | 1850 | KkcSegment* _tmp39_ = NULL; | 1816 | KkcSegment* _tmp39_ = NULL; |
2790 | 1851 | KkcSegment* _tmp40_ = NULL; | 1817 | KkcSegment* _tmp40_ = NULL; |
2791 | 1852 | KkcSegment* _tmp41_ = NULL; | 1818 | KkcSegment* _tmp41_ = NULL; |
2792 | 1853 | KkcSegment* _tmp42_ = NULL; | 1819 | KkcSegment* _tmp42_ = NULL; |
2800 | 1854 | KkcSegment* _tmp43_ = NULL; | 1820 | if (!_tmp19_) { |
2801 | 1855 | KkcSegment* _tmp44_ = NULL; | 1821 | gint _tmp20_ = 0; |
2802 | 1856 | _tmp21_ = _tmp20_; | 1822 | _tmp20_ = i; |
2803 | 1857 | if (!_tmp21_) { | 1823 | i = _tmp20_ - 1; |
2797 | 1858 | gint _tmp22_ = 0; | ||
2798 | 1859 | _tmp22_ = i; | ||
2799 | 1860 | i = _tmp22_ - 1; | ||
2804 | 1861 | } | 1824 | } |
2808 | 1862 | _tmp20_ = FALSE; | 1825 | _tmp19_ = FALSE; |
2809 | 1863 | _tmp23_ = i; | 1826 | _tmp21_ = i; |
2810 | 1864 | if (!(_tmp23_ >= 0)) { | 1827 | if (!(_tmp21_ >= 0)) { |
2811 | 1865 | break; | 1828 | break; |
2812 | 1866 | } | 1829 | } |
2823 | 1867 | _tmp24_ = node; | 1830 | _tmp22_ = node; |
2824 | 1868 | _tmp25_ = kkc_trellis_node_get_entries (_tmp24_, &_tmp25__length1); | 1831 | _tmp23_ = kkc_trellis_node_get_entries (_tmp22_, &_tmp23__length1); |
2825 | 1869 | _tmp26_ = _tmp25_; | 1832 | _tmp24_ = _tmp23_; |
2826 | 1870 | _tmp26__length1 = _tmp25__length1; | 1833 | _tmp24__length1 = _tmp23__length1; |
2827 | 1871 | _tmp27_ = i; | 1834 | _tmp25_ = i; |
2828 | 1872 | _tmp28_ = _tmp26_[_tmp27_]; | 1835 | _tmp26_ = _tmp24_[_tmp25_]; |
2829 | 1873 | kkc_language_model_entry_copy (&_tmp28_, &_tmp29_); | 1836 | kkc_language_model_entry_copy (&_tmp26_, &_tmp27_); |
2830 | 1874 | entry = _tmp29_; | 1837 | entry = _tmp27_; |
2831 | 1875 | _tmp30_ = entry; | 1838 | _tmp28_ = entry; |
2832 | 1876 | _tmp31_ = kkc_bigram_decoder_get_model (self); | 1839 | _tmp29_ = kkc_bigram_decoder_get_model (self); |
2833 | 1840 | _tmp30_ = _tmp29_; | ||
2834 | 1841 | kkc_language_model_get_bos ((KkcLanguageModel*) _tmp30_, &_tmp31_); | ||
2835 | 1877 | _tmp32_ = _tmp31_; | 1842 | _tmp32_ = _tmp31_; |
2839 | 1878 | kkc_language_model_get_bos ((KkcLanguageModel*) _tmp32_, &_tmp33_); | 1843 | if (_kkc_language_model_entry_equal (&_tmp28_, &_tmp32_) == TRUE) { |
2837 | 1879 | _tmp34_ = _tmp33_; | ||
2838 | 1880 | if (_kkc_language_model_entry_equal (&_tmp30_, &_tmp34_) == TRUE) { | ||
2840 | 1881 | kkc_language_model_entry_destroy (&entry); | 1844 | kkc_language_model_entry_destroy (&entry); |
2841 | 1882 | break; | 1845 | break; |
2842 | 1883 | } | 1846 | } |
2843 | 1847 | _tmp33_ = entry; | ||
2844 | 1848 | _tmp34_ = _tmp33_.input; | ||
2845 | 1884 | _tmp35_ = entry; | 1849 | _tmp35_ = entry; |
2850 | 1885 | _tmp36_ = _tmp35_.input; | 1850 | _tmp36_ = _tmp35_.output; |
2851 | 1886 | _tmp37_ = entry; | 1851 | _tmp37_ = kkc_segment_new (_tmp34_, _tmp36_); |
2848 | 1887 | _tmp38_ = _tmp37_.output; | ||
2849 | 1888 | _tmp39_ = kkc_segment_new (_tmp36_, _tmp38_); | ||
2852 | 1889 | _g_object_unref0 (segment); | 1852 | _g_object_unref0 (segment); |
2856 | 1890 | segment = _tmp39_; | 1853 | segment = _tmp37_; |
2857 | 1891 | _tmp40_ = segment; | 1854 | _tmp38_ = segment; |
2858 | 1892 | _tmp41_ = next_segment; | 1855 | _tmp39_ = next_segment; |
2859 | 1856 | _tmp40_ = _g_object_ref0 (_tmp39_); | ||
2860 | 1857 | _g_object_unref0 (_tmp38_->next); | ||
2861 | 1858 | _tmp38_->next = _tmp40_; | ||
2862 | 1859 | _tmp41_ = segment; | ||
2863 | 1893 | _tmp42_ = _g_object_ref0 (_tmp41_); | 1860 | _tmp42_ = _g_object_ref0 (_tmp41_); |
2864 | 1894 | _g_object_unref0 (_tmp40_->next); | ||
2865 | 1895 | _tmp40_->next = _tmp42_; | ||
2866 | 1896 | _tmp43_ = segment; | ||
2867 | 1897 | _tmp44_ = _g_object_ref0 (_tmp43_); | ||
2868 | 1898 | _g_object_unref0 (next_segment); | 1861 | _g_object_unref0 (next_segment); |
2870 | 1899 | next_segment = _tmp44_; | 1862 | next_segment = _tmp42_; |
2871 | 1900 | kkc_language_model_entry_destroy (&entry); | 1863 | kkc_language_model_entry_destroy (&entry); |
2872 | 1901 | } | 1864 | } |
2873 | 1902 | } | 1865 | } |
2874 | @@ -1905,281 +1868,275 @@ | |||
2875 | 1905 | } | 1868 | } |
2876 | 1906 | _kkc_trellis_node_unref0 (node); | 1869 | _kkc_trellis_node_unref0 (node); |
2877 | 1907 | } | 1870 | } |
2884 | 1908 | _tmp45_ = segment; | 1871 | _tmp43_ = segment; |
2885 | 1909 | _tmp46_ = _g_object_ref0 (_tmp45_); | 1872 | _tmp44_ = _g_object_ref0 (_tmp43_); |
2886 | 1910 | _tmp47_ = g_new0 (KkcSegment*, 1 + 1); | 1873 | _tmp45_ = g_new0 (KkcSegment*, 1 + 1); |
2887 | 1911 | _tmp47_[0] = _tmp46_; | 1874 | _tmp45_[0] = _tmp44_; |
2888 | 1912 | _tmp48_ = _tmp47_; | 1875 | _tmp46_ = _tmp45_; |
2889 | 1913 | _tmp48__length1 = 1; | 1876 | _tmp46__length1 = 1; |
2890 | 1914 | if (result_length1) { | 1877 | if (result_length1) { |
2892 | 1915 | *result_length1 = _tmp48__length1; | 1878 | *result_length1 = _tmp46__length1; |
2893 | 1916 | } | 1879 | } |
2895 | 1917 | result = _tmp48_; | 1880 | result = _tmp46_; |
2896 | 1918 | _g_object_unref0 (next_segment); | 1881 | _g_object_unref0 (next_segment); |
2897 | 1919 | _g_object_unref0 (segment); | 1882 | _g_object_unref0 (segment); |
2898 | 1920 | _kkc_trellis_node_unref0 (eos_trellis_node); | 1883 | _kkc_trellis_node_unref0 (eos_trellis_node); |
2899 | 1921 | _kkc_trellis_node_unref0 (bos_trellis_node); | 1884 | _kkc_trellis_node_unref0 (bos_trellis_node); |
2900 | 1922 | return result; | 1885 | return result; |
2901 | 1923 | } | 1886 | } |
2924 | 1924 | _tmp49_ = g_direct_hash; | 1887 | _tmp47_ = gee_hash_map_new (KKC_TYPE_TRELLIS_NODE, (GBoxedCopyFunc) kkc_trellis_node_ref, kkc_trellis_node_unref, KKC_TYPE_NBEST_NODE, (GBoxedCopyFunc) kkc_nbest_node_ref, kkc_nbest_node_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); |
2925 | 1925 | _tmp50_ = g_direct_equal; | 1888 | trellis_nbest_map = _tmp47_; |
2926 | 1926 | _tmp51_ = gee_hash_map_new (KKC_TYPE_TRELLIS_NODE, (GBoxedCopyFunc) kkc_trellis_node_ref, kkc_trellis_node_unref, KKC_TYPE_NBEST_NODE, (GBoxedCopyFunc) kkc_nbest_node_ref, kkc_nbest_node_unref, _tmp49_, _tmp50_, NULL); | 1889 | _tmp48_ = gee_priority_queue_new (KKC_TYPE_NBEST_NODE, (GBoxedCopyFunc) kkc_nbest_node_ref, kkc_nbest_node_unref, _kkc_bigram_decoder_compare_nbest_node_gcompare_data_func, NULL, NULL); |
2927 | 1927 | trellis_nbest_map = _tmp51_; | 1890 | open_list = _tmp48_; |
2928 | 1928 | _tmp52_ = gee_priority_queue_new (KKC_TYPE_NBEST_NODE, (GBoxedCopyFunc) kkc_nbest_node_ref, kkc_nbest_node_unref, (GCompareFunc) kkc_bigram_decoder_compare_nbest_node); | 1891 | _tmp49_ = gee_priority_queue_new (KKC_TYPE_NBEST_NODE, (GBoxedCopyFunc) kkc_nbest_node_ref, kkc_nbest_node_unref, _kkc_bigram_decoder_compare_nbest_node_gcompare_data_func, NULL, NULL); |
2929 | 1929 | open_list = _tmp52_; | 1892 | close_list = _tmp49_; |
2930 | 1930 | _tmp53_ = gee_priority_queue_new (KKC_TYPE_NBEST_NODE, (GBoxedCopyFunc) kkc_nbest_node_ref, kkc_nbest_node_unref, (GCompareFunc) kkc_bigram_decoder_compare_nbest_node); | 1893 | _tmp50_ = gee_hash_set_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL, NULL, NULL, NULL, NULL, NULL); |
2931 | 1931 | close_list = _tmp53_; | 1894 | duplicates = _tmp50_; |
2932 | 1932 | _tmp54_ = g_str_hash; | 1895 | _tmp51_ = eos_trellis_node; |
2933 | 1933 | _tmp55_ = g_str_equal; | 1896 | _tmp52_ = kkc_nbest_node_new (_tmp51_); |
2934 | 1934 | _tmp56_ = gee_hash_set_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, _tmp54_, _tmp55_); | 1897 | eos_nbest_node = _tmp52_; |
2935 | 1935 | duplicates = _tmp56_; | 1898 | _tmp53_ = trellis_nbest_map; |
2936 | 1936 | _tmp57_ = eos_trellis_node; | 1899 | _tmp54_ = eos_trellis_node; |
2937 | 1937 | _tmp58_ = kkc_nbest_node_new (_tmp57_); | 1900 | _tmp55_ = eos_nbest_node; |
2938 | 1938 | eos_nbest_node = _tmp58_; | 1901 | gee_abstract_map_set ((GeeAbstractMap*) _tmp53_, _tmp54_, _tmp55_); |
2939 | 1939 | _tmp59_ = trellis_nbest_map; | 1902 | _tmp56_ = open_list; |
2940 | 1940 | _tmp60_ = eos_trellis_node; | 1903 | _tmp57_ = eos_nbest_node; |
2941 | 1941 | _tmp61_ = eos_nbest_node; | 1904 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp56_, _tmp57_); |
2920 | 1942 | gee_abstract_map_set ((GeeAbstractMap*) _tmp59_, _tmp60_, _tmp61_); | ||
2921 | 1943 | _tmp62_ = open_list; | ||
2922 | 1944 | _tmp63_ = eos_nbest_node; | ||
2923 | 1945 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp62_, _tmp63_); | ||
2942 | 1946 | while (TRUE) { | 1905 | while (TRUE) { |
2946 | 1947 | GeePriorityQueue* _tmp64_ = NULL; | 1906 | GeePriorityQueue* _tmp58_ = NULL; |
2947 | 1948 | gboolean _tmp65_ = FALSE; | 1907 | gboolean _tmp59_ = FALSE; |
2948 | 1949 | gboolean _tmp66_ = FALSE; | 1908 | gboolean _tmp60_ = FALSE; |
2949 | 1950 | KkcNbestNode* current_nbest_node = NULL; | 1909 | KkcNbestNode* current_nbest_node = NULL; |
2959 | 1951 | GeePriorityQueue* _tmp67_ = NULL; | 1910 | GeePriorityQueue* _tmp61_ = NULL; |
2960 | 1952 | gpointer _tmp68_ = NULL; | 1911 | gpointer _tmp62_ = NULL; |
2961 | 1953 | KkcNbestNode* _tmp69_ = NULL; | 1912 | KkcNbestNode* _tmp63_ = NULL; |
2962 | 1954 | KkcTrellisNode* _tmp70_ = NULL; | 1913 | KkcTrellisNode* _tmp64_ = NULL; |
2963 | 1955 | KkcTrellisNode* _tmp71_ = NULL; | 1914 | KkcTrellisNode* _tmp65_ = NULL; |
2964 | 1956 | _tmp64_ = open_list; | 1915 | _tmp58_ = open_list; |
2965 | 1957 | _tmp65_ = gee_abstract_collection_get_is_empty ((GeeAbstractCollection*) _tmp64_); | 1916 | _tmp59_ = gee_collection_get_is_empty ((GeeCollection*) _tmp58_); |
2966 | 1958 | _tmp66_ = _tmp65_; | 1917 | _tmp60_ = _tmp59_; |
2967 | 1959 | if (!(!_tmp66_)) { | 1918 | if (!(!_tmp60_)) { |
2968 | 1960 | break; | 1919 | break; |
2969 | 1961 | } | 1920 | } |
2977 | 1962 | _tmp67_ = open_list; | 1921 | _tmp61_ = open_list; |
2978 | 1963 | _tmp68_ = gee_abstract_queue_poll ((GeeAbstractQueue*) _tmp67_); | 1922 | _tmp62_ = gee_abstract_queue_poll ((GeeAbstractQueue*) _tmp61_); |
2979 | 1964 | current_nbest_node = (KkcNbestNode*) _tmp68_; | 1923 | current_nbest_node = (KkcNbestNode*) _tmp62_; |
2980 | 1965 | _tmp69_ = current_nbest_node; | 1924 | _tmp63_ = current_nbest_node; |
2981 | 1966 | _tmp70_ = _tmp69_->node; | 1925 | _tmp64_ = _tmp63_->node; |
2982 | 1967 | _tmp71_ = bos_trellis_node; | 1926 | _tmp65_ = bos_trellis_node; |
2983 | 1968 | if (_tmp70_ == _tmp71_) { | 1927 | if (_tmp64_ == _tmp65_) { |
2984 | 1969 | gchar* output = NULL; | 1928 | gchar* output = NULL; |
3022 | 1970 | KkcNbestNode* _tmp72_ = NULL; | 1929 | KkcNbestNode* _tmp66_ = NULL; |
3023 | 1971 | gchar* _tmp73_ = NULL; | 1930 | gchar* _tmp67_ = NULL; |
3024 | 1972 | GeeHashSet* _tmp74_ = NULL; | 1931 | GeeHashSet* _tmp68_ = NULL; |
3025 | 1973 | const gchar* _tmp75_ = NULL; | 1932 | const gchar* _tmp69_ = NULL; |
3026 | 1974 | gboolean _tmp76_ = FALSE; | 1933 | gboolean _tmp70_ = FALSE; |
3027 | 1975 | _tmp72_ = current_nbest_node; | 1934 | _tmp66_ = current_nbest_node; |
3028 | 1976 | _tmp73_ = kkc_bigram_decoder_concat_nbest_node_outputs (self, _tmp72_); | 1935 | _tmp67_ = kkc_bigram_decoder_concat_nbest_node_outputs (self, _tmp66_); |
3029 | 1977 | output = _tmp73_; | 1936 | output = _tmp67_; |
3030 | 1978 | _tmp74_ = duplicates; | 1937 | _tmp68_ = duplicates; |
3031 | 1979 | _tmp75_ = output; | 1938 | _tmp69_ = output; |
3032 | 1980 | _tmp76_ = gee_abstract_collection_contains ((GeeAbstractCollection*) _tmp74_, _tmp75_); | 1939 | _tmp70_ = gee_abstract_collection_contains ((GeeAbstractCollection*) _tmp68_, _tmp69_); |
3033 | 1981 | if (!_tmp76_) { | 1940 | if (!_tmp70_) { |
3034 | 1982 | KkcTrellisNode* _tmp77_ = NULL; | 1941 | KkcTrellisNode* _tmp71_ = NULL; |
3035 | 1983 | gdouble _tmp78_ = 0.0; | 1942 | gdouble _tmp72_ = 0.0; |
3036 | 1984 | KkcNbestNode* _tmp79_ = NULL; | 1943 | KkcNbestNode* _tmp73_ = NULL; |
3037 | 1985 | gdouble _tmp80_ = 0.0; | 1944 | gdouble _tmp74_ = 0.0; |
3038 | 1986 | gdouble _tmp81_ = 0.0; | 1945 | gdouble _tmp75_ = 0.0; |
3039 | 1987 | GeePriorityQueue* _tmp82_ = NULL; | 1946 | GeePriorityQueue* _tmp76_ = NULL; |
3040 | 1988 | KkcNbestNode* _tmp83_ = NULL; | 1947 | KkcNbestNode* _tmp77_ = NULL; |
3041 | 1989 | GeePriorityQueue* _tmp84_ = NULL; | 1948 | GeePriorityQueue* _tmp78_ = NULL; |
3042 | 1990 | gint _tmp85_ = 0; | 1949 | gint _tmp79_ = 0; |
3043 | 1991 | gint _tmp86_ = 0; | 1950 | gint _tmp80_ = 0; |
3044 | 1992 | gint _tmp87_ = 0; | 1951 | gint _tmp81_ = 0; |
3045 | 1993 | GeeHashSet* _tmp88_ = NULL; | 1952 | GeeHashSet* _tmp82_ = NULL; |
3046 | 1994 | const gchar* _tmp89_ = NULL; | 1953 | const gchar* _tmp83_ = NULL; |
3047 | 1995 | _tmp77_ = eos_trellis_node; | 1954 | _tmp71_ = eos_trellis_node; |
3048 | 1996 | _tmp78_ = _tmp77_->cumulative_cost; | 1955 | _tmp72_ = _tmp71_->cumulative_cost; |
3049 | 1997 | _tmp79_ = current_nbest_node; | 1956 | _tmp73_ = current_nbest_node; |
3050 | 1998 | _tmp80_ = _tmp79_->fn; | 1957 | _tmp74_ = _tmp73_->fn; |
3051 | 1999 | _tmp81_ = max_distance; | 1958 | _tmp75_ = max_distance; |
3052 | 2000 | if ((_tmp78_ - _tmp80_) > _tmp81_) { | 1959 | if ((_tmp72_ - _tmp74_) > _tmp75_) { |
3053 | 2001 | _g_free0 (output); | 1960 | _g_free0 (output); |
3054 | 2002 | _kkc_nbest_node_unref0 (current_nbest_node); | 1961 | _kkc_nbest_node_unref0 (current_nbest_node); |
3055 | 2003 | break; | 1962 | break; |
3056 | 2004 | } | 1963 | } |
3057 | 2005 | _tmp82_ = close_list; | 1964 | _tmp76_ = close_list; |
3058 | 2006 | _tmp83_ = current_nbest_node; | 1965 | _tmp77_ = current_nbest_node; |
3059 | 1966 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp76_, _tmp77_); | ||
3060 | 1967 | _tmp78_ = close_list; | ||
3061 | 1968 | _tmp79_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp78_); | ||
3062 | 1969 | _tmp80_ = _tmp79_; | ||
3063 | 1970 | _tmp81_ = nbest; | ||
3064 | 1971 | if (_tmp80_ == _tmp81_) { | ||
3065 | 1972 | _g_free0 (output); | ||
3066 | 1973 | _kkc_nbest_node_unref0 (current_nbest_node); | ||
3067 | 1974 | break; | ||
3068 | 1975 | } | ||
3069 | 1976 | _tmp82_ = duplicates; | ||
3070 | 1977 | _tmp83_ = output; | ||
3071 | 2007 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp82_, _tmp83_); | 1978 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp82_, _tmp83_); |
3072 | 2008 | _tmp84_ = close_list; | ||
3073 | 2009 | _tmp85_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp84_); | ||
3074 | 2010 | _tmp86_ = _tmp85_; | ||
3075 | 2011 | _tmp87_ = nbest; | ||
3076 | 2012 | if (_tmp86_ == _tmp87_) { | ||
3077 | 2013 | _g_free0 (output); | ||
3078 | 2014 | _kkc_nbest_node_unref0 (current_nbest_node); | ||
3079 | 2015 | break; | ||
3080 | 2016 | } | ||
3081 | 2017 | _tmp88_ = duplicates; | ||
3082 | 2018 | _tmp89_ = output; | ||
3083 | 2019 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp88_, _tmp89_); | ||
3084 | 2020 | } | 1979 | } |
3085 | 2021 | _g_free0 (output); | 1980 | _g_free0 (output); |
3086 | 2022 | } else { | 1981 | } else { |
3104 | 2023 | KkcNbestNode* _tmp90_ = NULL; | 1982 | KkcNbestNode* _tmp84_ = NULL; |
3105 | 2024 | KkcTrellisNode* _tmp91_ = NULL; | 1983 | KkcTrellisNode* _tmp85_ = NULL; |
3106 | 2025 | guint _tmp92_ = 0U; | 1984 | guint _tmp86_ = 0U; |
3107 | 2026 | guint _tmp93_ = 0U; | 1985 | guint _tmp87_ = 0U; |
3108 | 2027 | KkcNbestNode* _tmp94_ = NULL; | 1986 | KkcNbestNode* _tmp88_ = NULL; |
3109 | 2028 | KkcTrellisNode* _tmp95_ = NULL; | 1987 | KkcTrellisNode* _tmp89_ = NULL; |
3110 | 2029 | guint _tmp96_ = 0U; | 1988 | guint _tmp90_ = 0U; |
3111 | 2030 | guint _tmp97_ = 0U; | 1989 | guint _tmp91_ = 0U; |
3112 | 2031 | _tmp90_ = current_nbest_node; | 1990 | _tmp84_ = current_nbest_node; |
3113 | 2032 | _tmp91_ = _tmp90_->node; | 1991 | _tmp85_ = _tmp84_->node; |
3114 | 2033 | _tmp92_ = kkc_trellis_node_get_endpos (_tmp91_); | 1992 | _tmp86_ = kkc_trellis_node_get_endpos (_tmp85_); |
3115 | 2034 | _tmp93_ = _tmp92_; | 1993 | _tmp87_ = _tmp86_; |
3116 | 2035 | _tmp94_ = current_nbest_node; | 1994 | _tmp88_ = current_nbest_node; |
3117 | 2036 | _tmp95_ = _tmp94_->node; | 1995 | _tmp89_ = _tmp88_->node; |
3118 | 2037 | _tmp96_ = kkc_trellis_node_get_length (_tmp95_); | 1996 | _tmp90_ = kkc_trellis_node_get_length (_tmp89_); |
3119 | 2038 | _tmp97_ = _tmp96_; | 1997 | _tmp91_ = _tmp90_; |
3120 | 2039 | if (_tmp93_ >= _tmp97_) { | 1998 | if (_tmp87_ >= _tmp91_) { |
3121 | 2040 | guint i = 0U; | 1999 | guint i = 0U; |
3139 | 2041 | KkcNbestNode* _tmp98_ = NULL; | 2000 | KkcNbestNode* _tmp92_ = NULL; |
3140 | 2042 | KkcTrellisNode* _tmp99_ = NULL; | 2001 | KkcTrellisNode* _tmp93_ = NULL; |
3141 | 2043 | guint _tmp100_ = 0U; | 2002 | guint _tmp94_ = 0U; |
3142 | 2044 | guint _tmp101_ = 0U; | 2003 | guint _tmp95_ = 0U; |
3143 | 2045 | KkcNbestNode* _tmp102_ = NULL; | 2004 | KkcNbestNode* _tmp96_ = NULL; |
3144 | 2046 | KkcTrellisNode* _tmp103_ = NULL; | 2005 | KkcTrellisNode* _tmp97_ = NULL; |
3145 | 2047 | guint _tmp104_ = 0U; | 2006 | guint _tmp98_ = 0U; |
3146 | 2048 | guint _tmp105_ = 0U; | 2007 | guint _tmp99_ = 0U; |
3147 | 2049 | _tmp98_ = current_nbest_node; | 2008 | _tmp92_ = current_nbest_node; |
3148 | 2050 | _tmp99_ = _tmp98_->node; | 2009 | _tmp93_ = _tmp92_->node; |
3149 | 2051 | _tmp100_ = kkc_trellis_node_get_endpos (_tmp99_); | 2010 | _tmp94_ = kkc_trellis_node_get_endpos (_tmp93_); |
3150 | 2052 | _tmp101_ = _tmp100_; | 2011 | _tmp95_ = _tmp94_; |
3151 | 2053 | _tmp102_ = current_nbest_node; | 2012 | _tmp96_ = current_nbest_node; |
3152 | 2054 | _tmp103_ = _tmp102_->node; | 2013 | _tmp97_ = _tmp96_->node; |
3153 | 2055 | _tmp104_ = kkc_trellis_node_get_length (_tmp103_); | 2014 | _tmp98_ = kkc_trellis_node_get_length (_tmp97_); |
3154 | 2056 | _tmp105_ = _tmp104_; | 2015 | _tmp99_ = _tmp98_; |
3155 | 2057 | i = ((gint) _tmp101_) - _tmp105_; | 2016 | i = ((gint) _tmp95_) - _tmp99_; |
3156 | 2058 | { | 2017 | { |
3157 | 2059 | GeeArrayList* _trellis_node_list = NULL; | 2018 | GeeArrayList* _trellis_node_list = NULL; |
3163 | 2060 | GeeArrayList** _tmp106_ = NULL; | 2019 | GeeArrayList** _tmp100_ = NULL; |
3164 | 2061 | gint _tmp106__length1 = 0; | 2020 | gint _tmp100__length1 = 0; |
3165 | 2062 | guint _tmp107_ = 0U; | 2021 | guint _tmp101_ = 0U; |
3166 | 2063 | GeeArrayList* _tmp108_ = NULL; | 2022 | GeeArrayList* _tmp102_ = NULL; |
3167 | 2064 | GeeArrayList* _tmp109_ = NULL; | 2023 | GeeArrayList* _tmp103_ = NULL; |
3168 | 2065 | gint _trellis_node_size = 0; | 2024 | gint _trellis_node_size = 0; |
3172 | 2066 | GeeArrayList* _tmp110_ = NULL; | 2025 | GeeArrayList* _tmp104_ = NULL; |
3173 | 2067 | gint _tmp111_ = 0; | 2026 | gint _tmp105_ = 0; |
3174 | 2068 | gint _tmp112_ = 0; | 2027 | gint _tmp106_ = 0; |
3175 | 2069 | gint _trellis_node_index = 0; | 2028 | gint _trellis_node_index = 0; |
3186 | 2070 | _tmp106_ = trellis; | 2029 | _tmp100_ = trellis; |
3187 | 2071 | _tmp106__length1 = trellis_length1; | 2030 | _tmp100__length1 = trellis_length1; |
3188 | 2072 | _tmp107_ = i; | 2031 | _tmp101_ = i; |
3189 | 2073 | _tmp108_ = _tmp106_[_tmp107_]; | 2032 | _tmp102_ = _tmp100_[_tmp101_]; |
3190 | 2074 | _tmp109_ = _g_object_ref0 (_tmp108_); | 2033 | _tmp103_ = _g_object_ref0 (_tmp102_); |
3191 | 2075 | _trellis_node_list = _tmp109_; | 2034 | _trellis_node_list = _tmp103_; |
3192 | 2076 | _tmp110_ = _trellis_node_list; | 2035 | _tmp104_ = _trellis_node_list; |
3193 | 2077 | _tmp111_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp110_); | 2036 | _tmp105_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp104_); |
3194 | 2078 | _tmp112_ = _tmp111_; | 2037 | _tmp106_ = _tmp105_; |
3195 | 2079 | _trellis_node_size = _tmp112_; | 2038 | _trellis_node_size = _tmp106_; |
3196 | 2080 | _trellis_node_index = -1; | 2039 | _trellis_node_index = -1; |
3197 | 2081 | while (TRUE) { | 2040 | while (TRUE) { |
3201 | 2082 | gint _tmp113_ = 0; | 2041 | gint _tmp107_ = 0; |
3202 | 2083 | gint _tmp114_ = 0; | 2042 | gint _tmp108_ = 0; |
3203 | 2084 | gint _tmp115_ = 0; | 2043 | gint _tmp109_ = 0; |
3204 | 2085 | KkcTrellisNode* trellis_node = NULL; | 2044 | KkcTrellisNode* trellis_node = NULL; |
3208 | 2086 | GeeArrayList* _tmp116_ = NULL; | 2045 | GeeArrayList* _tmp110_ = NULL; |
3209 | 2087 | gint _tmp117_ = 0; | 2046 | gint _tmp111_ = 0; |
3210 | 2088 | gpointer _tmp118_ = NULL; | 2047 | gpointer _tmp112_ = NULL; |
3211 | 2089 | KkcNbestNode* nbest_node = NULL; | 2048 | KkcNbestNode* nbest_node = NULL; |
3214 | 2090 | KkcTrellisNode* _tmp119_ = NULL; | 2049 | KkcTrellisNode* _tmp113_ = NULL; |
3215 | 2091 | KkcNbestNode* _tmp120_ = NULL; | 2050 | KkcNbestNode* _tmp114_ = NULL; |
3216 | 2092 | gdouble cost = 0.0; | 2051 | gdouble cost = 0.0; |
3218 | 2093 | KkcNbestNode* _tmp121_ = NULL; | 2052 | KkcNbestNode* _tmp115_ = NULL; |
3219 | 2053 | KkcTrellisNode* _tmp116_ = NULL; | ||
3220 | 2054 | KkcNbestNode* _tmp117_ = NULL; | ||
3221 | 2055 | KkcTrellisNode* _tmp118_ = NULL; | ||
3222 | 2056 | guint _tmp119_ = 0U; | ||
3223 | 2057 | gdouble _tmp120_ = 0.0; | ||
3224 | 2058 | gboolean _tmp121_ = FALSE; | ||
3225 | 2094 | KkcTrellisNode* _tmp122_ = NULL; | 2059 | KkcTrellisNode* _tmp122_ = NULL; |
3234 | 2095 | KkcNbestNode* _tmp123_ = NULL; | 2060 | KkcTrellisNode* _tmp123_ = NULL; |
3235 | 2096 | KkcTrellisNode* _tmp124_ = NULL; | 2061 | KkcNbestNode* _tmp126_ = NULL; |
3236 | 2097 | guint _tmp125_ = 0U; | 2062 | gdouble _tmp127_ = 0.0; |
3237 | 2098 | gdouble _tmp126_ = 0.0; | 2063 | KkcNbestNode* _tmp128_ = NULL; |
3238 | 2099 | gboolean _tmp127_ = FALSE; | 2064 | gdouble _tmp129_ = 0.0; |
3239 | 2100 | KkcTrellisNode* _tmp128_ = NULL; | 2065 | KkcNbestNode* _tmp130_ = NULL; |
3240 | 2101 | KkcTrellisNode* _tmp129_ = NULL; | 2066 | KkcNbestNode* _tmp131_ = NULL; |
3241 | 2102 | gboolean _tmp132_ = FALSE; | 2067 | gdouble _tmp132_ = 0.0; |
3242 | 2103 | KkcNbestNode* _tmp133_ = NULL; | 2068 | KkcNbestNode* _tmp133_ = NULL; |
3246 | 2104 | gdouble _tmp134_ = 0.0; | 2069 | KkcTrellisNode* _tmp134_ = NULL; |
3247 | 2105 | KkcNbestNode* _tmp135_ = NULL; | 2070 | gdouble _tmp135_ = 0.0; |
3248 | 2106 | gdouble _tmp136_ = 0.0; | 2071 | KkcNbestNode* _tmp136_ = NULL; |
3249 | 2107 | KkcNbestNode* _tmp137_ = NULL; | 2072 | KkcNbestNode* _tmp137_ = NULL; |
3250 | 2108 | KkcNbestNode* _tmp138_ = NULL; | 2073 | KkcNbestNode* _tmp138_ = NULL; |
3255 | 2109 | gdouble _tmp139_ = 0.0; | 2074 | GeeHashMap* _tmp139_ = NULL; |
3256 | 2110 | KkcNbestNode* _tmp140_ = NULL; | 2075 | KkcTrellisNode* _tmp140_ = NULL; |
3257 | 2111 | KkcTrellisNode* _tmp141_ = NULL; | 2076 | KkcNbestNode* _tmp141_ = NULL; |
3258 | 2112 | gdouble _tmp142_ = 0.0; | 2077 | GeePriorityQueue* _tmp142_ = NULL; |
3259 | 2113 | KkcNbestNode* _tmp143_ = NULL; | 2078 | KkcNbestNode* _tmp143_ = NULL; |
3272 | 2114 | KkcNbestNode* _tmp144_ = NULL; | 2079 | _tmp107_ = _trellis_node_index; |
3273 | 2115 | KkcNbestNode* _tmp145_ = NULL; | 2080 | _trellis_node_index = _tmp107_ + 1; |
3274 | 2116 | GeeHashMap* _tmp146_ = NULL; | 2081 | _tmp108_ = _trellis_node_index; |
3275 | 2117 | KkcTrellisNode* _tmp147_ = NULL; | 2082 | _tmp109_ = _trellis_node_size; |
3276 | 2118 | KkcNbestNode* _tmp148_ = NULL; | 2083 | if (!(_tmp108_ < _tmp109_)) { |
3265 | 2119 | GeePriorityQueue* _tmp149_ = NULL; | ||
3266 | 2120 | KkcNbestNode* _tmp150_ = NULL; | ||
3267 | 2121 | _tmp113_ = _trellis_node_index; | ||
3268 | 2122 | _trellis_node_index = _tmp113_ + 1; | ||
3269 | 2123 | _tmp114_ = _trellis_node_index; | ||
3270 | 2124 | _tmp115_ = _trellis_node_size; | ||
3271 | 2125 | if (!(_tmp114_ < _tmp115_)) { | ||
3277 | 2126 | break; | 2084 | break; |
3278 | 2127 | } | 2085 | } |
3301 | 2128 | _tmp116_ = _trellis_node_list; | 2086 | _tmp110_ = _trellis_node_list; |
3302 | 2129 | _tmp117_ = _trellis_node_index; | 2087 | _tmp111_ = _trellis_node_index; |
3303 | 2130 | _tmp118_ = gee_abstract_list_get ((GeeAbstractList*) _tmp116_, _tmp117_); | 2088 | _tmp112_ = gee_abstract_list_get ((GeeAbstractList*) _tmp110_, _tmp111_); |
3304 | 2131 | trellis_node = (KkcTrellisNode*) _tmp118_; | 2089 | trellis_node = (KkcTrellisNode*) _tmp112_; |
3305 | 2132 | _tmp119_ = trellis_node; | 2090 | _tmp113_ = trellis_node; |
3306 | 2133 | _tmp120_ = kkc_nbest_node_new (_tmp119_); | 2091 | _tmp114_ = kkc_nbest_node_new (_tmp113_); |
3307 | 2134 | nbest_node = _tmp120_; | 2092 | nbest_node = _tmp114_; |
3308 | 2135 | _tmp121_ = nbest_node; | 2093 | _tmp115_ = nbest_node; |
3309 | 2136 | _tmp122_ = _tmp121_->node; | 2094 | _tmp116_ = _tmp115_->node; |
3310 | 2137 | _tmp123_ = current_nbest_node; | 2095 | _tmp117_ = current_nbest_node; |
3311 | 2138 | _tmp124_ = _tmp123_->node; | 2096 | _tmp118_ = _tmp117_->node; |
3312 | 2139 | _tmp125_ = i; | 2097 | _tmp119_ = i; |
3313 | 2140 | _tmp126_ = kkc_bigram_decoder_path_cost (self, _tmp122_, _tmp124_, (gint) _tmp125_); | 2098 | _tmp120_ = kkc_bigram_decoder_path_cost (self, _tmp116_, _tmp118_, (gint) _tmp119_); |
3314 | 2141 | cost = _tmp126_; | 2099 | cost = _tmp120_; |
3315 | 2142 | _tmp128_ = trellis_node; | 2100 | _tmp122_ = trellis_node; |
3316 | 2143 | _tmp129_ = bos_trellis_node; | 2101 | _tmp123_ = bos_trellis_node; |
3317 | 2144 | if (_tmp128_ != _tmp129_) { | 2102 | if (_tmp122_ != _tmp123_) { |
3318 | 2145 | gdouble _tmp130_ = 0.0; | 2103 | gdouble _tmp124_ = 0.0; |
3319 | 2146 | gdouble _tmp131_ = 0.0; | 2104 | gdouble _tmp125_ = 0.0; |
3320 | 2147 | _tmp130_ = cost; | 2105 | _tmp124_ = cost; |
3321 | 2148 | _tmp131_ = min_path_cost; | 2106 | _tmp125_ = min_path_cost; |
3322 | 2149 | _tmp127_ = _tmp130_ < _tmp131_; | 2107 | _tmp121_ = _tmp124_ < _tmp125_; |
3323 | 2150 | } else { | 2108 | } else { |
3325 | 2151 | _tmp127_ = FALSE; | 2109 | _tmp121_ = FALSE; |
3326 | 2152 | } | 2110 | } |
3329 | 2153 | _tmp132_ = _tmp127_; | 2111 | if (_tmp121_) { |
3328 | 2154 | if (_tmp132_) { | ||
3330 | 2155 | _kkc_nbest_node_unref0 (nbest_node); | 2112 | _kkc_nbest_node_unref0 (nbest_node); |
3331 | 2156 | _kkc_trellis_node_unref0 (trellis_node); | 2113 | _kkc_trellis_node_unref0 (trellis_node); |
3332 | 2157 | continue; | 2114 | continue; |
3333 | 2158 | } | 2115 | } |
3334 | 2116 | _tmp126_ = nbest_node; | ||
3335 | 2117 | _tmp127_ = cost; | ||
3336 | 2118 | _tmp128_ = current_nbest_node; | ||
3337 | 2119 | _tmp129_ = _tmp128_->gn; | ||
3338 | 2120 | _tmp126_->gn = _tmp127_ + _tmp129_; | ||
3339 | 2121 | _tmp130_ = nbest_node; | ||
3340 | 2122 | _tmp131_ = nbest_node; | ||
3341 | 2123 | _tmp132_ = _tmp131_->gn; | ||
3342 | 2159 | _tmp133_ = nbest_node; | 2124 | _tmp133_ = nbest_node; |
3354 | 2160 | _tmp134_ = cost; | 2125 | _tmp134_ = _tmp133_->node; |
3355 | 2161 | _tmp135_ = current_nbest_node; | 2126 | _tmp135_ = _tmp134_->cumulative_cost; |
3356 | 2162 | _tmp136_ = _tmp135_->gn; | 2127 | _tmp130_->fn = _tmp132_ + _tmp135_; |
3357 | 2163 | _tmp133_->gn = _tmp134_ + _tmp136_; | 2128 | _tmp136_ = nbest_node; |
3358 | 2164 | _tmp137_ = nbest_node; | 2129 | _tmp137_ = current_nbest_node; |
3359 | 2165 | _tmp138_ = nbest_node; | 2130 | _tmp138_ = _kkc_nbest_node_ref0 (_tmp137_); |
3360 | 2166 | _tmp139_ = _tmp138_->gn; | 2131 | _kkc_nbest_node_unref0 (_tmp136_->next); |
3361 | 2167 | _tmp140_ = nbest_node; | 2132 | _tmp136_->next = _tmp138_; |
3362 | 2168 | _tmp141_ = _tmp140_->node; | 2133 | _tmp139_ = trellis_nbest_map; |
3363 | 2169 | _tmp142_ = _tmp141_->cumulative_cost; | 2134 | _tmp140_ = trellis_node; |
3364 | 2170 | _tmp137_->fn = _tmp139_ + _tmp142_; | 2135 | _tmp141_ = nbest_node; |
3365 | 2136 | gee_abstract_map_set ((GeeAbstractMap*) _tmp139_, _tmp140_, _tmp141_); | ||
3366 | 2137 | _tmp142_ = open_list; | ||
3367 | 2171 | _tmp143_ = nbest_node; | 2138 | _tmp143_ = nbest_node; |
3379 | 2172 | _tmp144_ = current_nbest_node; | 2139 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp142_, _tmp143_); |
3369 | 2173 | _tmp145_ = _kkc_nbest_node_ref0 (_tmp144_); | ||
3370 | 2174 | _kkc_nbest_node_unref0 (_tmp143_->next); | ||
3371 | 2175 | _tmp143_->next = _tmp145_; | ||
3372 | 2176 | _tmp146_ = trellis_nbest_map; | ||
3373 | 2177 | _tmp147_ = trellis_node; | ||
3374 | 2178 | _tmp148_ = nbest_node; | ||
3375 | 2179 | gee_abstract_map_set ((GeeAbstractMap*) _tmp146_, _tmp147_, _tmp148_); | ||
3376 | 2180 | _tmp149_ = open_list; | ||
3377 | 2181 | _tmp150_ = nbest_node; | ||
3378 | 2182 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp149_, _tmp150_); | ||
3380 | 2183 | _kkc_nbest_node_unref0 (nbest_node); | 2140 | _kkc_nbest_node_unref0 (nbest_node); |
3381 | 2184 | _kkc_trellis_node_unref0 (trellis_node); | 2141 | _kkc_trellis_node_unref0 (trellis_node); |
3382 | 2185 | } | 2142 | } |
3383 | @@ -2189,53 +2146,53 @@ | |||
3384 | 2189 | } | 2146 | } |
3385 | 2190 | _kkc_nbest_node_unref0 (current_nbest_node); | 2147 | _kkc_nbest_node_unref0 (current_nbest_node); |
3386 | 2191 | } | 2148 | } |
3389 | 2192 | _tmp151_ = gee_array_list_new (KKC_TYPE_SEGMENT, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL); | 2149 | _tmp144_ = gee_array_list_new (KKC_TYPE_SEGMENT, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL); |
3390 | 2193 | segments = _tmp151_; | 2150 | segments = _tmp144_; |
3391 | 2194 | { | 2151 | { |
3392 | 2195 | GeeIterator* _nbest_node_it = NULL; | 2152 | GeeIterator* _nbest_node_it = NULL; |
3398 | 2196 | GeePriorityQueue* _tmp152_ = NULL; | 2153 | GeePriorityQueue* _tmp145_ = NULL; |
3399 | 2197 | GeeIterator* _tmp153_ = NULL; | 2154 | GeeIterator* _tmp146_ = NULL; |
3400 | 2198 | _tmp152_ = close_list; | 2155 | _tmp145_ = close_list; |
3401 | 2199 | _tmp153_ = gee_abstract_collection_iterator ((GeeAbstractCollection*) _tmp152_); | 2156 | _tmp146_ = gee_abstract_collection_iterator ((GeeAbstractCollection*) _tmp145_); |
3402 | 2200 | _nbest_node_it = _tmp153_; | 2157 | _nbest_node_it = _tmp146_; |
3403 | 2201 | while (TRUE) { | 2158 | while (TRUE) { |
3406 | 2202 | GeeIterator* _tmp154_ = NULL; | 2159 | GeeIterator* _tmp147_ = NULL; |
3407 | 2203 | gboolean _tmp155_ = FALSE; | 2160 | gboolean _tmp148_ = FALSE; |
3408 | 2204 | KkcNbestNode* nbest_node = NULL; | 2161 | KkcNbestNode* nbest_node = NULL; |
3419 | 2205 | GeeIterator* _tmp156_ = NULL; | 2162 | GeeIterator* _tmp149_ = NULL; |
3420 | 2206 | gpointer _tmp157_ = NULL; | 2163 | gpointer _tmp150_ = NULL; |
3421 | 2207 | GeeArrayList* _tmp158_ = NULL; | 2164 | GeeArrayList* _tmp151_ = NULL; |
3422 | 2208 | KkcNbestNode* _tmp159_ = NULL; | 2165 | KkcNbestNode* _tmp152_ = NULL; |
3423 | 2209 | KkcNbestNode* _tmp160_ = NULL; | 2166 | KkcNbestNode* _tmp153_ = NULL; |
3424 | 2210 | KkcSegment* _tmp161_ = NULL; | 2167 | KkcSegment* _tmp154_ = NULL; |
3425 | 2211 | KkcSegment* _tmp162_ = NULL; | 2168 | KkcSegment* _tmp155_ = NULL; |
3426 | 2212 | _tmp154_ = _nbest_node_it; | 2169 | _tmp147_ = _nbest_node_it; |
3427 | 2213 | _tmp155_ = gee_iterator_next (_tmp154_); | 2170 | _tmp148_ = gee_iterator_next (_tmp147_); |
3428 | 2214 | if (!_tmp155_) { | 2171 | if (!_tmp148_) { |
3429 | 2215 | break; | 2172 | break; |
3430 | 2216 | } | 2173 | } |
3441 | 2217 | _tmp156_ = _nbest_node_it; | 2174 | _tmp149_ = _nbest_node_it; |
3442 | 2218 | _tmp157_ = gee_iterator_get (_tmp156_); | 2175 | _tmp150_ = gee_iterator_get (_tmp149_); |
3443 | 2219 | nbest_node = (KkcNbestNode*) _tmp157_; | 2176 | nbest_node = (KkcNbestNode*) _tmp150_; |
3444 | 2220 | _tmp158_ = segments; | 2177 | _tmp151_ = segments; |
3445 | 2221 | _tmp159_ = nbest_node; | 2178 | _tmp152_ = nbest_node; |
3446 | 2222 | _tmp160_ = _tmp159_->next; | 2179 | _tmp153_ = _tmp152_->next; |
3447 | 2223 | _tmp161_ = kkc_bigram_decoder_nbest_node_to_segment (self, _tmp160_); | 2180 | _tmp154_ = kkc_bigram_decoder_nbest_node_to_segment (self, _tmp153_); |
3448 | 2224 | _tmp162_ = _tmp161_; | 2181 | _tmp155_ = _tmp154_; |
3449 | 2225 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp158_, _tmp162_); | 2182 | gee_abstract_collection_add ((GeeAbstractCollection*) _tmp151_, _tmp155_); |
3450 | 2226 | _g_object_unref0 (_tmp162_); | 2183 | _g_object_unref0 (_tmp155_); |
3451 | 2227 | _kkc_nbest_node_unref0 (nbest_node); | 2184 | _kkc_nbest_node_unref0 (nbest_node); |
3452 | 2228 | } | 2185 | } |
3453 | 2229 | _g_object_unref0 (_nbest_node_it); | 2186 | _g_object_unref0 (_nbest_node_it); |
3454 | 2230 | } | 2187 | } |
3459 | 2231 | _tmp163_ = segments; | 2188 | _tmp156_ = segments; |
3460 | 2232 | _tmp165_ = gee_abstract_collection_to_array ((GeeAbstractCollection*) _tmp163_, &_tmp164_); | 2189 | _tmp158_ = gee_collection_to_array ((GeeCollection*) _tmp156_, &_tmp157_); |
3461 | 2233 | _tmp166_ = _tmp165_; | 2190 | _tmp159_ = _tmp158_; |
3462 | 2234 | _tmp166__length1 = _tmp164_; | 2191 | _tmp159__length1 = _tmp157_; |
3463 | 2235 | if (result_length1) { | 2192 | if (result_length1) { |
3465 | 2236 | *result_length1 = _tmp166__length1; | 2193 | *result_length1 = _tmp159__length1; |
3466 | 2237 | } | 2194 | } |
3468 | 2238 | result = _tmp166_; | 2195 | result = _tmp159_; |
3469 | 2239 | _g_object_unref0 (segments); | 2196 | _g_object_unref0 (segments); |
3470 | 2240 | _kkc_nbest_node_unref0 (eos_nbest_node); | 2197 | _kkc_nbest_node_unref0 (eos_nbest_node); |
3471 | 2241 | _g_object_unref0 (duplicates); | 2198 | _g_object_unref0 (duplicates); |
3472 | @@ -2358,9 +2315,9 @@ | |||
3473 | 2358 | static void kkc_bigram_decoder_class_init (KkcBigramDecoderClass * klass) { | 2315 | static void kkc_bigram_decoder_class_init (KkcBigramDecoderClass * klass) { |
3474 | 2359 | kkc_bigram_decoder_parent_class = g_type_class_peek_parent (klass); | 2316 | kkc_bigram_decoder_parent_class = g_type_class_peek_parent (klass); |
3475 | 2360 | g_type_class_add_private (klass, sizeof (KkcBigramDecoderPrivate)); | 2317 | g_type_class_add_private (klass, sizeof (KkcBigramDecoderPrivate)); |
3479 | 2361 | KKC_DECODER_CLASS (klass)->decode = kkc_bigram_decoder_real_decode; | 2318 | ((KkcDecoderClass *) klass)->decode = kkc_bigram_decoder_real_decode; |
3480 | 2362 | KKC_DECODER_CLASS (klass)->decode_with_costs = kkc_bigram_decoder_real_decode_with_costs; | 2319 | ((KkcDecoderClass *) klass)->decode_with_costs = kkc_bigram_decoder_real_decode_with_costs; |
3481 | 2363 | KKC_BIGRAM_DECODER_CLASS (klass)->path_cost = kkc_bigram_decoder_real_path_cost; | 2320 | ((KkcBigramDecoderClass *) klass)->path_cost = kkc_bigram_decoder_real_path_cost; |
3482 | 2364 | G_OBJECT_CLASS (klass)->get_property = _vala_kkc_bigram_decoder_get_property; | 2321 | G_OBJECT_CLASS (klass)->get_property = _vala_kkc_bigram_decoder_get_property; |
3483 | 2365 | G_OBJECT_CLASS (klass)->finalize = kkc_bigram_decoder_finalize; | 2322 | G_OBJECT_CLASS (klass)->finalize = kkc_bigram_decoder_finalize; |
3484 | 2366 | g_object_class_install_property (G_OBJECT_CLASS (klass), KKC_BIGRAM_DECODER_MODEL, g_param_spec_object ("model", "model", "model", KKC_TYPE_BIGRAM_LANGUAGE_MODEL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE)); | 2323 | g_object_class_install_property (G_OBJECT_CLASS (klass), KKC_BIGRAM_DECODER_MODEL, g_param_spec_object ("model", "model", "model", KKC_TYPE_BIGRAM_LANGUAGE_MODEL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE)); |
3485 | 2367 | 2324 | ||
3486 | === modified file 'libkkc/bigram-decoder.vala' | |||
3487 | --- libkkc/bigram-decoder.vala 2014-02-26 22:51:39 +0000 | |||
3488 | +++ libkkc/bigram-decoder.vala 2014-10-01 15:12:30 +0000 | |||
3489 | @@ -1,6 +1,6 @@ | |||
3490 | 1 | /* | 1 | /* |
3493 | 2 | * Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
3494 | 3 | * Copyright (C) 2012-2013 Red Hat, Inc. | 3 | * Copyright (C) 2012-2014 Red Hat, Inc. |
3495 | 4 | * | 4 | * |
3496 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
3497 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
3498 | @@ -228,17 +228,13 @@ | |||
3499 | 228 | return new Segment[] { segment }; | 228 | return new Segment[] { segment }; |
3500 | 229 | } | 229 | } |
3501 | 230 | 230 | ||
3513 | 231 | var trellis_nbest_map = new HashMap<TrellisNode,NbestNode> ( | 231 | var trellis_nbest_map = new HashMap<TrellisNode,NbestNode> (); |
3514 | 232 | direct_hash, | 232 | |
3515 | 233 | direct_equal); | 233 | var open_list = new PriorityQueue<NbestNode> (compare_nbest_node); |
3516 | 234 | 234 | ||
3517 | 235 | var open_list = new PriorityQueue<NbestNode> ( | 235 | var close_list = new PriorityQueue<NbestNode> (compare_nbest_node); |
3518 | 236 | (CompareFunc)compare_nbest_node); | 236 | |
3519 | 237 | 237 | var duplicates = new Gee.HashSet<string> (); | |
3509 | 238 | var close_list = new PriorityQueue<NbestNode> ( | ||
3510 | 239 | (CompareFunc)compare_nbest_node); | ||
3511 | 240 | |||
3512 | 241 | var duplicates = new HashSet<string> (str_hash, str_equal); | ||
3520 | 242 | 238 | ||
3521 | 243 | var eos_nbest_node = new NbestNode (eos_trellis_node); | 239 | var eos_nbest_node = new NbestNode (eos_trellis_node); |
3522 | 244 | trellis_nbest_map.set (eos_trellis_node, eos_nbest_node); | 240 | trellis_nbest_map.set (eos_trellis_node, eos_nbest_node); |
3523 | 245 | 241 | ||
3524 | === modified file 'libkkc/bloom-filter.c' | |||
3525 | --- libkkc/bloom-filter.c 2014-06-15 23:27:57 +0000 | |||
3526 | +++ libkkc/bloom-filter.c 2014-10-01 15:12:30 +0000 | |||
3527 | @@ -1,9 +1,9 @@ | |||
3529 | 1 | /* bloom-filter.c generated by valac 0.22.1, the Vala compiler | 1 | /* bloom-filter.c generated by valac 0.24.0.131-42e78, the Vala compiler |
3530 | 2 | * generated from bloom-filter.vala, do not modify */ | 2 | * generated from bloom-filter.vala, do not modify */ |
3531 | 3 | 3 | ||
3532 | 4 | /* | 4 | /* |
3535 | 5 | * Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
3536 | 6 | * Copyright (C) 2012-2013 Red Hat, Inc. | 6 | * Copyright (C) 2012-2014 Red Hat, Inc. |
3537 | 7 | * | 7 | * |
3538 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
3539 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
3540 | @@ -160,19 +160,23 @@ | |||
3541 | 160 | GMappedFile* _tmp0_ = NULL; | 160 | GMappedFile* _tmp0_ = NULL; |
3542 | 161 | const gchar* _tmp1_ = NULL; | 161 | const gchar* _tmp1_ = NULL; |
3543 | 162 | GMappedFile* _tmp2_ = NULL; | 162 | GMappedFile* _tmp2_ = NULL; |
3544 | 163 | GMappedFile* _tmp3_ = NULL; | ||
3545 | 163 | GError * _inner_error_ = NULL; | 164 | GError * _inner_error_ = NULL; |
3546 | 164 | g_return_val_if_fail (filename != NULL, NULL); | 165 | g_return_val_if_fail (filename != NULL, NULL); |
3547 | 165 | self = (KkcBloomFilter*) g_object_new (object_type, NULL); | 166 | self = (KkcBloomFilter*) g_object_new (object_type, NULL); |
3548 | 166 | _tmp1_ = filename; | 167 | _tmp1_ = filename; |
3549 | 167 | _tmp2_ = g_mapped_file_new (_tmp1_, FALSE, &_inner_error_); | 168 | _tmp2_ = g_mapped_file_new (_tmp1_, FALSE, &_inner_error_); |
3550 | 168 | _tmp0_ = _tmp2_; | 169 | _tmp0_ = _tmp2_; |
3552 | 169 | if (_inner_error_ != NULL) { | 170 | if (G_UNLIKELY (_inner_error_ != NULL)) { |
3553 | 170 | g_propagate_error (error, _inner_error_); | 171 | g_propagate_error (error, _inner_error_); |
3554 | 171 | _g_object_unref0 (self); | 172 | _g_object_unref0 (self); |
3555 | 172 | return NULL; | 173 | return NULL; |
3556 | 173 | } | 174 | } |
3557 | 175 | _tmp3_ = _tmp0_; | ||
3558 | 176 | _tmp0_ = NULL; | ||
3559 | 174 | _g_mapped_file_unref0 (self->priv->mmap); | 177 | _g_mapped_file_unref0 (self->priv->mmap); |
3561 | 175 | self->priv->mmap = _tmp0_; | 178 | self->priv->mmap = _tmp3_; |
3562 | 179 | _g_mapped_file_unref0 (_tmp0_); | ||
3563 | 176 | return self; | 180 | return self; |
3564 | 177 | } | 181 | } |
3565 | 178 | 182 | ||
3566 | @@ -217,42 +221,40 @@ | |||
3567 | 217 | gboolean _tmp0_ = FALSE; | 221 | gboolean _tmp0_ = FALSE; |
3568 | 218 | _tmp0_ = TRUE; | 222 | _tmp0_ = TRUE; |
3569 | 219 | while (TRUE) { | 223 | while (TRUE) { |
3572 | 220 | gboolean _tmp1_ = FALSE; | 224 | gint _tmp2_ = 0; |
3571 | 221 | gint _tmp3_ = 0; | ||
3573 | 222 | guint32 h = 0U; | 225 | guint32 h = 0U; |
3574 | 226 | guint32 _tmp3_ = 0U; | ||
3575 | 223 | guint32 _tmp4_ = 0U; | 227 | guint32 _tmp4_ = 0U; |
3578 | 224 | guint32 _tmp5_ = 0U; | 228 | gint _tmp5_ = 0; |
3579 | 225 | gint _tmp6_ = 0; | 229 | guint32 _tmp6_ = 0U; |
3580 | 230 | guint32 i = 0U; | ||
3581 | 226 | guint32 _tmp7_ = 0U; | 231 | guint32 _tmp7_ = 0U; |
3593 | 227 | guint32 i = 0U; | 232 | GMappedFile* _tmp8_ = NULL; |
3594 | 228 | guint32 _tmp8_ = 0U; | 233 | gsize _tmp9_ = 0UL; |
3595 | 229 | GMappedFile* _tmp9_ = NULL; | 234 | guint32 _tmp10_ = 0U; |
3596 | 230 | gsize _tmp10_ = 0UL; | 235 | gboolean _tmp11_ = FALSE; |
3597 | 231 | guint32 _tmp11_ = 0U; | 236 | if (!_tmp0_) { |
3598 | 232 | gboolean _tmp12_ = FALSE; | 237 | gint _tmp1_ = 0; |
3599 | 233 | _tmp1_ = _tmp0_; | 238 | _tmp1_ = k; |
3600 | 234 | if (!_tmp1_) { | 239 | k = _tmp1_ + 1; |
3590 | 235 | gint _tmp2_ = 0; | ||
3591 | 236 | _tmp2_ = k; | ||
3592 | 237 | k = _tmp2_ + 1; | ||
3601 | 238 | } | 240 | } |
3602 | 239 | _tmp0_ = FALSE; | 241 | _tmp0_ = FALSE; |
3605 | 240 | _tmp3_ = k; | 242 | _tmp2_ = k; |
3606 | 241 | if (!(_tmp3_ < 4)) { | 243 | if (!(_tmp2_ < 4)) { |
3607 | 242 | break; | 244 | break; |
3608 | 243 | } | 245 | } |
3621 | 244 | _tmp4_ = b0; | 246 | _tmp3_ = b0; |
3622 | 245 | _tmp5_ = b1; | 247 | _tmp4_ = b1; |
3623 | 246 | _tmp6_ = k; | 248 | _tmp5_ = k; |
3624 | 247 | _tmp7_ = kkc_murmur_hash3_32 (_tmp4_, _tmp5_, (guint32) _tmp6_); | 249 | _tmp6_ = kkc_murmur_hash3_32 (_tmp3_, _tmp4_, (guint32) _tmp5_); |
3625 | 248 | h = _tmp7_; | 250 | h = _tmp6_; |
3626 | 249 | _tmp8_ = h; | 251 | _tmp7_ = h; |
3627 | 250 | _tmp9_ = self->priv->mmap; | 252 | _tmp8_ = self->priv->mmap; |
3628 | 251 | _tmp10_ = g_mapped_file_get_length (_tmp9_); | 253 | _tmp9_ = g_mapped_file_get_length (_tmp8_); |
3629 | 252 | i = (guint32) (_tmp8_ * ((_tmp10_ * 8) / ((gdouble) 0xFFFFFFFFLL))); | 254 | i = (guint32) (_tmp7_ * ((_tmp9_ * 8) / ((gdouble) 0xFFFFFFFFLL))); |
3630 | 253 | _tmp11_ = i; | 255 | _tmp10_ = i; |
3631 | 254 | _tmp12_ = kkc_bloom_filter_is_bit_set (self, _tmp11_); | 256 | _tmp11_ = kkc_bloom_filter_is_bit_set (self, _tmp10_); |
3632 | 255 | if (!_tmp12_) { | 257 | if (!_tmp11_) { |
3633 | 256 | result = FALSE; | 258 | result = FALSE; |
3634 | 257 | return result; | 259 | return result; |
3635 | 258 | } | 260 | } |
3636 | 259 | 261 | ||
3637 | === modified file 'libkkc/bloom-filter.vala' | |||
3638 | --- libkkc/bloom-filter.vala 2014-02-26 22:51:39 +0000 | |||
3639 | +++ libkkc/bloom-filter.vala 2014-10-01 15:12:30 +0000 | |||
3640 | @@ -1,6 +1,6 @@ | |||
3641 | 1 | /* | 1 | /* |
3644 | 2 | * Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
3645 | 3 | * Copyright (C) 2012-2013 Red Hat, Inc. | 3 | * Copyright (C) 2012-2014 Red Hat, Inc. |
3646 | 4 | * | 4 | * |
3647 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
3648 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
3649 | 7 | 7 | ||
3650 | === modified file 'libkkc/candidate-list.c' | |||
3651 | --- libkkc/candidate-list.c 2014-06-15 23:27:57 +0000 | |||
3652 | +++ libkkc/candidate-list.c 2014-10-01 15:12:30 +0000 | |||
3653 | @@ -1,9 +1,9 @@ | |||
3655 | 1 | /* candidate-list.c generated by valac 0.22.1, the Vala compiler | 1 | /* candidate-list.c generated by valac 0.24.0.131-42e78, the Vala compiler |
3656 | 2 | * generated from candidate-list.vala, do not modify */ | 2 | * generated from candidate-list.vala, do not modify */ |
3657 | 3 | 3 | ||
3658 | 4 | /* | 4 | /* |
3661 | 5 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
3662 | 6 | * Copyright (C) 2011-2013 Red Hat, Inc. | 6 | * Copyright (C) 2011-2014 Red Hat, Inc. |
3663 | 7 | * | 7 | * |
3664 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
3665 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
3666 | @@ -134,10 +134,9 @@ | |||
3667 | 134 | gint _tmp0_ = 0; | 134 | gint _tmp0_ = 0; |
3668 | 135 | gboolean _tmp2_ = FALSE; | 135 | gboolean _tmp2_ = FALSE; |
3669 | 136 | gint _tmp3_ = 0; | 136 | gint _tmp3_ = 0; |
3674 | 137 | gboolean _tmp7_ = FALSE; | 137 | GeeArrayList* _tmp7_ = NULL; |
3675 | 138 | GeeArrayList* _tmp8_ = NULL; | 138 | gint _tmp8_ = 0; |
3676 | 139 | gint _tmp9_ = 0; | 139 | gpointer _tmp9_ = NULL; |
3673 | 140 | gpointer _tmp10_ = NULL; | ||
3677 | 141 | g_return_val_if_fail (self != NULL, NULL); | 140 | g_return_val_if_fail (self != NULL, NULL); |
3678 | 142 | _tmp0_ = index; | 141 | _tmp0_ = index; |
3679 | 143 | if (_tmp0_ < 0) { | 142 | if (_tmp0_ < 0) { |
3680 | @@ -157,12 +156,11 @@ | |||
3681 | 157 | } else { | 156 | } else { |
3682 | 158 | _tmp2_ = FALSE; | 157 | _tmp2_ = FALSE; |
3683 | 159 | } | 158 | } |
3690 | 160 | _tmp7_ = _tmp2_; | 159 | _vala_assert (_tmp2_, "0 <= index && index < size"); |
3691 | 161 | _vala_assert (_tmp7_, "0 <= index && index < size"); | 160 | _tmp7_ = self->priv->_candidates; |
3692 | 162 | _tmp8_ = self->priv->_candidates; | 161 | _tmp8_ = index; |
3693 | 163 | _tmp9_ = index; | 162 | _tmp9_ = gee_abstract_list_get ((GeeAbstractList*) _tmp7_, _tmp8_); |
3694 | 164 | _tmp10_ = gee_abstract_list_get ((GeeAbstractList*) _tmp8_, _tmp9_); | 163 | result = (KkcCandidate*) _tmp9_; |
3689 | 165 | result = (KkcCandidate*) _tmp10_; | ||
3695 | 166 | return result; | 164 | return result; |
3696 | 167 | } | 165 | } |
3697 | 168 | 166 | ||
3698 | @@ -337,7 +335,7 @@ | |||
3699 | 337 | gint _tmp3__length1 = 0; | 335 | gint _tmp3__length1 = 0; |
3700 | 338 | g_return_val_if_fail (self != NULL, NULL); | 336 | g_return_val_if_fail (self != NULL, NULL); |
3701 | 339 | _tmp0_ = self->priv->_candidates; | 337 | _tmp0_ = self->priv->_candidates; |
3703 | 340 | _tmp2_ = gee_abstract_collection_to_array ((GeeAbstractCollection*) _tmp0_, &_tmp1_); | 338 | _tmp2_ = gee_collection_to_array ((GeeCollection*) _tmp0_, &_tmp1_); |
3704 | 341 | _tmp3_ = _tmp2_; | 339 | _tmp3_ = _tmp2_; |
3705 | 342 | _tmp3__length1 = _tmp1_; | 340 | _tmp3__length1 = _tmp1_; |
3706 | 343 | if (result_length1) { | 341 | if (result_length1) { |
3707 | @@ -551,10 +549,9 @@ | |||
3708 | 551 | gboolean _tmp2_ = FALSE; | 549 | gboolean _tmp2_ = FALSE; |
3709 | 552 | gboolean _tmp3_ = FALSE; | 550 | gboolean _tmp3_ = FALSE; |
3710 | 553 | gboolean _tmp5_ = FALSE; | 551 | gboolean _tmp5_ = FALSE; |
3711 | 554 | gboolean _tmp6_ = FALSE; | ||
3712 | 555 | g_return_val_if_fail (self != NULL, FALSE); | 552 | g_return_val_if_fail (self != NULL, FALSE); |
3713 | 556 | _tmp1_ = self->priv->_candidates; | 553 | _tmp1_ = self->priv->_candidates; |
3715 | 557 | _tmp2_ = gee_abstract_collection_get_is_empty ((GeeAbstractCollection*) _tmp1_); | 554 | _tmp2_ = gee_collection_get_is_empty ((GeeCollection*) _tmp1_); |
3716 | 558 | _tmp3_ = _tmp2_; | 555 | _tmp3_ = _tmp2_; |
3717 | 559 | if (_tmp3_) { | 556 | if (_tmp3_) { |
3718 | 560 | _tmp0_ = TRUE; | 557 | _tmp0_ = TRUE; |
3719 | @@ -563,30 +560,156 @@ | |||
3720 | 563 | _tmp4_ = step; | 560 | _tmp4_ = step; |
3721 | 564 | _tmp0_ = _tmp4_ == 0; | 561 | _tmp0_ = _tmp4_ == 0; |
3722 | 565 | } | 562 | } |
3725 | 566 | _tmp5_ = _tmp0_; | 563 | if (_tmp0_) { |
3724 | 567 | if (_tmp5_) { | ||
3726 | 568 | result = FALSE; | 564 | result = FALSE; |
3727 | 569 | return result; | 565 | return result; |
3728 | 570 | } | 566 | } |
3731 | 571 | _tmp6_ = self->priv->_round; | 567 | _tmp5_ = self->priv->_round; |
3732 | 572 | if (_tmp6_) { | 568 | if (_tmp5_) { |
3733 | 573 | gint pos = 0; | 569 | gint pos = 0; |
3734 | 570 | gint _tmp6_ = 0; | ||
3735 | 574 | gint _tmp7_ = 0; | 571 | gint _tmp7_ = 0; |
3736 | 572 | GeeArrayList* _tmp8_ = NULL; | ||
3737 | 573 | gint _tmp9_ = 0; | ||
3738 | 574 | gint _tmp10_ = 0; | ||
3739 | 575 | gint _tmp11_ = 0; | ||
3740 | 576 | gint _tmp16_ = 0; | ||
3741 | 577 | _tmp6_ = self->priv->_cursor_pos; | ||
3742 | 578 | _tmp7_ = step; | ||
3743 | 579 | _tmp8_ = self->priv->_candidates; | ||
3744 | 580 | _tmp9_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp8_); | ||
3745 | 581 | _tmp10_ = _tmp9_; | ||
3746 | 582 | pos = (_tmp6_ + _tmp7_) % _tmp10_; | ||
3747 | 583 | _tmp11_ = pos; | ||
3748 | 584 | if (_tmp11_ < 0) { | ||
3749 | 585 | gint _tmp12_ = 0; | ||
3750 | 586 | GeeArrayList* _tmp13_ = NULL; | ||
3751 | 587 | gint _tmp14_ = 0; | ||
3752 | 588 | gint _tmp15_ = 0; | ||
3753 | 589 | _tmp12_ = pos; | ||
3754 | 590 | _tmp13_ = self->priv->_candidates; | ||
3755 | 591 | _tmp14_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp13_); | ||
3756 | 592 | _tmp15_ = _tmp14_; | ||
3757 | 593 | pos = _tmp12_ + _tmp15_; | ||
3758 | 594 | } | ||
3759 | 595 | _tmp16_ = pos; | ||
3760 | 596 | self->priv->_cursor_pos = _tmp16_; | ||
3761 | 597 | g_object_notify ((GObject*) self, "cursor-pos"); | ||
3762 | 598 | result = TRUE; | ||
3763 | 599 | return result; | ||
3764 | 600 | } else { | ||
3765 | 601 | gint pos = 0; | ||
3766 | 602 | gint _tmp17_ = 0; | ||
3767 | 603 | gint _tmp18_ = 0; | ||
3768 | 604 | gboolean _tmp19_ = FALSE; | ||
3769 | 605 | gint _tmp20_ = 0; | ||
3770 | 606 | _tmp17_ = self->priv->_cursor_pos; | ||
3771 | 607 | _tmp18_ = step; | ||
3772 | 608 | pos = _tmp17_ + _tmp18_; | ||
3773 | 609 | _tmp20_ = pos; | ||
3774 | 610 | if (0 <= _tmp20_) { | ||
3775 | 611 | gint _tmp21_ = 0; | ||
3776 | 612 | GeeArrayList* _tmp22_ = NULL; | ||
3777 | 613 | gint _tmp23_ = 0; | ||
3778 | 614 | gint _tmp24_ = 0; | ||
3779 | 615 | _tmp21_ = pos; | ||
3780 | 616 | _tmp22_ = self->priv->_candidates; | ||
3781 | 617 | _tmp23_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp22_); | ||
3782 | 618 | _tmp24_ = _tmp23_; | ||
3783 | 619 | _tmp19_ = _tmp21_ < _tmp24_; | ||
3784 | 620 | } else { | ||
3785 | 621 | _tmp19_ = FALSE; | ||
3786 | 622 | } | ||
3787 | 623 | if (_tmp19_) { | ||
3788 | 624 | gint _tmp25_ = 0; | ||
3789 | 625 | _tmp25_ = pos; | ||
3790 | 626 | self->priv->_cursor_pos = _tmp25_; | ||
3791 | 627 | g_object_notify ((GObject*) self, "cursor-pos"); | ||
3792 | 628 | result = TRUE; | ||
3793 | 629 | return result; | ||
3794 | 630 | } | ||
3795 | 631 | } | ||
3796 | 632 | result = FALSE; | ||
3797 | 633 | return result; | ||
3798 | 634 | } | ||
3799 | 635 | |||
3800 | 636 | |||
3801 | 637 | /** | ||
3802 | 638 | * Move cursor to the previous candidate. | ||
3803 | 639 | * | ||
3804 | 640 | * @return `true` if cursor position has changed, `false` otherwise. | ||
3805 | 641 | */ | ||
3806 | 642 | gboolean kkc_candidate_list_cursor_up (KkcCandidateList* self) { | ||
3807 | 643 | gboolean result = FALSE; | ||
3808 | 644 | gboolean _tmp0_ = FALSE; | ||
3809 | 645 | g_return_val_if_fail (self != NULL, FALSE); | ||
3810 | 646 | _tmp0_ = kkc_candidate_list_cursor_move (self, -1); | ||
3811 | 647 | result = _tmp0_; | ||
3812 | 648 | return result; | ||
3813 | 649 | } | ||
3814 | 650 | |||
3815 | 651 | |||
3816 | 652 | /** | ||
3817 | 653 | * Move cursor to the next candidate. | ||
3818 | 654 | * | ||
3819 | 655 | * @return `true` if cursor position has changed, `false` otherwise | ||
3820 | 656 | */ | ||
3821 | 657 | gboolean kkc_candidate_list_cursor_down (KkcCandidateList* self) { | ||
3822 | 658 | gboolean result = FALSE; | ||
3823 | 659 | gboolean _tmp0_ = FALSE; | ||
3824 | 660 | g_return_val_if_fail (self != NULL, FALSE); | ||
3825 | 661 | _tmp0_ = kkc_candidate_list_cursor_move (self, 1); | ||
3826 | 662 | result = _tmp0_; | ||
3827 | 663 | return result; | ||
3828 | 664 | } | ||
3829 | 665 | |||
3830 | 666 | |||
3831 | 667 | static gboolean kkc_candidate_list_page_move (KkcCandidateList* self, gint step) { | ||
3832 | 668 | gboolean result = FALSE; | ||
3833 | 669 | gboolean _tmp0_ = FALSE; | ||
3834 | 670 | GeeArrayList* _tmp1_ = NULL; | ||
3835 | 671 | gboolean _tmp2_ = FALSE; | ||
3836 | 672 | gboolean _tmp3_ = FALSE; | ||
3837 | 673 | gboolean _tmp5_ = FALSE; | ||
3838 | 674 | g_return_val_if_fail (self != NULL, FALSE); | ||
3839 | 675 | _tmp1_ = self->priv->_candidates; | ||
3840 | 676 | _tmp2_ = gee_collection_get_is_empty ((GeeCollection*) _tmp1_); | ||
3841 | 677 | _tmp3_ = _tmp2_; | ||
3842 | 678 | if (_tmp3_) { | ||
3843 | 679 | _tmp0_ = TRUE; | ||
3844 | 680 | } else { | ||
3845 | 681 | gint _tmp4_ = 0; | ||
3846 | 682 | _tmp4_ = step; | ||
3847 | 683 | _tmp0_ = _tmp4_ == 0; | ||
3848 | 684 | } | ||
3849 | 685 | if (_tmp0_) { | ||
3850 | 686 | result = FALSE; | ||
3851 | 687 | return result; | ||
3852 | 688 | } | ||
3853 | 689 | _tmp5_ = self->priv->_round; | ||
3854 | 690 | if (_tmp5_) { | ||
3855 | 691 | guint pos = 0U; | ||
3856 | 692 | gint _tmp6_ = 0; | ||
3857 | 693 | guint _tmp7_ = 0U; | ||
3858 | 575 | gint _tmp8_ = 0; | 694 | gint _tmp8_ = 0; |
3859 | 576 | GeeArrayList* _tmp9_ = NULL; | 695 | GeeArrayList* _tmp9_ = NULL; |
3860 | 577 | gint _tmp10_ = 0; | 696 | gint _tmp10_ = 0; |
3861 | 578 | gint _tmp11_ = 0; | 697 | gint _tmp11_ = 0; |
3865 | 579 | gint _tmp12_ = 0; | 698 | guint _tmp12_ = 0U; |
3866 | 580 | gint _tmp17_ = 0; | 699 | guint _tmp17_ = 0U; |
3867 | 581 | _tmp7_ = self->priv->_cursor_pos; | 700 | guint _tmp18_ = 0U; |
3868 | 701 | guint _tmp19_ = 0U; | ||
3869 | 702 | gint _tmp20_ = 0; | ||
3870 | 703 | _tmp6_ = self->priv->_cursor_pos; | ||
3871 | 704 | _tmp7_ = self->priv->_page_size; | ||
3872 | 582 | _tmp8_ = step; | 705 | _tmp8_ = step; |
3873 | 583 | _tmp9_ = self->priv->_candidates; | 706 | _tmp9_ = self->priv->_candidates; |
3874 | 584 | _tmp10_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp9_); | 707 | _tmp10_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp9_); |
3875 | 585 | _tmp11_ = _tmp10_; | 708 | _tmp11_ = _tmp10_; |
3877 | 586 | pos = (_tmp7_ + _tmp8_) % _tmp11_; | 709 | pos = (_tmp6_ + (_tmp7_ * _tmp8_)) % _tmp11_; |
3878 | 587 | _tmp12_ = pos; | 710 | _tmp12_ = pos; |
3881 | 588 | if (_tmp12_ < 0) { | 711 | if (_tmp12_ < ((guint) 0)) { |
3882 | 589 | gint _tmp13_ = 0; | 712 | guint _tmp13_ = 0U; |
3883 | 590 | GeeArrayList* _tmp14_ = NULL; | 713 | GeeArrayList* _tmp14_ = NULL; |
3884 | 591 | gint _tmp15_ = 0; | 714 | gint _tmp15_ = 0; |
3885 | 592 | gint _tmp16_ = 0; | 715 | gint _tmp16_ = 0; |
3886 | @@ -597,190 +720,57 @@ | |||
3887 | 597 | pos = _tmp13_ + _tmp16_; | 720 | pos = _tmp13_ + _tmp16_; |
3888 | 598 | } | 721 | } |
3889 | 599 | _tmp17_ = pos; | 722 | _tmp17_ = pos; |
3894 | 600 | self->priv->_cursor_pos = _tmp17_; | 723 | _tmp18_ = kkc_candidate_list_get_page_start_cursor_pos (self, _tmp17_); |
3895 | 601 | g_object_notify ((GObject*) self, "cursor-pos"); | 724 | pos = _tmp18_; |
3896 | 602 | result = TRUE; | 725 | _tmp19_ = pos; |
3897 | 603 | return result; | 726 | _tmp20_ = self->priv->_cursor_pos; |
3898 | 727 | if (_tmp19_ != ((guint) _tmp20_)) { | ||
3899 | 728 | guint _tmp21_ = 0U; | ||
3900 | 729 | _tmp21_ = pos; | ||
3901 | 730 | self->priv->_cursor_pos = (gint) _tmp21_; | ||
3902 | 731 | g_object_notify ((GObject*) self, "cursor-pos"); | ||
3903 | 732 | result = TRUE; | ||
3904 | 733 | return result; | ||
3905 | 734 | } | ||
3906 | 604 | } else { | 735 | } else { |
3933 | 605 | gint pos = 0; | 736 | guint pos = 0U; |
3934 | 606 | gint _tmp18_ = 0; | 737 | gint _tmp22_ = 0; |
3935 | 607 | gint _tmp19_ = 0; | 738 | guint _tmp23_ = 0U; |
3936 | 608 | gboolean _tmp20_ = FALSE; | 739 | gint _tmp24_ = 0; |
3937 | 609 | gint _tmp21_ = 0; | 740 | gboolean _tmp25_ = FALSE; |
3938 | 610 | gboolean _tmp26_ = FALSE; | 741 | guint _tmp26_ = 0U; |
3939 | 611 | _tmp18_ = self->priv->_cursor_pos; | 742 | _tmp22_ = self->priv->_cursor_pos; |
3940 | 612 | _tmp19_ = step; | 743 | _tmp23_ = self->priv->_page_size; |
3941 | 613 | pos = _tmp18_ + _tmp19_; | 744 | _tmp24_ = step; |
3942 | 614 | _tmp21_ = pos; | 745 | pos = _tmp22_ + (_tmp23_ * _tmp24_); |
3943 | 615 | if (0 <= _tmp21_) { | 746 | _tmp26_ = pos; |
3944 | 616 | gint _tmp22_ = 0; | 747 | if (((guint) 0) <= _tmp26_) { |
3945 | 617 | GeeArrayList* _tmp23_ = NULL; | 748 | guint _tmp27_ = 0U; |
3946 | 618 | gint _tmp24_ = 0; | 749 | GeeArrayList* _tmp28_ = NULL; |
3947 | 619 | gint _tmp25_ = 0; | 750 | gint _tmp29_ = 0; |
3948 | 620 | _tmp22_ = pos; | 751 | gint _tmp30_ = 0; |
3923 | 621 | _tmp23_ = self->priv->_candidates; | ||
3924 | 622 | _tmp24_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp23_); | ||
3925 | 623 | _tmp25_ = _tmp24_; | ||
3926 | 624 | _tmp20_ = _tmp22_ < _tmp25_; | ||
3927 | 625 | } else { | ||
3928 | 626 | _tmp20_ = FALSE; | ||
3929 | 627 | } | ||
3930 | 628 | _tmp26_ = _tmp20_; | ||
3931 | 629 | if (_tmp26_) { | ||
3932 | 630 | gint _tmp27_ = 0; | ||
3949 | 631 | _tmp27_ = pos; | 752 | _tmp27_ = pos; |
4084 | 632 | self->priv->_cursor_pos = _tmp27_; | 753 | _tmp28_ = self->priv->_candidates; |
4085 | 633 | g_object_notify ((GObject*) self, "cursor-pos"); | 754 | _tmp29_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp28_); |
4086 | 634 | result = TRUE; | 755 | _tmp30_ = _tmp29_; |
4087 | 635 | return result; | 756 | _tmp25_ = _tmp27_ < ((guint) _tmp30_); |
3954 | 636 | } | ||
3955 | 637 | } | ||
3956 | 638 | result = FALSE; | ||
3957 | 639 | return result; | ||
3958 | 640 | } | ||
3959 | 641 | |||
3960 | 642 | |||
3961 | 643 | /** | ||
3962 | 644 | * Move cursor to the previous candidate. | ||
3963 | 645 | * | ||
3964 | 646 | * @return `true` if cursor position has changed, `false` otherwise. | ||
3965 | 647 | */ | ||
3966 | 648 | gboolean kkc_candidate_list_cursor_up (KkcCandidateList* self) { | ||
3967 | 649 | gboolean result = FALSE; | ||
3968 | 650 | gboolean _tmp0_ = FALSE; | ||
3969 | 651 | g_return_val_if_fail (self != NULL, FALSE); | ||
3970 | 652 | _tmp0_ = kkc_candidate_list_cursor_move (self, -1); | ||
3971 | 653 | result = _tmp0_; | ||
3972 | 654 | return result; | ||
3973 | 655 | } | ||
3974 | 656 | |||
3975 | 657 | |||
3976 | 658 | /** | ||
3977 | 659 | * Move cursor to the next candidate. | ||
3978 | 660 | * | ||
3979 | 661 | * @return `true` if cursor position has changed, `false` otherwise | ||
3980 | 662 | */ | ||
3981 | 663 | gboolean kkc_candidate_list_cursor_down (KkcCandidateList* self) { | ||
3982 | 664 | gboolean result = FALSE; | ||
3983 | 665 | gboolean _tmp0_ = FALSE; | ||
3984 | 666 | g_return_val_if_fail (self != NULL, FALSE); | ||
3985 | 667 | _tmp0_ = kkc_candidate_list_cursor_move (self, 1); | ||
3986 | 668 | result = _tmp0_; | ||
3987 | 669 | return result; | ||
3988 | 670 | } | ||
3989 | 671 | |||
3990 | 672 | |||
3991 | 673 | static gboolean kkc_candidate_list_page_move (KkcCandidateList* self, gint step) { | ||
3992 | 674 | gboolean result = FALSE; | ||
3993 | 675 | gboolean _tmp0_ = FALSE; | ||
3994 | 676 | GeeArrayList* _tmp1_ = NULL; | ||
3995 | 677 | gboolean _tmp2_ = FALSE; | ||
3996 | 678 | gboolean _tmp3_ = FALSE; | ||
3997 | 679 | gboolean _tmp5_ = FALSE; | ||
3998 | 680 | gboolean _tmp6_ = FALSE; | ||
3999 | 681 | g_return_val_if_fail (self != NULL, FALSE); | ||
4000 | 682 | _tmp1_ = self->priv->_candidates; | ||
4001 | 683 | _tmp2_ = gee_abstract_collection_get_is_empty ((GeeAbstractCollection*) _tmp1_); | ||
4002 | 684 | _tmp3_ = _tmp2_; | ||
4003 | 685 | if (_tmp3_) { | ||
4004 | 686 | _tmp0_ = TRUE; | ||
4005 | 687 | } else { | ||
4006 | 688 | gint _tmp4_ = 0; | ||
4007 | 689 | _tmp4_ = step; | ||
4008 | 690 | _tmp0_ = _tmp4_ == 0; | ||
4009 | 691 | } | ||
4010 | 692 | _tmp5_ = _tmp0_; | ||
4011 | 693 | if (_tmp5_) { | ||
4012 | 694 | result = FALSE; | ||
4013 | 695 | return result; | ||
4014 | 696 | } | ||
4015 | 697 | _tmp6_ = self->priv->_round; | ||
4016 | 698 | if (_tmp6_) { | ||
4017 | 699 | guint pos = 0U; | ||
4018 | 700 | gint _tmp7_ = 0; | ||
4019 | 701 | guint _tmp8_ = 0U; | ||
4020 | 702 | gint _tmp9_ = 0; | ||
4021 | 703 | GeeArrayList* _tmp10_ = NULL; | ||
4022 | 704 | gint _tmp11_ = 0; | ||
4023 | 705 | gint _tmp12_ = 0; | ||
4024 | 706 | guint _tmp13_ = 0U; | ||
4025 | 707 | guint _tmp18_ = 0U; | ||
4026 | 708 | guint _tmp19_ = 0U; | ||
4027 | 709 | guint _tmp20_ = 0U; | ||
4028 | 710 | gint _tmp21_ = 0; | ||
4029 | 711 | _tmp7_ = self->priv->_cursor_pos; | ||
4030 | 712 | _tmp8_ = self->priv->_page_size; | ||
4031 | 713 | _tmp9_ = step; | ||
4032 | 714 | _tmp10_ = self->priv->_candidates; | ||
4033 | 715 | _tmp11_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp10_); | ||
4034 | 716 | _tmp12_ = _tmp11_; | ||
4035 | 717 | pos = (_tmp7_ + (_tmp8_ * _tmp9_)) % _tmp12_; | ||
4036 | 718 | _tmp13_ = pos; | ||
4037 | 719 | if (_tmp13_ < ((guint) 0)) { | ||
4038 | 720 | guint _tmp14_ = 0U; | ||
4039 | 721 | GeeArrayList* _tmp15_ = NULL; | ||
4040 | 722 | gint _tmp16_ = 0; | ||
4041 | 723 | gint _tmp17_ = 0; | ||
4042 | 724 | _tmp14_ = pos; | ||
4043 | 725 | _tmp15_ = self->priv->_candidates; | ||
4044 | 726 | _tmp16_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp15_); | ||
4045 | 727 | _tmp17_ = _tmp16_; | ||
4046 | 728 | pos = _tmp14_ + _tmp17_; | ||
4047 | 729 | } | ||
4048 | 730 | _tmp18_ = pos; | ||
4049 | 731 | _tmp19_ = kkc_candidate_list_get_page_start_cursor_pos (self, _tmp18_); | ||
4050 | 732 | pos = _tmp19_; | ||
4051 | 733 | _tmp20_ = pos; | ||
4052 | 734 | _tmp21_ = self->priv->_cursor_pos; | ||
4053 | 735 | if (_tmp20_ != ((guint) _tmp21_)) { | ||
4054 | 736 | guint _tmp22_ = 0U; | ||
4055 | 737 | _tmp22_ = pos; | ||
4056 | 738 | self->priv->_cursor_pos = (gint) _tmp22_; | ||
4057 | 739 | g_object_notify ((GObject*) self, "cursor-pos"); | ||
4058 | 740 | result = TRUE; | ||
4059 | 741 | return result; | ||
4060 | 742 | } | ||
4061 | 743 | } else { | ||
4062 | 744 | guint pos = 0U; | ||
4063 | 745 | gint _tmp23_ = 0; | ||
4064 | 746 | guint _tmp24_ = 0U; | ||
4065 | 747 | gint _tmp25_ = 0; | ||
4066 | 748 | gboolean _tmp26_ = FALSE; | ||
4067 | 749 | guint _tmp27_ = 0U; | ||
4068 | 750 | gboolean _tmp32_ = FALSE; | ||
4069 | 751 | _tmp23_ = self->priv->_cursor_pos; | ||
4070 | 752 | _tmp24_ = self->priv->_page_size; | ||
4071 | 753 | _tmp25_ = step; | ||
4072 | 754 | pos = _tmp23_ + (_tmp24_ * _tmp25_); | ||
4073 | 755 | _tmp27_ = pos; | ||
4074 | 756 | if (((guint) 0) <= _tmp27_) { | ||
4075 | 757 | guint _tmp28_ = 0U; | ||
4076 | 758 | GeeArrayList* _tmp29_ = NULL; | ||
4077 | 759 | gint _tmp30_ = 0; | ||
4078 | 760 | gint _tmp31_ = 0; | ||
4079 | 761 | _tmp28_ = pos; | ||
4080 | 762 | _tmp29_ = self->priv->_candidates; | ||
4081 | 763 | _tmp30_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp29_); | ||
4082 | 764 | _tmp31_ = _tmp30_; | ||
4083 | 765 | _tmp26_ = _tmp28_ < ((guint) _tmp31_); | ||
4088 | 766 | } else { | 757 | } else { |
4090 | 767 | _tmp26_ = FALSE; | 758 | _tmp25_ = FALSE; |
4091 | 768 | } | 759 | } |
4094 | 769 | _tmp32_ = _tmp26_; | 760 | if (_tmp25_) { |
4095 | 770 | if (_tmp32_) { | 761 | guint _tmp31_ = 0U; |
4096 | 762 | guint _tmp32_ = 0U; | ||
4097 | 771 | guint _tmp33_ = 0U; | 763 | guint _tmp33_ = 0U; |
4101 | 772 | guint _tmp34_ = 0U; | 764 | gint _tmp34_ = 0; |
4102 | 773 | guint _tmp35_ = 0U; | 765 | _tmp31_ = pos; |
4103 | 774 | gint _tmp36_ = 0; | 766 | _tmp32_ = kkc_candidate_list_get_page_start_cursor_pos (self, _tmp31_); |
4104 | 767 | pos = _tmp32_; | ||
4105 | 775 | _tmp33_ = pos; | 768 | _tmp33_ = pos; |
4114 | 776 | _tmp34_ = kkc_candidate_list_get_page_start_cursor_pos (self, _tmp33_); | 769 | _tmp34_ = self->priv->_cursor_pos; |
4115 | 777 | pos = _tmp34_; | 770 | if (_tmp33_ != ((guint) _tmp34_)) { |
4116 | 778 | _tmp35_ = pos; | 771 | guint _tmp35_ = 0U; |
4117 | 779 | _tmp36_ = self->priv->_cursor_pos; | 772 | _tmp35_ = pos; |
4118 | 780 | if (_tmp35_ != ((guint) _tmp36_)) { | 773 | self->priv->_cursor_pos = (gint) _tmp35_; |
4111 | 781 | guint _tmp37_ = 0U; | ||
4112 | 782 | _tmp37_ = pos; | ||
4113 | 783 | self->priv->_cursor_pos = (gint) _tmp37_; | ||
4119 | 784 | g_object_notify ((GObject*) self, "cursor-pos"); | 774 | g_object_notify ((GObject*) self, "cursor-pos"); |
4120 | 785 | result = TRUE; | 775 | result = TRUE; |
4121 | 786 | return result; | 776 | return result; |
4122 | @@ -927,8 +917,8 @@ | |||
4123 | 927 | static void kkc_candidate_list_class_init (KkcCandidateListClass * klass) { | 917 | static void kkc_candidate_list_class_init (KkcCandidateListClass * klass) { |
4124 | 928 | kkc_candidate_list_parent_class = g_type_class_peek_parent (klass); | 918 | kkc_candidate_list_parent_class = g_type_class_peek_parent (klass); |
4125 | 929 | g_type_class_add_private (klass, sizeof (KkcCandidateListPrivate)); | 919 | g_type_class_add_private (klass, sizeof (KkcCandidateListPrivate)); |
4128 | 930 | KKC_CANDIDATE_LIST_CLASS (klass)->next = kkc_candidate_list_real_next; | 920 | ((KkcCandidateListClass *) klass)->next = kkc_candidate_list_real_next; |
4129 | 931 | KKC_CANDIDATE_LIST_CLASS (klass)->previous = kkc_candidate_list_real_previous; | 921 | ((KkcCandidateListClass *) klass)->previous = kkc_candidate_list_real_previous; |
4130 | 932 | G_OBJECT_CLASS (klass)->get_property = _vala_kkc_candidate_list_get_property; | 922 | G_OBJECT_CLASS (klass)->get_property = _vala_kkc_candidate_list_get_property; |
4131 | 933 | G_OBJECT_CLASS (klass)->set_property = _vala_kkc_candidate_list_set_property; | 923 | G_OBJECT_CLASS (klass)->set_property = _vala_kkc_candidate_list_set_property; |
4132 | 934 | G_OBJECT_CLASS (klass)->finalize = kkc_candidate_list_finalize; | 924 | G_OBJECT_CLASS (klass)->finalize = kkc_candidate_list_finalize; |
4133 | @@ -973,9 +963,9 @@ | |||
4134 | 973 | GeeArrayList* _tmp0_ = NULL; | 963 | GeeArrayList* _tmp0_ = NULL; |
4135 | 974 | GeeHashSet* _tmp1_ = NULL; | 964 | GeeHashSet* _tmp1_ = NULL; |
4136 | 975 | self->priv = KKC_CANDIDATE_LIST_GET_PRIVATE (self); | 965 | self->priv = KKC_CANDIDATE_LIST_GET_PRIVATE (self); |
4138 | 976 | _tmp0_ = gee_array_list_new (KKC_TYPE_CANDIDATE, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL); | 966 | _tmp0_ = gee_array_list_new (KKC_TYPE_CANDIDATE, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL); |
4139 | 977 | self->priv->_candidates = _tmp0_; | 967 | self->priv->_candidates = _tmp0_; |
4141 | 978 | _tmp1_ = gee_hash_set_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL, NULL); | 968 | _tmp1_ = gee_hash_set_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL, NULL, NULL, NULL, NULL, NULL); |
4142 | 979 | self->priv->seen = (GeeSet*) _tmp1_; | 969 | self->priv->seen = (GeeSet*) _tmp1_; |
4143 | 980 | } | 970 | } |
4144 | 981 | 971 | ||
4145 | 982 | 972 | ||
4146 | === modified file 'libkkc/candidate-list.vala' | |||
4147 | --- libkkc/candidate-list.vala 2014-02-26 22:51:39 +0000 | |||
4148 | +++ libkkc/candidate-list.vala 2014-10-01 15:12:30 +0000 | |||
4149 | @@ -1,6 +1,6 @@ | |||
4150 | 1 | /* | 1 | /* |
4153 | 2 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4154 | 3 | * Copyright (C) 2011-2013 Red Hat, Inc. | 3 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4155 | 4 | * | 4 | * |
4156 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
4157 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
4158 | @@ -63,7 +63,7 @@ | |||
4159 | 63 | } | 63 | } |
4160 | 64 | } | 64 | } |
4161 | 65 | 65 | ||
4163 | 66 | Set<string> seen = new HashSet<string> (); | 66 | Set<string> seen = new Gee.HashSet<string> (); |
4164 | 67 | 67 | ||
4165 | 68 | internal void clear () { | 68 | internal void clear () { |
4166 | 69 | bool is_populated = false; | 69 | bool is_populated = false; |
4167 | 70 | 70 | ||
4168 | === modified file 'libkkc/candidate.c' | |||
4169 | --- libkkc/candidate.c 2014-06-15 23:27:57 +0000 | |||
4170 | +++ libkkc/candidate.c 2014-10-01 15:12:30 +0000 | |||
4171 | @@ -1,9 +1,9 @@ | |||
4173 | 1 | /* candidate.c generated by valac 0.22.1, the Vala compiler | 1 | /* candidate.c generated by valac 0.24.0.131-42e78, the Vala compiler |
4174 | 2 | * generated from candidate.vala, do not modify */ | 2 | * generated from candidate.vala, do not modify */ |
4175 | 3 | 3 | ||
4176 | 4 | /* | 4 | /* |
4179 | 5 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4180 | 6 | * Copyright (C) 2011-2013 Red Hat, Inc. | 6 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4181 | 7 | * | 7 | * |
4182 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
4183 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
4184 | @@ -140,7 +140,6 @@ | |||
4185 | 140 | const gchar* _tmp3_ = NULL; | 140 | const gchar* _tmp3_ = NULL; |
4186 | 141 | const gchar* _tmp4_ = NULL; | 141 | const gchar* _tmp4_ = NULL; |
4187 | 142 | const gchar* _tmp5_ = NULL; | 142 | const gchar* _tmp5_ = NULL; |
4188 | 143 | const gchar* _tmp8_ = NULL; | ||
4189 | 144 | g_return_val_if_fail (midasi != NULL, NULL); | 143 | g_return_val_if_fail (midasi != NULL, NULL); |
4190 | 145 | g_return_val_if_fail (text != NULL, NULL); | 144 | g_return_val_if_fail (text != NULL, NULL); |
4191 | 146 | self = (KkcCandidate*) g_object_new (object_type, NULL); | 145 | self = (KkcCandidate*) g_object_new (object_type, NULL); |
4192 | @@ -162,8 +161,7 @@ | |||
4193 | 162 | _tmp7_ = output; | 161 | _tmp7_ = output; |
4194 | 163 | _tmp4_ = _tmp7_; | 162 | _tmp4_ = _tmp7_; |
4195 | 164 | } | 163 | } |
4198 | 165 | _tmp8_ = _tmp4_; | 164 | kkc_candidate_set_output (self, _tmp4_); |
4197 | 166 | kkc_candidate_set_output (self, _tmp8_); | ||
4199 | 167 | return self; | 165 | return self; |
4200 | 168 | } | 166 | } |
4201 | 169 | 167 | ||
4202 | 170 | 168 | ||
4203 | === modified file 'libkkc/candidate.vala' | |||
4204 | --- libkkc/candidate.vala 2014-02-26 22:51:39 +0000 | |||
4205 | +++ libkkc/candidate.vala 2014-10-01 15:12:30 +0000 | |||
4206 | @@ -1,6 +1,6 @@ | |||
4207 | 1 | /* | 1 | /* |
4210 | 2 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4211 | 3 | * Copyright (C) 2011-2013 Red Hat, Inc. | 3 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4212 | 4 | * | 4 | * |
4213 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
4214 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
4215 | 7 | 7 | ||
4216 | === modified file 'libkkc/context.c' | |||
4217 | --- libkkc/context.c 2014-06-15 23:27:57 +0000 | |||
4218 | +++ libkkc/context.c 2014-10-01 15:12:30 +0000 | |||
4219 | @@ -1,9 +1,9 @@ | |||
4221 | 1 | /* context.c generated by valac 0.22.1, the Vala compiler | 1 | /* context.c generated by valac 0.24.0.131-42e78, the Vala compiler |
4222 | 2 | * generated from context.vala, do not modify */ | 2 | * generated from context.vala, do not modify */ |
4223 | 3 | 3 | ||
4224 | 4 | /* | 4 | /* |
4227 | 5 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4228 | 6 | * Copyright (C) 2011-2013 Red Hat, Inc. | 6 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4229 | 7 | * | 7 | * |
4230 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
4231 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
4232 | @@ -472,17 +472,17 @@ | |||
4233 | 472 | 472 | ||
4234 | 473 | 473 | ||
4235 | 474 | static void _kkc_context_notify_input_mode_cb_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) { | 474 | static void _kkc_context_notify_input_mode_cb_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) { |
4237 | 475 | kkc_context_notify_input_mode_cb (self, _sender, pspec); | 475 | kkc_context_notify_input_mode_cb ((KkcContext*) self, _sender, pspec); |
4238 | 476 | } | 476 | } |
4239 | 477 | 477 | ||
4240 | 478 | 478 | ||
4241 | 479 | static void _kkc_context_request_selection_text_cb_kkc_state_request_selection_text (KkcState* _sender, gpointer self) { | 479 | static void _kkc_context_request_selection_text_cb_kkc_state_request_selection_text (KkcState* _sender, gpointer self) { |
4243 | 480 | kkc_context_request_selection_text_cb (self); | 480 | kkc_context_request_selection_text_cb ((KkcContext*) self); |
4244 | 481 | } | 481 | } |
4245 | 482 | 482 | ||
4246 | 483 | 483 | ||
4247 | 484 | static void _kkc_context_candidates_selected_cb_kkc_candidate_list_selected (KkcCandidateList* _sender, KkcCandidate* candidate, gpointer self) { | 484 | static void _kkc_context_candidates_selected_cb_kkc_candidate_list_selected (KkcCandidateList* _sender, KkcCandidate* candidate, gpointer self) { |
4249 | 485 | kkc_context_candidates_selected_cb (self); | 485 | kkc_context_candidates_selected_cb ((KkcContext*) self); |
4250 | 486 | } | 486 | } |
4251 | 487 | 487 | ||
4252 | 488 | 488 | ||
4253 | @@ -620,7 +620,7 @@ | |||
4254 | 620 | GError * _inner_error_ = NULL; | 620 | GError * _inner_error_ = NULL; |
4255 | 621 | g_return_val_if_fail (self != NULL, FALSE); | 621 | g_return_val_if_fail (self != NULL, FALSE); |
4256 | 622 | g_return_val_if_fail (keyseq != NULL, FALSE); | 622 | g_return_val_if_fail (keyseq != NULL, FALSE); |
4258 | 623 | _tmp0_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL); | 623 | _tmp0_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL, NULL, NULL); |
4259 | 624 | keys = (GeeList*) _tmp0_; | 624 | keys = (GeeList*) _tmp0_; |
4260 | 625 | _tmp1_ = g_string_new (""); | 625 | _tmp1_ = g_string_new (""); |
4261 | 626 | builder = _tmp1_; | 626 | builder = _tmp1_; |
4262 | @@ -827,7 +827,6 @@ | |||
4263 | 827 | gboolean _tmp60_ = FALSE; | 827 | gboolean _tmp60_ = FALSE; |
4264 | 828 | KkcKeyEvent* _tmp61_ = NULL; | 828 | KkcKeyEvent* _tmp61_ = NULL; |
4265 | 829 | gboolean _tmp62_ = FALSE; | 829 | gboolean _tmp62_ = FALSE; |
4266 | 830 | gboolean _tmp64_ = FALSE; | ||
4267 | 831 | _tmp44_ = _key_index; | 830 | _tmp44_ = _key_index; |
4268 | 832 | _key_index = _tmp44_ + 1; | 831 | _key_index = _tmp44_ + 1; |
4269 | 833 | _tmp45_ = _key_index; | 832 | _tmp45_ = _key_index; |
4270 | @@ -876,7 +875,7 @@ | |||
4271 | 876 | _tmp58_ = key; | 875 | _tmp58_ = key; |
4272 | 877 | _tmp59_ = kkc_key_event_new_from_string (_tmp58_, &_inner_error_); | 876 | _tmp59_ = kkc_key_event_new_from_string (_tmp58_, &_inner_error_); |
4273 | 878 | ev = _tmp59_; | 877 | ev = _tmp59_; |
4275 | 879 | if (_inner_error_ != NULL) { | 878 | if (G_UNLIKELY (_inner_error_ != NULL)) { |
4276 | 880 | if (_inner_error_->domain == KKC_KEY_EVENT_FORMAT_ERROR) { | 879 | if (_inner_error_->domain == KKC_KEY_EVENT_FORMAT_ERROR) { |
4277 | 881 | g_propagate_error (error, _inner_error_); | 880 | g_propagate_error (error, _inner_error_); |
4278 | 882 | _g_free0 (key); | 881 | _g_free0 (key); |
4279 | @@ -903,8 +902,7 @@ | |||
4280 | 903 | } else { | 902 | } else { |
4281 | 904 | _tmp60_ = FALSE; | 903 | _tmp60_ = FALSE; |
4282 | 905 | } | 904 | } |
4285 | 906 | _tmp64_ = _tmp60_; | 905 | if (_tmp60_) { |
4284 | 907 | if (_tmp64_) { | ||
4286 | 908 | retval = TRUE; | 906 | retval = TRUE; |
4287 | 909 | } | 907 | } |
4288 | 910 | _g_object_unref0 (ev); | 908 | _g_object_unref0 (ev); |
4289 | @@ -1320,7 +1318,7 @@ | |||
4290 | 1320 | 1318 | ||
4291 | 1321 | 1319 | ||
4292 | 1322 | static void _kkc_context_filter_forwarded_cb_kkc_key_event_filter_forwarded (KkcKeyEventFilter* _sender, KkcKeyEvent* key, gpointer self) { | 1320 | static void _kkc_context_filter_forwarded_cb_kkc_key_event_filter_forwarded (KkcKeyEventFilter* _sender, KkcKeyEvent* key, gpointer self) { |
4294 | 1323 | kkc_context_filter_forwarded_cb (self, key); | 1321 | kkc_context_filter_forwarded_cb ((KkcContext*) self, key); |
4295 | 1324 | } | 1322 | } |
4296 | 1325 | 1323 | ||
4297 | 1326 | 1324 | ||
4298 | @@ -1439,7 +1437,7 @@ | |||
4299 | 1439 | static void kkc_context_instance_init (KkcContext * self) { | 1437 | static void kkc_context_instance_init (KkcContext * self) { |
4300 | 1440 | GeeHashMap* _tmp0_ = NULL; | 1438 | GeeHashMap* _tmp0_ = NULL; |
4301 | 1441 | self->priv = KKC_CONTEXT_GET_PRIVATE (self); | 1439 | self->priv = KKC_CONTEXT_GET_PRIVATE (self); |
4303 | 1442 | _tmp0_ = gee_hash_map_new (G_TYPE_GTYPE, NULL, NULL, KKC_TYPE_STATE_HANDLER, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL); | 1440 | _tmp0_ = gee_hash_map_new (G_TYPE_GTYPE, NULL, NULL, KKC_TYPE_STATE_HANDLER, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); |
4304 | 1443 | self->priv->handlers = (GeeMap*) _tmp0_; | 1441 | self->priv->handlers = (GeeMap*) _tmp0_; |
4305 | 1444 | } | 1442 | } |
4306 | 1445 | 1443 | ||
4307 | 1446 | 1444 | ||
4308 | === modified file 'libkkc/context.vala' | |||
4309 | --- libkkc/context.vala 2014-02-26 22:51:39 +0000 | |||
4310 | +++ libkkc/context.vala 2014-10-01 15:12:30 +0000 | |||
4311 | @@ -1,6 +1,6 @@ | |||
4312 | 1 | /* | 1 | /* |
4315 | 2 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4316 | 3 | * Copyright (C) 2011-2013 Red Hat, Inc. | 3 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4317 | 4 | * | 4 | * |
4318 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
4319 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
4320 | 7 | 7 | ||
4321 | === modified file 'libkkc/convert-segment-state-handler.c' | |||
4322 | --- libkkc/convert-segment-state-handler.c 2014-06-15 23:27:57 +0000 | |||
4323 | +++ libkkc/convert-segment-state-handler.c 2014-10-01 15:12:30 +0000 | |||
4324 | @@ -1,9 +1,9 @@ | |||
4326 | 1 | /* convert-segment-state-handler.c generated by valac 0.22.1, the Vala compiler | 1 | /* convert-segment-state-handler.c generated by valac 0.24.0.131-42e78, the Vala compiler |
4327 | 2 | * generated from convert-segment-state-handler.vala, do not modify */ | 2 | * generated from convert-segment-state-handler.vala, do not modify */ |
4328 | 3 | 3 | ||
4329 | 4 | /* | 4 | /* |
4332 | 5 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4333 | 6 | * Copyright (C) 2011-2013 Red Hat, Inc. | 6 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4334 | 7 | * | 7 | * |
4335 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
4336 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
4337 | @@ -409,35 +409,35 @@ | |||
4338 | 409 | 409 | ||
4339 | 410 | static gboolean _kkc_convert_segment_state_handler_do_next_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 410 | static gboolean _kkc_convert_segment_state_handler_do_next_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4340 | 411 | gboolean result; | 411 | gboolean result; |
4342 | 412 | result = kkc_convert_segment_state_handler_do_next_candidate (self, command, state, key); | 412 | result = kkc_convert_segment_state_handler_do_next_candidate ((KkcConvertSegmentStateHandler*) self, command, state, key); |
4343 | 413 | return result; | 413 | return result; |
4344 | 414 | } | 414 | } |
4345 | 415 | 415 | ||
4346 | 416 | 416 | ||
4347 | 417 | static gboolean _kkc_convert_segment_state_handler_do_previous_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 417 | static gboolean _kkc_convert_segment_state_handler_do_previous_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4348 | 418 | gboolean result; | 418 | gboolean result; |
4350 | 419 | result = kkc_convert_segment_state_handler_do_previous_candidate (self, command, state, key); | 419 | result = kkc_convert_segment_state_handler_do_previous_candidate ((KkcConvertSegmentStateHandler*) self, command, state, key); |
4351 | 420 | return result; | 420 | return result; |
4352 | 421 | } | 421 | } |
4353 | 422 | 422 | ||
4354 | 423 | 423 | ||
4355 | 424 | static gboolean _kkc_convert_segment_state_handler_do_purge_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 424 | static gboolean _kkc_convert_segment_state_handler_do_purge_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4356 | 425 | gboolean result; | 425 | gboolean result; |
4358 | 426 | result = kkc_convert_segment_state_handler_do_purge_candidate (self, command, state, key); | 426 | result = kkc_convert_segment_state_handler_do_purge_candidate ((KkcConvertSegmentStateHandler*) self, command, state, key); |
4359 | 427 | return result; | 427 | return result; |
4360 | 428 | } | 428 | } |
4361 | 429 | 429 | ||
4362 | 430 | 430 | ||
4363 | 431 | static gboolean _kkc_convert_segment_state_handler_do_clear_unhandled_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 431 | static gboolean _kkc_convert_segment_state_handler_do_clear_unhandled_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4364 | 432 | gboolean result; | 432 | gboolean result; |
4366 | 433 | result = kkc_convert_segment_state_handler_do_clear_unhandled (self, command, state, key); | 433 | result = kkc_convert_segment_state_handler_do_clear_unhandled ((KkcConvertSegmentStateHandler*) self, command, state, key); |
4367 | 434 | return result; | 434 | return result; |
4368 | 435 | } | 435 | } |
4369 | 436 | 436 | ||
4370 | 437 | 437 | ||
4371 | 438 | static gboolean _kkc_convert_segment_state_handler_do_select_unhandled_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 438 | static gboolean _kkc_convert_segment_state_handler_do_select_unhandled_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4372 | 439 | gboolean result; | 439 | gboolean result; |
4374 | 440 | result = kkc_convert_segment_state_handler_do_select_unhandled (self, command, state, key); | 440 | result = kkc_convert_segment_state_handler_do_select_unhandled ((KkcConvertSegmentStateHandler*) self, command, state, key); |
4375 | 441 | return result; | 441 | return result; |
4376 | 442 | } | 442 | } |
4377 | 443 | 443 | ||
4378 | @@ -487,46 +487,44 @@ | |||
4379 | 487 | gboolean _tmp3_ = FALSE; | 487 | gboolean _tmp3_ = FALSE; |
4380 | 488 | _tmp3_ = TRUE; | 488 | _tmp3_ = TRUE; |
4381 | 489 | while (TRUE) { | 489 | while (TRUE) { |
4386 | 490 | gboolean _tmp4_ = FALSE; | 490 | gint _tmp5_ = 0; |
4387 | 491 | gint _tmp6_ = 0; | 491 | GEnumClass* _tmp6_ = NULL; |
4388 | 492 | GEnumClass* _tmp7_ = NULL; | 492 | gint _tmp7_ = 0; |
4385 | 493 | gint _tmp8_ = 0; | ||
4389 | 494 | GEnumValue* enum_value = NULL; | 493 | GEnumValue* enum_value = NULL; |
4392 | 495 | GEnumClass* _tmp9_ = NULL; | 494 | GEnumClass* _tmp8_ = NULL; |
4393 | 496 | gint _tmp10_ = 0; | 495 | gint _tmp9_ = 0; |
4394 | 496 | GEnumValue* _tmp10_ = NULL; | ||
4395 | 497 | GEnumValue* _tmp11_ = NULL; | 497 | GEnumValue* _tmp11_ = NULL; |
4396 | 498 | GEnumValue* _tmp12_ = NULL; | 498 | GEnumValue* _tmp12_ = NULL; |
4403 | 499 | GEnumValue* _tmp13_ = NULL; | 499 | if (!_tmp3_) { |
4404 | 500 | _tmp4_ = _tmp3_; | 500 | gint _tmp4_ = 0; |
4405 | 501 | if (!_tmp4_) { | 501 | _tmp4_ = i; |
4406 | 502 | gint _tmp5_ = 0; | 502 | i = _tmp4_ + 1; |
4401 | 503 | _tmp5_ = i; | ||
4402 | 504 | i = _tmp5_ + 1; | ||
4407 | 505 | } | 503 | } |
4408 | 506 | _tmp3_ = FALSE; | 504 | _tmp3_ = FALSE; |
4413 | 507 | _tmp6_ = i; | 505 | _tmp5_ = i; |
4414 | 508 | _tmp7_ = enum_class; | 506 | _tmp6_ = enum_class; |
4415 | 509 | _tmp8_ = _tmp7_->maximum; | 507 | _tmp7_ = _tmp6_->maximum; |
4416 | 510 | if (!(_tmp6_ <= _tmp8_)) { | 508 | if (!(_tmp5_ <= _tmp7_)) { |
4417 | 511 | break; | 509 | break; |
4418 | 512 | } | 510 | } |
4428 | 513 | _tmp9_ = enum_class; | 511 | _tmp8_ = enum_class; |
4429 | 514 | _tmp10_ = i; | 512 | _tmp9_ = i; |
4430 | 515 | _tmp11_ = g_enum_get_value (_tmp9_, _tmp10_); | 513 | _tmp10_ = g_enum_get_value (_tmp8_, _tmp9_); |
4431 | 516 | _tmp12_ = __g_enum_value_dup0 (_tmp11_); | 514 | _tmp11_ = __g_enum_value_dup0 (_tmp10_); |
4432 | 517 | enum_value = _tmp12_; | 515 | enum_value = _tmp11_; |
4433 | 518 | _tmp13_ = enum_value; | 516 | _tmp12_ = enum_value; |
4434 | 519 | if (_tmp13_ != NULL) { | 517 | if (_tmp12_ != NULL) { |
4435 | 520 | GEnumValue* _tmp14_ = NULL; | 518 | GEnumValue* _tmp13_ = NULL; |
4436 | 521 | const gchar* _tmp15_ = NULL; | 519 | const gchar* _tmp14_ = NULL; |
4437 | 520 | gchar* _tmp15_ = NULL; | ||
4438 | 522 | gchar* _tmp16_ = NULL; | 521 | gchar* _tmp16_ = NULL; |
4446 | 523 | gchar* _tmp17_ = NULL; | 522 | _tmp13_ = enum_value; |
4447 | 524 | _tmp14_ = enum_value; | 523 | _tmp14_ = (*_tmp13_).value_nick; |
4448 | 525 | _tmp15_ = (*_tmp14_).value_nick; | 524 | _tmp15_ = g_strconcat ("convert-", _tmp14_, NULL); |
4449 | 526 | _tmp16_ = g_strconcat ("convert-", _tmp15_, NULL); | 525 | _tmp16_ = _tmp15_; |
4450 | 527 | _tmp17_ = _tmp16_; | 526 | kkc_state_handler_register_command_callback ((KkcStateHandler*) self, _tmp16_, _kkc_convert_segment_state_handler_do_clear_unhandled_kkc_command_callback, self); |
4451 | 528 | kkc_state_handler_register_command_callback ((KkcStateHandler*) self, _tmp17_, _kkc_convert_segment_state_handler_do_clear_unhandled_kkc_command_callback, self); | 527 | _g_free0 (_tmp16_); |
4445 | 529 | _g_free0 (_tmp17_); | ||
4452 | 530 | } | 528 | } |
4453 | 531 | _g_free0 (enum_value); | 529 | _g_free0 (enum_value); |
4454 | 532 | } | 530 | } |
4455 | @@ -540,7 +538,7 @@ | |||
4456 | 540 | 538 | ||
4457 | 541 | static void kkc_convert_segment_state_handler_class_init (KkcConvertSegmentStateHandlerClass * klass) { | 539 | static void kkc_convert_segment_state_handler_class_init (KkcConvertSegmentStateHandlerClass * klass) { |
4458 | 542 | kkc_convert_segment_state_handler_parent_class = g_type_class_peek_parent (klass); | 540 | kkc_convert_segment_state_handler_parent_class = g_type_class_peek_parent (klass); |
4460 | 543 | KKC_STATE_HANDLER_CLASS (klass)->process_key_event = kkc_convert_segment_state_handler_real_process_key_event; | 541 | ((KkcStateHandlerClass *) klass)->process_key_event = kkc_convert_segment_state_handler_real_process_key_event; |
4461 | 544 | G_OBJECT_CLASS (klass)->constructor = kkc_convert_segment_state_handler_constructor; | 542 | G_OBJECT_CLASS (klass)->constructor = kkc_convert_segment_state_handler_constructor; |
4462 | 545 | } | 543 | } |
4463 | 546 | 544 | ||
4464 | 547 | 545 | ||
4465 | === modified file 'libkkc/convert-segment-state-handler.vala' | |||
4466 | --- libkkc/convert-segment-state-handler.vala 2014-06-15 23:27:57 +0000 | |||
4467 | +++ libkkc/convert-segment-state-handler.vala 2014-10-01 15:12:30 +0000 | |||
4468 | @@ -1,6 +1,6 @@ | |||
4469 | 1 | /* | 1 | /* |
4472 | 2 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4473 | 3 | * Copyright (C) 2011-2013 Red Hat, Inc. | 3 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4474 | 4 | * | 4 | * |
4475 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
4476 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
4477 | 7 | 7 | ||
4478 | === modified file 'libkkc/convert-sentence-state-handler.c' | |||
4479 | --- libkkc/convert-sentence-state-handler.c 2014-06-15 23:27:57 +0000 | |||
4480 | +++ libkkc/convert-sentence-state-handler.c 2014-10-01 15:12:30 +0000 | |||
4481 | @@ -1,9 +1,9 @@ | |||
4483 | 1 | /* convert-sentence-state-handler.c generated by valac 0.22.1, the Vala compiler | 1 | /* convert-sentence-state-handler.c generated by valac 0.24.0.131-42e78, the Vala compiler |
4484 | 2 | * generated from convert-sentence-state-handler.vala, do not modify */ | 2 | * generated from convert-sentence-state-handler.vala, do not modify */ |
4485 | 3 | 3 | ||
4486 | 4 | /* | 4 | /* |
4489 | 5 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4490 | 6 | * Copyright (C) 2011-2013 Red Hat, Inc. | 6 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4491 | 7 | * | 7 | * |
4492 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
4493 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
4494 | @@ -599,10 +599,8 @@ | |||
4495 | 599 | KkcState* _tmp7_ = NULL; | 599 | KkcState* _tmp7_ = NULL; |
4496 | 600 | gboolean _tmp8_ = FALSE; | 600 | gboolean _tmp8_ = FALSE; |
4497 | 601 | const gchar* _tmp9_ = NULL; | 601 | const gchar* _tmp9_ = NULL; |
4502 | 602 | gboolean _tmp16_ = FALSE; | 602 | gboolean _tmp15_ = FALSE; |
4503 | 603 | gboolean _tmp17_ = FALSE; | 603 | const gchar* _tmp16_ = NULL; |
4500 | 604 | const gchar* _tmp18_ = NULL; | ||
4501 | 605 | gboolean _tmp27_ = FALSE; | ||
4504 | 606 | g_return_val_if_fail (self != NULL, FALSE); | 604 | g_return_val_if_fail (self != NULL, FALSE); |
4505 | 607 | g_return_val_if_fail (state != NULL, FALSE); | 605 | g_return_val_if_fail (state != NULL, FALSE); |
4506 | 608 | g_return_val_if_fail (key != NULL, FALSE); | 606 | g_return_val_if_fail (key != NULL, FALSE); |
4507 | @@ -624,7 +622,6 @@ | |||
4508 | 624 | } else { | 622 | } else { |
4509 | 625 | gboolean _tmp10_ = FALSE; | 623 | gboolean _tmp10_ = FALSE; |
4510 | 626 | const gchar* _tmp11_ = NULL; | 624 | const gchar* _tmp11_ = NULL; |
4511 | 627 | gboolean _tmp15_ = FALSE; | ||
4512 | 628 | _tmp11_ = command; | 625 | _tmp11_ = command; |
4513 | 629 | if (_tmp11_ == NULL) { | 626 | if (_tmp11_ == NULL) { |
4514 | 630 | KkcKeyEvent* _tmp12_ = NULL; | 627 | KkcKeyEvent* _tmp12_ = NULL; |
4515 | @@ -637,42 +634,37 @@ | |||
4516 | 637 | } else { | 634 | } else { |
4517 | 638 | _tmp10_ = FALSE; | 635 | _tmp10_ = FALSE; |
4518 | 639 | } | 636 | } |
4521 | 640 | _tmp15_ = _tmp10_; | 637 | _tmp8_ = _tmp10_; |
4520 | 641 | _tmp8_ = _tmp15_; | ||
4522 | 642 | } | 638 | } |
4525 | 643 | _tmp16_ = _tmp8_; | 639 | if (_tmp8_) { |
4524 | 644 | if (_tmp16_) { | ||
4526 | 645 | result = TRUE; | 640 | result = TRUE; |
4527 | 646 | return result; | 641 | return result; |
4528 | 647 | } | 642 | } |
4541 | 648 | _tmp18_ = command; | 643 | _tmp16_ = command; |
4542 | 649 | if (_tmp18_ == NULL) { | 644 | if (_tmp16_ == NULL) { |
4543 | 650 | gboolean _tmp19_ = FALSE; | 645 | gboolean _tmp17_ = FALSE; |
4544 | 651 | KkcKeyEvent* _tmp20_ = NULL; | 646 | KkcKeyEvent* _tmp18_ = NULL; |
4545 | 652 | KkcModifierType _tmp21_ = 0; | 647 | KkcModifierType _tmp19_ = 0; |
4546 | 653 | KkcModifierType _tmp22_ = 0; | 648 | KkcModifierType _tmp20_ = 0; |
4547 | 654 | gboolean _tmp26_ = FALSE; | 649 | _tmp18_ = key; |
4548 | 655 | _tmp20_ = key; | 650 | _tmp19_ = kkc_key_event_get_modifiers (_tmp18_); |
4549 | 656 | _tmp21_ = kkc_key_event_get_modifiers (_tmp20_); | 651 | _tmp20_ = _tmp19_; |
4550 | 657 | _tmp22_ = _tmp21_; | 652 | if (_tmp20_ == 0) { |
4551 | 658 | if (_tmp22_ == 0) { | 653 | _tmp17_ = TRUE; |
4540 | 659 | _tmp19_ = TRUE; | ||
4552 | 660 | } else { | 654 | } else { |
4560 | 661 | KkcKeyEvent* _tmp23_ = NULL; | 655 | KkcKeyEvent* _tmp21_ = NULL; |
4561 | 662 | KkcModifierType _tmp24_ = 0; | 656 | KkcModifierType _tmp22_ = 0; |
4562 | 663 | KkcModifierType _tmp25_ = 0; | 657 | KkcModifierType _tmp23_ = 0; |
4563 | 664 | _tmp23_ = key; | 658 | _tmp21_ = key; |
4564 | 665 | _tmp24_ = kkc_key_event_get_modifiers (_tmp23_); | 659 | _tmp22_ = kkc_key_event_get_modifiers (_tmp21_); |
4565 | 666 | _tmp25_ = _tmp24_; | 660 | _tmp23_ = _tmp22_; |
4566 | 667 | _tmp19_ = _tmp25_ == KKC_MODIFIER_TYPE_SHIFT_MASK; | 661 | _tmp17_ = _tmp23_ == KKC_MODIFIER_TYPE_SHIFT_MASK; |
4567 | 668 | } | 662 | } |
4570 | 669 | _tmp26_ = _tmp19_; | 663 | _tmp15_ = _tmp17_; |
4569 | 670 | _tmp17_ = _tmp26_; | ||
4571 | 671 | } else { | 664 | } else { |
4573 | 672 | _tmp17_ = FALSE; | 665 | _tmp15_ = FALSE; |
4574 | 673 | } | 666 | } |
4577 | 674 | _tmp27_ = _tmp17_; | 667 | if (_tmp15_) { |
4576 | 675 | if (_tmp27_) { | ||
4578 | 676 | result = FALSE; | 668 | result = FALSE; |
4579 | 677 | return result; | 669 | return result; |
4580 | 678 | } | 670 | } |
4581 | @@ -712,63 +704,63 @@ | |||
4582 | 712 | 704 | ||
4583 | 713 | static gboolean _kkc_convert_sentence_state_handler_do_start_segment_conversion_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 705 | static gboolean _kkc_convert_sentence_state_handler_do_start_segment_conversion_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4584 | 714 | gboolean result; | 706 | gboolean result; |
4586 | 715 | result = kkc_convert_sentence_state_handler_do_start_segment_conversion (self, command, state, key); | 707 | result = kkc_convert_sentence_state_handler_do_start_segment_conversion ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4587 | 716 | return result; | 708 | return result; |
4588 | 717 | } | 709 | } |
4589 | 718 | 710 | ||
4590 | 719 | 711 | ||
4591 | 720 | static gboolean _kkc_convert_sentence_state_handler_do_original_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 712 | static gboolean _kkc_convert_sentence_state_handler_do_original_candidate_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4592 | 721 | gboolean result; | 713 | gboolean result; |
4594 | 722 | result = kkc_convert_sentence_state_handler_do_original_candidate (self, command, state, key); | 714 | result = kkc_convert_sentence_state_handler_do_original_candidate ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4595 | 723 | return result; | 715 | return result; |
4596 | 724 | } | 716 | } |
4597 | 725 | 717 | ||
4598 | 726 | 718 | ||
4599 | 727 | static gboolean _kkc_convert_sentence_state_handler_do_expand_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 719 | static gboolean _kkc_convert_sentence_state_handler_do_expand_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4600 | 728 | gboolean result; | 720 | gboolean result; |
4602 | 729 | result = kkc_convert_sentence_state_handler_do_expand_segment (self, command, state, key); | 721 | result = kkc_convert_sentence_state_handler_do_expand_segment ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4603 | 730 | return result; | 722 | return result; |
4604 | 731 | } | 723 | } |
4605 | 732 | 724 | ||
4606 | 733 | 725 | ||
4607 | 734 | static gboolean _kkc_convert_sentence_state_handler_do_shrink_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 726 | static gboolean _kkc_convert_sentence_state_handler_do_shrink_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4608 | 735 | gboolean result; | 727 | gboolean result; |
4610 | 736 | result = kkc_convert_sentence_state_handler_do_shrink_segment (self, command, state, key); | 728 | result = kkc_convert_sentence_state_handler_do_shrink_segment ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4611 | 737 | return result; | 729 | return result; |
4612 | 738 | } | 730 | } |
4613 | 739 | 731 | ||
4614 | 740 | 732 | ||
4615 | 741 | static gboolean _kkc_convert_sentence_state_handler_do_next_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 733 | static gboolean _kkc_convert_sentence_state_handler_do_next_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4616 | 742 | gboolean result; | 734 | gboolean result; |
4618 | 743 | result = kkc_convert_sentence_state_handler_do_next_segment (self, command, state, key); | 735 | result = kkc_convert_sentence_state_handler_do_next_segment ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4619 | 744 | return result; | 736 | return result; |
4620 | 745 | } | 737 | } |
4621 | 746 | 738 | ||
4622 | 747 | 739 | ||
4623 | 748 | static gboolean _kkc_convert_sentence_state_handler_do_previous_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 740 | static gboolean _kkc_convert_sentence_state_handler_do_previous_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4624 | 749 | gboolean result; | 741 | gboolean result; |
4626 | 750 | result = kkc_convert_sentence_state_handler_do_previous_segment (self, command, state, key); | 742 | result = kkc_convert_sentence_state_handler_do_previous_segment ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4627 | 751 | return result; | 743 | return result; |
4628 | 752 | } | 744 | } |
4629 | 753 | 745 | ||
4630 | 754 | 746 | ||
4631 | 755 | static gboolean _kkc_convert_sentence_state_handler_do_first_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 747 | static gboolean _kkc_convert_sentence_state_handler_do_first_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4632 | 756 | gboolean result; | 748 | gboolean result; |
4634 | 757 | result = kkc_convert_sentence_state_handler_do_first_segment (self, command, state, key); | 749 | result = kkc_convert_sentence_state_handler_do_first_segment ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4635 | 758 | return result; | 750 | return result; |
4636 | 759 | } | 751 | } |
4637 | 760 | 752 | ||
4638 | 761 | 753 | ||
4639 | 762 | static gboolean _kkc_convert_sentence_state_handler_do_last_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 754 | static gboolean _kkc_convert_sentence_state_handler_do_last_segment_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4640 | 763 | gboolean result; | 755 | gboolean result; |
4642 | 764 | result = kkc_convert_sentence_state_handler_do_last_segment (self, command, state, key); | 756 | result = kkc_convert_sentence_state_handler_do_last_segment ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4643 | 765 | return result; | 757 | return result; |
4644 | 766 | } | 758 | } |
4645 | 767 | 759 | ||
4646 | 768 | 760 | ||
4647 | 769 | static gboolean _kkc_convert_sentence_state_handler_do_clear_unhandled_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 761 | static gboolean _kkc_convert_sentence_state_handler_do_clear_unhandled_kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4648 | 770 | gboolean result; | 762 | gboolean result; |
4650 | 771 | result = kkc_convert_sentence_state_handler_do_clear_unhandled (self, command, state, key); | 763 | result = kkc_convert_sentence_state_handler_do_clear_unhandled ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4651 | 772 | return result; | 764 | return result; |
4652 | 773 | } | 765 | } |
4653 | 774 | 766 | ||
4654 | @@ -788,7 +780,7 @@ | |||
4655 | 788 | 780 | ||
4656 | 789 | static gboolean _kkc_convert_sentence_state_handler_do__kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { | 781 | static gboolean _kkc_convert_sentence_state_handler_do__kkc_command_callback (const gchar* command, KkcState* state, KkcKeyEvent* key, gpointer self) { |
4657 | 790 | gboolean result; | 782 | gboolean result; |
4659 | 791 | result = kkc_convert_sentence_state_handler_do_ (self, command, state, key); | 783 | result = kkc_convert_sentence_state_handler_do_ ((KkcConvertSentenceStateHandler*) self, command, state, key); |
4660 | 792 | return result; | 784 | return result; |
4661 | 793 | } | 785 | } |
4662 | 794 | 786 | ||
4663 | @@ -827,55 +819,53 @@ | |||
4664 | 827 | gboolean _tmp3_ = FALSE; | 819 | gboolean _tmp3_ = FALSE; |
4665 | 828 | _tmp3_ = TRUE; | 820 | _tmp3_ = TRUE; |
4666 | 829 | while (TRUE) { | 821 | while (TRUE) { |
4671 | 830 | gboolean _tmp4_ = FALSE; | 822 | gint _tmp5_ = 0; |
4672 | 831 | gint _tmp6_ = 0; | 823 | GEnumClass* _tmp6_ = NULL; |
4673 | 832 | GEnumClass* _tmp7_ = NULL; | 824 | gint _tmp7_ = 0; |
4670 | 833 | gint _tmp8_ = 0; | ||
4674 | 834 | GEnumValue* enum_value = NULL; | 825 | GEnumValue* enum_value = NULL; |
4677 | 835 | GEnumClass* _tmp9_ = NULL; | 826 | GEnumClass* _tmp8_ = NULL; |
4678 | 836 | gint _tmp10_ = 0; | 827 | gint _tmp9_ = 0; |
4679 | 828 | GEnumValue* _tmp10_ = NULL; | ||
4680 | 837 | GEnumValue* _tmp11_ = NULL; | 829 | GEnumValue* _tmp11_ = NULL; |
4681 | 838 | GEnumValue* _tmp12_ = NULL; | 830 | GEnumValue* _tmp12_ = NULL; |
4688 | 839 | GEnumValue* _tmp13_ = NULL; | 831 | if (!_tmp3_) { |
4689 | 840 | _tmp4_ = _tmp3_; | 832 | gint _tmp4_ = 0; |
4690 | 841 | if (!_tmp4_) { | 833 | _tmp4_ = i; |
4691 | 842 | gint _tmp5_ = 0; | 834 | i = _tmp4_ + 1; |
4686 | 843 | _tmp5_ = i; | ||
4687 | 844 | i = _tmp5_ + 1; | ||
4692 | 845 | } | 835 | } |
4693 | 846 | _tmp3_ = FALSE; | 836 | _tmp3_ = FALSE; |
4698 | 847 | _tmp6_ = i; | 837 | _tmp5_ = i; |
4699 | 848 | _tmp7_ = enum_class; | 838 | _tmp6_ = enum_class; |
4700 | 849 | _tmp8_ = _tmp7_->maximum; | 839 | _tmp7_ = _tmp6_->maximum; |
4701 | 850 | if (!(_tmp6_ <= _tmp8_)) { | 840 | if (!(_tmp5_ <= _tmp7_)) { |
4702 | 851 | break; | 841 | break; |
4703 | 852 | } | 842 | } |
4713 | 853 | _tmp9_ = enum_class; | 843 | _tmp8_ = enum_class; |
4714 | 854 | _tmp10_ = i; | 844 | _tmp9_ = i; |
4715 | 855 | _tmp11_ = g_enum_get_value (_tmp9_, _tmp10_); | 845 | _tmp10_ = g_enum_get_value (_tmp8_, _tmp9_); |
4716 | 856 | _tmp12_ = __g_enum_value_dup0 (_tmp11_); | 846 | _tmp11_ = __g_enum_value_dup0 (_tmp10_); |
4717 | 857 | enum_value = _tmp12_; | 847 | enum_value = _tmp11_; |
4718 | 858 | _tmp13_ = enum_value; | 848 | _tmp12_ = enum_value; |
4719 | 859 | if (_tmp13_ != NULL) { | 849 | if (_tmp12_ != NULL) { |
4720 | 860 | GEnumValue* _tmp14_ = NULL; | 850 | GEnumValue* _tmp13_ = NULL; |
4721 | 861 | const gchar* _tmp15_ = NULL; | 851 | const gchar* _tmp14_ = NULL; |
4722 | 852 | gchar* _tmp15_ = NULL; | ||
4723 | 862 | gchar* _tmp16_ = NULL; | 853 | gchar* _tmp16_ = NULL; |
4727 | 863 | gchar* _tmp17_ = NULL; | 854 | GEnumValue* _tmp17_ = NULL; |
4728 | 864 | GEnumValue* _tmp18_ = NULL; | 855 | gint _tmp18_ = 0; |
4729 | 865 | gint _tmp19_ = 0; | 856 | KkcConvertSentenceStateHandlerConvertCommandHandler* _tmp19_ = NULL; |
4730 | 866 | KkcConvertSentenceStateHandlerConvertCommandHandler* _tmp20_ = NULL; | 857 | KkcConvertSentenceStateHandlerConvertCommandHandler* _tmp20_ = NULL; |
4743 | 867 | KkcConvertSentenceStateHandlerConvertCommandHandler* _tmp21_ = NULL; | 858 | _tmp13_ = enum_value; |
4744 | 868 | _tmp14_ = enum_value; | 859 | _tmp14_ = (*_tmp13_).value_nick; |
4745 | 869 | _tmp15_ = (*_tmp14_).value_nick; | 860 | _tmp15_ = g_strconcat ("convert-", _tmp14_, NULL); |
4746 | 870 | _tmp16_ = g_strconcat ("convert-", _tmp15_, NULL); | 861 | _tmp16_ = _tmp15_; |
4747 | 871 | _tmp17_ = _tmp16_; | 862 | _tmp17_ = enum_value; |
4748 | 872 | _tmp18_ = enum_value; | 863 | _tmp18_ = (*_tmp17_).value; |
4749 | 873 | _tmp19_ = (*_tmp18_).value; | 864 | _tmp19_ = kkc_convert_sentence_state_handler_convert_command_handler_new ((KkcKanaMode) _tmp18_); |
4750 | 874 | _tmp20_ = kkc_convert_sentence_state_handler_convert_command_handler_new ((KkcKanaMode) _tmp19_); | 865 | _tmp20_ = _tmp19_; |
4751 | 875 | _tmp21_ = _tmp20_; | 866 | kkc_state_handler_register_command_handler ((KkcStateHandler*) self, _tmp16_, (KkcCommandHandler*) _tmp20_); |
4752 | 876 | kkc_state_handler_register_command_handler ((KkcStateHandler*) self, _tmp17_, (KkcCommandHandler*) _tmp21_); | 867 | _g_object_unref0 (_tmp20_); |
4753 | 877 | _g_object_unref0 (_tmp21_); | 868 | _g_free0 (_tmp16_); |
4742 | 878 | _g_free0 (_tmp17_); | ||
4754 | 879 | } | 869 | } |
4755 | 880 | _g_free0 (enum_value); | 870 | _g_free0 (enum_value); |
4756 | 881 | } | 871 | } |
4757 | @@ -959,7 +949,7 @@ | |||
4758 | 959 | 949 | ||
4759 | 960 | static void kkc_convert_sentence_state_handler_class_init (KkcConvertSentenceStateHandlerClass * klass) { | 950 | static void kkc_convert_sentence_state_handler_class_init (KkcConvertSentenceStateHandlerClass * klass) { |
4760 | 961 | kkc_convert_sentence_state_handler_parent_class = g_type_class_peek_parent (klass); | 951 | kkc_convert_sentence_state_handler_parent_class = g_type_class_peek_parent (klass); |
4762 | 962 | KKC_STATE_HANDLER_CLASS (klass)->process_key_event = kkc_convert_sentence_state_handler_real_process_key_event; | 952 | ((KkcStateHandlerClass *) klass)->process_key_event = kkc_convert_sentence_state_handler_real_process_key_event; |
4763 | 963 | G_OBJECT_CLASS (klass)->constructor = kkc_convert_sentence_state_handler_constructor; | 953 | G_OBJECT_CLASS (klass)->constructor = kkc_convert_sentence_state_handler_constructor; |
4764 | 964 | } | 954 | } |
4765 | 965 | 955 | ||
4766 | 966 | 956 | ||
4767 | === modified file 'libkkc/convert-sentence-state-handler.vala' | |||
4768 | --- libkkc/convert-sentence-state-handler.vala 2014-06-15 23:27:57 +0000 | |||
4769 | +++ libkkc/convert-sentence-state-handler.vala 2014-10-01 15:12:30 +0000 | |||
4770 | @@ -1,6 +1,6 @@ | |||
4771 | 1 | /* | 1 | /* |
4774 | 2 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4775 | 3 | * Copyright (C) 2011-2013 Red Hat, Inc. | 3 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4776 | 4 | * | 4 | * |
4777 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
4778 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
4779 | 7 | 7 | ||
4780 | === modified file 'libkkc/decoder.c' | |||
4781 | --- libkkc/decoder.c 2014-06-15 23:27:57 +0000 | |||
4782 | +++ libkkc/decoder.c 2014-10-01 15:12:30 +0000 | |||
4783 | @@ -1,9 +1,9 @@ | |||
4785 | 1 | /* decoder.c generated by valac 0.22.1, the Vala compiler | 1 | /* decoder.c generated by valac 0.24.0.131-42e78, the Vala compiler |
4786 | 2 | * generated from decoder.vala, do not modify */ | 2 | * generated from decoder.vala, do not modify */ |
4787 | 3 | 3 | ||
4788 | 4 | /* | 4 | /* |
4791 | 5 | * Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
4792 | 6 | * Copyright (C) 2012-2013 Red Hat, Inc. | 6 | * Copyright (C) 2012-2014 Red Hat, Inc. |
4793 | 7 | * | 7 | * |
4794 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
4795 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
4796 | @@ -234,8 +234,8 @@ | |||
4797 | 234 | 234 | ||
4798 | 235 | static void kkc_decoder_class_init (KkcDecoderClass * klass) { | 235 | static void kkc_decoder_class_init (KkcDecoderClass * klass) { |
4799 | 236 | kkc_decoder_parent_class = g_type_class_peek_parent (klass); | 236 | kkc_decoder_parent_class = g_type_class_peek_parent (klass); |
4802 | 237 | KKC_DECODER_CLASS (klass)->decode = kkc_decoder_real_decode; | 237 | ((KkcDecoderClass *) klass)->decode = kkc_decoder_real_decode; |
4803 | 238 | KKC_DECODER_CLASS (klass)->decode_with_costs = kkc_decoder_real_decode_with_costs; | 238 | ((KkcDecoderClass *) klass)->decode_with_costs = kkc_decoder_real_decode_with_costs; |
4804 | 239 | } | 239 | } |
4805 | 240 | 240 | ||
4806 | 241 | 241 | ||
4807 | 242 | 242 | ||
4808 | === modified file 'libkkc/decoder.vala' | |||
4809 | --- libkkc/decoder.vala 2014-02-26 22:51:39 +0000 | |||
4810 | +++ libkkc/decoder.vala 2014-10-01 15:12:30 +0000 | |||
4811 | @@ -1,6 +1,6 @@ | |||
4812 | 1 | /* | 1 | /* |
4815 | 2 | * Copyright (C) 2012-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2012-2014 Daiki Ueno <ueno@gnu.org> |
4816 | 3 | * Copyright (C) 2012-2013 Red Hat, Inc. | 3 | * Copyright (C) 2012-2014 Red Hat, Inc. |
4817 | 4 | * | 4 | * |
4818 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
4819 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
4820 | 7 | 7 | ||
4821 | === modified file 'libkkc/dictionary-list.c' | |||
4822 | --- libkkc/dictionary-list.c 2014-06-15 23:27:57 +0000 | |||
4823 | +++ libkkc/dictionary-list.c 2014-10-01 15:12:30 +0000 | |||
4824 | @@ -1,9 +1,9 @@ | |||
4826 | 1 | /* dictionary-list.c generated by valac 0.22.1, the Vala compiler | 1 | /* dictionary-list.c generated by valac 0.24.0.131-42e78, the Vala compiler |
4827 | 2 | * generated from dictionary-list.vala, do not modify */ | 2 | * generated from dictionary-list.vala, do not modify */ |
4828 | 3 | 3 | ||
4829 | 4 | /* | 4 | /* |
4832 | 5 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4833 | 6 | * Copyright (C) 2011-2013 Red Hat, Inc. | 6 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4834 | 7 | * | 7 | * |
4835 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
4836 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
4837 | @@ -88,9 +88,9 @@ | |||
4838 | 88 | void kkc_dictionary_list_clear (KkcDictionaryList* self); | 88 | void kkc_dictionary_list_clear (KkcDictionaryList* self); |
4839 | 89 | void kkc_dictionary_list_call (KkcDictionaryList* self, GType* type, KkcDictionaryListDictionaryCallback callback, void* callback_target); | 89 | void kkc_dictionary_list_call (KkcDictionaryList* self, GType* type, KkcDictionaryListDictionaryCallback callback, void* callback_target); |
4840 | 90 | void kkc_dictionary_list_save (KkcDictionaryList* self); | 90 | void kkc_dictionary_list_save (KkcDictionaryList* self); |
4842 | 91 | static KkcDictionaryCallbackReturn __lambda7_ (KkcDictionaryList* self, KkcDictionary* dictionary); | 91 | static KkcDictionaryCallbackReturn __lambda9_ (KkcDictionaryList* self, KkcDictionary* dictionary); |
4843 | 92 | void kkc_dictionary_save (KkcDictionary* self, GError** error); | 92 | void kkc_dictionary_save (KkcDictionary* self, GError** error); |
4845 | 93 | static KkcDictionaryCallbackReturn ___lambda7__kkc_dictionary_list_dictionary_callback (KkcDictionary* dictionary, gpointer self); | 93 | static KkcDictionaryCallbackReturn ___lambda9__kkc_dictionary_list_dictionary_callback (KkcDictionary* dictionary, gpointer self); |
4846 | 94 | KkcDictionaryList* kkc_dictionary_list_new (void); | 94 | KkcDictionaryList* kkc_dictionary_list_new (void); |
4847 | 95 | KkcDictionaryList* kkc_dictionary_list_construct (GType object_type); | 95 | KkcDictionaryList* kkc_dictionary_list_construct (GType object_type); |
4848 | 96 | gint kkc_dictionary_list_get_size (KkcDictionaryList* self); | 96 | gint kkc_dictionary_list_get_size (KkcDictionaryList* self); |
4849 | @@ -197,8 +197,6 @@ | |||
4850 | 197 | gboolean _tmp11_ = FALSE; | 197 | gboolean _tmp11_ = FALSE; |
4851 | 198 | gboolean _tmp12_ = FALSE; | 198 | gboolean _tmp12_ = FALSE; |
4852 | 199 | GType* _tmp13_ = NULL; | 199 | GType* _tmp13_ = NULL; |
4853 | 200 | gboolean _tmp18_ = FALSE; | ||
4854 | 201 | gboolean _tmp22_ = FALSE; | ||
4855 | 202 | _tmp5_ = _dictionary_index; | 200 | _tmp5_ = _dictionary_index; |
4856 | 203 | _dictionary_index = _tmp5_ + 1; | 201 | _dictionary_index = _tmp5_ + 1; |
4857 | 204 | _tmp6_ = _dictionary_index; | 202 | _tmp6_ = _dictionary_index; |
4858 | @@ -224,22 +222,20 @@ | |||
4859 | 224 | _tmp17_ = g_type_is_a (_tmp15_, *_tmp16_); | 222 | _tmp17_ = g_type_is_a (_tmp15_, *_tmp16_); |
4860 | 225 | _tmp12_ = _tmp17_; | 223 | _tmp12_ = _tmp17_; |
4861 | 226 | } | 224 | } |
4873 | 227 | _tmp18_ = _tmp12_; | 225 | if (_tmp12_) { |
4874 | 228 | if (_tmp18_) { | 226 | KkcDictionaryListDictionaryCallback _tmp18_ = NULL; |
4875 | 229 | KkcDictionaryListDictionaryCallback _tmp19_ = NULL; | 227 | void* _tmp18__target = NULL; |
4876 | 230 | void* _tmp19__target = NULL; | 228 | KkcDictionary* _tmp19_ = NULL; |
4877 | 231 | KkcDictionary* _tmp20_ = NULL; | 229 | KkcDictionaryCallbackReturn _tmp20_ = 0; |
4878 | 232 | KkcDictionaryCallbackReturn _tmp21_ = 0; | 230 | _tmp18_ = callback; |
4879 | 233 | _tmp19_ = callback; | 231 | _tmp18__target = callback_target; |
4880 | 234 | _tmp19__target = callback_target; | 232 | _tmp19_ = dictionary; |
4881 | 235 | _tmp20_ = dictionary; | 233 | _tmp20_ = _tmp18_ (_tmp19_, _tmp18__target); |
4882 | 236 | _tmp21_ = _tmp19_ (_tmp20_, _tmp19__target); | 234 | _tmp11_ = _tmp20_ == KKC_DICTIONARY_CALLBACK_RETURN_REMOVE; |
4872 | 237 | _tmp11_ = _tmp21_ == KKC_DICTIONARY_CALLBACK_RETURN_REMOVE; | ||
4883 | 238 | } else { | 235 | } else { |
4884 | 239 | _tmp11_ = FALSE; | 236 | _tmp11_ = FALSE; |
4885 | 240 | } | 237 | } |
4888 | 241 | _tmp22_ = _tmp11_; | 238 | if (_tmp11_) { |
4887 | 242 | if (_tmp22_) { | ||
4889 | 243 | _g_object_unref0 (dictionary); | 239 | _g_object_unref0 (dictionary); |
4890 | 244 | _g_object_unref0 (_dictionary_list); | 240 | _g_object_unref0 (_dictionary_list); |
4891 | 245 | return; | 241 | return; |
4892 | @@ -254,7 +250,7 @@ | |||
4893 | 254 | /** | 250 | /** |
4894 | 255 | * Save dictionaries on to disk. | 251 | * Save dictionaries on to disk. |
4895 | 256 | */ | 252 | */ |
4897 | 257 | static KkcDictionaryCallbackReturn __lambda7_ (KkcDictionaryList* self, KkcDictionary* dictionary) { | 253 | static KkcDictionaryCallbackReturn __lambda9_ (KkcDictionaryList* self, KkcDictionary* dictionary) { |
4898 | 258 | KkcDictionaryCallbackReturn result = 0; | 254 | KkcDictionaryCallbackReturn result = 0; |
4899 | 259 | GError * _inner_error_ = NULL; | 255 | GError * _inner_error_ = NULL; |
4900 | 260 | g_return_val_if_fail (dictionary != NULL, 0); | 256 | g_return_val_if_fail (dictionary != NULL, 0); |
4901 | @@ -262,7 +258,7 @@ | |||
4902 | 262 | KkcDictionary* _tmp0_ = NULL; | 258 | KkcDictionary* _tmp0_ = NULL; |
4903 | 263 | _tmp0_ = dictionary; | 259 | _tmp0_ = dictionary; |
4904 | 264 | kkc_dictionary_save (_tmp0_, &_inner_error_); | 260 | kkc_dictionary_save (_tmp0_, &_inner_error_); |
4906 | 265 | if (_inner_error_ != NULL) { | 261 | if (G_UNLIKELY (_inner_error_ != NULL)) { |
4907 | 266 | goto __catch19_g_error; | 262 | goto __catch19_g_error; |
4908 | 267 | } | 263 | } |
4909 | 268 | } | 264 | } |
4910 | @@ -280,7 +276,7 @@ | |||
4911 | 280 | _g_error_free0 (e); | 276 | _g_error_free0 (e); |
4912 | 281 | } | 277 | } |
4913 | 282 | __finally19: | 278 | __finally19: |
4915 | 283 | if (_inner_error_ != NULL) { | 279 | if (G_UNLIKELY (_inner_error_ != NULL)) { |
4916 | 284 | g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); | 280 | g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); |
4917 | 285 | g_clear_error (&_inner_error_); | 281 | g_clear_error (&_inner_error_); |
4918 | 286 | return 0; | 282 | return 0; |
4919 | @@ -290,16 +286,16 @@ | |||
4920 | 290 | } | 286 | } |
4921 | 291 | 287 | ||
4922 | 292 | 288 | ||
4924 | 293 | static KkcDictionaryCallbackReturn ___lambda7__kkc_dictionary_list_dictionary_callback (KkcDictionary* dictionary, gpointer self) { | 289 | static KkcDictionaryCallbackReturn ___lambda9__kkc_dictionary_list_dictionary_callback (KkcDictionary* dictionary, gpointer self) { |
4925 | 294 | KkcDictionaryCallbackReturn result; | 290 | KkcDictionaryCallbackReturn result; |
4927 | 295 | result = __lambda7_ (self, dictionary); | 291 | result = __lambda9_ ((KkcDictionaryList*) self, dictionary); |
4928 | 296 | return result; | 292 | return result; |
4929 | 297 | } | 293 | } |
4930 | 298 | 294 | ||
4931 | 299 | 295 | ||
4932 | 300 | void kkc_dictionary_list_save (KkcDictionaryList* self) { | 296 | void kkc_dictionary_list_save (KkcDictionaryList* self) { |
4933 | 301 | g_return_if_fail (self != NULL); | 297 | g_return_if_fail (self != NULL); |
4935 | 302 | kkc_dictionary_list_call (self, NULL, ___lambda7__kkc_dictionary_list_dictionary_callback, self); | 298 | kkc_dictionary_list_call (self, NULL, ___lambda9__kkc_dictionary_list_dictionary_callback, self); |
4936 | 303 | } | 299 | } |
4937 | 304 | 300 | ||
4938 | 305 | 301 | ||
4939 | @@ -344,7 +340,7 @@ | |||
4940 | 344 | static void kkc_dictionary_list_instance_init (KkcDictionaryList * self) { | 340 | static void kkc_dictionary_list_instance_init (KkcDictionaryList * self) { |
4941 | 345 | GeeArrayList* _tmp0_ = NULL; | 341 | GeeArrayList* _tmp0_ = NULL; |
4942 | 346 | self->priv = KKC_DICTIONARY_LIST_GET_PRIVATE (self); | 342 | self->priv = KKC_DICTIONARY_LIST_GET_PRIVATE (self); |
4944 | 347 | _tmp0_ = gee_array_list_new (KKC_TYPE_DICTIONARY, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL); | 343 | _tmp0_ = gee_array_list_new (KKC_TYPE_DICTIONARY, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL); |
4945 | 348 | self->priv->dictionaries = (GeeList*) _tmp0_; | 344 | self->priv->dictionaries = (GeeList*) _tmp0_; |
4946 | 349 | } | 345 | } |
4947 | 350 | 346 | ||
4948 | 351 | 347 | ||
4949 | === modified file 'libkkc/dictionary-list.vala' | |||
4950 | --- libkkc/dictionary-list.vala 2014-02-26 22:51:39 +0000 | |||
4951 | +++ libkkc/dictionary-list.vala 2014-10-01 15:12:30 +0000 | |||
4952 | @@ -1,6 +1,6 @@ | |||
4953 | 1 | /* | 1 | /* |
4956 | 2 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 2 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4957 | 3 | * Copyright (C) 2011-2013 Red Hat, Inc. | 3 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4958 | 4 | * | 4 | * |
4959 | 5 | * This program is free software: you can redistribute it and/or modify | 5 | * This program is free software: you can redistribute it and/or modify |
4960 | 6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
4961 | 7 | 7 | ||
4962 | === modified file 'libkkc/dictionary.c' | |||
4963 | --- libkkc/dictionary.c 2014-06-15 23:27:57 +0000 | |||
4964 | +++ libkkc/dictionary.c 2014-10-01 15:12:30 +0000 | |||
4965 | @@ -1,9 +1,9 @@ | |||
4967 | 1 | /* dictionary.c generated by valac 0.22.1, the Vala compiler | 1 | /* dictionary.c generated by valac 0.24.0.131-42e78, the Vala compiler |
4968 | 2 | * generated from dictionary.vala, do not modify */ | 2 | * generated from dictionary.vala, do not modify */ |
4969 | 3 | 3 | ||
4970 | 4 | /* | 4 | /* |
4973 | 5 | * Copyright (C) 2011-2013 Daiki Ueno <ueno@gnu.org> | 5 | * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org> |
4974 | 6 | * Copyright (C) 2011-2013 Red Hat, Inc. | 6 | * Copyright (C) 2011-2014 Red Hat, Inc. |
4975 | 7 | * | 7 | * |
4976 | 8 | * This program is free software: you can redistribute it and/or modify | 8 | * This program is free software: you can redistribute it and/or modify |
4977 | 9 | * it under the terms of the GNU General Public License as published by | 9 | * it under the terms of the GNU General Public License as published by |
4978 | @@ -143,15 +143,13 @@ | |||
4979 | 143 | gboolean _tmp8_ = FALSE; | 143 | gboolean _tmp8_ = FALSE; |
4980 | 144 | glong _tmp9_ = 0L; | 144 | glong _tmp9_ = 0L; |
4981 | 145 | gboolean _tmp12_ = FALSE; | 145 | gboolean _tmp12_ = FALSE; |
4985 | 146 | gboolean _tmp13_ = FALSE; | 146 | glong _tmp13_ = 0L; |
4986 | 147 | glong _tmp14_ = 0L; | 147 | glong _tmp16_ = 0L; |
4987 | 148 | gboolean _tmp17_ = FALSE; | 148 | glong _tmp17_ = 0L; |
4988 | 149 | glong _tmp18_ = 0L; | 149 | glong _tmp18_ = 0L; |
4989 | 150 | glong _tmp19_ = 0L; | 150 | glong _tmp19_ = 0L; |
4990 | 151 | glong _tmp20_ = 0L; | 151 | glong _tmp20_ = 0L; |
4994 | 152 | glong _tmp21_ = 0L; | 152 | gchar* _tmp21_ = NULL; |
4992 | 153 | glong _tmp22_ = 0L; | ||
4993 | 154 | gchar* _tmp23_ = NULL; | ||
4995 | 155 | g_return_val_if_fail (self != NULL, NULL); | 153 | g_return_val_if_fail (self != NULL, NULL); |
4996 | 156 | _tmp0_ = strlen (self); | 154 | _tmp0_ = strlen (self); |
4997 | 157 | _tmp1_ = _tmp0_; | 155 | _tmp1_ = _tmp0_; |
4998 | @@ -182,28 +180,26 @@ | |||
4999 | 182 | } else { | 180 | } else { |
5000 | 183 | _tmp8_ = FALSE; | 181 | _tmp8_ = FALSE; |
The diff has been truncated for viewing.
Already archived new package in debian. Does not need to merge, just sync.