gherkin 2.12.2 → 3.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (333) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +2 -15
  3. data/CONTRIBUTING.md +23 -0
  4. data/Gemfile +0 -3
  5. data/LICENSE +18 -17
  6. data/Makefile +65 -0
  7. data/README.md +9 -268
  8. data/Rakefile +17 -19
  9. data/bin/gherkin-generate-ast +21 -0
  10. data/bin/gherkin-generate-pickles +25 -0
  11. data/bin/gherkin-generate-tokens +12 -0
  12. data/gherkin-ruby.razor +218 -0
  13. data/gherkin.gemspec +22 -76
  14. data/lib/gherkin/ast_builder.rb +243 -0
  15. data/lib/gherkin/ast_node.rb +30 -0
  16. data/lib/gherkin/dialect.rb +58 -0
  17. data/lib/gherkin/errors.rb +45 -0
  18. data/lib/gherkin/gherkin-languages.json +2968 -0
  19. data/lib/gherkin/gherkin_line.rb +95 -0
  20. data/lib/gherkin/parser.rb +1910 -0
  21. data/lib/gherkin/pickles/compiler.rb +164 -0
  22. data/lib/gherkin/token.rb +18 -0
  23. data/lib/gherkin/token_formatter_builder.rb +39 -0
  24. data/lib/gherkin/token_matcher.rb +169 -0
  25. data/lib/gherkin/token_scanner.rb +40 -0
  26. data/spec/capture_warnings.rb +68 -0
  27. data/spec/coverage.rb +10 -0
  28. data/spec/gherkin/parser_spec.rb +146 -0
  29. metadata +60 -567
  30. data/.gitattributes +0 -2
  31. data/.mailmap +0 -2
  32. data/.rbenv-gemsets +0 -1
  33. data/.rspec +0 -1
  34. data/.ruby-gemset +0 -1
  35. data/.ruby-version +0 -1
  36. data/.yardopts +0 -5
  37. data/History.md +0 -881
  38. data/build_native_gems.sh +0 -7
  39. data/cucumber.yml +0 -5
  40. data/examples/parse_and_output_json.rb +0 -19
  41. data/ext/gherkin_lexer_ar/extconf.rb +0 -6
  42. data/ext/gherkin_lexer_ar/gherkin_lexer_ar.c +0 -1432
  43. data/ext/gherkin_lexer_bg/extconf.rb +0 -6
  44. data/ext/gherkin_lexer_bg/gherkin_lexer_bg.c +0 -1655
  45. data/ext/gherkin_lexer_bm/extconf.rb +0 -6
  46. data/ext/gherkin_lexer_bm/gherkin_lexer_bm.c +0 -1516
  47. data/ext/gherkin_lexer_ca/extconf.rb +0 -6
  48. data/ext/gherkin_lexer_ca/gherkin_lexer_ca.c +0 -1581
  49. data/ext/gherkin_lexer_cs/extconf.rb +0 -6
  50. data/ext/gherkin_lexer_cs/gherkin_lexer_cs.c +0 -1515
  51. data/ext/gherkin_lexer_cy_gb/extconf.rb +0 -6
  52. data/ext/gherkin_lexer_cy_gb/gherkin_lexer_cy_gb.c +0 -1282
  53. data/ext/gherkin_lexer_da/extconf.rb +0 -6
  54. data/ext/gherkin_lexer_da/gherkin_lexer_da.c +0 -1298
  55. data/ext/gherkin_lexer_de/extconf.rb +0 -6
  56. data/ext/gherkin_lexer_de/gherkin_lexer_de.c +0 -1425
  57. data/ext/gherkin_lexer_el/extconf.rb +0 -6
  58. data/ext/gherkin_lexer_el/gherkin_lexer_el.c +0 -1919
  59. data/ext/gherkin_lexer_en/extconf.rb +0 -6
  60. data/ext/gherkin_lexer_en/gherkin_lexer_en.c +0 -1418
  61. data/ext/gherkin_lexer_en_au/extconf.rb +0 -6
  62. data/ext/gherkin_lexer_en_au/gherkin_lexer_en_au.c +0 -1765
  63. data/ext/gherkin_lexer_en_lol/extconf.rb +0 -6
  64. data/ext/gherkin_lexer_en_lol/gherkin_lexer_en_lol.c +0 -1177
  65. data/ext/gherkin_lexer_en_old/extconf.rb +0 -6
  66. data/ext/gherkin_lexer_en_old/gherkin_lexer_en_old.c +0 -1309
  67. data/ext/gherkin_lexer_en_pirate/extconf.rb +0 -6
  68. data/ext/gherkin_lexer_en_pirate/gherkin_lexer_en_pirate.c +0 -1471
  69. data/ext/gherkin_lexer_en_scouse/extconf.rb +0 -6
  70. data/ext/gherkin_lexer_en_scouse/gherkin_lexer_en_scouse.c +0 -1634
  71. data/ext/gherkin_lexer_en_tx/extconf.rb +0 -6
  72. data/ext/gherkin_lexer_en_tx/gherkin_lexer_en_tx.c +0 -1265
  73. data/ext/gherkin_lexer_eo/extconf.rb +0 -6
  74. data/ext/gherkin_lexer_eo/gherkin_lexer_eo.c +0 -1241
  75. data/ext/gherkin_lexer_es/extconf.rb +0 -6
  76. data/ext/gherkin_lexer_es/gherkin_lexer_es.c +0 -1399
  77. data/ext/gherkin_lexer_et/extconf.rb +0 -6
  78. data/ext/gherkin_lexer_et/gherkin_lexer_et.c +0 -1236
  79. data/ext/gherkin_lexer_fa/extconf.rb +0 -6
  80. data/ext/gherkin_lexer_fa/gherkin_lexer_fa.c +0 -1475
  81. data/ext/gherkin_lexer_fi/extconf.rb +0 -6
  82. data/ext/gherkin_lexer_fi/gherkin_lexer_fi.c +0 -1215
  83. data/ext/gherkin_lexer_fr/extconf.rb +0 -6
  84. data/ext/gherkin_lexer_fr/gherkin_lexer_fr.c +0 -1493
  85. data/ext/gherkin_lexer_gl/extconf.rb +0 -6
  86. data/ext/gherkin_lexer_gl/gherkin_lexer_gl.c +0 -1374
  87. data/ext/gherkin_lexer_he/extconf.rb +0 -6
  88. data/ext/gherkin_lexer_he/gherkin_lexer_he.c +0 -1374
  89. data/ext/gherkin_lexer_hi/extconf.rb +0 -6
  90. data/ext/gherkin_lexer_hi/gherkin_lexer_hi.c +0 -1848
  91. data/ext/gherkin_lexer_hr/extconf.rb +0 -6
  92. data/ext/gherkin_lexer_hr/gherkin_lexer_hr.c +0 -1323
  93. data/ext/gherkin_lexer_hu/extconf.rb +0 -6
  94. data/ext/gherkin_lexer_hu/gherkin_lexer_hu.c +0 -1376
  95. data/ext/gherkin_lexer_id/extconf.rb +0 -6
  96. data/ext/gherkin_lexer_id/gherkin_lexer_id.c +0 -1208
  97. data/ext/gherkin_lexer_is/extconf.rb +0 -6
  98. data/ext/gherkin_lexer_is/gherkin_lexer_is.c +0 -1376
  99. data/ext/gherkin_lexer_it/extconf.rb +0 -6
  100. data/ext/gherkin_lexer_it/gherkin_lexer_it.c +0 -1340
  101. data/ext/gherkin_lexer_ja/extconf.rb +0 -6
  102. data/ext/gherkin_lexer_ja/gherkin_lexer_ja.c +0 -1699
  103. data/ext/gherkin_lexer_kn/extconf.rb +0 -6
  104. data/ext/gherkin_lexer_kn/gherkin_lexer_kn.c +0 -1965
  105. data/ext/gherkin_lexer_ko/extconf.rb +0 -6
  106. data/ext/gherkin_lexer_ko/gherkin_lexer_ko.c +0 -1360
  107. data/ext/gherkin_lexer_lt/extconf.rb +0 -6
  108. data/ext/gherkin_lexer_lt/gherkin_lexer_lt.c +0 -1296
  109. data/ext/gherkin_lexer_lu/extconf.rb +0 -6
  110. data/ext/gherkin_lexer_lu/gherkin_lexer_lu.c +0 -1389
  111. data/ext/gherkin_lexer_lv/extconf.rb +0 -6
  112. data/ext/gherkin_lexer_lv/gherkin_lexer_lv.c +0 -1425
  113. data/ext/gherkin_lexer_nl/extconf.rb +0 -6
  114. data/ext/gherkin_lexer_nl/gherkin_lexer_nl.c +0 -1368
  115. data/ext/gherkin_lexer_no/extconf.rb +0 -6
  116. data/ext/gherkin_lexer_no/gherkin_lexer_no.c +0 -1311
  117. data/ext/gherkin_lexer_pa/extconf.rb +0 -6
  118. data/ext/gherkin_lexer_pa/gherkin_lexer_pa.c +0 -2160
  119. data/ext/gherkin_lexer_pl/extconf.rb +0 -6
  120. data/ext/gherkin_lexer_pl/gherkin_lexer_pl.c +0 -1738
  121. data/ext/gherkin_lexer_pt/extconf.rb +0 -6
  122. data/ext/gherkin_lexer_pt/gherkin_lexer_pt.c +0 -1711
  123. data/ext/gherkin_lexer_ro/extconf.rb +0 -6
  124. data/ext/gherkin_lexer_ro/gherkin_lexer_ro.c +0 -1427
  125. data/ext/gherkin_lexer_ru/extconf.rb +0 -6
  126. data/ext/gherkin_lexer_ru/gherkin_lexer_ru.c +0 -2071
  127. data/ext/gherkin_lexer_sk/extconf.rb +0 -6
  128. data/ext/gherkin_lexer_sk/gherkin_lexer_sk.c +0 -1739
  129. data/ext/gherkin_lexer_sr_cyrl/extconf.rb +0 -6
  130. data/ext/gherkin_lexer_sr_cyrl/gherkin_lexer_sr_cyrl.c +0 -2112
  131. data/ext/gherkin_lexer_sr_latn/extconf.rb +0 -6
  132. data/ext/gherkin_lexer_sr_latn/gherkin_lexer_sr_latn.c +0 -1567
  133. data/ext/gherkin_lexer_sv/extconf.rb +0 -6
  134. data/ext/gherkin_lexer_sv/gherkin_lexer_sv.c +0 -1324
  135. data/ext/gherkin_lexer_th/extconf.rb +0 -6
  136. data/ext/gherkin_lexer_th/gherkin_lexer_th.c +0 -2840
  137. data/ext/gherkin_lexer_tl/extconf.rb +0 -6
  138. data/ext/gherkin_lexer_tl/gherkin_lexer_tl.c +0 -2021
  139. data/ext/gherkin_lexer_tr/extconf.rb +0 -6
  140. data/ext/gherkin_lexer_tr/gherkin_lexer_tr.c +0 -1347
  141. data/ext/gherkin_lexer_tt/extconf.rb +0 -6
  142. data/ext/gherkin_lexer_tt/gherkin_lexer_tt.c +0 -1936
  143. data/ext/gherkin_lexer_uk/extconf.rb +0 -6
  144. data/ext/gherkin_lexer_uk/gherkin_lexer_uk.c +0 -1941
  145. data/ext/gherkin_lexer_uz/extconf.rb +0 -6
  146. data/ext/gherkin_lexer_uz/gherkin_lexer_uz.c +0 -1651
  147. data/ext/gherkin_lexer_vi/extconf.rb +0 -6
  148. data/ext/gherkin_lexer_vi/gherkin_lexer_vi.c +0 -1458
  149. data/ext/gherkin_lexer_zh_cn/extconf.rb +0 -6
  150. data/ext/gherkin_lexer_zh_cn/gherkin_lexer_zh_cn.c +0 -1314
  151. data/ext/gherkin_lexer_zh_tw/extconf.rb +0 -6
  152. data/ext/gherkin_lexer_zh_tw/gherkin_lexer_zh_tw.c +0 -1307
  153. data/features/.cucumber/stepdefs.json +0 -244
  154. data/features/escaped_pipes.feature +0 -8
  155. data/features/feature_parser.feature +0 -237
  156. data/features/json_formatter.feature +0 -498
  157. data/features/json_parser.feature +0 -331
  158. data/features/native_lexer.feature +0 -19
  159. data/features/parser_with_native_lexer.feature +0 -205
  160. data/features/pretty_formatter.feature +0 -17
  161. data/features/step_definitions/eyeball_steps.rb +0 -3
  162. data/features/step_definitions/gherkin_steps.rb +0 -29
  163. data/features/step_definitions/json_formatter_steps.rb +0 -30
  164. data/features/step_definitions/json_parser_steps.rb +0 -21
  165. data/features/step_definitions/pretty_formatter_steps.rb +0 -85
  166. data/features/steps_parser.feature +0 -46
  167. data/features/support/env.rb +0 -41
  168. data/install_mingw_os_x.sh +0 -5
  169. data/js/.npmignore +0 -1
  170. data/js/lib/gherkin/lexer/.npmignore +0 -0
  171. data/lib/gherkin.rb +0 -2
  172. data/lib/gherkin/README.md +0 -7
  173. data/lib/gherkin/c_lexer.rb +0 -17
  174. data/lib/gherkin/formatter/ansi_escapes.rb +0 -97
  175. data/lib/gherkin/formatter/argument.rb +0 -16
  176. data/lib/gherkin/formatter/escaping.rb +0 -15
  177. data/lib/gherkin/formatter/filter_formatter.rb +0 -150
  178. data/lib/gherkin/formatter/hashable.rb +0 -25
  179. data/lib/gherkin/formatter/json_formatter.rb +0 -133
  180. data/lib/gherkin/formatter/line_filter.rb +0 -26
  181. data/lib/gherkin/formatter/model.rb +0 -281
  182. data/lib/gherkin/formatter/pretty_formatter.rb +0 -245
  183. data/lib/gherkin/formatter/regexp_filter.rb +0 -21
  184. data/lib/gherkin/formatter/step_printer.rb +0 -21
  185. data/lib/gherkin/formatter/tag_count_formatter.rb +0 -47
  186. data/lib/gherkin/formatter/tag_filter.rb +0 -19
  187. data/lib/gherkin/i18n.json +0 -786
  188. data/lib/gherkin/i18n.rb +0 -176
  189. data/lib/gherkin/json_parser.rb +0 -177
  190. data/lib/gherkin/lexer/ar.rb +0 -1170
  191. data/lib/gherkin/lexer/bg.rb +0 -1382
  192. data/lib/gherkin/lexer/bm.rb +0 -1250
  193. data/lib/gherkin/lexer/ca.rb +0 -1310
  194. data/lib/gherkin/lexer/cs.rb +0 -1246
  195. data/lib/gherkin/lexer/cy_gb.rb +0 -1032
  196. data/lib/gherkin/lexer/da.rb +0 -1048
  197. data/lib/gherkin/lexer/de.rb +0 -1166
  198. data/lib/gherkin/lexer/el.rb +0 -1628
  199. data/lib/gherkin/lexer/en.rb +0 -1156
  200. data/lib/gherkin/lexer/en_au.rb +0 -1486
  201. data/lib/gherkin/lexer/en_lol.rb +0 -934
  202. data/lib/gherkin/lexer/en_old.rb +0 -1037
  203. data/lib/gherkin/lexer/en_pirate.rb +0 -1210
  204. data/lib/gherkin/lexer/en_scouse.rb +0 -1362
  205. data/lib/gherkin/lexer/en_tx.rb +0 -1016
  206. data/lib/gherkin/lexer/encoding.rb +0 -41
  207. data/lib/gherkin/lexer/eo.rb +0 -995
  208. data/lib/gherkin/lexer/es.rb +0 -1140
  209. data/lib/gherkin/lexer/et.rb +0 -990
  210. data/lib/gherkin/lexer/fa.rb +0 -1214
  211. data/lib/gherkin/lexer/fi.rb +0 -969
  212. data/lib/gherkin/lexer/fr.rb +0 -1228
  213. data/lib/gherkin/lexer/gl.rb +0 -1117
  214. data/lib/gherkin/lexer/he.rb +0 -1118
  215. data/lib/gherkin/lexer/hi.rb +0 -1559
  216. data/lib/gherkin/lexer/hr.rb +0 -1066
  217. data/lib/gherkin/lexer/hu.rb +0 -1118
  218. data/lib/gherkin/lexer/i18n_lexer.rb +0 -48
  219. data/lib/gherkin/lexer/id.rb +0 -963
  220. data/lib/gherkin/lexer/is.rb +0 -1120
  221. data/lib/gherkin/lexer/it.rb +0 -1086
  222. data/lib/gherkin/lexer/ja.rb +0 -1418
  223. data/lib/gherkin/lexer/kn.rb +0 -1672
  224. data/lib/gherkin/lexer/ko.rb +0 -1102
  225. data/lib/gherkin/lexer/lt.rb +0 -1045
  226. data/lib/gherkin/lexer/lu.rb +0 -1132
  227. data/lib/gherkin/lexer/lv.rb +0 -1166
  228. data/lib/gherkin/lexer/nl.rb +0 -1115
  229. data/lib/gherkin/lexer/no.rb +0 -1060
  230. data/lib/gherkin/lexer/pa.rb +0 -1852
  231. data/lib/gherkin/lexer/pl.rb +0 -1457
  232. data/lib/gherkin/lexer/pt.rb +0 -1430
  233. data/lib/gherkin/lexer/ro.rb +0 -1164
  234. data/lib/gherkin/lexer/ru.rb +0 -1766
  235. data/lib/gherkin/lexer/sk.rb +0 -1452
  236. data/lib/gherkin/lexer/sr_cyrl.rb +0 -1803
  237. data/lib/gherkin/lexer/sr_latn.rb +0 -1294
  238. data/lib/gherkin/lexer/sv.rb +0 -1070
  239. data/lib/gherkin/lexer/th.rb +0 -2492
  240. data/lib/gherkin/lexer/tl.rb +0 -1726
  241. data/lib/gherkin/lexer/tr.rb +0 -1092
  242. data/lib/gherkin/lexer/tt.rb +0 -1643
  243. data/lib/gherkin/lexer/uk.rb +0 -1646
  244. data/lib/gherkin/lexer/uz.rb +0 -1376
  245. data/lib/gherkin/lexer/vi.rb +0 -1198
  246. data/lib/gherkin/lexer/zh_cn.rb +0 -1058
  247. data/lib/gherkin/lexer/zh_tw.rb +0 -1052
  248. data/lib/gherkin/listener/event.rb +0 -45
  249. data/lib/gherkin/listener/formatter_listener.rb +0 -150
  250. data/lib/gherkin/native.rb +0 -7
  251. data/lib/gherkin/native/java.rb +0 -72
  252. data/lib/gherkin/native/null.rb +0 -5
  253. data/lib/gherkin/native/therubyracer.rb +0 -41
  254. data/lib/gherkin/parser/meta.txt +0 -5
  255. data/lib/gherkin/parser/parser.rb +0 -166
  256. data/lib/gherkin/parser/root.txt +0 -11
  257. data/lib/gherkin/parser/steps.txt +0 -4
  258. data/lib/gherkin/platform.rb +0 -13
  259. data/lib/gherkin/rubify.rb +0 -31
  260. data/lib/gherkin/tag_expression.rb +0 -63
  261. data/ragel/lexer.c.rl.erb +0 -454
  262. data/ragel/lexer.java.rl.erb +0 -219
  263. data/ragel/lexer.js.rl.erb +0 -322
  264. data/ragel/lexer.rb.rl.erb +0 -179
  265. data/ragel/lexer_common.rl.erb +0 -50
  266. data/spec/gherkin/c_lexer_spec.rb +0 -22
  267. data/spec/gherkin/fixtures/1.feature +0 -8
  268. data/spec/gherkin/fixtures/comments_in_table.feature +0 -9
  269. data/spec/gherkin/fixtures/complex.feature +0 -45
  270. data/spec/gherkin/fixtures/complex.json +0 -139
  271. data/spec/gherkin/fixtures/complex_for_filtering.feature +0 -60
  272. data/spec/gherkin/fixtures/complex_with_tags.feature +0 -61
  273. data/spec/gherkin/fixtures/dos_line_endings.feature +0 -45
  274. data/spec/gherkin/fixtures/examples_with_only_header.feature +0 -14
  275. data/spec/gherkin/fixtures/hantu_pisang.feature +0 -35
  276. data/spec/gherkin/fixtures/i18n_fr.feature +0 -14
  277. data/spec/gherkin/fixtures/i18n_fr2.feature +0 -8
  278. data/spec/gherkin/fixtures/i18n_no.feature +0 -7
  279. data/spec/gherkin/fixtures/i18n_pt1.feature +0 -44
  280. data/spec/gherkin/fixtures/i18n_pt2.feature +0 -4
  281. data/spec/gherkin/fixtures/i18n_pt3.feature +0 -4
  282. data/spec/gherkin/fixtures/i18n_pt4.feature +0 -4
  283. data/spec/gherkin/fixtures/i18n_zh-CN.feature +0 -9
  284. data/spec/gherkin/fixtures/iso-8859-1.feature +0 -6
  285. data/spec/gherkin/fixtures/issue_145.feature +0 -22
  286. data/spec/gherkin/fixtures/scenario_outline_with_tags.feature +0 -13
  287. data/spec/gherkin/fixtures/scenario_without_steps.feature +0 -5
  288. data/spec/gherkin/fixtures/simple_with_comments.feature +0 -7
  289. data/spec/gherkin/fixtures/simple_with_tags.feature +0 -11
  290. data/spec/gherkin/fixtures/with_bom.feature +0 -3
  291. data/spec/gherkin/fixtures/with_bom_and_language_spec.feature +0 -4
  292. data/spec/gherkin/formatter/ansi_escapes_spec.rb +0 -32
  293. data/spec/gherkin/formatter/filter_formatter_spec.rb +0 -204
  294. data/spec/gherkin/formatter/json_formatter_spec.rb +0 -179
  295. data/spec/gherkin/formatter/model_spec.rb +0 -28
  296. data/spec/gherkin/formatter/pretty_formatter_spec.rb +0 -184
  297. data/spec/gherkin/formatter/spaces.feature +0 -9
  298. data/spec/gherkin/formatter/step_printer_spec.rb +0 -55
  299. data/spec/gherkin/formatter/tabs.feature +0 -9
  300. data/spec/gherkin/formatter/tag_count_formatter_spec.rb +0 -30
  301. data/spec/gherkin/i18n_spec.rb +0 -256
  302. data/spec/gherkin/java_lexer_spec.rb +0 -20
  303. data/spec/gherkin/json_parser_spec.rb +0 -165
  304. data/spec/gherkin/lexer/i18n_lexer_spec.rb +0 -65
  305. data/spec/gherkin/native_lexer_spec.rb +0 -29
  306. data/spec/gherkin/parser/parser_spec.rb +0 -16
  307. data/spec/gherkin/rubify_spec.rb +0 -23
  308. data/spec/gherkin/sexp_recorder.rb +0 -59
  309. data/spec/gherkin/shared/doc_string_group.rb +0 -161
  310. data/spec/gherkin/shared/encoding_group.rb +0 -48
  311. data/spec/gherkin/shared/lexer_group.rb +0 -589
  312. data/spec/gherkin/shared/row_group.rb +0 -123
  313. data/spec/gherkin/shared/tags_group.rb +0 -52
  314. data/spec/gherkin/tag_expression_spec.rb +0 -146
  315. data/spec/spec_helper.rb +0 -94
  316. data/tasks/apidoc.rake +0 -32
  317. data/tasks/bench.rake +0 -184
  318. data/tasks/bench/feature_builder.rb +0 -49
  319. data/tasks/bench/null_listener.rb +0 -4
  320. data/tasks/compile.rake +0 -83
  321. data/tasks/cucumber.rake +0 -23
  322. data/tasks/gems.rake +0 -46
  323. data/tasks/ikvm.rake +0 -126
  324. data/tasks/ragel_task.rb +0 -124
  325. data/tasks/release.rake +0 -34
  326. data/tasks/rspec.rake +0 -6
  327. data/tasks/yard/default/layout/html/bubble_32x32.png +0 -0
  328. data/tasks/yard/default/layout/html/bubble_48x48.png +0 -0
  329. data/tasks/yard/default/layout/html/footer.erb +0 -5
  330. data/tasks/yard/default/layout/html/index.erb +0 -1
  331. data/tasks/yard/default/layout/html/layout.erb +0 -25
  332. data/tasks/yard/default/layout/html/logo.erb +0 -1
  333. data/tasks/yard/default/layout/html/setup.rb +0 -4
@@ -1,1102 +0,0 @@
1
-
2
- # line 1 "ragel/i18n/ko.rb.rl"
3
- require 'gherkin/native'
4
-
5
- module Gherkin
6
- module Lexer
7
- class Ko #:nodoc:
8
- native_impl('gherkin')
9
-
10
-
11
- # line 125 "ragel/i18n/ko.rb.rl"
12
-
13
-
14
- def initialize(listener)
15
- @listener = listener
16
-
17
- # Initialize ivars to avoid warnings
18
- @keyword = nil
19
-
20
- # line 21 "lib/gherkin/lexer/ko.rb"
21
- class << self
22
- attr_accessor :_lexer_actions
23
- private :_lexer_actions, :_lexer_actions=
24
- end
25
- self._lexer_actions = [
26
- 0, 1, 0, 1, 1, 1, 2, 1,
27
- 3, 1, 4, 1, 5, 1, 6, 1,
28
- 7, 1, 8, 1, 9, 1, 10, 1,
29
- 11, 1, 12, 1, 13, 1, 16, 1,
30
- 17, 1, 18, 1, 19, 1, 20, 1,
31
- 21, 1, 22, 1, 23, 2, 2, 18,
32
- 2, 3, 4, 2, 13, 0, 2, 14,
33
- 15, 2, 17, 0, 2, 17, 1, 2,
34
- 17, 16, 2, 17, 19, 2, 18, 6,
35
- 2, 18, 7, 2, 18, 8, 2, 18,
36
- 9, 2, 18, 10, 2, 18, 16, 2,
37
- 20, 21, 2, 22, 0, 2, 22, 1,
38
- 2, 22, 16, 2, 22, 19, 3, 4,
39
- 14, 15, 3, 5, 14, 15, 3, 11,
40
- 14, 15, 3, 12, 14, 15, 3, 13,
41
- 14, 15, 3, 14, 15, 18, 3, 17,
42
- 0, 11, 3, 17, 14, 15, 4, 2,
43
- 14, 15, 18, 4, 3, 4, 14, 15,
44
- 4, 17, 0, 14, 15, 5, 17, 0,
45
- 11, 14, 15
46
- ]
47
-
48
- class << self
49
- attr_accessor :_lexer_key_offsets
50
- private :_lexer_key_offsets, :_lexer_key_offsets=
51
- end
52
- self._lexer_key_offsets = [
53
- 0, 0, 15, 17, 18, 19, 21, 22,
54
- 23, 24, 25, 27, 29, 43, 47, 48,
55
- 49, 50, 52, 53, 54, 55, 56, 57,
56
- 58, 59, 60, 61, 62, 63, 64, 65,
57
- 77, 80, 82, 84, 87, 89, 91, 93,
58
- 95, 109, 112, 113, 114, 115, 116, 117,
59
- 118, 119, 120, 121, 122, 124, 125, 126,
60
- 127, 128, 129, 130, 131, 132, 133, 145,
61
- 148, 150, 152, 155, 157, 159, 161, 163,
62
- 165, 167, 169, 171, 173, 175, 177, 179,
63
- 181, 185, 187, 189, 191, 194, 196, 198,
64
- 200, 202, 204, 206, 209, 211, 213, 215,
65
- 217, 219, 221, 223, 225, 227, 229, 231,
66
- 233, 235, 237, 239, 241, 243, 245, 247,
67
- 249, 251, 253, 255, 257, 259, 261, 263,
68
- 265, 267, 269, 271, 273, 275, 277, 279,
69
- 281, 282, 283, 295, 298, 300, 302, 305,
70
- 307, 309, 311, 313, 315, 317, 319, 321,
71
- 323, 325, 327, 329, 331, 336, 338, 340,
72
- 342, 345, 347, 349, 351, 353, 355, 357,
73
- 359, 361, 363, 365, 368, 370, 372, 374,
74
- 376, 378, 380, 382, 384, 386, 388, 391,
75
- 393, 395, 397, 399, 401, 403, 405, 407,
76
- 409, 411, 413, 415, 417, 419, 421, 423,
77
- 425, 427, 429, 431, 433, 435, 437, 439,
78
- 441, 443, 445, 447, 449, 451, 453, 455,
79
- 456, 457, 458, 459, 466, 468, 470, 472,
80
- 474, 476, 478, 479, 480, 481, 482, 483,
81
- 484, 485, 486, 487, 488, 489, 490, 491,
82
- 493, 495, 500, 505, 510, 515, 519, 523,
83
- 525, 526, 527, 528, 529, 530, 531, 532,
84
- 533, 534, 535, 536, 537, 538, 539, 540,
85
- 541, 546, 553, 558, 562, 568, 571, 573,
86
- 579, 593, 595, 597, 599, 601, 603, 605,
87
- 607, 609, 611, 615, 617, 619, 621, 624,
88
- 626, 628, 630, 632, 634, 636, 639, 641,
89
- 643, 645, 647, 649, 651, 653, 655, 657,
90
- 659, 662, 664, 666, 668, 670, 672, 674,
91
- 676, 678, 680, 682, 684, 686, 688, 690,
92
- 692, 694, 696, 698, 700, 702, 704, 706,
93
- 708, 710, 712, 714, 716, 718, 720, 722,
94
- 724, 726, 727, 728, 729, 730, 731, 732,
95
- 733, 734, 735, 736, 737, 747, 749, 751,
96
- 753, 755, 757, 759, 761, 763, 765, 767,
97
- 769, 772, 774, 776, 778, 780, 782, 784,
98
- 786, 788, 790, 792, 795, 797, 799, 801,
99
- 803, 805, 807, 809, 811, 813, 815, 817,
100
- 819, 821, 823, 825, 827, 829, 831, 833,
101
- 835, 837, 838, 839
102
- ]
103
-
104
- class << self
105
- attr_accessor :_lexer_trans_keys
106
- private :_lexer_trans_keys, :_lexer_trans_keys=
107
- end
108
- self._lexer_trans_keys = [
109
- -22, -21, -20, -19, -17, 10, 32, 34,
110
- 35, 37, 42, 64, 124, 9, 13, -73,
111
- -72, -72, -21, -97, -90, -84, -21, -87,
112
- -76, 10, 13, 10, 13, -22, -21, -20,
113
- -19, 10, 32, 34, 35, 37, 42, 64,
114
- 124, 9, 13, -117, -89, -88, -80, -88,
115
- -116, -20, -107, -99, -67, -68, -68, -20,
116
- -96, -128, -80, -22, -78, -67, 58, 10,
117
- 10, -22, -21, -20, -19, 10, 32, 35,
118
- 37, 42, 64, 9, 13, -73, -72, 10,
119
- -72, 10, -21, 10, -97, -90, 10, -84,
120
- 10, -21, 10, -87, 10, -76, 10, -22,
121
- -21, -20, -19, 10, 32, 34, 35, 37,
122
- 42, 64, 124, 9, 13, -117, -104, -95,
123
- -100, -21, -126, -104, -21, -90, -84, -20,
124
- -104, -92, 32, 58, -22, -80, -100, -20,
125
- -102, -108, 58, 10, 10, -22, -21, -20,
126
- -19, 10, 32, 35, 37, 42, 64, 9,
127
- 13, -73, -72, 10, -72, 10, -21, 10,
128
- -97, -90, 10, -84, 10, -21, 10, -87,
129
- 10, -76, 10, -84, 10, -22, 10, -77,
130
- 10, -96, 10, -80, 10, -21, 10, -118,
131
- 10, -91, 10, 10, 58, -117, -89, -88,
132
- 10, -88, 10, -116, 10, -20, 10, -107,
133
- -99, 10, -67, 10, -68, 10, -68, 10,
134
- -20, 10, -96, 10, -128, 10, -117, -95,
135
- 10, -100, 10, -21, 10, -126, 10, -104,
136
- 10, -21, 10, -90, 10, -84, 10, -20,
137
- 10, -104, 10, -92, 10, -80, 10, -22,
138
- 10, -79, 10, -107, 10, -104, 10, -20,
139
- 10, -89, 10, -128, 10, -21, 10, -89,
140
- 10, -116, 10, 10, 95, 10, 70, 10,
141
- 69, 10, 65, 10, 84, 10, 85, 10,
142
- 82, 10, 69, 10, 95, 10, 69, 10,
143
- 78, 10, 68, 10, 95, 10, 37, 10,
144
- 32, 10, 10, -22, -21, -20, -19, 10,
145
- 32, 35, 37, 42, 64, 9, 13, -73,
146
- -72, 10, -72, 10, -21, 10, -97, -90,
147
- 10, -84, 10, -21, 10, -87, 10, -76,
148
- 10, -84, 10, -22, 10, -77, 10, -96,
149
- 10, -80, 10, -21, 10, -118, 10, -91,
150
- 10, 10, 58, -117, -89, -88, -80, 10,
151
- -88, 10, -116, 10, -20, 10, -107, -99,
152
- 10, -67, 10, -68, 10, -68, 10, -20,
153
- 10, -96, 10, -128, 10, -80, 10, -22,
154
- 10, -78, 10, -67, 10, -117, -95, 10,
155
- -100, 10, -21, 10, -126, 10, -104, 10,
156
- -21, 10, -90, 10, -84, 10, -20, 10,
157
- -104, 10, -92, 10, 10, 32, 58, -22,
158
- 10, -80, 10, -100, 10, -20, 10, -102,
159
- 10, -108, 10, -80, 10, -22, 10, -79,
160
- 10, -107, 10, -104, 10, -20, 10, -89,
161
- 10, -128, 10, -21, 10, -89, 10, -116,
162
- 10, 10, 95, 10, 70, 10, 69, 10,
163
- 65, 10, 84, 10, 85, 10, 82, 10,
164
- 69, 10, 95, 10, 69, 10, 78, 10,
165
- 68, 10, 95, 10, 37, 10, 32, -120,
166
- 58, 10, 10, -22, 10, 32, 35, 124,
167
- 9, 13, -72, 10, -80, 10, -21, 10,
168
- -118, 10, -91, 10, 10, 58, -80, -22,
169
- -79, -107, -104, -20, -89, -128, -21, -89,
170
- -116, 34, 34, 10, 13, 10, 13, 10,
171
- 32, 34, 9, 13, 10, 32, 34, 9,
172
- 13, 10, 32, 34, 9, 13, 10, 32,
173
- 34, 9, 13, 10, 32, 9, 13, 10,
174
- 32, 9, 13, 10, 13, 10, 95, 70,
175
- 69, 65, 84, 85, 82, 69, 95, 69,
176
- 78, 68, 95, 37, 32, 13, 32, 64,
177
- 9, 10, 9, 10, 13, 32, 64, 11,
178
- 12, 10, 32, 64, 9, 13, 32, 124,
179
- 9, 13, 10, 32, 92, 124, 9, 13,
180
- 10, 92, 124, 10, 92, 10, 32, 92,
181
- 124, 9, 13, -22, -21, -20, -19, 10,
182
- 32, 34, 35, 37, 42, 64, 124, 9,
183
- 13, -84, 10, -22, 10, -77, 10, -96,
184
- 10, -80, 10, -21, 10, -118, 10, -91,
185
- 10, 10, 58, -117, -89, -88, 10, -88,
186
- 10, -116, 10, -20, 10, -107, -99, 10,
187
- -67, 10, -68, 10, -68, 10, -20, 10,
188
- -96, 10, -128, 10, -117, -95, 10, -100,
189
- 10, -21, 10, -126, 10, -104, 10, -21,
190
- 10, -90, 10, -84, 10, -20, 10, -104,
191
- 10, -92, 10, 10, 32, 58, -22, 10,
192
- -80, 10, -100, 10, -20, 10, -102, 10,
193
- -108, 10, -80, 10, -22, 10, -79, 10,
194
- -107, 10, -104, 10, -20, 10, -89, 10,
195
- -128, 10, -21, 10, -89, 10, -116, 10,
196
- 10, 95, 10, 70, 10, 69, 10, 65,
197
- 10, 84, 10, 85, 10, 82, 10, 69,
198
- 10, 95, 10, 69, 10, 78, 10, 68,
199
- 10, 95, 10, 37, 10, 32, -84, -22,
200
- -77, -96, -80, -21, -118, -91, 58, 10,
201
- 10, -22, -21, -20, 10, 32, 35, 37,
202
- 64, 9, 13, -72, 10, -80, 10, -21,
203
- 10, -118, 10, -91, 10, 10, 58, -80,
204
- 10, -80, 10, -22, 10, -78, 10, -67,
205
- 10, -117, -104, 10, -100, 10, -21, 10,
206
- -126, 10, -104, 10, -21, 10, -90, 10,
207
- -84, 10, -20, 10, -104, 10, -92, 10,
208
- 10, 32, 58, -22, 10, -80, 10, -100,
209
- 10, -20, 10, -102, 10, -108, 10, -120,
210
- 10, 10, 95, 10, 70, 10, 69, 10,
211
- 65, 10, 84, 10, 85, 10, 82, 10,
212
- 69, 10, 95, 10, 69, 10, 78, 10,
213
- 68, 10, 95, 10, 37, -69, -65, 0
214
- ]
215
-
216
- class << self
217
- attr_accessor :_lexer_single_lengths
218
- private :_lexer_single_lengths, :_lexer_single_lengths=
219
- end
220
- self._lexer_single_lengths = [
221
- 0, 13, 2, 1, 1, 2, 1, 1,
222
- 1, 1, 2, 2, 12, 4, 1, 1,
223
- 1, 2, 1, 1, 1, 1, 1, 1,
224
- 1, 1, 1, 1, 1, 1, 1, 10,
225
- 3, 2, 2, 3, 2, 2, 2, 2,
226
- 12, 3, 1, 1, 1, 1, 1, 1,
227
- 1, 1, 1, 1, 2, 1, 1, 1,
228
- 1, 1, 1, 1, 1, 1, 10, 3,
229
- 2, 2, 3, 2, 2, 2, 2, 2,
230
- 2, 2, 2, 2, 2, 2, 2, 2,
231
- 4, 2, 2, 2, 3, 2, 2, 2,
232
- 2, 2, 2, 3, 2, 2, 2, 2,
233
- 2, 2, 2, 2, 2, 2, 2, 2,
234
- 2, 2, 2, 2, 2, 2, 2, 2,
235
- 2, 2, 2, 2, 2, 2, 2, 2,
236
- 2, 2, 2, 2, 2, 2, 2, 2,
237
- 1, 1, 10, 3, 2, 2, 3, 2,
238
- 2, 2, 2, 2, 2, 2, 2, 2,
239
- 2, 2, 2, 2, 5, 2, 2, 2,
240
- 3, 2, 2, 2, 2, 2, 2, 2,
241
- 2, 2, 2, 3, 2, 2, 2, 2,
242
- 2, 2, 2, 2, 2, 2, 3, 2,
243
- 2, 2, 2, 2, 2, 2, 2, 2,
244
- 2, 2, 2, 2, 2, 2, 2, 2,
245
- 2, 2, 2, 2, 2, 2, 2, 2,
246
- 2, 2, 2, 2, 2, 2, 2, 1,
247
- 1, 1, 1, 5, 2, 2, 2, 2,
248
- 2, 2, 1, 1, 1, 1, 1, 1,
249
- 1, 1, 1, 1, 1, 1, 1, 2,
250
- 2, 3, 3, 3, 3, 2, 2, 2,
251
- 1, 1, 1, 1, 1, 1, 1, 1,
252
- 1, 1, 1, 1, 1, 1, 1, 1,
253
- 3, 5, 3, 2, 4, 3, 2, 4,
254
- 12, 2, 2, 2, 2, 2, 2, 2,
255
- 2, 2, 4, 2, 2, 2, 3, 2,
256
- 2, 2, 2, 2, 2, 3, 2, 2,
257
- 2, 2, 2, 2, 2, 2, 2, 2,
258
- 3, 2, 2, 2, 2, 2, 2, 2,
259
- 2, 2, 2, 2, 2, 2, 2, 2,
260
- 2, 2, 2, 2, 2, 2, 2, 2,
261
- 2, 2, 2, 2, 2, 2, 2, 2,
262
- 2, 1, 1, 1, 1, 1, 1, 1,
263
- 1, 1, 1, 1, 8, 2, 2, 2,
264
- 2, 2, 2, 2, 2, 2, 2, 2,
265
- 3, 2, 2, 2, 2, 2, 2, 2,
266
- 2, 2, 2, 3, 2, 2, 2, 2,
267
- 2, 2, 2, 2, 2, 2, 2, 2,
268
- 2, 2, 2, 2, 2, 2, 2, 2,
269
- 2, 1, 1, 0
270
- ]
271
-
272
- class << self
273
- attr_accessor :_lexer_range_lengths
274
- private :_lexer_range_lengths, :_lexer_range_lengths=
275
- end
276
- self._lexer_range_lengths = [
277
- 0, 1, 0, 0, 0, 0, 0, 0,
278
- 0, 0, 0, 0, 1, 0, 0, 0,
279
- 0, 0, 0, 0, 0, 0, 0, 0,
280
- 0, 0, 0, 0, 0, 0, 0, 1,
281
- 0, 0, 0, 0, 0, 0, 0, 0,
282
- 1, 0, 0, 0, 0, 0, 0, 0,
283
- 0, 0, 0, 0, 0, 0, 0, 0,
284
- 0, 0, 0, 0, 0, 0, 1, 0,
285
- 0, 0, 0, 0, 0, 0, 0, 0,
286
- 0, 0, 0, 0, 0, 0, 0, 0,
287
- 0, 0, 0, 0, 0, 0, 0, 0,
288
- 0, 0, 0, 0, 0, 0, 0, 0,
289
- 0, 0, 0, 0, 0, 0, 0, 0,
290
- 0, 0, 0, 0, 0, 0, 0, 0,
291
- 0, 0, 0, 0, 0, 0, 0, 0,
292
- 0, 0, 0, 0, 0, 0, 0, 0,
293
- 0, 0, 1, 0, 0, 0, 0, 0,
294
- 0, 0, 0, 0, 0, 0, 0, 0,
295
- 0, 0, 0, 0, 0, 0, 0, 0,
296
- 0, 0, 0, 0, 0, 0, 0, 0,
297
- 0, 0, 0, 0, 0, 0, 0, 0,
298
- 0, 0, 0, 0, 0, 0, 0, 0,
299
- 0, 0, 0, 0, 0, 0, 0, 0,
300
- 0, 0, 0, 0, 0, 0, 0, 0,
301
- 0, 0, 0, 0, 0, 0, 0, 0,
302
- 0, 0, 0, 0, 0, 0, 0, 0,
303
- 0, 0, 0, 1, 0, 0, 0, 0,
304
- 0, 0, 0, 0, 0, 0, 0, 0,
305
- 0, 0, 0, 0, 0, 0, 0, 0,
306
- 0, 1, 1, 1, 1, 1, 1, 0,
307
- 0, 0, 0, 0, 0, 0, 0, 0,
308
- 0, 0, 0, 0, 0, 0, 0, 0,
309
- 1, 1, 1, 1, 1, 0, 0, 1,
310
- 1, 0, 0, 0, 0, 0, 0, 0,
311
- 0, 0, 0, 0, 0, 0, 0, 0,
312
- 0, 0, 0, 0, 0, 0, 0, 0,
313
- 0, 0, 0, 0, 0, 0, 0, 0,
314
- 0, 0, 0, 0, 0, 0, 0, 0,
315
- 0, 0, 0, 0, 0, 0, 0, 0,
316
- 0, 0, 0, 0, 0, 0, 0, 0,
317
- 0, 0, 0, 0, 0, 0, 0, 0,
318
- 0, 0, 0, 0, 0, 0, 0, 0,
319
- 0, 0, 0, 0, 1, 0, 0, 0,
320
- 0, 0, 0, 0, 0, 0, 0, 0,
321
- 0, 0, 0, 0, 0, 0, 0, 0,
322
- 0, 0, 0, 0, 0, 0, 0, 0,
323
- 0, 0, 0, 0, 0, 0, 0, 0,
324
- 0, 0, 0, 0, 0, 0, 0, 0,
325
- 0, 0, 0, 0
326
- ]
327
-
328
- class << self
329
- attr_accessor :_lexer_index_offsets
330
- private :_lexer_index_offsets, :_lexer_index_offsets=
331
- end
332
- self._lexer_index_offsets = [
333
- 0, 0, 15, 18, 20, 22, 25, 27,
334
- 29, 31, 33, 36, 39, 53, 58, 60,
335
- 62, 64, 67, 69, 71, 73, 75, 77,
336
- 79, 81, 83, 85, 87, 89, 91, 93,
337
- 105, 109, 112, 115, 119, 122, 125, 128,
338
- 131, 145, 149, 151, 153, 155, 157, 159,
339
- 161, 163, 165, 167, 169, 172, 174, 176,
340
- 178, 180, 182, 184, 186, 188, 190, 202,
341
- 206, 209, 212, 216, 219, 222, 225, 228,
342
- 231, 234, 237, 240, 243, 246, 249, 252,
343
- 255, 260, 263, 266, 269, 273, 276, 279,
344
- 282, 285, 288, 291, 295, 298, 301, 304,
345
- 307, 310, 313, 316, 319, 322, 325, 328,
346
- 331, 334, 337, 340, 343, 346, 349, 352,
347
- 355, 358, 361, 364, 367, 370, 373, 376,
348
- 379, 382, 385, 388, 391, 394, 397, 400,
349
- 403, 405, 407, 419, 423, 426, 429, 433,
350
- 436, 439, 442, 445, 448, 451, 454, 457,
351
- 460, 463, 466, 469, 472, 478, 481, 484,
352
- 487, 491, 494, 497, 500, 503, 506, 509,
353
- 512, 515, 518, 521, 525, 528, 531, 534,
354
- 537, 540, 543, 546, 549, 552, 555, 559,
355
- 562, 565, 568, 571, 574, 577, 580, 583,
356
- 586, 589, 592, 595, 598, 601, 604, 607,
357
- 610, 613, 616, 619, 622, 625, 628, 631,
358
- 634, 637, 640, 643, 646, 649, 652, 655,
359
- 657, 659, 661, 663, 670, 673, 676, 679,
360
- 682, 685, 688, 690, 692, 694, 696, 698,
361
- 700, 702, 704, 706, 708, 710, 712, 714,
362
- 717, 720, 725, 730, 735, 740, 744, 748,
363
- 751, 753, 755, 757, 759, 761, 763, 765,
364
- 767, 769, 771, 773, 775, 777, 779, 781,
365
- 783, 788, 795, 800, 804, 810, 814, 817,
366
- 823, 837, 840, 843, 846, 849, 852, 855,
367
- 858, 861, 864, 869, 872, 875, 878, 882,
368
- 885, 888, 891, 894, 897, 900, 904, 907,
369
- 910, 913, 916, 919, 922, 925, 928, 931,
370
- 934, 938, 941, 944, 947, 950, 953, 956,
371
- 959, 962, 965, 968, 971, 974, 977, 980,
372
- 983, 986, 989, 992, 995, 998, 1001, 1004,
373
- 1007, 1010, 1013, 1016, 1019, 1022, 1025, 1028,
374
- 1031, 1034, 1036, 1038, 1040, 1042, 1044, 1046,
375
- 1048, 1050, 1052, 1054, 1056, 1066, 1069, 1072,
376
- 1075, 1078, 1081, 1084, 1087, 1090, 1093, 1096,
377
- 1099, 1103, 1106, 1109, 1112, 1115, 1118, 1121,
378
- 1124, 1127, 1130, 1133, 1137, 1140, 1143, 1146,
379
- 1149, 1152, 1155, 1158, 1161, 1164, 1167, 1170,
380
- 1173, 1176, 1179, 1182, 1185, 1188, 1191, 1194,
381
- 1197, 1200, 1202, 1204
382
- ]
383
-
384
- class << self
385
- attr_accessor :_lexer_indicies
386
- private :_lexer_indicies, :_lexer_indicies=
387
- end
388
- self._lexer_indicies = [
389
- 1, 2, 3, 4, 5, 7, 6, 8,
390
- 9, 10, 11, 12, 13, 6, 0, 14,
391
- 15, 0, 16, 0, 17, 0, 18, 19,
392
- 0, 20, 0, 21, 0, 22, 0, 23,
393
- 0, 25, 26, 24, 28, 29, 27, 1,
394
- 2, 3, 4, 7, 6, 8, 9, 10,
395
- 11, 12, 13, 6, 0, 30, 31, 32,
396
- 33, 0, 23, 0, 34, 0, 35, 0,
397
- 36, 37, 0, 23, 0, 23, 0, 38,
398
- 0, 39, 0, 40, 0, 23, 0, 41,
399
- 0, 42, 0, 43, 0, 44, 0, 45,
400
- 0, 47, 46, 49, 48, 50, 51, 52,
401
- 53, 49, 54, 55, 56, 57, 55, 54,
402
- 48, 58, 59, 49, 48, 60, 49, 48,
403
- 61, 49, 48, 62, 63, 49, 48, 64,
404
- 49, 48, 65, 49, 48, 66, 49, 48,
405
- 67, 49, 48, 68, 69, 70, 71, 73,
406
- 72, 74, 75, 76, 77, 78, 79, 72,
407
- 0, 80, 81, 82, 0, 83, 0, 84,
408
- 0, 85, 0, 86, 0, 87, 0, 88,
409
- 0, 89, 0, 90, 0, 91, 0, 92,
410
- 0, 93, 94, 0, 95, 0, 96, 0,
411
- 97, 0, 98, 0, 99, 0, 100, 0,
412
- 101, 0, 103, 102, 105, 104, 106, 107,
413
- 108, 109, 105, 110, 111, 112, 113, 111,
414
- 110, 104, 114, 115, 105, 104, 116, 105,
415
- 104, 117, 105, 104, 118, 119, 105, 104,
416
- 120, 105, 104, 121, 105, 104, 122, 105,
417
- 104, 123, 105, 104, 124, 105, 104, 125,
418
- 105, 104, 126, 105, 104, 123, 105, 104,
419
- 127, 105, 104, 128, 105, 104, 129, 105,
420
- 104, 130, 105, 104, 105, 123, 104, 131,
421
- 132, 133, 105, 104, 123, 105, 104, 134,
422
- 105, 104, 135, 105, 104, 136, 137, 105,
423
- 104, 123, 105, 104, 123, 105, 104, 138,
424
- 105, 104, 139, 105, 104, 140, 105, 104,
425
- 123, 105, 104, 141, 142, 105, 104, 143,
426
- 105, 104, 144, 105, 104, 145, 105, 104,
427
- 146, 105, 104, 147, 105, 104, 148, 105,
428
- 104, 149, 105, 104, 150, 105, 104, 151,
429
- 105, 104, 130, 105, 104, 152, 105, 104,
430
- 153, 105, 104, 122, 105, 104, 154, 105,
431
- 104, 155, 105, 104, 156, 105, 104, 157,
432
- 105, 104, 158, 105, 104, 159, 105, 104,
433
- 160, 105, 104, 123, 105, 104, 105, 161,
434
- 104, 105, 162, 104, 105, 163, 104, 105,
435
- 164, 104, 105, 165, 104, 105, 166, 104,
436
- 105, 167, 104, 105, 168, 104, 105, 169,
437
- 104, 105, 170, 104, 105, 171, 104, 105,
438
- 172, 104, 105, 173, 104, 105, 174, 104,
439
- 105, 123, 104, 176, 175, 178, 177, 179,
440
- 180, 181, 182, 178, 183, 184, 185, 186,
441
- 184, 183, 177, 187, 188, 178, 177, 189,
442
- 178, 177, 190, 178, 177, 191, 192, 178,
443
- 177, 193, 178, 177, 194, 178, 177, 195,
444
- 178, 177, 196, 178, 177, 197, 178, 177,
445
- 198, 178, 177, 199, 178, 177, 196, 178,
446
- 177, 200, 178, 177, 201, 178, 177, 202,
447
- 178, 177, 203, 178, 177, 178, 196, 177,
448
- 204, 205, 206, 207, 178, 177, 196, 178,
449
- 177, 208, 178, 177, 209, 178, 177, 210,
450
- 211, 178, 177, 196, 178, 177, 196, 178,
451
- 177, 212, 178, 177, 213, 178, 177, 214,
452
- 178, 177, 196, 178, 177, 215, 178, 177,
453
- 216, 178, 177, 217, 178, 177, 203, 178,
454
- 177, 218, 219, 178, 177, 220, 178, 177,
455
- 221, 178, 177, 222, 178, 177, 223, 178,
456
- 177, 224, 178, 177, 225, 178, 177, 226,
457
- 178, 177, 227, 178, 177, 228, 178, 177,
458
- 229, 178, 177, 178, 230, 196, 177, 231,
459
- 178, 177, 232, 178, 177, 233, 178, 177,
460
- 234, 178, 177, 235, 178, 177, 203, 178,
461
- 177, 236, 178, 177, 237, 178, 177, 195,
462
- 178, 177, 238, 178, 177, 239, 178, 177,
463
- 240, 178, 177, 241, 178, 177, 242, 178,
464
- 177, 243, 178, 177, 244, 178, 177, 196,
465
- 178, 177, 178, 245, 177, 178, 246, 177,
466
- 178, 247, 177, 178, 248, 177, 178, 249,
467
- 177, 178, 250, 177, 178, 251, 177, 178,
468
- 252, 177, 178, 253, 177, 178, 254, 177,
469
- 178, 255, 177, 178, 256, 177, 178, 257,
470
- 177, 178, 258, 177, 178, 196, 177, 259,
471
- 0, 260, 0, 262, 261, 264, 263, 265,
472
- 264, 266, 267, 267, 266, 263, 268, 264,
473
- 263, 269, 264, 263, 270, 264, 263, 271,
474
- 264, 263, 272, 264, 263, 264, 273, 263,
475
- 274, 0, 275, 0, 22, 0, 276, 0,
476
- 277, 0, 278, 0, 279, 0, 280, 0,
477
- 281, 0, 282, 0, 23, 0, 283, 0,
478
- 284, 0, 286, 287, 285, 289, 290, 288,
479
- 293, 292, 294, 292, 291, 297, 296, 298,
480
- 296, 295, 297, 296, 299, 296, 295, 297,
481
- 296, 300, 296, 295, 302, 301, 301, 0,
482
- 7, 303, 303, 0, 305, 306, 304, 7,
483
- 0, 307, 0, 308, 0, 309, 0, 310,
484
- 0, 311, 0, 312, 0, 313, 0, 314,
485
- 0, 315, 0, 316, 0, 317, 0, 318,
486
- 0, 319, 0, 320, 0, 23, 0, 0,
487
- 0, 0, 0, 321, 322, 323, 322, 322,
488
- 325, 324, 321, 7, 326, 12, 326, 0,
489
- 327, 328, 327, 0, 331, 330, 332, 333,
490
- 330, 329, 0, 335, 336, 334, 0, 335,
491
- 334, 331, 337, 335, 336, 337, 334, 338,
492
- 339, 340, 341, 331, 342, 343, 344, 345,
493
- 346, 347, 348, 342, 0, 349, 49, 48,
494
- 350, 49, 48, 351, 49, 48, 67, 49,
495
- 48, 352, 49, 48, 353, 49, 48, 354,
496
- 49, 48, 355, 49, 48, 49, 67, 48,
497
- 356, 357, 358, 49, 48, 67, 49, 48,
498
- 359, 49, 48, 360, 49, 48, 361, 362,
499
- 49, 48, 67, 49, 48, 67, 49, 48,
500
- 363, 49, 48, 364, 49, 48, 365, 49,
501
- 48, 67, 49, 48, 366, 367, 49, 48,
502
- 368, 49, 48, 369, 49, 48, 370, 49,
503
- 48, 371, 49, 48, 372, 49, 48, 373,
504
- 49, 48, 374, 49, 48, 375, 49, 48,
505
- 376, 49, 48, 377, 49, 48, 49, 378,
506
- 67, 48, 379, 49, 48, 380, 49, 48,
507
- 381, 49, 48, 382, 49, 48, 383, 49,
508
- 48, 355, 49, 48, 384, 49, 48, 385,
509
- 49, 48, 66, 49, 48, 386, 49, 48,
510
- 387, 49, 48, 388, 49, 48, 389, 49,
511
- 48, 390, 49, 48, 391, 49, 48, 392,
512
- 49, 48, 67, 49, 48, 49, 393, 48,
513
- 49, 394, 48, 49, 395, 48, 49, 396,
514
- 48, 49, 397, 48, 49, 398, 48, 49,
515
- 399, 48, 49, 400, 48, 49, 401, 48,
516
- 49, 402, 48, 49, 403, 48, 49, 404,
517
- 48, 49, 405, 48, 49, 406, 48, 49,
518
- 67, 48, 407, 0, 408, 0, 409, 0,
519
- 23, 0, 410, 0, 411, 0, 412, 0,
520
- 413, 0, 414, 0, 416, 415, 418, 417,
521
- 419, 420, 421, 418, 422, 423, 424, 423,
522
- 422, 417, 425, 418, 417, 426, 418, 417,
523
- 427, 418, 417, 428, 418, 417, 429, 418,
524
- 417, 418, 430, 417, 431, 418, 417, 432,
525
- 418, 417, 433, 418, 417, 434, 418, 417,
526
- 429, 418, 417, 435, 436, 418, 417, 437,
527
- 418, 417, 438, 418, 417, 439, 418, 417,
528
- 440, 418, 417, 441, 418, 417, 442, 418,
529
- 417, 443, 418, 417, 444, 418, 417, 445,
530
- 418, 417, 446, 418, 417, 418, 447, 430,
531
- 417, 448, 418, 417, 449, 418, 417, 450,
532
- 418, 417, 451, 418, 417, 452, 418, 417,
533
- 429, 418, 417, 429, 418, 417, 418, 453,
534
- 417, 418, 454, 417, 418, 455, 417, 418,
535
- 456, 417, 418, 457, 417, 418, 458, 417,
536
- 418, 459, 417, 418, 460, 417, 418, 461,
537
- 417, 418, 462, 417, 418, 463, 417, 418,
538
- 464, 417, 418, 465, 417, 418, 466, 417,
539
- 467, 0, 6, 0, 468, 0
540
- ]
541
-
542
- class << self
543
- attr_accessor :_lexer_trans_targs
544
- private :_lexer_trans_targs, :_lexer_trans_targs=
545
- end
546
- self._lexer_trans_targs = [
547
- 0, 2, 13, 41, 221, 385, 12, 12,
548
- 229, 239, 241, 255, 256, 259, 3, 333,
549
- 4, 5, 6, 329, 7, 8, 9, 10,
550
- 11, 12, 240, 11, 12, 240, 14, 15,
551
- 20, 24, 16, 17, 18, 19, 21, 22,
552
- 23, 25, 26, 27, 28, 29, 30, 31,
553
- 30, 31, 32, 274, 285, 306, 31, 12,
554
- 314, 328, 33, 269, 34, 35, 36, 265,
555
- 37, 38, 39, 40, 2, 13, 41, 221,
556
- 12, 12, 229, 239, 241, 255, 256, 259,
557
- 42, 207, 218, 43, 44, 45, 46, 47,
558
- 48, 49, 50, 51, 52, 53, 128, 54,
559
- 55, 56, 57, 58, 59, 60, 61, 62,
560
- 61, 62, 63, 80, 91, 105, 62, 12,
561
- 113, 127, 64, 75, 65, 66, 67, 71,
562
- 68, 69, 70, 40, 72, 73, 74, 76,
563
- 77, 78, 79, 81, 82, 87, 83, 84,
564
- 85, 86, 88, 89, 90, 92, 102, 93,
565
- 94, 95, 96, 97, 98, 99, 100, 101,
566
- 103, 104, 106, 107, 108, 109, 110, 111,
567
- 112, 114, 115, 116, 117, 118, 119, 120,
568
- 121, 122, 123, 124, 125, 126, 12, 129,
569
- 130, 129, 130, 131, 148, 163, 184, 130,
570
- 12, 192, 206, 132, 143, 133, 134, 135,
571
- 139, 136, 137, 138, 40, 140, 141, 142,
572
- 144, 145, 146, 147, 149, 150, 155, 159,
573
- 151, 152, 153, 154, 156, 157, 158, 160,
574
- 161, 162, 164, 181, 165, 166, 167, 168,
575
- 169, 170, 171, 172, 173, 174, 175, 176,
576
- 177, 178, 179, 180, 182, 183, 185, 186,
577
- 187, 188, 189, 190, 191, 193, 194, 195,
578
- 196, 197, 198, 199, 200, 201, 202, 203,
579
- 204, 205, 12, 208, 209, 210, 211, 210,
580
- 211, 212, 211, 12, 213, 214, 215, 216,
581
- 217, 40, 219, 220, 222, 223, 224, 225,
582
- 226, 227, 228, 230, 231, 232, 233, 232,
583
- 232, 233, 232, 234, 234, 234, 235, 234,
584
- 234, 234, 235, 236, 237, 238, 12, 238,
585
- 239, 12, 240, 242, 243, 244, 245, 246,
586
- 247, 248, 249, 250, 251, 252, 253, 254,
587
- 387, 257, 258, 12, 257, 256, 258, 259,
588
- 260, 261, 263, 264, 262, 260, 261, 262,
589
- 260, 263, 2, 13, 41, 221, 264, 229,
590
- 239, 241, 255, 256, 259, 266, 267, 268,
591
- 270, 271, 272, 273, 275, 276, 281, 277,
592
- 278, 279, 280, 282, 283, 284, 286, 303,
593
- 287, 288, 289, 290, 291, 292, 293, 294,
594
- 295, 296, 297, 298, 299, 300, 301, 302,
595
- 304, 305, 307, 308, 309, 310, 311, 312,
596
- 313, 315, 316, 317, 318, 319, 320, 321,
597
- 322, 323, 324, 325, 326, 327, 12, 330,
598
- 331, 332, 334, 335, 336, 337, 338, 339,
599
- 340, 339, 340, 341, 347, 352, 340, 12,
600
- 371, 342, 343, 344, 345, 346, 40, 348,
601
- 349, 350, 351, 353, 370, 354, 355, 356,
602
- 357, 358, 359, 360, 361, 362, 363, 364,
603
- 365, 366, 367, 368, 369, 372, 373, 374,
604
- 375, 376, 377, 378, 379, 380, 381, 382,
605
- 383, 384, 12, 386, 0
606
- ]
607
-
608
- class << self
609
- attr_accessor :_lexer_trans_actions
610
- private :_lexer_trans_actions, :_lexer_trans_actions=
611
- end
612
- self._lexer_trans_actions = [
613
- 43, 29, 29, 29, 29, 0, 0, 54,
614
- 3, 1, 0, 29, 1, 35, 0, 0,
615
- 0, 0, 0, 0, 0, 0, 0, 0,
616
- 57, 149, 126, 0, 110, 23, 0, 0,
617
- 0, 0, 0, 0, 0, 0, 0, 0,
618
- 0, 0, 0, 0, 0, 0, 57, 144,
619
- 0, 54, 84, 84, 84, 84, 0, 72,
620
- 33, 84, 0, 0, 0, 0, 0, 0,
621
- 0, 0, 0, 15, 63, 63, 63, 63,
622
- 31, 130, 60, 57, 31, 63, 57, 66,
623
- 0, 0, 0, 0, 0, 0, 0, 0,
624
- 0, 0, 0, 0, 0, 0, 0, 0,
625
- 0, 0, 0, 0, 0, 0, 57, 144,
626
- 0, 54, 84, 84, 84, 84, 0, 78,
627
- 33, 84, 0, 0, 0, 0, 0, 0,
628
- 0, 0, 0, 19, 0, 0, 0, 0,
629
- 0, 0, 0, 0, 0, 0, 0, 0,
630
- 0, 0, 0, 0, 0, 0, 0, 0,
631
- 0, 0, 0, 0, 0, 0, 0, 0,
632
- 0, 0, 0, 0, 0, 0, 0, 0,
633
- 0, 0, 0, 0, 0, 0, 0, 0,
634
- 0, 0, 0, 0, 0, 0, 19, 57,
635
- 144, 0, 54, 84, 84, 84, 84, 0,
636
- 75, 33, 84, 0, 0, 0, 0, 0,
637
- 0, 0, 0, 0, 17, 0, 0, 0,
638
- 0, 0, 0, 0, 0, 0, 0, 0,
639
- 0, 0, 0, 0, 0, 0, 0, 0,
640
- 0, 0, 0, 0, 0, 0, 0, 0,
641
- 0, 0, 0, 0, 0, 0, 0, 0,
642
- 0, 0, 0, 0, 0, 0, 0, 0,
643
- 0, 0, 0, 0, 0, 0, 0, 0,
644
- 0, 0, 0, 0, 0, 0, 0, 0,
645
- 0, 0, 17, 0, 0, 57, 144, 0,
646
- 54, 84, 0, 81, 0, 0, 0, 0,
647
- 0, 21, 0, 0, 0, 0, 0, 0,
648
- 0, 0, 0, 0, 0, 7, 139, 48,
649
- 0, 102, 9, 5, 45, 134, 45, 0,
650
- 33, 122, 33, 33, 0, 11, 106, 0,
651
- 0, 114, 25, 0, 0, 0, 0, 0,
652
- 0, 0, 0, 0, 0, 0, 0, 0,
653
- 0, 0, 27, 118, 27, 51, 0, 0,
654
- 0, 37, 37, 54, 37, 87, 0, 0,
655
- 39, 0, 96, 96, 96, 96, 0, 93,
656
- 90, 41, 96, 90, 99, 0, 0, 0,
657
- 0, 0, 0, 0, 0, 0, 0, 0,
658
- 0, 0, 0, 0, 0, 0, 0, 0,
659
- 0, 0, 0, 0, 0, 0, 0, 0,
660
- 0, 0, 0, 0, 0, 0, 0, 0,
661
- 0, 0, 0, 0, 0, 0, 0, 0,
662
- 0, 0, 0, 0, 0, 0, 0, 0,
663
- 0, 0, 0, 0, 0, 0, 15, 0,
664
- 0, 0, 0, 0, 0, 0, 0, 57,
665
- 144, 0, 54, 84, 84, 84, 0, 69,
666
- 33, 0, 0, 0, 0, 0, 13, 0,
667
- 0, 0, 0, 0, 0, 0, 0, 0,
668
- 0, 0, 0, 0, 0, 0, 0, 0,
669
- 0, 0, 0, 0, 0, 0, 0, 0,
670
- 0, 0, 0, 0, 0, 0, 0, 0,
671
- 0, 0, 13, 0, 0
672
- ]
673
-
674
- class << self
675
- attr_accessor :_lexer_eof_actions
676
- private :_lexer_eof_actions, :_lexer_eof_actions=
677
- end
678
- self._lexer_eof_actions = [
679
- 0, 43, 43, 43, 43, 43, 43, 43,
680
- 43, 43, 43, 43, 43, 43, 43, 43,
681
- 43, 43, 43, 43, 43, 43, 43, 43,
682
- 43, 43, 43, 43, 43, 43, 43, 43,
683
- 43, 43, 43, 43, 43, 43, 43, 43,
684
- 43, 43, 43, 43, 43, 43, 43, 43,
685
- 43, 43, 43, 43, 43, 43, 43, 43,
686
- 43, 43, 43, 43, 43, 43, 43, 43,
687
- 43, 43, 43, 43, 43, 43, 43, 43,
688
- 43, 43, 43, 43, 43, 43, 43, 43,
689
- 43, 43, 43, 43, 43, 43, 43, 43,
690
- 43, 43, 43, 43, 43, 43, 43, 43,
691
- 43, 43, 43, 43, 43, 43, 43, 43,
692
- 43, 43, 43, 43, 43, 43, 43, 43,
693
- 43, 43, 43, 43, 43, 43, 43, 43,
694
- 43, 43, 43, 43, 43, 43, 43, 43,
695
- 43, 43, 43, 43, 43, 43, 43, 43,
696
- 43, 43, 43, 43, 43, 43, 43, 43,
697
- 43, 43, 43, 43, 43, 43, 43, 43,
698
- 43, 43, 43, 43, 43, 43, 43, 43,
699
- 43, 43, 43, 43, 43, 43, 43, 43,
700
- 43, 43, 43, 43, 43, 43, 43, 43,
701
- 43, 43, 43, 43, 43, 43, 43, 43,
702
- 43, 43, 43, 43, 43, 43, 43, 43,
703
- 43, 43, 43, 43, 43, 43, 43, 43,
704
- 43, 43, 43, 43, 43, 43, 43, 43,
705
- 43, 43, 43, 43, 43, 43, 43, 43,
706
- 43, 43, 43, 43, 43, 43, 43, 43,
707
- 43, 43, 43, 43, 43, 43, 43, 43,
708
- 43, 43, 43, 43, 43, 43, 43, 43,
709
- 43, 43, 43, 43, 43, 43, 43, 43,
710
- 43, 43, 43, 43, 43, 43, 43, 43,
711
- 43, 43, 43, 43, 43, 43, 43, 43,
712
- 43, 43, 43, 43, 43, 43, 43, 43,
713
- 43, 43, 43, 43, 43, 43, 43, 43,
714
- 43, 43, 43, 43, 43, 43, 43, 43,
715
- 43, 43, 43, 43, 43, 43, 43, 43,
716
- 43, 43, 43, 43, 43, 43, 43, 43,
717
- 43, 43, 43, 43, 43, 43, 43, 43,
718
- 43, 43, 43, 43, 43, 43, 43, 43,
719
- 43, 43, 43, 43, 43, 43, 43, 43,
720
- 43, 43, 43, 43, 43, 43, 43, 43,
721
- 43, 43, 43, 43, 43, 43, 43, 43,
722
- 43, 43, 43, 43, 43, 43, 43, 43,
723
- 43, 43, 43, 43, 43, 43, 43, 43,
724
- 43, 43, 43, 43, 43, 43, 43, 43,
725
- 43, 43, 43, 43, 43, 43, 43, 43,
726
- 43, 43, 43, 43, 43, 43, 43, 43,
727
- 43, 43, 43, 43
728
- ]
729
-
730
- class << self
731
- attr_accessor :lexer_start
732
- end
733
- self.lexer_start = 1;
734
- class << self
735
- attr_accessor :lexer_first_final
736
- end
737
- self.lexer_first_final = 387;
738
- class << self
739
- attr_accessor :lexer_error
740
- end
741
- self.lexer_error = 0;
742
-
743
- class << self
744
- attr_accessor :lexer_en_main
745
- end
746
- self.lexer_en_main = 1;
747
-
748
-
749
- # line 133 "ragel/i18n/ko.rb.rl"
750
- end
751
-
752
- def scan(data)
753
- data = (data + "\n%_FEATURE_END_%").unpack("c*") # Explicit EOF simplifies things considerably
754
- eof = pe = data.length
755
-
756
- @line_number = 1
757
- @last_newline = 0
758
-
759
-
760
- # line 761 "lib/gherkin/lexer/ko.rb"
761
- begin
762
- p ||= 0
763
- pe ||= data.length
764
- cs = lexer_start
765
- end
766
-
767
- # line 143 "ragel/i18n/ko.rb.rl"
768
-
769
- # line 770 "lib/gherkin/lexer/ko.rb"
770
- begin
771
- _klen, _trans, _keys, _acts, _nacts = nil
772
- _goto_level = 0
773
- _resume = 10
774
- _eof_trans = 15
775
- _again = 20
776
- _test_eof = 30
777
- _out = 40
778
- while true
779
- _trigger_goto = false
780
- if _goto_level <= 0
781
- if p == pe
782
- _goto_level = _test_eof
783
- next
784
- end
785
- if cs == 0
786
- _goto_level = _out
787
- next
788
- end
789
- end
790
- if _goto_level <= _resume
791
- _keys = _lexer_key_offsets[cs]
792
- _trans = _lexer_index_offsets[cs]
793
- _klen = _lexer_single_lengths[cs]
794
- _break_match = false
795
-
796
- begin
797
- if _klen > 0
798
- _lower = _keys
799
- _upper = _keys + _klen - 1
800
-
801
- loop do
802
- break if _upper < _lower
803
- _mid = _lower + ( (_upper - _lower) >> 1 )
804
-
805
- if data[p].ord < _lexer_trans_keys[_mid]
806
- _upper = _mid - 1
807
- elsif data[p].ord > _lexer_trans_keys[_mid]
808
- _lower = _mid + 1
809
- else
810
- _trans += (_mid - _keys)
811
- _break_match = true
812
- break
813
- end
814
- end # loop
815
- break if _break_match
816
- _keys += _klen
817
- _trans += _klen
818
- end
819
- _klen = _lexer_range_lengths[cs]
820
- if _klen > 0
821
- _lower = _keys
822
- _upper = _keys + (_klen << 1) - 2
823
- loop do
824
- break if _upper < _lower
825
- _mid = _lower + (((_upper-_lower) >> 1) & ~1)
826
- if data[p].ord < _lexer_trans_keys[_mid]
827
- _upper = _mid - 2
828
- elsif data[p].ord > _lexer_trans_keys[_mid+1]
829
- _lower = _mid + 2
830
- else
831
- _trans += ((_mid - _keys) >> 1)
832
- _break_match = true
833
- break
834
- end
835
- end # loop
836
- break if _break_match
837
- _trans += _klen
838
- end
839
- end while false
840
- _trans = _lexer_indicies[_trans]
841
- cs = _lexer_trans_targs[_trans]
842
- if _lexer_trans_actions[_trans] != 0
843
- _acts = _lexer_trans_actions[_trans]
844
- _nacts = _lexer_actions[_acts]
845
- _acts += 1
846
- while _nacts > 0
847
- _nacts -= 1
848
- _acts += 1
849
- case _lexer_actions[_acts - 1]
850
- when 0 then
851
- # line 11 "ragel/i18n/ko.rb.rl"
852
- begin
853
-
854
- @content_start = p
855
- @current_line = @line_number
856
- @start_col = p - @last_newline - "#{@keyword}:".length
857
- end
858
- when 1 then
859
- # line 17 "ragel/i18n/ko.rb.rl"
860
- begin
861
-
862
- @current_line = @line_number
863
- @start_col = p - @last_newline
864
- end
865
- when 2 then
866
- # line 22 "ragel/i18n/ko.rb.rl"
867
- begin
868
-
869
- @content_start = p
870
- end
871
- when 3 then
872
- # line 26 "ragel/i18n/ko.rb.rl"
873
- begin
874
-
875
- @docstring_content_type_start = p
876
- end
877
- when 4 then
878
- # line 29 "ragel/i18n/ko.rb.rl"
879
- begin
880
-
881
- @docstring_content_type_end = p
882
- end
883
- when 5 then
884
- # line 33 "ragel/i18n/ko.rb.rl"
885
- begin
886
-
887
- con = unindent(@start_col, utf8_pack(data[@content_start...@next_keyword_start-1]).sub(/(\r?\n)?([\t ])*\Z/, '').gsub(/\\"\\"\\"/, '"""'))
888
- con_type = utf8_pack(data[@docstring_content_type_start...@docstring_content_type_end]).strip
889
- @listener.doc_string(con_type, con, @current_line)
890
- end
891
- when 6 then
892
- # line 38 "ragel/i18n/ko.rb.rl"
893
- begin
894
-
895
- p = store_keyword_content(:feature, data, p, eof)
896
- end
897
- when 7 then
898
- # line 42 "ragel/i18n/ko.rb.rl"
899
- begin
900
-
901
- p = store_keyword_content(:background, data, p, eof)
902
- end
903
- when 8 then
904
- # line 46 "ragel/i18n/ko.rb.rl"
905
- begin
906
-
907
- p = store_keyword_content(:scenario, data, p, eof)
908
- end
909
- when 9 then
910
- # line 50 "ragel/i18n/ko.rb.rl"
911
- begin
912
-
913
- p = store_keyword_content(:scenario_outline, data, p, eof)
914
- end
915
- when 10 then
916
- # line 54 "ragel/i18n/ko.rb.rl"
917
- begin
918
-
919
- p = store_keyword_content(:examples, data, p, eof)
920
- end
921
- when 11 then
922
- # line 58 "ragel/i18n/ko.rb.rl"
923
- begin
924
-
925
- con = utf8_pack(data[@content_start...p]).strip
926
- @listener.step(@keyword, con, @current_line)
927
- end
928
- when 12 then
929
- # line 63 "ragel/i18n/ko.rb.rl"
930
- begin
931
-
932
- con = utf8_pack(data[@content_start...p]).strip
933
- @listener.comment(con, @line_number)
934
- @keyword_start = nil
935
- end
936
- when 13 then
937
- # line 69 "ragel/i18n/ko.rb.rl"
938
- begin
939
-
940
- con = utf8_pack(data[@content_start...p]).strip
941
- @listener.tag(con, @current_line)
942
- @keyword_start = nil
943
- end
944
- when 14 then
945
- # line 75 "ragel/i18n/ko.rb.rl"
946
- begin
947
-
948
- @line_number += 1
949
- end
950
- when 15 then
951
- # line 79 "ragel/i18n/ko.rb.rl"
952
- begin
953
-
954
- @last_newline = p + 1
955
- end
956
- when 16 then
957
- # line 83 "ragel/i18n/ko.rb.rl"
958
- begin
959
-
960
- @keyword_start ||= p
961
- end
962
- when 17 then
963
- # line 87 "ragel/i18n/ko.rb.rl"
964
- begin
965
-
966
- @keyword = utf8_pack(data[@keyword_start...p]).sub(/:$/,'')
967
- @keyword_start = nil
968
- end
969
- when 18 then
970
- # line 92 "ragel/i18n/ko.rb.rl"
971
- begin
972
-
973
- @next_keyword_start = p
974
- end
975
- when 19 then
976
- # line 96 "ragel/i18n/ko.rb.rl"
977
- begin
978
-
979
- p = p - 1
980
- current_row = []
981
- @current_line = @line_number
982
- end
983
- when 20 then
984
- # line 102 "ragel/i18n/ko.rb.rl"
985
- begin
986
-
987
- @content_start = p
988
- end
989
- when 21 then
990
- # line 106 "ragel/i18n/ko.rb.rl"
991
- begin
992
-
993
- con = utf8_pack(data[@content_start...p]).strip
994
- current_row << con.gsub(/\\\|/, "|").gsub(/\\n/, "\n").gsub(/\\\\/, "\\")
995
- end
996
- when 22 then
997
- # line 111 "ragel/i18n/ko.rb.rl"
998
- begin
999
-
1000
- @listener.row(current_row, @current_line)
1001
- end
1002
- when 23 then
1003
- # line 115 "ragel/i18n/ko.rb.rl"
1004
- begin
1005
-
1006
- if cs < lexer_first_final
1007
- content = current_line_content(data, p)
1008
- raise Gherkin::Lexer::LexingError.new("Lexing error on line %d: '%s'. See http://wiki.github.com/cucumber/gherkin/lexingerror for more information." % [@line_number, content])
1009
- else
1010
- @listener.eof
1011
- end
1012
- end
1013
- # line 1014 "lib/gherkin/lexer/ko.rb"
1014
- end # action switch
1015
- end
1016
- end
1017
- if _trigger_goto
1018
- next
1019
- end
1020
- end
1021
- if _goto_level <= _again
1022
- if cs == 0
1023
- _goto_level = _out
1024
- next
1025
- end
1026
- p += 1
1027
- if p != pe
1028
- _goto_level = _resume
1029
- next
1030
- end
1031
- end
1032
- if _goto_level <= _test_eof
1033
- if p == eof
1034
- __acts = _lexer_eof_actions[cs]
1035
- __nacts = _lexer_actions[__acts]
1036
- __acts += 1
1037
- while __nacts > 0
1038
- __nacts -= 1
1039
- __acts += 1
1040
- case _lexer_actions[__acts - 1]
1041
- when 23 then
1042
- # line 115 "ragel/i18n/ko.rb.rl"
1043
- begin
1044
-
1045
- if cs < lexer_first_final
1046
- content = current_line_content(data, p)
1047
- raise Gherkin::Lexer::LexingError.new("Lexing error on line %d: '%s'. See http://wiki.github.com/cucumber/gherkin/lexingerror for more information." % [@line_number, content])
1048
- else
1049
- @listener.eof
1050
- end
1051
- end
1052
- # line 1053 "lib/gherkin/lexer/ko.rb"
1053
- end # eof action switch
1054
- end
1055
- if _trigger_goto
1056
- next
1057
- end
1058
- end
1059
- end
1060
- if _goto_level <= _out
1061
- break
1062
- end
1063
- end
1064
- end
1065
-
1066
- # line 144 "ragel/i18n/ko.rb.rl"
1067
- end
1068
-
1069
- def unindent(startcol, text)
1070
- text.gsub(/^[\t ]{0,#{startcol}}/, "")
1071
- end
1072
-
1073
- def store_keyword_content(event, data, p, eof)
1074
- end_point = (!@next_keyword_start or (p == eof)) ? p : @next_keyword_start
1075
- content = unindent(@start_col + 2, utf8_pack(data[@content_start...end_point])).rstrip
1076
- content_lines = content.split("\n")
1077
- name = content_lines.shift || ""
1078
- name.strip!
1079
- description = content_lines.join("\n")
1080
- @listener.__send__(event, @keyword, name, description, @current_line)
1081
- @next_keyword_start ? @next_keyword_start - 1 : p
1082
- ensure
1083
- @next_keyword_start = nil
1084
- end
1085
-
1086
- def current_line_content(data, p)
1087
- rest = data[@last_newline..-1]
1088
- utf8_pack(rest[0..rest.index(10)||-1]).strip # 10 is \n
1089
- end
1090
-
1091
- if (RUBY_VERSION =~ /^1\.9|2\.0/)
1092
- def utf8_pack(array)
1093
- array.pack("c*").force_encoding("UTF-8")
1094
- end
1095
- else
1096
- def utf8_pack(array)
1097
- array.pack("c*")
1098
- end
1099
- end
1100
- end
1101
- end
1102
- end