bel_parser 1.0.0.alpha.27-java

Sign up to get free protection for your applications and to get access to all the features.
Files changed (332) hide show
  1. checksums.yaml +7 -0
  2. data/.gemspec-java +32 -0
  3. data/CHANGELOG.md +10 -0
  4. data/LICENSE +191 -0
  5. data/README.md +20 -0
  6. data/VERSION +1 -0
  7. data/bin/bel2_validator +62 -0
  8. data/bin/bel_script_reader +132 -0
  9. data/lib/bel/translator/plugins/bel_script.rb +38 -0
  10. data/lib/bel/translator/plugins/bel_script/bel_citation_serialization.rb +125 -0
  11. data/lib/bel/translator/plugins/bel_script/bel_discrete_serialization.rb +109 -0
  12. data/lib/bel/translator/plugins/bel_script/bel_top_down_serialization.rb +100 -0
  13. data/lib/bel/translator/plugins/bel_script/nanopub_serialization.rb +79 -0
  14. data/lib/bel/translator/plugins/bel_script/reader.rb +39 -0
  15. data/lib/bel/translator/plugins/bel_script/translator.rb +37 -0
  16. data/lib/bel/translator/plugins/bel_script/writer.rb +180 -0
  17. data/lib/bel_parser.rb +23 -0
  18. data/lib/bel_parser/ast_filter.rb +44 -0
  19. data/lib/bel_parser/ast_generator.rb +83 -0
  20. data/lib/bel_parser/expression.rb +3 -0
  21. data/lib/bel_parser/expression/filter.rb +31 -0
  22. data/lib/bel_parser/expression/parser.rb +72 -0
  23. data/lib/bel_parser/expression/validator.rb +79 -0
  24. data/lib/bel_parser/language.rb +114 -0
  25. data/lib/bel_parser/language/amino_acid.rb +68 -0
  26. data/lib/bel_parser/language/apply_namespace_encoding.rb +98 -0
  27. data/lib/bel_parser/language/base_specification.rb +82 -0
  28. data/lib/bel_parser/language/covalent_protein_modification.rb +56 -0
  29. data/lib/bel_parser/language/expression_validator.rb +68 -0
  30. data/lib/bel_parser/language/function.rb +67 -0
  31. data/lib/bel_parser/language/relationship.rb +102 -0
  32. data/lib/bel_parser/language/semantics.rb +40 -0
  33. data/lib/bel_parser/language/semantics/deeply_nested_statement.rb +65 -0
  34. data/lib/bel_parser/language/semantics/function_deprecation.rb +43 -0
  35. data/lib/bel_parser/language/semantics/list_function_subject.rb +45 -0
  36. data/lib/bel_parser/language/semantics/multiple_subject_object.rb +55 -0
  37. data/lib/bel_parser/language/semantics/non_causal_nested_statement.rb +50 -0
  38. data/lib/bel_parser/language/semantics/non_object_list.rb +56 -0
  39. data/lib/bel_parser/language/semantics/relationship_deprecation.rb +44 -0
  40. data/lib/bel_parser/language/semantics/relationship_not_listable.rb +60 -0
  41. data/lib/bel_parser/language/semantics/signature_mapping.rb +83 -0
  42. data/lib/bel_parser/language/semantics_ast.rb +784 -0
  43. data/lib/bel_parser/language/semantics_ast_warnings.rb +180 -0
  44. data/lib/bel_parser/language/semantics_function.rb +16 -0
  45. data/lib/bel_parser/language/semantics_match.rb +28 -0
  46. data/lib/bel_parser/language/semantics_result.rb +33 -0
  47. data/lib/bel_parser/language/semantics_type_warning.rb +22 -0
  48. data/lib/bel_parser/language/semantics_warning.rb +27 -0
  49. data/lib/bel_parser/language/signature.rb +39 -0
  50. data/lib/bel_parser/language/specification.rb +118 -0
  51. data/lib/bel_parser/language/syntax.rb +38 -0
  52. data/lib/bel_parser/language/syntax/invalid_function.rb +39 -0
  53. data/lib/bel_parser/language/syntax/invalid_relationship.rb +42 -0
  54. data/lib/bel_parser/language/syntax/undefined_namespace.rb +49 -0
  55. data/lib/bel_parser/language/syntax/undefined_namespace_value.rb +44 -0
  56. data/lib/bel_parser/language/syntax_error.rb +32 -0
  57. data/lib/bel_parser/language/syntax_function.rb +16 -0
  58. data/lib/bel_parser/language/syntax_result.rb +32 -0
  59. data/lib/bel_parser/language/syntax_warning.rb +27 -0
  60. data/lib/bel_parser/language/version1_0.rb +20 -0
  61. data/lib/bel_parser/language/version1_0/functions/abundance.rb +83 -0
  62. data/lib/bel_parser/language/version1_0/functions/biological_process.rb +83 -0
  63. data/lib/bel_parser/language/version1_0/functions/catalytic_activity.rb +114 -0
  64. data/lib/bel_parser/language/version1_0/functions/cell_secretion.rb +83 -0
  65. data/lib/bel_parser/language/version1_0/functions/cell_surface_expression.rb +83 -0
  66. data/lib/bel_parser/language/version1_0/functions/chaperone_activity.rb +114 -0
  67. data/lib/bel_parser/language/version1_0/functions/complex_abundance.rb +115 -0
  68. data/lib/bel_parser/language/version1_0/functions/composite_abundance.rb +81 -0
  69. data/lib/bel_parser/language/version1_0/functions/degradation.rb +83 -0
  70. data/lib/bel_parser/language/version1_0/functions/fusion.rb +287 -0
  71. data/lib/bel_parser/language/version1_0/functions/gene_abundance.rb +122 -0
  72. data/lib/bel_parser/language/version1_0/functions/gtp_bound_activity.rb +113 -0
  73. data/lib/bel_parser/language/version1_0/functions/kinase_activity.rb +114 -0
  74. data/lib/bel_parser/language/version1_0/functions/list.rb +114 -0
  75. data/lib/bel_parser/language/version1_0/functions/micro_rna_abundance.rb +85 -0
  76. data/lib/bel_parser/language/version1_0/functions/molecular_activity.rb +82 -0
  77. data/lib/bel_parser/language/version1_0/functions/pathology.rb +83 -0
  78. data/lib/bel_parser/language/version1_0/functions/peptidase_activity.rb +112 -0
  79. data/lib/bel_parser/language/version1_0/functions/phosphatase_activity.rb +112 -0
  80. data/lib/bel_parser/language/version1_0/functions/products.rb +79 -0
  81. data/lib/bel_parser/language/version1_0/functions/protein_abundance.rb +234 -0
  82. data/lib/bel_parser/language/version1_0/functions/protein_modification.rb +179 -0
  83. data/lib/bel_parser/language/version1_0/functions/reactants.rb +79 -0
  84. data/lib/bel_parser/language/version1_0/functions/reaction.rb +86 -0
  85. data/lib/bel_parser/language/version1_0/functions/ribosylation_activity.rb +114 -0
  86. data/lib/bel_parser/language/version1_0/functions/rna_abundance.rb +122 -0
  87. data/lib/bel_parser/language/version1_0/functions/substitution.rb +93 -0
  88. data/lib/bel_parser/language/version1_0/functions/transcriptional_activity.rb +114 -0
  89. data/lib/bel_parser/language/version1_0/functions/translocation.rb +98 -0
  90. data/lib/bel_parser/language/version1_0/functions/transport_activity.rb +115 -0
  91. data/lib/bel_parser/language/version1_0/functions/truncation.rb +81 -0
  92. data/lib/bel_parser/language/version1_0/relationships/acts_in.rb +61 -0
  93. data/lib/bel_parser/language/version1_0/relationships/analogous.rb +41 -0
  94. data/lib/bel_parser/language/version1_0/relationships/association.rb +42 -0
  95. data/lib/bel_parser/language/version1_0/relationships/biomarker_for.rb +42 -0
  96. data/lib/bel_parser/language/version1_0/relationships/causes_no_change.rb +50 -0
  97. data/lib/bel_parser/language/version1_0/relationships/decreases.rb +63 -0
  98. data/lib/bel_parser/language/version1_0/relationships/directly_decreases.rb +56 -0
  99. data/lib/bel_parser/language/version1_0/relationships/directly_increases.rb +56 -0
  100. data/lib/bel_parser/language/version1_0/relationships/has_component.rb +62 -0
  101. data/lib/bel_parser/language/version1_0/relationships/has_components.rb +61 -0
  102. data/lib/bel_parser/language/version1_0/relationships/has_member.rb +48 -0
  103. data/lib/bel_parser/language/version1_0/relationships/has_members.rb +57 -0
  104. data/lib/bel_parser/language/version1_0/relationships/has_modification.rb +54 -0
  105. data/lib/bel_parser/language/version1_0/relationships/has_product.rb +60 -0
  106. data/lib/bel_parser/language/version1_0/relationships/has_variant.rb +54 -0
  107. data/lib/bel_parser/language/version1_0/relationships/includes.rb +59 -0
  108. data/lib/bel_parser/language/version1_0/relationships/increases.rb +63 -0
  109. data/lib/bel_parser/language/version1_0/relationships/is_a.rb +48 -0
  110. data/lib/bel_parser/language/version1_0/relationships/negative_correlation.rb +50 -0
  111. data/lib/bel_parser/language/version1_0/relationships/orthologous.rb +48 -0
  112. data/lib/bel_parser/language/version1_0/relationships/positive_correlation.rb +46 -0
  113. data/lib/bel_parser/language/version1_0/relationships/prognostic_biomarker_for.rb +44 -0
  114. data/lib/bel_parser/language/version1_0/relationships/rate_limiting_step_of.rb +53 -0
  115. data/lib/bel_parser/language/version1_0/relationships/reactant_in.rb +60 -0
  116. data/lib/bel_parser/language/version1_0/relationships/sub_process_of.rb +55 -0
  117. data/lib/bel_parser/language/version1_0/relationships/transcribed_to.rb +53 -0
  118. data/lib/bel_parser/language/version1_0/relationships/translated_to.rb +54 -0
  119. data/lib/bel_parser/language/version1_0/relationships/translocates.rb +57 -0
  120. data/lib/bel_parser/language/version1_0/return_types/abundance.rb +20 -0
  121. data/lib/bel_parser/language/version1_0/return_types/any.rb +74 -0
  122. data/lib/bel_parser/language/version1_0/return_types/biological_process.rb +17 -0
  123. data/lib/bel_parser/language/version1_0/return_types/catalytic_activity.rb +20 -0
  124. data/lib/bel_parser/language/version1_0/return_types/chaperone_activity.rb +20 -0
  125. data/lib/bel_parser/language/version1_0/return_types/complex_abundance.rb +17 -0
  126. data/lib/bel_parser/language/version1_0/return_types/fusion.rb +17 -0
  127. data/lib/bel_parser/language/version1_0/return_types/gene_abundance.rb +17 -0
  128. data/lib/bel_parser/language/version1_0/return_types/gtp_bound_activity.rb +20 -0
  129. data/lib/bel_parser/language/version1_0/return_types/kinase_activity.rb +20 -0
  130. data/lib/bel_parser/language/version1_0/return_types/list.rb +17 -0
  131. data/lib/bel_parser/language/version1_0/return_types/micro_rna_abundance.rb +17 -0
  132. data/lib/bel_parser/language/version1_0/return_types/molecular_activity.rb +20 -0
  133. data/lib/bel_parser/language/version1_0/return_types/pathology.rb +17 -0
  134. data/lib/bel_parser/language/version1_0/return_types/peptidase_activity.rb +20 -0
  135. data/lib/bel_parser/language/version1_0/return_types/phosphatase_activity.rb +20 -0
  136. data/lib/bel_parser/language/version1_0/return_types/products.rb +17 -0
  137. data/lib/bel_parser/language/version1_0/return_types/protein_abundance.rb +17 -0
  138. data/lib/bel_parser/language/version1_0/return_types/protein_modification.rb +17 -0
  139. data/lib/bel_parser/language/version1_0/return_types/reactants.rb +17 -0
  140. data/lib/bel_parser/language/version1_0/return_types/ribosylation_activity.rb +20 -0
  141. data/lib/bel_parser/language/version1_0/return_types/rna_abundance.rb +17 -0
  142. data/lib/bel_parser/language/version1_0/return_types/substitution.rb +17 -0
  143. data/lib/bel_parser/language/version1_0/return_types/transcriptional_activity.rb +20 -0
  144. data/lib/bel_parser/language/version1_0/return_types/transport_activity.rb +20 -0
  145. data/lib/bel_parser/language/version1_0/return_types/truncation.rb +17 -0
  146. data/lib/bel_parser/language/version1_0/value_encodings/abundance.rb +21 -0
  147. data/lib/bel_parser/language/version1_0/value_encodings/any.rb +74 -0
  148. data/lib/bel_parser/language/version1_0/value_encodings/biological_process.rb +21 -0
  149. data/lib/bel_parser/language/version1_0/value_encodings/complex_abundance.rb +21 -0
  150. data/lib/bel_parser/language/version1_0/value_encodings/gene_abundance.rb +21 -0
  151. data/lib/bel_parser/language/version1_0/value_encodings/micro_rna_abundance.rb +21 -0
  152. data/lib/bel_parser/language/version1_0/value_encodings/pathology.rb +21 -0
  153. data/lib/bel_parser/language/version1_0/value_encodings/protein_abundance.rb +21 -0
  154. data/lib/bel_parser/language/version1_0/value_encodings/rna_abundance.rb +21 -0
  155. data/lib/bel_parser/language/version2_0.rb +20 -0
  156. data/lib/bel_parser/language/version2_0/functions/abundance.rb +161 -0
  157. data/lib/bel_parser/language/version2_0/functions/activity.rb +118 -0
  158. data/lib/bel_parser/language/version2_0/functions/biological_process.rb +84 -0
  159. data/lib/bel_parser/language/version2_0/functions/cell_secretion.rb +83 -0
  160. data/lib/bel_parser/language/version2_0/functions/cell_surface_expression.rb +83 -0
  161. data/lib/bel_parser/language/version2_0/functions/complex_abundance.rb +190 -0
  162. data/lib/bel_parser/language/version2_0/functions/composite_abundance.rb +81 -0
  163. data/lib/bel_parser/language/version2_0/functions/degradation.rb +83 -0
  164. data/lib/bel_parser/language/version2_0/functions/fragment.rb +116 -0
  165. data/lib/bel_parser/language/version2_0/functions/from_location.rb +85 -0
  166. data/lib/bel_parser/language/version2_0/functions/fusion.rb +203 -0
  167. data/lib/bel_parser/language/version2_0/functions/gene_abundance.rb +192 -0
  168. data/lib/bel_parser/language/version2_0/functions/list.rb +114 -0
  169. data/lib/bel_parser/language/version2_0/functions/location.rb +83 -0
  170. data/lib/bel_parser/language/version2_0/functions/micro_rna_abundance.rb +163 -0
  171. data/lib/bel_parser/language/version2_0/functions/molecular_activity.rb +86 -0
  172. data/lib/bel_parser/language/version2_0/functions/pathology.rb +83 -0
  173. data/lib/bel_parser/language/version2_0/functions/products.rb +79 -0
  174. data/lib/bel_parser/language/version2_0/functions/protein_abundance.rb +270 -0
  175. data/lib/bel_parser/language/version2_0/functions/protein_modification.rb +172 -0
  176. data/lib/bel_parser/language/version2_0/functions/reactants.rb +79 -0
  177. data/lib/bel_parser/language/version2_0/functions/reaction.rb +86 -0
  178. data/lib/bel_parser/language/version2_0/functions/rna_abundance.rb +192 -0
  179. data/lib/bel_parser/language/version2_0/functions/to_location.rb +84 -0
  180. data/lib/bel_parser/language/version2_0/functions/translocation.rb +91 -0
  181. data/lib/bel_parser/language/version2_0/functions/variant.rb +80 -0
  182. data/lib/bel_parser/language/version2_0/relationships/acts_in.rb +61 -0
  183. data/lib/bel_parser/language/version2_0/relationships/analogous.rb +45 -0
  184. data/lib/bel_parser/language/version2_0/relationships/association.rb +42 -0
  185. data/lib/bel_parser/language/version2_0/relationships/biomarker_for.rb +46 -0
  186. data/lib/bel_parser/language/version2_0/relationships/causes_no_change.rb +50 -0
  187. data/lib/bel_parser/language/version2_0/relationships/decreases.rb +63 -0
  188. data/lib/bel_parser/language/version2_0/relationships/directly_decreases.rb +56 -0
  189. data/lib/bel_parser/language/version2_0/relationships/directly_increases.rb +56 -0
  190. data/lib/bel_parser/language/version2_0/relationships/has_component.rb +62 -0
  191. data/lib/bel_parser/language/version2_0/relationships/has_components.rb +61 -0
  192. data/lib/bel_parser/language/version2_0/relationships/has_member.rb +48 -0
  193. data/lib/bel_parser/language/version2_0/relationships/has_members.rb +57 -0
  194. data/lib/bel_parser/language/version2_0/relationships/has_modification.rb +54 -0
  195. data/lib/bel_parser/language/version2_0/relationships/has_product.rb +60 -0
  196. data/lib/bel_parser/language/version2_0/relationships/has_variant.rb +54 -0
  197. data/lib/bel_parser/language/version2_0/relationships/includes.rb +59 -0
  198. data/lib/bel_parser/language/version2_0/relationships/increases.rb +63 -0
  199. data/lib/bel_parser/language/version2_0/relationships/is_a.rb +48 -0
  200. data/lib/bel_parser/language/version2_0/relationships/negative_correlation.rb +50 -0
  201. data/lib/bel_parser/language/version2_0/relationships/orthologous.rb +48 -0
  202. data/lib/bel_parser/language/version2_0/relationships/positive_correlation.rb +46 -0
  203. data/lib/bel_parser/language/version2_0/relationships/prognostic_biomarker_for.rb +48 -0
  204. data/lib/bel_parser/language/version2_0/relationships/rate_limiting_step_of.rb +53 -0
  205. data/lib/bel_parser/language/version2_0/relationships/reactant_in.rb +60 -0
  206. data/lib/bel_parser/language/version2_0/relationships/regulates.rb +51 -0
  207. data/lib/bel_parser/language/version2_0/relationships/sub_process_of.rb +55 -0
  208. data/lib/bel_parser/language/version2_0/relationships/transcribed_to.rb +53 -0
  209. data/lib/bel_parser/language/version2_0/relationships/translated_to.rb +54 -0
  210. data/lib/bel_parser/language/version2_0/relationships/translocates.rb +57 -0
  211. data/lib/bel_parser/language/version2_0/return_types/abundance.rb +20 -0
  212. data/lib/bel_parser/language/version2_0/return_types/activity.rb +20 -0
  213. data/lib/bel_parser/language/version2_0/return_types/any.rb +74 -0
  214. data/lib/bel_parser/language/version2_0/return_types/biological_process.rb +17 -0
  215. data/lib/bel_parser/language/version2_0/return_types/complex_abundance.rb +17 -0
  216. data/lib/bel_parser/language/version2_0/return_types/fragment.rb +20 -0
  217. data/lib/bel_parser/language/version2_0/return_types/from_location.rb +20 -0
  218. data/lib/bel_parser/language/version2_0/return_types/fusion.rb +17 -0
  219. data/lib/bel_parser/language/version2_0/return_types/gene_abundance.rb +17 -0
  220. data/lib/bel_parser/language/version2_0/return_types/list.rb +17 -0
  221. data/lib/bel_parser/language/version2_0/return_types/location.rb +20 -0
  222. data/lib/bel_parser/language/version2_0/return_types/micro_rna_abundance.rb +17 -0
  223. data/lib/bel_parser/language/version2_0/return_types/molecular_activity.rb +20 -0
  224. data/lib/bel_parser/language/version2_0/return_types/pathology.rb +17 -0
  225. data/lib/bel_parser/language/version2_0/return_types/products.rb +17 -0
  226. data/lib/bel_parser/language/version2_0/return_types/protein_abundance.rb +17 -0
  227. data/lib/bel_parser/language/version2_0/return_types/protein_modification.rb +17 -0
  228. data/lib/bel_parser/language/version2_0/return_types/reactants.rb +17 -0
  229. data/lib/bel_parser/language/version2_0/return_types/rna_abundance.rb +17 -0
  230. data/lib/bel_parser/language/version2_0/return_types/to_location.rb +20 -0
  231. data/lib/bel_parser/language/version2_0/return_types/variant.rb +20 -0
  232. data/lib/bel_parser/language/version2_0/value_encodings/abundance.rb +21 -0
  233. data/lib/bel_parser/language/version2_0/value_encodings/activity.rb +21 -0
  234. data/lib/bel_parser/language/version2_0/value_encodings/any.rb +74 -0
  235. data/lib/bel_parser/language/version2_0/value_encodings/biological_process.rb +21 -0
  236. data/lib/bel_parser/language/version2_0/value_encodings/complex_abundance.rb +21 -0
  237. data/lib/bel_parser/language/version2_0/value_encodings/gene_abundance.rb +21 -0
  238. data/lib/bel_parser/language/version2_0/value_encodings/location.rb +21 -0
  239. data/lib/bel_parser/language/version2_0/value_encodings/micro_rna_abundance.rb +21 -0
  240. data/lib/bel_parser/language/version2_0/value_encodings/pathology.rb +21 -0
  241. data/lib/bel_parser/language/version2_0/value_encodings/protein_abundance.rb +21 -0
  242. data/lib/bel_parser/language/version2_0/value_encodings/protein_modification.rb +21 -0
  243. data/lib/bel_parser/language/version2_0/value_encodings/rna_abundance.rb +21 -0
  244. data/lib/bel_parser/mixin/line_continuator.rb +15 -0
  245. data/lib/bel_parser/mixin/line_mapping.rb +14 -0
  246. data/lib/bel_parser/parsers/ast/node.rb +987 -0
  247. data/lib/bel_parser/parsers/ast/sexp.rb +8 -0
  248. data/lib/bel_parser/parsers/bel_script.rb +5 -0
  249. data/lib/bel_parser/parsers/bel_script/define_annotation.rb +5920 -0
  250. data/lib/bel_parser/parsers/bel_script/define_annotation.rl +141 -0
  251. data/lib/bel_parser/parsers/bel_script/define_namespace.rb +1780 -0
  252. data/lib/bel_parser/parsers/bel_script/define_namespace.rl +121 -0
  253. data/lib/bel_parser/parsers/bel_script/set.rb +5008 -0
  254. data/lib/bel_parser/parsers/bel_script/set.rl +116 -0
  255. data/lib/bel_parser/parsers/bel_script/set_document.rb +7722 -0
  256. data/lib/bel_parser/parsers/bel_script/set_document.rl +97 -0
  257. data/lib/bel_parser/parsers/bel_script/unset.rb +706 -0
  258. data/lib/bel_parser/parsers/bel_script/unset.rl +95 -0
  259. data/lib/bel_parser/parsers/common.rb +5 -0
  260. data/lib/bel_parser/parsers/common/blank_line.rb +211 -0
  261. data/lib/bel_parser/parsers/common/blank_line.rl +81 -0
  262. data/lib/bel_parser/parsers/common/comment_line.rb +245 -0
  263. data/lib/bel_parser/parsers/common/comment_line.rl +97 -0
  264. data/lib/bel_parser/parsers/common/common.rb +7 -0
  265. data/lib/bel_parser/parsers/common/common.rl +13 -0
  266. data/lib/bel_parser/parsers/common/identifier.rb +289 -0
  267. data/lib/bel_parser/parsers/common/identifier.rl +106 -0
  268. data/lib/bel_parser/parsers/common/list.rb +2388 -0
  269. data/lib/bel_parser/parsers/common/list.rl +146 -0
  270. data/lib/bel_parser/parsers/common/string.rb +271 -0
  271. data/lib/bel_parser/parsers/common/string.rl +107 -0
  272. data/lib/bel_parser/parsers/expression.rb +7 -0
  273. data/lib/bel_parser/parsers/expression/comment.rb +239 -0
  274. data/lib/bel_parser/parsers/expression/comment.rl +97 -0
  275. data/lib/bel_parser/parsers/expression/nested_statement.rb +17802 -0
  276. data/lib/bel_parser/parsers/expression/nested_statement.rl +141 -0
  277. data/lib/bel_parser/parsers/expression/observed_term.rb +7291 -0
  278. data/lib/bel_parser/parsers/expression/observed_term.rl +92 -0
  279. data/lib/bel_parser/parsers/expression/parameter.rb +1506 -0
  280. data/lib/bel_parser/parsers/expression/parameter.rl +97 -0
  281. data/lib/bel_parser/parsers/expression/relationship.rb +254 -0
  282. data/lib/bel_parser/parsers/expression/relationship.rl +98 -0
  283. data/lib/bel_parser/parsers/expression/simple_statement.rb +10475 -0
  284. data/lib/bel_parser/parsers/expression/simple_statement.rl +112 -0
  285. data/lib/bel_parser/parsers/expression/term.rb +3989 -0
  286. data/lib/bel_parser/parsers/expression/term.rl +157 -0
  287. data/lib/bel_parser/parsers/line_parser.rb +92 -0
  288. data/lib/bel_parser/parsers/mixin/buffer.rb +10 -0
  289. data/lib/bel_parser/parsers/nonblocking_io_wrapper.rb +50 -0
  290. data/lib/bel_parser/parsers/serializer.rb +205 -0
  291. data/lib/bel_parser/quoting.rb +177 -0
  292. data/lib/bel_parser/resource/concept.rb +56 -0
  293. data/lib/bel_parser/resource/concept_scheme.rb +35 -0
  294. data/lib/bel_parser/resource/dataset.rb +34 -0
  295. data/lib/bel_parser/resource/eager_reader.rb +89 -0
  296. data/lib/bel_parser/resource/eager_sparql_reader.rb +51 -0
  297. data/lib/bel_parser/resource/file_resource.rb +21 -0
  298. data/lib/bel_parser/resource/file_resource_value.rb +24 -0
  299. data/lib/bel_parser/resource/jena_tdb_reader.rb +246 -0
  300. data/lib/bel_parser/resource/lru_cache.rb +111 -0
  301. data/lib/bel_parser/resource/lru_reader.rb +34 -0
  302. data/lib/bel_parser/resource/reader.rb +18 -0
  303. data/lib/bel_parser/resource/resource_url_reader.rb +181 -0
  304. data/lib/bel_parser/resource/sparql_reader.rb +179 -0
  305. data/lib/bel_parser/resource/value.rb +31 -0
  306. data/lib/bel_parser/script.rb +8 -0
  307. data/lib/bel_parser/script/filter.rb +35 -0
  308. data/lib/bel_parser/script/first_node.rb +21 -0
  309. data/lib/bel_parser/script/keywords.rb +32 -0
  310. data/lib/bel_parser/script/nanopub_mapper.rb +182 -0
  311. data/lib/bel_parser/script/parser.rb +51 -0
  312. data/lib/bel_parser/script/state/annotation_definition.rb +62 -0
  313. data/lib/bel_parser/script/state/bel_version.rb +36 -0
  314. data/lib/bel_parser/script/state/document_property.rb +29 -0
  315. data/lib/bel_parser/script/state/namespace_definition.rb +32 -0
  316. data/lib/bel_parser/script/state/set.rb +82 -0
  317. data/lib/bel_parser/script/state/unset.rb +46 -0
  318. data/lib/bel_parser/script/state_aggregator.rb +49 -0
  319. data/lib/bel_parser/script/state_function.rb +10 -0
  320. data/lib/bel_parser/script/syntax/expression_validation.rb +46 -0
  321. data/lib/bel_parser/script/syntax/invalid_regex_pattern.rb +49 -0
  322. data/lib/bel_parser/script/syntax/undefined_annotation.rb +61 -0
  323. data/lib/bel_parser/script/syntax/undefined_annotation_value.rb +84 -0
  324. data/lib/bel_parser/script/syntax/unresolvable_namespace.rb +54 -0
  325. data/lib/bel_parser/script/syntax/unsupported_bel_version.rb +59 -0
  326. data/lib/bel_parser/script/validator.rb +65 -0
  327. data/lib/bel_parser/vendor/ast.rb +17 -0
  328. data/lib/bel_parser/vendor/ast/node.rb +254 -0
  329. data/lib/bel_parser/vendor/ast/processor.rb +12 -0
  330. data/lib/bel_parser/vendor/ast/processor/mixin.rb +282 -0
  331. data/lib/bel_parser/vendor/ast/sexp.rb +30 -0
  332. metadata +390 -0
@@ -0,0 +1,112 @@
1
+ # begin: ragel
2
+ =begin
3
+ %%{
4
+ machine bel;
5
+
6
+ include 'term.rl';
7
+ include 'relationship.rl';
8
+ include 'comment.rl';
9
+
10
+ action statement_subject {
11
+ @buffers[:subject] = subject(
12
+ @buffers[:term_stack][-1])
13
+ @buffers[:term_stack] = nil
14
+ }
15
+
16
+ action statement_object {
17
+ @buffers[:object] = object(
18
+ @buffers[:term_stack][-1])
19
+ @buffers[:term_stack] = nil
20
+ }
21
+
22
+ action yield_simple_statement {
23
+ @buffers[:comment] ||= comment(nil)
24
+ yield simple_statement(
25
+ statement(
26
+ @buffers[:subject],
27
+ @buffers[:relationship],
28
+ @buffers[:object],
29
+ @buffers[:comment]))
30
+ }
31
+
32
+ STATEMENT_SIMPLE =
33
+ outer_term %statement_subject
34
+ SP+
35
+ RELATIONSHIP
36
+ SP+
37
+ outer_term %statement_object;
38
+
39
+ simple_statement :=
40
+ STATEMENT_SIMPLE
41
+ SP*
42
+ COMMENT? %yield_simple_statement
43
+ NL;
44
+ }%%
45
+ =end
46
+ # end: ragel
47
+
48
+ require_relative '../ast/node'
49
+ require_relative '../mixin/buffer'
50
+ require_relative '../nonblocking_io_wrapper'
51
+
52
+ module BELParser
53
+ module Parsers
54
+ module Expression
55
+ module SimpleStatement
56
+
57
+ class << self
58
+
59
+ MAX_LENGTH = 1024 * 128 # 128K
60
+
61
+ def parse(content)
62
+ return nil unless content
63
+
64
+ Parser.new(content).each do |obj|
65
+ yield obj
66
+ end
67
+ end
68
+ end
69
+
70
+ private
71
+
72
+ class Parser
73
+ include Enumerable
74
+ include BELParser::Parsers::Buffer
75
+ include BELParser::Parsers::AST::Sexp
76
+
77
+ def initialize(content)
78
+ @content = content
79
+ # begin: ragel
80
+ %% write data;
81
+ # end: ragel
82
+ end
83
+
84
+ def each
85
+ @buffers = {}
86
+ stack = []
87
+ data = @content.unpack('C*')
88
+ p = 0
89
+ pe = data.length
90
+ eof = data.length
91
+
92
+ # begin: ragel
93
+ %% write init;
94
+ %% write exec;
95
+ # end: ragel
96
+ end
97
+ end
98
+ end
99
+ end
100
+ end
101
+ end
102
+
103
+ if __FILE__ == $0
104
+ $stdin.each_line do |line|
105
+ BELParser::Parsers::Expression::SimpleStatement.parse(line) { |obj|
106
+ puts obj.inspect
107
+ }
108
+ end
109
+ end
110
+
111
+ # vim: ft=ruby ts=2 sw=2:
112
+ # encoding: utf-8
@@ -0,0 +1,3989 @@
1
+
2
+ # begin: ragel
3
+ =begin
4
+
5
+ class << self
6
+ attr_accessor :_bel_trans_keys
7
+ private :_bel_trans_keys, :_bel_trans_keys=
8
+ end
9
+ self._bel_trans_keys = [
10
+ 0, 0, 48, 122, 9, 122,
11
+ 9, 40, 9, 122, 9,
12
+ 122, 34, 92, 9, 44,
13
+ 9, 44, 9, 122, 9, 122,
14
+ 9, 44, 10, 10, 92,
15
+ 92, 9, 122, 48, 122,
16
+ 10, 122, 34, 34, 34, 92,
17
+ 10, 10, 92, 92, 9,
18
+ 122, 9, 122, 34, 92,
19
+ 10, 10, 92, 92, 10, 122,
20
+ 10, 122, 48, 122, 9,
21
+ 122, 9, 40, 9, 122,
22
+ 9, 122, 34, 92, 9, 44,
23
+ 9, 44, 9, 122, 9,
24
+ 122, 9, 44, 92, 92,
25
+ 9, 122, 0, 0, 0, 0,
26
+ 0, 0, 0, 0, 0,
27
+ 0, 0
28
+ ]
29
+
30
+ class << self
31
+ attr_accessor :_bel_key_spans
32
+ private :_bel_key_spans, :_bel_key_spans=
33
+ end
34
+ self._bel_key_spans = [
35
+ 0, 75, 114, 32, 114, 114, 59, 36,
36
+ 36, 114, 114, 36, 1, 1, 114, 75,
37
+ 113, 1, 59, 1, 1, 114, 114, 59,
38
+ 1, 1, 113, 113, 75, 114, 32, 114,
39
+ 114, 59, 36, 36, 114, 114, 36, 1,
40
+ 114, 0, 0, 0, 0, 0
41
+ ]
42
+
43
+ class << self
44
+ attr_accessor :_bel_index_offsets
45
+ private :_bel_index_offsets, :_bel_index_offsets=
46
+ end
47
+ self._bel_index_offsets = [
48
+ 0, 0, 76, 191, 224, 339, 454, 514,
49
+ 551, 588, 703, 818, 855, 857, 859, 974,
50
+ 1050, 1164, 1166, 1226, 1228, 1230, 1345, 1460,
51
+ 1520, 1522, 1524, 1638, 1752, 1828, 1943, 1976,
52
+ 2091, 2206, 2266, 2303, 2340, 2455, 2570, 2607,
53
+ 2609, 2724, 2725, 2726, 2727, 2728
54
+ ]
55
+
56
+ class << self
57
+ attr_accessor :_bel_indicies
58
+ private :_bel_indicies, :_bel_indicies=
59
+ end
60
+ self._bel_indicies = [
61
+ 1, 1, 1, 1, 1, 1, 1, 1,
62
+ 1, 1, 0, 0, 0, 0, 0, 0,
63
+ 0, 1, 1, 1, 1, 1, 1, 1,
64
+ 1, 1, 1, 1, 1, 1, 1, 1,
65
+ 1, 1, 1, 1, 1, 1, 1, 1,
66
+ 1, 1, 1, 0, 0, 0, 0, 1,
67
+ 0, 1, 1, 1, 1, 1, 1, 1,
68
+ 1, 1, 1, 1, 1, 1, 1, 1,
69
+ 1, 1, 1, 1, 1, 1, 1, 1,
70
+ 1, 1, 1, 0, 2, 0, 0, 0,
71
+ 0, 0, 0, 0, 0, 0, 0, 0,
72
+ 0, 0, 0, 0, 0, 0, 0, 0,
73
+ 0, 0, 0, 2, 0, 0, 0, 0,
74
+ 0, 0, 0, 3, 0, 0, 0, 0,
75
+ 0, 0, 0, 4, 4, 4, 4, 4,
76
+ 4, 4, 4, 4, 4, 0, 0, 0,
77
+ 0, 0, 0, 0, 4, 4, 4, 4,
78
+ 4, 4, 4, 4, 4, 4, 4, 4,
79
+ 4, 4, 4, 4, 4, 4, 4, 4,
80
+ 4, 4, 4, 4, 4, 4, 0, 0,
81
+ 0, 0, 4, 0, 4, 4, 4, 4,
82
+ 4, 4, 4, 4, 4, 4, 4, 4,
83
+ 4, 4, 4, 4, 4, 4, 4, 4,
84
+ 4, 4, 4, 4, 4, 4, 0, 5,
85
+ 6, 6, 6, 6, 6, 6, 6, 6,
86
+ 6, 6, 6, 6, 6, 6, 6, 6,
87
+ 6, 6, 6, 6, 6, 6, 5, 6,
88
+ 6, 6, 6, 6, 6, 6, 7, 6,
89
+ 9, 8, 8, 8, 8, 8, 8, 8,
90
+ 8, 8, 8, 8, 8, 8, 8, 8,
91
+ 8, 8, 8, 8, 8, 8, 8, 9,
92
+ 8, 10, 8, 8, 8, 8, 8, 8,
93
+ 8, 8, 8, 8, 8, 8, 8, 11,
94
+ 11, 11, 11, 11, 11, 11, 11, 11,
95
+ 11, 8, 8, 8, 8, 8, 8, 8,
96
+ 11, 11, 11, 11, 11, 11, 11, 11,
97
+ 11, 11, 11, 11, 11, 11, 11, 11,
98
+ 11, 11, 11, 11, 11, 11, 11, 11,
99
+ 11, 11, 8, 8, 8, 8, 11, 8,
100
+ 11, 11, 11, 11, 11, 11, 11, 11,
101
+ 11, 11, 11, 11, 11, 11, 11, 11,
102
+ 11, 11, 11, 11, 11, 11, 11, 11,
103
+ 11, 11, 8, 9, 12, 12, 12, 12,
104
+ 12, 12, 12, 12, 12, 12, 12, 12,
105
+ 12, 12, 12, 12, 12, 12, 12, 12,
106
+ 12, 12, 9, 12, 10, 12, 12, 12,
107
+ 12, 12, 12, 12, 12, 12, 12, 12,
108
+ 12, 12, 13, 13, 13, 13, 13, 13,
109
+ 13, 13, 13, 13, 12, 12, 12, 12,
110
+ 12, 12, 12, 13, 13, 13, 13, 13,
111
+ 13, 13, 13, 13, 13, 13, 13, 13,
112
+ 13, 13, 13, 13, 13, 13, 13, 13,
113
+ 13, 13, 13, 13, 13, 12, 12, 12,
114
+ 12, 13, 12, 13, 13, 13, 13, 13,
115
+ 13, 13, 13, 13, 13, 13, 13, 13,
116
+ 13, 13, 13, 13, 13, 13, 13, 13,
117
+ 13, 13, 13, 13, 13, 12, 15, 14,
118
+ 14, 14, 14, 14, 14, 14, 14, 14,
119
+ 14, 14, 14, 14, 14, 14, 14, 14,
120
+ 14, 14, 14, 14, 14, 14, 14, 14,
121
+ 14, 14, 14, 14, 14, 14, 14, 14,
122
+ 14, 14, 14, 14, 14, 14, 14, 14,
123
+ 14, 14, 14, 14, 14, 14, 14, 14,
124
+ 14, 14, 14, 14, 14, 14, 14, 14,
125
+ 16, 14, 18, 17, 17, 17, 17, 17,
126
+ 17, 17, 17, 17, 17, 17, 17, 17,
127
+ 17, 17, 17, 17, 17, 17, 17, 17,
128
+ 17, 18, 17, 17, 17, 17, 17, 17,
129
+ 17, 17, 19, 17, 17, 20, 17, 21,
130
+ 6, 6, 6, 6, 6, 6, 6, 6,
131
+ 6, 6, 6, 6, 6, 6, 6, 6,
132
+ 6, 6, 6, 6, 6, 6, 21, 6,
133
+ 6, 6, 6, 6, 6, 6, 6, 6,
134
+ 6, 6, 22, 6, 22, 8, 8, 8,
135
+ 8, 8, 8, 8, 8, 8, 8, 8,
136
+ 8, 8, 8, 8, 8, 8, 8, 8,
137
+ 8, 8, 8, 22, 8, 10, 8, 8,
138
+ 8, 8, 8, 8, 8, 8, 8, 8,
139
+ 8, 8, 8, 11, 11, 11, 11, 11,
140
+ 11, 11, 11, 11, 11, 8, 8, 8,
141
+ 8, 8, 8, 8, 11, 11, 11, 11,
142
+ 11, 11, 11, 11, 11, 11, 11, 11,
143
+ 11, 11, 11, 11, 11, 11, 11, 11,
144
+ 11, 11, 11, 11, 11, 11, 8, 8,
145
+ 8, 8, 11, 8, 11, 11, 11, 11,
146
+ 11, 11, 11, 11, 11, 11, 11, 11,
147
+ 11, 11, 11, 11, 11, 11, 11, 11,
148
+ 11, 11, 11, 11, 11, 11, 8, 23,
149
+ 0, 0, 0, 0, 0, 0, 0, 0,
150
+ 0, 0, 0, 0, 0, 0, 0, 0,
151
+ 0, 0, 0, 0, 0, 0, 23, 0,
152
+ 0, 0, 0, 0, 0, 0, 24, 25,
153
+ 0, 0, 26, 0, 0, 0, 27, 27,
154
+ 27, 27, 27, 27, 27, 27, 27, 27,
155
+ 28, 0, 0, 0, 0, 0, 0, 27,
156
+ 27, 27, 27, 27, 27, 27, 27, 27,
157
+ 27, 27, 27, 27, 27, 27, 27, 27,
158
+ 27, 27, 27, 27, 27, 27, 27, 27,
159
+ 27, 0, 0, 0, 0, 27, 0, 27,
160
+ 27, 27, 27, 27, 27, 27, 27, 27,
161
+ 27, 27, 27, 27, 27, 27, 27, 27,
162
+ 27, 27, 27, 27, 27, 27, 27, 27,
163
+ 27, 0, 21, 6, 6, 6, 6, 6,
164
+ 6, 6, 6, 6, 6, 6, 6, 6,
165
+ 6, 6, 6, 6, 6, 6, 6, 6,
166
+ 6, 21, 6, 6, 6, 6, 6, 6,
167
+ 6, 6, 29, 6, 6, 22, 6, 30,
168
+ 6, 16, 14, 23, 0, 0, 0, 0,
169
+ 0, 0, 0, 0, 0, 0, 0, 0,
170
+ 0, 0, 0, 0, 0, 0, 0, 0,
171
+ 0, 0, 23, 0, 0, 0, 0, 0,
172
+ 0, 0, 0, 25, 0, 0, 26, 0,
173
+ 0, 0, 31, 31, 31, 31, 31, 31,
174
+ 31, 31, 31, 31, 0, 0, 0, 0,
175
+ 0, 0, 0, 31, 31, 31, 31, 31,
176
+ 31, 31, 31, 31, 31, 31, 31, 31,
177
+ 31, 31, 31, 31, 31, 31, 31, 31,
178
+ 31, 31, 31, 31, 31, 0, 0, 0,
179
+ 0, 31, 0, 31, 31, 31, 31, 31,
180
+ 31, 31, 31, 31, 31, 31, 31, 31,
181
+ 31, 31, 31, 31, 31, 31, 31, 31,
182
+ 31, 31, 31, 31, 31, 0, 33, 33,
183
+ 33, 33, 33, 33, 33, 33, 33, 33,
184
+ 32, 32, 32, 32, 32, 32, 32, 33,
185
+ 33, 33, 33, 33, 33, 33, 33, 33,
186
+ 33, 33, 33, 33, 33, 33, 33, 33,
187
+ 33, 33, 33, 33, 33, 33, 33, 33,
188
+ 33, 32, 32, 32, 32, 33, 32, 33,
189
+ 33, 33, 33, 33, 33, 33, 33, 33,
190
+ 33, 33, 33, 33, 33, 33, 33, 33,
191
+ 33, 33, 33, 33, 33, 33, 33, 33,
192
+ 33, 32, 34, 32, 32, 32, 32, 32,
193
+ 32, 32, 32, 32, 32, 32, 32, 32,
194
+ 32, 32, 32, 32, 32, 32, 32, 32,
195
+ 32, 32, 32, 32, 32, 32, 32, 32,
196
+ 32, 32, 32, 32, 32, 32, 32, 32,
197
+ 35, 35, 35, 35, 35, 35, 35, 35,
198
+ 35, 35, 32, 32, 32, 32, 32, 32,
199
+ 32, 35, 35, 35, 35, 35, 35, 35,
200
+ 35, 35, 35, 35, 35, 35, 35, 35,
201
+ 35, 35, 35, 35, 35, 35, 35, 35,
202
+ 35, 35, 35, 32, 32, 32, 32, 35,
203
+ 32, 35, 35, 35, 35, 35, 35, 35,
204
+ 35, 35, 35, 35, 35, 35, 35, 35,
205
+ 35, 35, 35, 35, 35, 35, 35, 35,
206
+ 35, 35, 35, 32, 37, 36, 39, 38,
207
+ 38, 38, 38, 38, 38, 38, 38, 38,
208
+ 38, 38, 38, 38, 38, 38, 38, 38,
209
+ 38, 38, 38, 38, 38, 38, 38, 38,
210
+ 38, 38, 38, 38, 38, 38, 38, 38,
211
+ 38, 38, 38, 38, 38, 38, 38, 38,
212
+ 38, 38, 38, 38, 38, 38, 38, 38,
213
+ 38, 38, 38, 38, 38, 38, 38, 38,
214
+ 40, 38, 41, 36, 40, 38, 42, 8,
215
+ 8, 8, 8, 8, 8, 8, 8, 8,
216
+ 8, 8, 8, 8, 8, 8, 8, 8,
217
+ 8, 8, 8, 8, 8, 42, 8, 43,
218
+ 8, 8, 8, 8, 8, 8, 8, 8,
219
+ 8, 8, 8, 8, 8, 44, 44, 44,
220
+ 44, 44, 44, 44, 44, 44, 44, 8,
221
+ 8, 8, 8, 8, 8, 8, 44, 44,
222
+ 44, 44, 44, 44, 44, 44, 44, 44,
223
+ 44, 44, 44, 44, 44, 44, 44, 44,
224
+ 44, 44, 44, 44, 44, 44, 44, 44,
225
+ 8, 8, 8, 8, 44, 8, 44, 44,
226
+ 44, 44, 44, 44, 44, 44, 44, 44,
227
+ 44, 44, 44, 44, 44, 44, 44, 44,
228
+ 44, 44, 44, 44, 44, 44, 44, 44,
229
+ 8, 42, 12, 12, 12, 12, 12, 12,
230
+ 12, 12, 12, 12, 12, 12, 12, 12,
231
+ 12, 12, 12, 12, 12, 12, 12, 12,
232
+ 42, 12, 43, 12, 12, 12, 12, 12,
233
+ 12, 12, 12, 12, 12, 12, 12, 12,
234
+ 45, 45, 45, 45, 45, 45, 45, 45,
235
+ 45, 45, 12, 12, 12, 12, 12, 12,
236
+ 12, 45, 45, 45, 45, 45, 45, 45,
237
+ 45, 45, 45, 45, 45, 45, 45, 45,
238
+ 45, 45, 45, 45, 45, 45, 45, 45,
239
+ 45, 45, 45, 12, 12, 12, 12, 45,
240
+ 12, 45, 45, 45, 45, 45, 45, 45,
241
+ 45, 45, 45, 45, 45, 45, 45, 45,
242
+ 45, 45, 45, 45, 45, 45, 45, 45,
243
+ 45, 45, 45, 12, 47, 46, 46, 46,
244
+ 46, 46, 46, 46, 46, 46, 46, 46,
245
+ 46, 46, 46, 46, 46, 46, 46, 46,
246
+ 46, 46, 46, 46, 46, 46, 46, 46,
247
+ 46, 46, 46, 46, 46, 46, 46, 46,
248
+ 46, 46, 46, 46, 46, 46, 46, 46,
249
+ 46, 46, 46, 46, 46, 46, 46, 46,
250
+ 46, 46, 46, 46, 46, 46, 48, 46,
251
+ 49, 17, 48, 46, 50, 0, 0, 0,
252
+ 0, 0, 0, 0, 0, 0, 0, 0,
253
+ 0, 0, 0, 0, 0, 0, 0, 0,
254
+ 0, 0, 0, 0, 0, 0, 0, 0,
255
+ 0, 0, 0, 0, 0, 0, 0, 0,
256
+ 0, 0, 51, 51, 51, 51, 51, 51,
257
+ 51, 51, 51, 51, 0, 0, 0, 0,
258
+ 0, 0, 0, 51, 51, 51, 51, 51,
259
+ 51, 51, 51, 51, 51, 51, 51, 51,
260
+ 51, 51, 51, 51, 51, 51, 51, 51,
261
+ 51, 51, 51, 51, 51, 0, 0, 0,
262
+ 0, 51, 0, 51, 51, 51, 51, 51,
263
+ 51, 51, 51, 51, 51, 51, 51, 51,
264
+ 51, 51, 51, 51, 51, 51, 51, 51,
265
+ 51, 51, 51, 51, 51, 0, 50, 0,
266
+ 0, 0, 0, 0, 0, 0, 0, 0,
267
+ 0, 0, 0, 0, 0, 0, 0, 0,
268
+ 0, 0, 0, 0, 0, 0, 0, 0,
269
+ 0, 0, 0, 0, 0, 0, 0, 0,
270
+ 0, 0, 0, 0, 52, 52, 52, 52,
271
+ 52, 52, 52, 52, 52, 52, 53, 0,
272
+ 0, 0, 0, 0, 0, 52, 52, 52,
273
+ 52, 52, 52, 52, 52, 52, 52, 52,
274
+ 52, 52, 52, 52, 52, 52, 52, 52,
275
+ 52, 52, 52, 52, 52, 52, 52, 0,
276
+ 0, 0, 0, 52, 0, 52, 52, 52,
277
+ 52, 52, 52, 52, 52, 52, 52, 52,
278
+ 52, 52, 52, 52, 52, 52, 52, 52,
279
+ 52, 52, 52, 52, 52, 52, 52, 0,
280
+ 54, 54, 54, 54, 54, 54, 54, 54,
281
+ 54, 54, 0, 0, 0, 0, 0, 0,
282
+ 0, 54, 54, 54, 54, 54, 54, 54,
283
+ 54, 54, 54, 54, 54, 54, 54, 54,
284
+ 54, 54, 54, 54, 54, 54, 54, 54,
285
+ 54, 54, 54, 0, 0, 0, 0, 54,
286
+ 0, 54, 54, 54, 54, 54, 54, 54,
287
+ 54, 54, 54, 54, 54, 54, 54, 54,
288
+ 54, 54, 54, 54, 54, 54, 54, 54,
289
+ 54, 54, 54, 0, 55, 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, 55, 0, 0, 0, 0,
293
+ 0, 0, 0, 56, 0, 0, 0, 0,
294
+ 0, 0, 0, 57, 57, 57, 57, 57,
295
+ 57, 57, 57, 57, 57, 0, 0, 0,
296
+ 0, 0, 0, 0, 57, 57, 57, 57,
297
+ 57, 57, 57, 57, 57, 57, 57, 57,
298
+ 57, 57, 57, 57, 57, 57, 57, 57,
299
+ 57, 57, 57, 57, 57, 57, 0, 0,
300
+ 0, 0, 57, 0, 57, 57, 57, 57,
301
+ 57, 57, 57, 57, 57, 57, 57, 57,
302
+ 57, 57, 57, 57, 57, 57, 57, 57,
303
+ 57, 57, 57, 57, 57, 57, 0, 58,
304
+ 6, 6, 6, 6, 6, 6, 6, 6,
305
+ 6, 6, 6, 6, 6, 6, 6, 6,
306
+ 6, 6, 6, 6, 6, 6, 58, 6,
307
+ 6, 6, 6, 6, 6, 6, 59, 6,
308
+ 60, 8, 8, 8, 8, 8, 8, 8,
309
+ 8, 8, 8, 8, 8, 8, 8, 8,
310
+ 8, 8, 8, 8, 8, 8, 8, 60,
311
+ 8, 61, 8, 8, 8, 8, 8, 8,
312
+ 8, 8, 8, 8, 8, 8, 8, 62,
313
+ 62, 62, 62, 62, 62, 62, 62, 62,
314
+ 62, 8, 8, 8, 8, 8, 8, 8,
315
+ 62, 62, 62, 62, 62, 62, 62, 62,
316
+ 62, 62, 62, 62, 62, 62, 62, 62,
317
+ 62, 62, 62, 62, 62, 62, 62, 62,
318
+ 62, 62, 8, 8, 8, 8, 62, 8,
319
+ 62, 62, 62, 62, 62, 62, 62, 62,
320
+ 62, 62, 62, 62, 62, 62, 62, 62,
321
+ 62, 62, 62, 62, 62, 62, 62, 62,
322
+ 62, 62, 8, 60, 12, 12, 12, 12,
323
+ 12, 12, 12, 12, 12, 12, 12, 12,
324
+ 12, 12, 12, 12, 12, 12, 12, 12,
325
+ 12, 12, 60, 12, 61, 12, 12, 12,
326
+ 12, 12, 12, 12, 12, 12, 12, 12,
327
+ 12, 12, 63, 63, 63, 63, 63, 63,
328
+ 63, 63, 63, 63, 12, 12, 12, 12,
329
+ 12, 12, 12, 63, 63, 63, 63, 63,
330
+ 63, 63, 63, 63, 63, 63, 63, 63,
331
+ 63, 63, 63, 63, 63, 63, 63, 63,
332
+ 63, 63, 63, 63, 63, 12, 12, 12,
333
+ 12, 63, 12, 63, 63, 63, 63, 63,
334
+ 63, 63, 63, 63, 63, 63, 63, 63,
335
+ 63, 63, 63, 63, 63, 63, 63, 63,
336
+ 63, 63, 63, 63, 63, 12, 65, 64,
337
+ 64, 64, 64, 64, 64, 64, 64, 64,
338
+ 64, 64, 64, 64, 64, 64, 64, 64,
339
+ 64, 64, 64, 64, 64, 64, 64, 64,
340
+ 64, 64, 64, 64, 64, 64, 64, 64,
341
+ 64, 64, 64, 64, 64, 64, 64, 64,
342
+ 64, 64, 64, 64, 64, 64, 64, 64,
343
+ 64, 64, 64, 64, 64, 64, 64, 64,
344
+ 66, 64, 67, 17, 17, 17, 17, 17,
345
+ 17, 17, 17, 17, 17, 17, 17, 17,
346
+ 17, 17, 17, 17, 17, 17, 17, 17,
347
+ 17, 67, 17, 17, 17, 17, 17, 17,
348
+ 17, 17, 68, 17, 17, 69, 17, 70,
349
+ 6, 6, 6, 6, 6, 6, 6, 6,
350
+ 6, 6, 6, 6, 6, 6, 6, 6,
351
+ 6, 6, 6, 6, 6, 6, 70, 6,
352
+ 6, 6, 6, 6, 6, 6, 6, 6,
353
+ 6, 6, 71, 6, 71, 8, 8, 8,
354
+ 8, 8, 8, 8, 8, 8, 8, 8,
355
+ 8, 8, 8, 8, 8, 8, 8, 8,
356
+ 8, 8, 8, 71, 8, 61, 8, 8,
357
+ 8, 8, 8, 8, 8, 8, 8, 8,
358
+ 8, 8, 8, 62, 62, 62, 62, 62,
359
+ 62, 62, 62, 62, 62, 8, 8, 8,
360
+ 8, 8, 8, 8, 62, 62, 62, 62,
361
+ 62, 62, 62, 62, 62, 62, 62, 62,
362
+ 62, 62, 62, 62, 62, 62, 62, 62,
363
+ 62, 62, 62, 62, 62, 62, 8, 8,
364
+ 8, 8, 62, 8, 62, 62, 62, 62,
365
+ 62, 62, 62, 62, 62, 62, 62, 62,
366
+ 62, 62, 62, 62, 62, 62, 62, 62,
367
+ 62, 62, 62, 62, 62, 62, 8, 72,
368
+ 0, 0, 0, 0, 0, 0, 0, 0,
369
+ 0, 0, 0, 0, 0, 0, 0, 0,
370
+ 0, 0, 0, 0, 0, 0, 72, 0,
371
+ 0, 0, 0, 0, 0, 0, 73, 74,
372
+ 0, 0, 75, 0, 0, 0, 76, 76,
373
+ 76, 76, 76, 76, 76, 76, 76, 76,
374
+ 77, 0, 0, 0, 0, 0, 0, 76,
375
+ 76, 76, 76, 76, 76, 76, 76, 76,
376
+ 76, 76, 76, 76, 76, 76, 76, 76,
377
+ 76, 76, 76, 76, 76, 76, 76, 76,
378
+ 76, 0, 0, 0, 0, 76, 0, 76,
379
+ 76, 76, 76, 76, 76, 76, 76, 76,
380
+ 76, 76, 76, 76, 76, 76, 76, 76,
381
+ 76, 76, 76, 76, 76, 76, 76, 76,
382
+ 76, 0, 70, 6, 6, 6, 6, 6,
383
+ 6, 6, 6, 6, 6, 6, 6, 6,
384
+ 6, 6, 6, 6, 6, 6, 6, 6,
385
+ 6, 70, 6, 6, 6, 6, 6, 6,
386
+ 6, 6, 78, 6, 6, 71, 6, 66,
387
+ 64, 72, 0, 0, 0, 0, 0, 0,
388
+ 0, 0, 0, 0, 0, 0, 0, 0,
389
+ 0, 0, 0, 0, 0, 0, 0, 0,
390
+ 72, 0, 0, 0, 0, 0, 0, 0,
391
+ 0, 74, 0, 0, 75, 0, 0, 0,
392
+ 79, 79, 79, 79, 79, 79, 79, 79,
393
+ 79, 79, 0, 0, 0, 0, 0, 0,
394
+ 0, 79, 79, 79, 79, 79, 79, 79,
395
+ 79, 79, 79, 79, 79, 79, 79, 79,
396
+ 79, 79, 79, 79, 79, 79, 79, 79,
397
+ 79, 79, 79, 0, 0, 0, 0, 79,
398
+ 0, 79, 79, 79, 79, 79, 79, 79,
399
+ 79, 79, 79, 79, 79, 79, 79, 79,
400
+ 79, 79, 79, 79, 79, 79, 79, 79,
401
+ 79, 79, 79, 0, 6, 6, 6, 6,
402
+ 6, 0
403
+ ]
404
+
405
+ class << self
406
+ attr_accessor :_bel_trans_targs
407
+ private :_bel_trans_targs, :_bel_trans_targs=
408
+ end
409
+ self._bel_trans_targs = [
410
+ 0, 2, 3, 4, 2, 3, 0, 4,
411
+ 0, 5, 6, 10, 0, 14, 6, 7,
412
+ 13, 0, 8, 12, 9, 8, 9, 8,
413
+ 11, 12, 9, 10, 5, 12, 41, 14,
414
+ 0, 16, 42, 16, 0, 18, 18, 19,
415
+ 20, 43, 22, 23, 27, 26, 23, 24,
416
+ 25, 44, 44, 26, 27, 22, 29, 30,
417
+ 31, 29, 30, 31, 32, 33, 37, 40,
418
+ 33, 34, 39, 35, 45, 36, 35, 36,
419
+ 35, 38, 45, 36, 37, 32, 45, 40
420
+ ]
421
+
422
+ class << self
423
+ attr_accessor :_bel_trans_actions
424
+ private :_bel_trans_actions, :_bel_trans_actions=
425
+ end
426
+ self._bel_trans_actions = [
427
+ 1, 2, 3, 4, 5, 0, 0, 6,
428
+ 7, 0, 8, 9, 10, 11, 13, 13,
429
+ 13, 12, 14, 14, 14, 0, 0, 15,
430
+ 16, 15, 15, 5, 17, 0, 18, 19,
431
+ 20, 11, 21, 19, 22, 8, 13, 13,
432
+ 13, 23, 0, 8, 11, 11, 13, 13,
433
+ 13, 24, 25, 19, 19, 17, 26, 3,
434
+ 4, 5, 0, 6, 0, 8, 9, 11,
435
+ 13, 13, 13, 14, 27, 14, 0, 0,
436
+ 15, 16, 28, 15, 5, 17, 29, 19
437
+ ]
438
+
439
+ class << self
440
+ attr_accessor :_bel_eof_actions
441
+ private :_bel_eof_actions, :_bel_eof_actions=
442
+ end
443
+ self._bel_eof_actions = [
444
+ 0, 1, 1, 0, 7, 10, 12, 12,
445
+ 0, 7, 1, 0, 0, 12, 1, 20,
446
+ 20, 22, 22, 22, 22, 7, 10, 12,
447
+ 12, 12, 1, 1, 1, 1, 0, 7,
448
+ 10, 12, 12, 0, 7, 1, 0, 12,
449
+ 1, 0, 0, 0, 0, 0
450
+ ]
451
+
452
+ class << self
453
+ attr_accessor :bel_start
454
+ end
455
+ self.bel_start = 1;
456
+ class << self
457
+ attr_accessor :bel_first_final
458
+ end
459
+ self.bel_first_final = 41;
460
+ class << self
461
+ attr_accessor :bel_error
462
+ end
463
+ self.bel_error = 0;
464
+
465
+ class << self
466
+ attr_accessor :bel_en_ident
467
+ end
468
+ self.bel_en_ident = 15;
469
+ class << self
470
+ attr_accessor :bel_en_string
471
+ end
472
+ self.bel_en_string = 17;
473
+ class << self
474
+ attr_accessor :bel_en_bel_parameter
475
+ end
476
+ self.bel_en_bel_parameter = 21;
477
+ class << self
478
+ attr_accessor :bel_en_inner_term
479
+ end
480
+ self.bel_en_inner_term = 28;
481
+ class << self
482
+ attr_accessor :bel_en_term
483
+ end
484
+ self.bel_en_term = 1;
485
+
486
+
487
+ begin
488
+ p ||= 0
489
+ pe ||= data.length
490
+ cs = bel_start
491
+ top = 0
492
+ end
493
+
494
+ begin
495
+ testEof = false
496
+ _slen, _trans, _keys, _inds, _acts, _nacts = nil
497
+ _goto_level = 0
498
+ _resume = 10
499
+ _eof_trans = 15
500
+ _again = 20
501
+ _test_eof = 30
502
+ _out = 40
503
+ while true
504
+ if _goto_level <= 0
505
+ if p == pe
506
+ _goto_level = _test_eof
507
+ next
508
+ end
509
+ if cs == 0
510
+ _goto_level = _out
511
+ next
512
+ end
513
+ end
514
+ if _goto_level <= _resume
515
+ _keys = cs << 1
516
+ _inds = _bel_index_offsets[cs]
517
+ _slen = _bel_key_spans[cs]
518
+ _wide = data[p].ord
519
+ _trans = if ( _slen > 0 &&
520
+ _bel_trans_keys[_keys] <= _wide &&
521
+ _wide <= _bel_trans_keys[_keys + 1]
522
+ ) then
523
+ _bel_indicies[ _inds + _wide - _bel_trans_keys[_keys] ]
524
+ else
525
+ _bel_indicies[ _inds + _slen ]
526
+ end
527
+ cs = _bel_trans_targs[_trans]
528
+ if _bel_trans_actions[_trans] != 0
529
+ case _bel_trans_actions[_trans]
530
+ when 19 then
531
+ begin
532
+
533
+ (@buffers[:ident] ||= []) << data[p].ord
534
+ end
535
+ when 1 then
536
+ begin
537
+
538
+ unless @buffers[:ident].is_a?(::AST::Node)
539
+ @buffers[:ident] ||= []
540
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
541
+ end
542
+ end
543
+ when 13 then
544
+ begin
545
+
546
+ (@buffers[:string] ||= []) << data[p].ord
547
+ end
548
+ when 12 then
549
+ begin
550
+
551
+ @buffers[:string] ||= []
552
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
553
+ end
554
+ when 6 then
555
+ begin
556
+
557
+ fx = @buffers[:function]
558
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
559
+ end
560
+ when 29 then
561
+ begin
562
+
563
+ inner_term = @buffers[:term_stack].pop
564
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
565
+ begin
566
+ top -= 1
567
+ cs = stack[top]
568
+ _goto_level = _again
569
+ next
570
+ end
571
+
572
+ end
573
+ when 18 then
574
+ begin
575
+
576
+ yield @buffers[:term_stack][-1]
577
+ end
578
+ when 11 then
579
+ begin
580
+
581
+ @buffers[:ident] = []
582
+ end
583
+ begin
584
+
585
+ (@buffers[:ident] ||= []) << data[p].ord
586
+ end
587
+ when 5 then
588
+ begin
589
+
590
+ (@buffers[:ident] ||= []) << data[p].ord
591
+ end
592
+ begin
593
+
594
+ @buffers[:function] << data[p].ord
595
+ end
596
+ when 21 then
597
+ begin
598
+
599
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
600
+ end
601
+ begin
602
+
603
+ yield @buffers[:ident]
604
+ end
605
+ when 17 then
606
+ begin
607
+
608
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
609
+ end
610
+ begin
611
+
612
+ @buffers[:parameter] = parameter(prefix(@buffers[:ident]))
613
+ end
614
+ when 3 then
615
+ begin
616
+
617
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
618
+ end
619
+ begin
620
+
621
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
622
+ end
623
+ when 16 then
624
+ begin
625
+
626
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
627
+ end
628
+ begin
629
+
630
+ p -= @buffers[:function].length + 1
631
+ begin
632
+ stack[top] = cs
633
+ top+= 1
634
+ cs = 28
635
+ _goto_level = _again
636
+ next
637
+ end
638
+
639
+ end
640
+ when 20 then
641
+ begin
642
+
643
+ unless @buffers[:ident].is_a?(::AST::Node)
644
+ @buffers[:ident] ||= []
645
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
646
+ end
647
+ end
648
+ begin
649
+
650
+ @buffers[:ident] ||= []
651
+ yield @buffers[:ident]
652
+ end
653
+ when 7 then
654
+ begin
655
+
656
+ unless @buffers[:ident].is_a?(::AST::Node)
657
+ @buffers[:ident] ||= []
658
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
659
+ end
660
+ end
661
+ begin
662
+
663
+ @buffers[:string] ||= []
664
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
665
+ end
666
+ when 8 then
667
+ begin
668
+
669
+ @buffers[:string] = []
670
+ end
671
+ begin
672
+
673
+ (@buffers[:string] ||= []) << data[p].ord
674
+ end
675
+ when 23 then
676
+ begin
677
+
678
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
679
+ end
680
+ begin
681
+
682
+ yield @buffers[:string]
683
+ end
684
+ when 10 then
685
+ begin
686
+
687
+ @buffers[:string] ||= []
688
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
689
+ end
690
+ begin
691
+
692
+ unless @buffers[:ident].is_a?(::AST::Node)
693
+ @buffers[:ident] ||= []
694
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
695
+ end
696
+ end
697
+ when 22 then
698
+ begin
699
+
700
+ @buffers[:string] ||= []
701
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
702
+ end
703
+ begin
704
+
705
+ @buffers[:string] ||= []
706
+ yield @buffers[:string]
707
+ end
708
+ when 25 then
709
+ begin
710
+
711
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
712
+ end
713
+ begin
714
+
715
+ @buffers[:parameter] ||= parameter(prefix(nil))
716
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
717
+ end
718
+ begin
719
+
720
+ yield @buffers[:parameter]
721
+ end
722
+ when 15 then
723
+ begin
724
+
725
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
726
+ end
727
+ begin
728
+
729
+ @buffers[:parameter] ||= parameter(prefix(nil))
730
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
731
+ end
732
+ begin
733
+
734
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
735
+ @buffers[:parameter] = nil
736
+ end
737
+ when 4 then
738
+ begin
739
+
740
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
741
+ end
742
+ begin
743
+
744
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
745
+ end
746
+ begin
747
+
748
+ fx = @buffers[:function]
749
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
750
+ end
751
+ when 24 then
752
+ begin
753
+
754
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
755
+ end
756
+ begin
757
+
758
+ @buffers[:parameter] ||= parameter(prefix(nil))
759
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
760
+ end
761
+ begin
762
+
763
+ yield @buffers[:parameter]
764
+ end
765
+ when 14 then
766
+ begin
767
+
768
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
769
+ end
770
+ begin
771
+
772
+ @buffers[:parameter] ||= parameter(prefix(nil))
773
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
774
+ end
775
+ begin
776
+
777
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
778
+ @buffers[:parameter] = nil
779
+ end
780
+ when 9 then
781
+ begin
782
+
783
+ @buffers[:ident] = []
784
+ end
785
+ begin
786
+
787
+ (@buffers[:ident] ||= []) << data[p].ord
788
+ end
789
+ begin
790
+
791
+ @buffers[:function] = []
792
+ end
793
+ begin
794
+
795
+ @buffers[:function] << data[p].ord
796
+ end
797
+ when 28 then
798
+ begin
799
+
800
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
801
+ end
802
+ begin
803
+
804
+ @buffers[:parameter] ||= parameter(prefix(nil))
805
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
806
+ end
807
+ begin
808
+
809
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
810
+ @buffers[:parameter] = nil
811
+ end
812
+ begin
813
+
814
+ inner_term = @buffers[:term_stack].pop
815
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
816
+ begin
817
+ top -= 1
818
+ cs = stack[top]
819
+ _goto_level = _again
820
+ next
821
+ end
822
+
823
+ end
824
+ when 27 then
825
+ begin
826
+
827
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
828
+ end
829
+ begin
830
+
831
+ @buffers[:parameter] ||= parameter(prefix(nil))
832
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
833
+ end
834
+ begin
835
+
836
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
837
+ @buffers[:parameter] = nil
838
+ end
839
+ begin
840
+
841
+ inner_term = @buffers[:term_stack].pop
842
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
843
+ begin
844
+ top -= 1
845
+ cs = stack[top]
846
+ _goto_level = _again
847
+ next
848
+ end
849
+
850
+ end
851
+ when 2 then
852
+ begin
853
+
854
+ @buffers[:term_stack] = [ term() ]
855
+ end
856
+ begin
857
+
858
+ @buffers[:function] = []
859
+ end
860
+ begin
861
+
862
+ @buffers[:ident] = []
863
+ end
864
+ begin
865
+
866
+ (@buffers[:ident] ||= []) << data[p].ord
867
+ end
868
+ begin
869
+
870
+ @buffers[:function] << data[p].ord
871
+ end
872
+ when 26 then
873
+ begin
874
+
875
+ @buffers[:term_stack] << term()
876
+ end
877
+ begin
878
+
879
+ @buffers[:function] = []
880
+ end
881
+ begin
882
+
883
+ @buffers[:ident] = []
884
+ end
885
+ begin
886
+
887
+ (@buffers[:ident] ||= []) << data[p].ord
888
+ end
889
+ begin
890
+
891
+ @buffers[:function] << data[p].ord
892
+ end
893
+ end
894
+ end
895
+ end
896
+ if _goto_level <= _again
897
+ if cs == 0
898
+ _goto_level = _out
899
+ next
900
+ end
901
+ p += 1
902
+ if p != pe
903
+ _goto_level = _resume
904
+ next
905
+ end
906
+ end
907
+ if _goto_level <= _test_eof
908
+ if p == eof
909
+ case _bel_eof_actions[cs]
910
+ when 1 then
911
+ begin
912
+
913
+ unless @buffers[:ident].is_a?(::AST::Node)
914
+ @buffers[:ident] ||= []
915
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
916
+ end
917
+ end
918
+ when 12 then
919
+ begin
920
+
921
+ @buffers[:string] ||= []
922
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
923
+ end
924
+ when 20 then
925
+ begin
926
+
927
+ unless @buffers[:ident].is_a?(::AST::Node)
928
+ @buffers[:ident] ||= []
929
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
930
+ end
931
+ end
932
+ begin
933
+
934
+ @buffers[:ident] ||= []
935
+ yield @buffers[:ident]
936
+ end
937
+ when 7 then
938
+ begin
939
+
940
+ unless @buffers[:ident].is_a?(::AST::Node)
941
+ @buffers[:ident] ||= []
942
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
943
+ end
944
+ end
945
+ begin
946
+
947
+ @buffers[:string] ||= []
948
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
949
+ end
950
+ when 10 then
951
+ begin
952
+
953
+ @buffers[:string] ||= []
954
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
955
+ end
956
+ begin
957
+
958
+ unless @buffers[:ident].is_a?(::AST::Node)
959
+ @buffers[:ident] ||= []
960
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
961
+ end
962
+ end
963
+ when 22 then
964
+ begin
965
+
966
+ @buffers[:string] ||= []
967
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
968
+ end
969
+ begin
970
+
971
+ @buffers[:string] ||= []
972
+ yield @buffers[:string]
973
+ end
974
+ end
975
+ end
976
+
977
+ end
978
+ if _goto_level <= _out
979
+ break
980
+ end
981
+ end
982
+ end
983
+
984
+ class << self
985
+ attr_accessor :_bel_trans_keys
986
+ private :_bel_trans_keys, :_bel_trans_keys=
987
+ end
988
+ self._bel_trans_keys = [
989
+ 0, 0, 48, 122, 9, 122,
990
+ 9, 40, 9, 122, 9,
991
+ 122, 34, 92, 9, 44,
992
+ 9, 44, 9, 122, 9, 122,
993
+ 9, 44, 10, 10, 92,
994
+ 92, 9, 122, 48, 122,
995
+ 10, 122, 34, 34, 34, 92,
996
+ 10, 10, 92, 92, 9,
997
+ 122, 9, 122, 34, 92,
998
+ 10, 10, 92, 92, 10, 122,
999
+ 10, 122, 48, 122, 9,
1000
+ 122, 9, 40, 9, 122,
1001
+ 9, 122, 34, 92, 9, 44,
1002
+ 9, 44, 9, 122, 9,
1003
+ 122, 9, 44, 92, 92,
1004
+ 9, 122, 0, 0, 0, 0,
1005
+ 0, 0, 0, 0, 0,
1006
+ 0, 0
1007
+ ]
1008
+
1009
+ class << self
1010
+ attr_accessor :_bel_key_spans
1011
+ private :_bel_key_spans, :_bel_key_spans=
1012
+ end
1013
+ self._bel_key_spans = [
1014
+ 0, 75, 114, 32, 114, 114, 59, 36,
1015
+ 36, 114, 114, 36, 1, 1, 114, 75,
1016
+ 113, 1, 59, 1, 1, 114, 114, 59,
1017
+ 1, 1, 113, 113, 75, 114, 32, 114,
1018
+ 114, 59, 36, 36, 114, 114, 36, 1,
1019
+ 114, 0, 0, 0, 0, 0
1020
+ ]
1021
+
1022
+ class << self
1023
+ attr_accessor :_bel_index_offsets
1024
+ private :_bel_index_offsets, :_bel_index_offsets=
1025
+ end
1026
+ self._bel_index_offsets = [
1027
+ 0, 0, 76, 191, 224, 339, 454, 514,
1028
+ 551, 588, 703, 818, 855, 857, 859, 974,
1029
+ 1050, 1164, 1166, 1226, 1228, 1230, 1345, 1460,
1030
+ 1520, 1522, 1524, 1638, 1752, 1828, 1943, 1976,
1031
+ 2091, 2206, 2266, 2303, 2340, 2455, 2570, 2607,
1032
+ 2609, 2724, 2725, 2726, 2727, 2728
1033
+ ]
1034
+
1035
+ class << self
1036
+ attr_accessor :_bel_indicies
1037
+ private :_bel_indicies, :_bel_indicies=
1038
+ end
1039
+ self._bel_indicies = [
1040
+ 1, 1, 1, 1, 1, 1, 1, 1,
1041
+ 1, 1, 0, 0, 0, 0, 0, 0,
1042
+ 0, 1, 1, 1, 1, 1, 1, 1,
1043
+ 1, 1, 1, 1, 1, 1, 1, 1,
1044
+ 1, 1, 1, 1, 1, 1, 1, 1,
1045
+ 1, 1, 1, 0, 0, 0, 0, 1,
1046
+ 0, 1, 1, 1, 1, 1, 1, 1,
1047
+ 1, 1, 1, 1, 1, 1, 1, 1,
1048
+ 1, 1, 1, 1, 1, 1, 1, 1,
1049
+ 1, 1, 1, 0, 2, 0, 0, 0,
1050
+ 0, 0, 0, 0, 0, 0, 0, 0,
1051
+ 0, 0, 0, 0, 0, 0, 0, 0,
1052
+ 0, 0, 0, 2, 0, 0, 0, 0,
1053
+ 0, 0, 0, 3, 0, 0, 0, 0,
1054
+ 0, 0, 0, 4, 4, 4, 4, 4,
1055
+ 4, 4, 4, 4, 4, 0, 0, 0,
1056
+ 0, 0, 0, 0, 4, 4, 4, 4,
1057
+ 4, 4, 4, 4, 4, 4, 4, 4,
1058
+ 4, 4, 4, 4, 4, 4, 4, 4,
1059
+ 4, 4, 4, 4, 4, 4, 0, 0,
1060
+ 0, 0, 4, 0, 4, 4, 4, 4,
1061
+ 4, 4, 4, 4, 4, 4, 4, 4,
1062
+ 4, 4, 4, 4, 4, 4, 4, 4,
1063
+ 4, 4, 4, 4, 4, 4, 0, 5,
1064
+ 6, 6, 6, 6, 6, 6, 6, 6,
1065
+ 6, 6, 6, 6, 6, 6, 6, 6,
1066
+ 6, 6, 6, 6, 6, 6, 5, 6,
1067
+ 6, 6, 6, 6, 6, 6, 7, 6,
1068
+ 9, 8, 8, 8, 8, 8, 8, 8,
1069
+ 8, 8, 8, 8, 8, 8, 8, 8,
1070
+ 8, 8, 8, 8, 8, 8, 8, 9,
1071
+ 8, 10, 8, 8, 8, 8, 8, 8,
1072
+ 8, 8, 8, 8, 8, 8, 8, 11,
1073
+ 11, 11, 11, 11, 11, 11, 11, 11,
1074
+ 11, 8, 8, 8, 8, 8, 8, 8,
1075
+ 11, 11, 11, 11, 11, 11, 11, 11,
1076
+ 11, 11, 11, 11, 11, 11, 11, 11,
1077
+ 11, 11, 11, 11, 11, 11, 11, 11,
1078
+ 11, 11, 8, 8, 8, 8, 11, 8,
1079
+ 11, 11, 11, 11, 11, 11, 11, 11,
1080
+ 11, 11, 11, 11, 11, 11, 11, 11,
1081
+ 11, 11, 11, 11, 11, 11, 11, 11,
1082
+ 11, 11, 8, 9, 12, 12, 12, 12,
1083
+ 12, 12, 12, 12, 12, 12, 12, 12,
1084
+ 12, 12, 12, 12, 12, 12, 12, 12,
1085
+ 12, 12, 9, 12, 10, 12, 12, 12,
1086
+ 12, 12, 12, 12, 12, 12, 12, 12,
1087
+ 12, 12, 13, 13, 13, 13, 13, 13,
1088
+ 13, 13, 13, 13, 12, 12, 12, 12,
1089
+ 12, 12, 12, 13, 13, 13, 13, 13,
1090
+ 13, 13, 13, 13, 13, 13, 13, 13,
1091
+ 13, 13, 13, 13, 13, 13, 13, 13,
1092
+ 13, 13, 13, 13, 13, 12, 12, 12,
1093
+ 12, 13, 12, 13, 13, 13, 13, 13,
1094
+ 13, 13, 13, 13, 13, 13, 13, 13,
1095
+ 13, 13, 13, 13, 13, 13, 13, 13,
1096
+ 13, 13, 13, 13, 13, 12, 15, 14,
1097
+ 14, 14, 14, 14, 14, 14, 14, 14,
1098
+ 14, 14, 14, 14, 14, 14, 14, 14,
1099
+ 14, 14, 14, 14, 14, 14, 14, 14,
1100
+ 14, 14, 14, 14, 14, 14, 14, 14,
1101
+ 14, 14, 14, 14, 14, 14, 14, 14,
1102
+ 14, 14, 14, 14, 14, 14, 14, 14,
1103
+ 14, 14, 14, 14, 14, 14, 14, 14,
1104
+ 16, 14, 18, 17, 17, 17, 17, 17,
1105
+ 17, 17, 17, 17, 17, 17, 17, 17,
1106
+ 17, 17, 17, 17, 17, 17, 17, 17,
1107
+ 17, 18, 17, 17, 17, 17, 17, 17,
1108
+ 17, 17, 19, 17, 17, 20, 17, 21,
1109
+ 6, 6, 6, 6, 6, 6, 6, 6,
1110
+ 6, 6, 6, 6, 6, 6, 6, 6,
1111
+ 6, 6, 6, 6, 6, 6, 21, 6,
1112
+ 6, 6, 6, 6, 6, 6, 6, 6,
1113
+ 6, 6, 22, 6, 22, 8, 8, 8,
1114
+ 8, 8, 8, 8, 8, 8, 8, 8,
1115
+ 8, 8, 8, 8, 8, 8, 8, 8,
1116
+ 8, 8, 8, 22, 8, 10, 8, 8,
1117
+ 8, 8, 8, 8, 8, 8, 8, 8,
1118
+ 8, 8, 8, 11, 11, 11, 11, 11,
1119
+ 11, 11, 11, 11, 11, 8, 8, 8,
1120
+ 8, 8, 8, 8, 11, 11, 11, 11,
1121
+ 11, 11, 11, 11, 11, 11, 11, 11,
1122
+ 11, 11, 11, 11, 11, 11, 11, 11,
1123
+ 11, 11, 11, 11, 11, 11, 8, 8,
1124
+ 8, 8, 11, 8, 11, 11, 11, 11,
1125
+ 11, 11, 11, 11, 11, 11, 11, 11,
1126
+ 11, 11, 11, 11, 11, 11, 11, 11,
1127
+ 11, 11, 11, 11, 11, 11, 8, 23,
1128
+ 0, 0, 0, 0, 0, 0, 0, 0,
1129
+ 0, 0, 0, 0, 0, 0, 0, 0,
1130
+ 0, 0, 0, 0, 0, 0, 23, 0,
1131
+ 0, 0, 0, 0, 0, 0, 24, 25,
1132
+ 0, 0, 26, 0, 0, 0, 27, 27,
1133
+ 27, 27, 27, 27, 27, 27, 27, 27,
1134
+ 28, 0, 0, 0, 0, 0, 0, 27,
1135
+ 27, 27, 27, 27, 27, 27, 27, 27,
1136
+ 27, 27, 27, 27, 27, 27, 27, 27,
1137
+ 27, 27, 27, 27, 27, 27, 27, 27,
1138
+ 27, 0, 0, 0, 0, 27, 0, 27,
1139
+ 27, 27, 27, 27, 27, 27, 27, 27,
1140
+ 27, 27, 27, 27, 27, 27, 27, 27,
1141
+ 27, 27, 27, 27, 27, 27, 27, 27,
1142
+ 27, 0, 21, 6, 6, 6, 6, 6,
1143
+ 6, 6, 6, 6, 6, 6, 6, 6,
1144
+ 6, 6, 6, 6, 6, 6, 6, 6,
1145
+ 6, 21, 6, 6, 6, 6, 6, 6,
1146
+ 6, 6, 29, 6, 6, 22, 6, 30,
1147
+ 6, 16, 14, 23, 0, 0, 0, 0,
1148
+ 0, 0, 0, 0, 0, 0, 0, 0,
1149
+ 0, 0, 0, 0, 0, 0, 0, 0,
1150
+ 0, 0, 23, 0, 0, 0, 0, 0,
1151
+ 0, 0, 0, 25, 0, 0, 26, 0,
1152
+ 0, 0, 31, 31, 31, 31, 31, 31,
1153
+ 31, 31, 31, 31, 0, 0, 0, 0,
1154
+ 0, 0, 0, 31, 31, 31, 31, 31,
1155
+ 31, 31, 31, 31, 31, 31, 31, 31,
1156
+ 31, 31, 31, 31, 31, 31, 31, 31,
1157
+ 31, 31, 31, 31, 31, 0, 0, 0,
1158
+ 0, 31, 0, 31, 31, 31, 31, 31,
1159
+ 31, 31, 31, 31, 31, 31, 31, 31,
1160
+ 31, 31, 31, 31, 31, 31, 31, 31,
1161
+ 31, 31, 31, 31, 31, 0, 33, 33,
1162
+ 33, 33, 33, 33, 33, 33, 33, 33,
1163
+ 32, 32, 32, 32, 32, 32, 32, 33,
1164
+ 33, 33, 33, 33, 33, 33, 33, 33,
1165
+ 33, 33, 33, 33, 33, 33, 33, 33,
1166
+ 33, 33, 33, 33, 33, 33, 33, 33,
1167
+ 33, 32, 32, 32, 32, 33, 32, 33,
1168
+ 33, 33, 33, 33, 33, 33, 33, 33,
1169
+ 33, 33, 33, 33, 33, 33, 33, 33,
1170
+ 33, 33, 33, 33, 33, 33, 33, 33,
1171
+ 33, 32, 34, 32, 32, 32, 32, 32,
1172
+ 32, 32, 32, 32, 32, 32, 32, 32,
1173
+ 32, 32, 32, 32, 32, 32, 32, 32,
1174
+ 32, 32, 32, 32, 32, 32, 32, 32,
1175
+ 32, 32, 32, 32, 32, 32, 32, 32,
1176
+ 35, 35, 35, 35, 35, 35, 35, 35,
1177
+ 35, 35, 32, 32, 32, 32, 32, 32,
1178
+ 32, 35, 35, 35, 35, 35, 35, 35,
1179
+ 35, 35, 35, 35, 35, 35, 35, 35,
1180
+ 35, 35, 35, 35, 35, 35, 35, 35,
1181
+ 35, 35, 35, 32, 32, 32, 32, 35,
1182
+ 32, 35, 35, 35, 35, 35, 35, 35,
1183
+ 35, 35, 35, 35, 35, 35, 35, 35,
1184
+ 35, 35, 35, 35, 35, 35, 35, 35,
1185
+ 35, 35, 35, 32, 37, 36, 39, 38,
1186
+ 38, 38, 38, 38, 38, 38, 38, 38,
1187
+ 38, 38, 38, 38, 38, 38, 38, 38,
1188
+ 38, 38, 38, 38, 38, 38, 38, 38,
1189
+ 38, 38, 38, 38, 38, 38, 38, 38,
1190
+ 38, 38, 38, 38, 38, 38, 38, 38,
1191
+ 38, 38, 38, 38, 38, 38, 38, 38,
1192
+ 38, 38, 38, 38, 38, 38, 38, 38,
1193
+ 40, 38, 41, 36, 40, 38, 42, 8,
1194
+ 8, 8, 8, 8, 8, 8, 8, 8,
1195
+ 8, 8, 8, 8, 8, 8, 8, 8,
1196
+ 8, 8, 8, 8, 8, 42, 8, 43,
1197
+ 8, 8, 8, 8, 8, 8, 8, 8,
1198
+ 8, 8, 8, 8, 8, 44, 44, 44,
1199
+ 44, 44, 44, 44, 44, 44, 44, 8,
1200
+ 8, 8, 8, 8, 8, 8, 44, 44,
1201
+ 44, 44, 44, 44, 44, 44, 44, 44,
1202
+ 44, 44, 44, 44, 44, 44, 44, 44,
1203
+ 44, 44, 44, 44, 44, 44, 44, 44,
1204
+ 8, 8, 8, 8, 44, 8, 44, 44,
1205
+ 44, 44, 44, 44, 44, 44, 44, 44,
1206
+ 44, 44, 44, 44, 44, 44, 44, 44,
1207
+ 44, 44, 44, 44, 44, 44, 44, 44,
1208
+ 8, 42, 12, 12, 12, 12, 12, 12,
1209
+ 12, 12, 12, 12, 12, 12, 12, 12,
1210
+ 12, 12, 12, 12, 12, 12, 12, 12,
1211
+ 42, 12, 43, 12, 12, 12, 12, 12,
1212
+ 12, 12, 12, 12, 12, 12, 12, 12,
1213
+ 45, 45, 45, 45, 45, 45, 45, 45,
1214
+ 45, 45, 12, 12, 12, 12, 12, 12,
1215
+ 12, 45, 45, 45, 45, 45, 45, 45,
1216
+ 45, 45, 45, 45, 45, 45, 45, 45,
1217
+ 45, 45, 45, 45, 45, 45, 45, 45,
1218
+ 45, 45, 45, 12, 12, 12, 12, 45,
1219
+ 12, 45, 45, 45, 45, 45, 45, 45,
1220
+ 45, 45, 45, 45, 45, 45, 45, 45,
1221
+ 45, 45, 45, 45, 45, 45, 45, 45,
1222
+ 45, 45, 45, 12, 47, 46, 46, 46,
1223
+ 46, 46, 46, 46, 46, 46, 46, 46,
1224
+ 46, 46, 46, 46, 46, 46, 46, 46,
1225
+ 46, 46, 46, 46, 46, 46, 46, 46,
1226
+ 46, 46, 46, 46, 46, 46, 46, 46,
1227
+ 46, 46, 46, 46, 46, 46, 46, 46,
1228
+ 46, 46, 46, 46, 46, 46, 46, 46,
1229
+ 46, 46, 46, 46, 46, 46, 48, 46,
1230
+ 49, 17, 48, 46, 50, 0, 0, 0,
1231
+ 0, 0, 0, 0, 0, 0, 0, 0,
1232
+ 0, 0, 0, 0, 0, 0, 0, 0,
1233
+ 0, 0, 0, 0, 0, 0, 0, 0,
1234
+ 0, 0, 0, 0, 0, 0, 0, 0,
1235
+ 0, 0, 51, 51, 51, 51, 51, 51,
1236
+ 51, 51, 51, 51, 0, 0, 0, 0,
1237
+ 0, 0, 0, 51, 51, 51, 51, 51,
1238
+ 51, 51, 51, 51, 51, 51, 51, 51,
1239
+ 51, 51, 51, 51, 51, 51, 51, 51,
1240
+ 51, 51, 51, 51, 51, 0, 0, 0,
1241
+ 0, 51, 0, 51, 51, 51, 51, 51,
1242
+ 51, 51, 51, 51, 51, 51, 51, 51,
1243
+ 51, 51, 51, 51, 51, 51, 51, 51,
1244
+ 51, 51, 51, 51, 51, 0, 50, 0,
1245
+ 0, 0, 0, 0, 0, 0, 0, 0,
1246
+ 0, 0, 0, 0, 0, 0, 0, 0,
1247
+ 0, 0, 0, 0, 0, 0, 0, 0,
1248
+ 0, 0, 0, 0, 0, 0, 0, 0,
1249
+ 0, 0, 0, 0, 52, 52, 52, 52,
1250
+ 52, 52, 52, 52, 52, 52, 53, 0,
1251
+ 0, 0, 0, 0, 0, 52, 52, 52,
1252
+ 52, 52, 52, 52, 52, 52, 52, 52,
1253
+ 52, 52, 52, 52, 52, 52, 52, 52,
1254
+ 52, 52, 52, 52, 52, 52, 52, 0,
1255
+ 0, 0, 0, 52, 0, 52, 52, 52,
1256
+ 52, 52, 52, 52, 52, 52, 52, 52,
1257
+ 52, 52, 52, 52, 52, 52, 52, 52,
1258
+ 52, 52, 52, 52, 52, 52, 52, 0,
1259
+ 54, 54, 54, 54, 54, 54, 54, 54,
1260
+ 54, 54, 0, 0, 0, 0, 0, 0,
1261
+ 0, 54, 54, 54, 54, 54, 54, 54,
1262
+ 54, 54, 54, 54, 54, 54, 54, 54,
1263
+ 54, 54, 54, 54, 54, 54, 54, 54,
1264
+ 54, 54, 54, 0, 0, 0, 0, 54,
1265
+ 0, 54, 54, 54, 54, 54, 54, 54,
1266
+ 54, 54, 54, 54, 54, 54, 54, 54,
1267
+ 54, 54, 54, 54, 54, 54, 54, 54,
1268
+ 54, 54, 54, 0, 55, 0, 0, 0,
1269
+ 0, 0, 0, 0, 0, 0, 0, 0,
1270
+ 0, 0, 0, 0, 0, 0, 0, 0,
1271
+ 0, 0, 0, 55, 0, 0, 0, 0,
1272
+ 0, 0, 0, 56, 0, 0, 0, 0,
1273
+ 0, 0, 0, 57, 57, 57, 57, 57,
1274
+ 57, 57, 57, 57, 57, 0, 0, 0,
1275
+ 0, 0, 0, 0, 57, 57, 57, 57,
1276
+ 57, 57, 57, 57, 57, 57, 57, 57,
1277
+ 57, 57, 57, 57, 57, 57, 57, 57,
1278
+ 57, 57, 57, 57, 57, 57, 0, 0,
1279
+ 0, 0, 57, 0, 57, 57, 57, 57,
1280
+ 57, 57, 57, 57, 57, 57, 57, 57,
1281
+ 57, 57, 57, 57, 57, 57, 57, 57,
1282
+ 57, 57, 57, 57, 57, 57, 0, 58,
1283
+ 6, 6, 6, 6, 6, 6, 6, 6,
1284
+ 6, 6, 6, 6, 6, 6, 6, 6,
1285
+ 6, 6, 6, 6, 6, 6, 58, 6,
1286
+ 6, 6, 6, 6, 6, 6, 59, 6,
1287
+ 60, 8, 8, 8, 8, 8, 8, 8,
1288
+ 8, 8, 8, 8, 8, 8, 8, 8,
1289
+ 8, 8, 8, 8, 8, 8, 8, 60,
1290
+ 8, 61, 8, 8, 8, 8, 8, 8,
1291
+ 8, 8, 8, 8, 8, 8, 8, 62,
1292
+ 62, 62, 62, 62, 62, 62, 62, 62,
1293
+ 62, 8, 8, 8, 8, 8, 8, 8,
1294
+ 62, 62, 62, 62, 62, 62, 62, 62,
1295
+ 62, 62, 62, 62, 62, 62, 62, 62,
1296
+ 62, 62, 62, 62, 62, 62, 62, 62,
1297
+ 62, 62, 8, 8, 8, 8, 62, 8,
1298
+ 62, 62, 62, 62, 62, 62, 62, 62,
1299
+ 62, 62, 62, 62, 62, 62, 62, 62,
1300
+ 62, 62, 62, 62, 62, 62, 62, 62,
1301
+ 62, 62, 8, 60, 12, 12, 12, 12,
1302
+ 12, 12, 12, 12, 12, 12, 12, 12,
1303
+ 12, 12, 12, 12, 12, 12, 12, 12,
1304
+ 12, 12, 60, 12, 61, 12, 12, 12,
1305
+ 12, 12, 12, 12, 12, 12, 12, 12,
1306
+ 12, 12, 63, 63, 63, 63, 63, 63,
1307
+ 63, 63, 63, 63, 12, 12, 12, 12,
1308
+ 12, 12, 12, 63, 63, 63, 63, 63,
1309
+ 63, 63, 63, 63, 63, 63, 63, 63,
1310
+ 63, 63, 63, 63, 63, 63, 63, 63,
1311
+ 63, 63, 63, 63, 63, 12, 12, 12,
1312
+ 12, 63, 12, 63, 63, 63, 63, 63,
1313
+ 63, 63, 63, 63, 63, 63, 63, 63,
1314
+ 63, 63, 63, 63, 63, 63, 63, 63,
1315
+ 63, 63, 63, 63, 63, 12, 65, 64,
1316
+ 64, 64, 64, 64, 64, 64, 64, 64,
1317
+ 64, 64, 64, 64, 64, 64, 64, 64,
1318
+ 64, 64, 64, 64, 64, 64, 64, 64,
1319
+ 64, 64, 64, 64, 64, 64, 64, 64,
1320
+ 64, 64, 64, 64, 64, 64, 64, 64,
1321
+ 64, 64, 64, 64, 64, 64, 64, 64,
1322
+ 64, 64, 64, 64, 64, 64, 64, 64,
1323
+ 66, 64, 67, 17, 17, 17, 17, 17,
1324
+ 17, 17, 17, 17, 17, 17, 17, 17,
1325
+ 17, 17, 17, 17, 17, 17, 17, 17,
1326
+ 17, 67, 17, 17, 17, 17, 17, 17,
1327
+ 17, 17, 68, 17, 17, 69, 17, 70,
1328
+ 6, 6, 6, 6, 6, 6, 6, 6,
1329
+ 6, 6, 6, 6, 6, 6, 6, 6,
1330
+ 6, 6, 6, 6, 6, 6, 70, 6,
1331
+ 6, 6, 6, 6, 6, 6, 6, 6,
1332
+ 6, 6, 71, 6, 71, 8, 8, 8,
1333
+ 8, 8, 8, 8, 8, 8, 8, 8,
1334
+ 8, 8, 8, 8, 8, 8, 8, 8,
1335
+ 8, 8, 8, 71, 8, 61, 8, 8,
1336
+ 8, 8, 8, 8, 8, 8, 8, 8,
1337
+ 8, 8, 8, 62, 62, 62, 62, 62,
1338
+ 62, 62, 62, 62, 62, 8, 8, 8,
1339
+ 8, 8, 8, 8, 62, 62, 62, 62,
1340
+ 62, 62, 62, 62, 62, 62, 62, 62,
1341
+ 62, 62, 62, 62, 62, 62, 62, 62,
1342
+ 62, 62, 62, 62, 62, 62, 8, 8,
1343
+ 8, 8, 62, 8, 62, 62, 62, 62,
1344
+ 62, 62, 62, 62, 62, 62, 62, 62,
1345
+ 62, 62, 62, 62, 62, 62, 62, 62,
1346
+ 62, 62, 62, 62, 62, 62, 8, 72,
1347
+ 0, 0, 0, 0, 0, 0, 0, 0,
1348
+ 0, 0, 0, 0, 0, 0, 0, 0,
1349
+ 0, 0, 0, 0, 0, 0, 72, 0,
1350
+ 0, 0, 0, 0, 0, 0, 73, 74,
1351
+ 0, 0, 75, 0, 0, 0, 76, 76,
1352
+ 76, 76, 76, 76, 76, 76, 76, 76,
1353
+ 77, 0, 0, 0, 0, 0, 0, 76,
1354
+ 76, 76, 76, 76, 76, 76, 76, 76,
1355
+ 76, 76, 76, 76, 76, 76, 76, 76,
1356
+ 76, 76, 76, 76, 76, 76, 76, 76,
1357
+ 76, 0, 0, 0, 0, 76, 0, 76,
1358
+ 76, 76, 76, 76, 76, 76, 76, 76,
1359
+ 76, 76, 76, 76, 76, 76, 76, 76,
1360
+ 76, 76, 76, 76, 76, 76, 76, 76,
1361
+ 76, 0, 70, 6, 6, 6, 6, 6,
1362
+ 6, 6, 6, 6, 6, 6, 6, 6,
1363
+ 6, 6, 6, 6, 6, 6, 6, 6,
1364
+ 6, 70, 6, 6, 6, 6, 6, 6,
1365
+ 6, 6, 78, 6, 6, 71, 6, 66,
1366
+ 64, 72, 0, 0, 0, 0, 0, 0,
1367
+ 0, 0, 0, 0, 0, 0, 0, 0,
1368
+ 0, 0, 0, 0, 0, 0, 0, 0,
1369
+ 72, 0, 0, 0, 0, 0, 0, 0,
1370
+ 0, 74, 0, 0, 75, 0, 0, 0,
1371
+ 79, 79, 79, 79, 79, 79, 79, 79,
1372
+ 79, 79, 0, 0, 0, 0, 0, 0,
1373
+ 0, 79, 79, 79, 79, 79, 79, 79,
1374
+ 79, 79, 79, 79, 79, 79, 79, 79,
1375
+ 79, 79, 79, 79, 79, 79, 79, 79,
1376
+ 79, 79, 79, 0, 0, 0, 0, 79,
1377
+ 0, 79, 79, 79, 79, 79, 79, 79,
1378
+ 79, 79, 79, 79, 79, 79, 79, 79,
1379
+ 79, 79, 79, 79, 79, 79, 79, 79,
1380
+ 79, 79, 79, 0, 6, 6, 6, 6,
1381
+ 6, 0
1382
+ ]
1383
+
1384
+ class << self
1385
+ attr_accessor :_bel_trans_targs
1386
+ private :_bel_trans_targs, :_bel_trans_targs=
1387
+ end
1388
+ self._bel_trans_targs = [
1389
+ 0, 2, 3, 4, 2, 3, 0, 4,
1390
+ 0, 5, 6, 10, 0, 14, 6, 7,
1391
+ 13, 0, 8, 12, 9, 8, 9, 8,
1392
+ 11, 12, 9, 10, 5, 12, 41, 14,
1393
+ 0, 16, 42, 16, 0, 18, 18, 19,
1394
+ 20, 43, 22, 23, 27, 26, 23, 24,
1395
+ 25, 44, 44, 26, 27, 22, 29, 30,
1396
+ 31, 29, 30, 31, 32, 33, 37, 40,
1397
+ 33, 34, 39, 35, 45, 36, 35, 36,
1398
+ 35, 38, 45, 36, 37, 32, 45, 40
1399
+ ]
1400
+
1401
+ class << self
1402
+ attr_accessor :_bel_trans_actions
1403
+ private :_bel_trans_actions, :_bel_trans_actions=
1404
+ end
1405
+ self._bel_trans_actions = [
1406
+ 1, 2, 3, 4, 5, 0, 0, 6,
1407
+ 7, 0, 8, 9, 10, 11, 13, 13,
1408
+ 13, 12, 14, 14, 14, 0, 0, 15,
1409
+ 16, 15, 15, 5, 17, 0, 18, 19,
1410
+ 20, 11, 21, 19, 22, 8, 13, 13,
1411
+ 13, 23, 0, 8, 11, 11, 13, 13,
1412
+ 13, 24, 25, 19, 19, 17, 26, 3,
1413
+ 4, 5, 0, 6, 0, 8, 9, 11,
1414
+ 13, 13, 13, 14, 27, 14, 0, 0,
1415
+ 15, 16, 28, 15, 5, 17, 29, 19
1416
+ ]
1417
+
1418
+ class << self
1419
+ attr_accessor :_bel_eof_actions
1420
+ private :_bel_eof_actions, :_bel_eof_actions=
1421
+ end
1422
+ self._bel_eof_actions = [
1423
+ 0, 1, 1, 0, 7, 10, 12, 12,
1424
+ 0, 7, 1, 0, 0, 12, 1, 20,
1425
+ 20, 22, 22, 22, 22, 7, 10, 12,
1426
+ 12, 12, 1, 1, 1, 1, 0, 7,
1427
+ 10, 12, 12, 0, 7, 1, 0, 12,
1428
+ 1, 0, 0, 0, 0, 0
1429
+ ]
1430
+
1431
+ class << self
1432
+ attr_accessor :bel_start
1433
+ end
1434
+ self.bel_start = 1;
1435
+ class << self
1436
+ attr_accessor :bel_first_final
1437
+ end
1438
+ self.bel_first_final = 41;
1439
+ class << self
1440
+ attr_accessor :bel_error
1441
+ end
1442
+ self.bel_error = 0;
1443
+
1444
+ class << self
1445
+ attr_accessor :bel_en_ident
1446
+ end
1447
+ self.bel_en_ident = 15;
1448
+ class << self
1449
+ attr_accessor :bel_en_string
1450
+ end
1451
+ self.bel_en_string = 17;
1452
+ class << self
1453
+ attr_accessor :bel_en_bel_parameter
1454
+ end
1455
+ self.bel_en_bel_parameter = 21;
1456
+ class << self
1457
+ attr_accessor :bel_en_inner_term
1458
+ end
1459
+ self.bel_en_inner_term = 28;
1460
+ class << self
1461
+ attr_accessor :bel_en_term
1462
+ end
1463
+ self.bel_en_term = 1;
1464
+
1465
+
1466
+ begin
1467
+ p ||= 0
1468
+ pe ||= data.length
1469
+ cs = bel_start
1470
+ top = 0
1471
+ end
1472
+
1473
+ begin
1474
+ testEof = false
1475
+ _slen, _trans, _keys, _inds, _acts, _nacts = nil
1476
+ _goto_level = 0
1477
+ _resume = 10
1478
+ _eof_trans = 15
1479
+ _again = 20
1480
+ _test_eof = 30
1481
+ _out = 40
1482
+ while true
1483
+ if _goto_level <= 0
1484
+ if p == pe
1485
+ _goto_level = _test_eof
1486
+ next
1487
+ end
1488
+ if cs == 0
1489
+ _goto_level = _out
1490
+ next
1491
+ end
1492
+ end
1493
+ if _goto_level <= _resume
1494
+ _keys = cs << 1
1495
+ _inds = _bel_index_offsets[cs]
1496
+ _slen = _bel_key_spans[cs]
1497
+ _wide = data[p].ord
1498
+ _trans = if ( _slen > 0 &&
1499
+ _bel_trans_keys[_keys] <= _wide &&
1500
+ _wide <= _bel_trans_keys[_keys + 1]
1501
+ ) then
1502
+ _bel_indicies[ _inds + _wide - _bel_trans_keys[_keys] ]
1503
+ else
1504
+ _bel_indicies[ _inds + _slen ]
1505
+ end
1506
+ cs = _bel_trans_targs[_trans]
1507
+ if _bel_trans_actions[_trans] != 0
1508
+ case _bel_trans_actions[_trans]
1509
+ when 19 then
1510
+ begin
1511
+
1512
+ (@buffers[:ident] ||= []) << data[p].ord
1513
+ end
1514
+ when 1 then
1515
+ begin
1516
+
1517
+ unless @buffers[:ident].is_a?(::AST::Node)
1518
+ @buffers[:ident] ||= []
1519
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1520
+ end
1521
+ end
1522
+ when 13 then
1523
+ begin
1524
+
1525
+ (@buffers[:string] ||= []) << data[p].ord
1526
+ end
1527
+ when 12 then
1528
+ begin
1529
+
1530
+ @buffers[:string] ||= []
1531
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1532
+ end
1533
+ when 6 then
1534
+ begin
1535
+
1536
+ fx = @buffers[:function]
1537
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
1538
+ end
1539
+ when 29 then
1540
+ begin
1541
+
1542
+ inner_term = @buffers[:term_stack].pop
1543
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
1544
+ begin
1545
+ top -= 1
1546
+ cs = stack[top]
1547
+ _goto_level = _again
1548
+ next
1549
+ end
1550
+
1551
+ end
1552
+ when 18 then
1553
+ begin
1554
+
1555
+ yield @buffers[:term_stack][-1]
1556
+ end
1557
+ when 11 then
1558
+ begin
1559
+
1560
+ @buffers[:ident] = []
1561
+ end
1562
+ begin
1563
+
1564
+ (@buffers[:ident] ||= []) << data[p].ord
1565
+ end
1566
+ when 5 then
1567
+ begin
1568
+
1569
+ (@buffers[:ident] ||= []) << data[p].ord
1570
+ end
1571
+ begin
1572
+
1573
+ @buffers[:function] << data[p].ord
1574
+ end
1575
+ when 21 then
1576
+ begin
1577
+
1578
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1579
+ end
1580
+ begin
1581
+
1582
+ yield @buffers[:ident]
1583
+ end
1584
+ when 17 then
1585
+ begin
1586
+
1587
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1588
+ end
1589
+ begin
1590
+
1591
+ @buffers[:parameter] = parameter(prefix(@buffers[:ident]))
1592
+ end
1593
+ when 3 then
1594
+ begin
1595
+
1596
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1597
+ end
1598
+ begin
1599
+
1600
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
1601
+ end
1602
+ when 16 then
1603
+ begin
1604
+
1605
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1606
+ end
1607
+ begin
1608
+
1609
+ p -= @buffers[:function].length + 1
1610
+ begin
1611
+ stack[top] = cs
1612
+ top+= 1
1613
+ cs = 28
1614
+ _goto_level = _again
1615
+ next
1616
+ end
1617
+
1618
+ end
1619
+ when 20 then
1620
+ begin
1621
+
1622
+ unless @buffers[:ident].is_a?(::AST::Node)
1623
+ @buffers[:ident] ||= []
1624
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1625
+ end
1626
+ end
1627
+ begin
1628
+
1629
+ @buffers[:ident] ||= []
1630
+ yield @buffers[:ident]
1631
+ end
1632
+ when 7 then
1633
+ begin
1634
+
1635
+ unless @buffers[:ident].is_a?(::AST::Node)
1636
+ @buffers[:ident] ||= []
1637
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1638
+ end
1639
+ end
1640
+ begin
1641
+
1642
+ @buffers[:string] ||= []
1643
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1644
+ end
1645
+ when 8 then
1646
+ begin
1647
+
1648
+ @buffers[:string] = []
1649
+ end
1650
+ begin
1651
+
1652
+ (@buffers[:string] ||= []) << data[p].ord
1653
+ end
1654
+ when 23 then
1655
+ begin
1656
+
1657
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
1658
+ end
1659
+ begin
1660
+
1661
+ yield @buffers[:string]
1662
+ end
1663
+ when 10 then
1664
+ begin
1665
+
1666
+ @buffers[:string] ||= []
1667
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1668
+ end
1669
+ begin
1670
+
1671
+ unless @buffers[:ident].is_a?(::AST::Node)
1672
+ @buffers[:ident] ||= []
1673
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1674
+ end
1675
+ end
1676
+ when 22 then
1677
+ begin
1678
+
1679
+ @buffers[:string] ||= []
1680
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1681
+ end
1682
+ begin
1683
+
1684
+ @buffers[:string] ||= []
1685
+ yield @buffers[:string]
1686
+ end
1687
+ when 25 then
1688
+ begin
1689
+
1690
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1691
+ end
1692
+ begin
1693
+
1694
+ @buffers[:parameter] ||= parameter(prefix(nil))
1695
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
1696
+ end
1697
+ begin
1698
+
1699
+ yield @buffers[:parameter]
1700
+ end
1701
+ when 15 then
1702
+ begin
1703
+
1704
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1705
+ end
1706
+ begin
1707
+
1708
+ @buffers[:parameter] ||= parameter(prefix(nil))
1709
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
1710
+ end
1711
+ begin
1712
+
1713
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
1714
+ @buffers[:parameter] = nil
1715
+ end
1716
+ when 4 then
1717
+ begin
1718
+
1719
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1720
+ end
1721
+ begin
1722
+
1723
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
1724
+ end
1725
+ begin
1726
+
1727
+ fx = @buffers[:function]
1728
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
1729
+ end
1730
+ when 24 then
1731
+ begin
1732
+
1733
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
1734
+ end
1735
+ begin
1736
+
1737
+ @buffers[:parameter] ||= parameter(prefix(nil))
1738
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
1739
+ end
1740
+ begin
1741
+
1742
+ yield @buffers[:parameter]
1743
+ end
1744
+ when 14 then
1745
+ begin
1746
+
1747
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
1748
+ end
1749
+ begin
1750
+
1751
+ @buffers[:parameter] ||= parameter(prefix(nil))
1752
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
1753
+ end
1754
+ begin
1755
+
1756
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
1757
+ @buffers[:parameter] = nil
1758
+ end
1759
+ when 9 then
1760
+ begin
1761
+
1762
+ @buffers[:ident] = []
1763
+ end
1764
+ begin
1765
+
1766
+ (@buffers[:ident] ||= []) << data[p].ord
1767
+ end
1768
+ begin
1769
+
1770
+ @buffers[:function] = []
1771
+ end
1772
+ begin
1773
+
1774
+ @buffers[:function] << data[p].ord
1775
+ end
1776
+ when 28 then
1777
+ begin
1778
+
1779
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
1780
+ end
1781
+ begin
1782
+
1783
+ @buffers[:parameter] ||= parameter(prefix(nil))
1784
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
1785
+ end
1786
+ begin
1787
+
1788
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
1789
+ @buffers[:parameter] = nil
1790
+ end
1791
+ begin
1792
+
1793
+ inner_term = @buffers[:term_stack].pop
1794
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
1795
+ begin
1796
+ top -= 1
1797
+ cs = stack[top]
1798
+ _goto_level = _again
1799
+ next
1800
+ end
1801
+
1802
+ end
1803
+ when 27 then
1804
+ begin
1805
+
1806
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
1807
+ end
1808
+ begin
1809
+
1810
+ @buffers[:parameter] ||= parameter(prefix(nil))
1811
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
1812
+ end
1813
+ begin
1814
+
1815
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
1816
+ @buffers[:parameter] = nil
1817
+ end
1818
+ begin
1819
+
1820
+ inner_term = @buffers[:term_stack].pop
1821
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
1822
+ begin
1823
+ top -= 1
1824
+ cs = stack[top]
1825
+ _goto_level = _again
1826
+ next
1827
+ end
1828
+
1829
+ end
1830
+ when 2 then
1831
+ begin
1832
+
1833
+ @buffers[:term_stack] = [ term() ]
1834
+ end
1835
+ begin
1836
+
1837
+ @buffers[:function] = []
1838
+ end
1839
+ begin
1840
+
1841
+ @buffers[:ident] = []
1842
+ end
1843
+ begin
1844
+
1845
+ (@buffers[:ident] ||= []) << data[p].ord
1846
+ end
1847
+ begin
1848
+
1849
+ @buffers[:function] << data[p].ord
1850
+ end
1851
+ when 26 then
1852
+ begin
1853
+
1854
+ @buffers[:term_stack] << term()
1855
+ end
1856
+ begin
1857
+
1858
+ @buffers[:function] = []
1859
+ end
1860
+ begin
1861
+
1862
+ @buffers[:ident] = []
1863
+ end
1864
+ begin
1865
+
1866
+ (@buffers[:ident] ||= []) << data[p].ord
1867
+ end
1868
+ begin
1869
+
1870
+ @buffers[:function] << data[p].ord
1871
+ end
1872
+ end
1873
+ end
1874
+ end
1875
+ if _goto_level <= _again
1876
+ if cs == 0
1877
+ _goto_level = _out
1878
+ next
1879
+ end
1880
+ p += 1
1881
+ if p != pe
1882
+ _goto_level = _resume
1883
+ next
1884
+ end
1885
+ end
1886
+ if _goto_level <= _test_eof
1887
+ if p == eof
1888
+ case _bel_eof_actions[cs]
1889
+ when 1 then
1890
+ begin
1891
+
1892
+ unless @buffers[:ident].is_a?(::AST::Node)
1893
+ @buffers[:ident] ||= []
1894
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1895
+ end
1896
+ end
1897
+ when 12 then
1898
+ begin
1899
+
1900
+ @buffers[:string] ||= []
1901
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1902
+ end
1903
+ when 20 then
1904
+ begin
1905
+
1906
+ unless @buffers[:ident].is_a?(::AST::Node)
1907
+ @buffers[:ident] ||= []
1908
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1909
+ end
1910
+ end
1911
+ begin
1912
+
1913
+ @buffers[:ident] ||= []
1914
+ yield @buffers[:ident]
1915
+ end
1916
+ when 7 then
1917
+ begin
1918
+
1919
+ unless @buffers[:ident].is_a?(::AST::Node)
1920
+ @buffers[:ident] ||= []
1921
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1922
+ end
1923
+ end
1924
+ begin
1925
+
1926
+ @buffers[:string] ||= []
1927
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1928
+ end
1929
+ when 10 then
1930
+ begin
1931
+
1932
+ @buffers[:string] ||= []
1933
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1934
+ end
1935
+ begin
1936
+
1937
+ unless @buffers[:ident].is_a?(::AST::Node)
1938
+ @buffers[:ident] ||= []
1939
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
1940
+ end
1941
+ end
1942
+ when 22 then
1943
+ begin
1944
+
1945
+ @buffers[:string] ||= []
1946
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
1947
+ end
1948
+ begin
1949
+
1950
+ @buffers[:string] ||= []
1951
+ yield @buffers[:string]
1952
+ end
1953
+ end
1954
+ end
1955
+
1956
+ end
1957
+ if _goto_level <= _out
1958
+ break
1959
+ end
1960
+ end
1961
+ end
1962
+
1963
+ class << self
1964
+ attr_accessor :_bel_trans_keys
1965
+ private :_bel_trans_keys, :_bel_trans_keys=
1966
+ end
1967
+ self._bel_trans_keys = [
1968
+ 0, 0, 48, 122, 9, 122,
1969
+ 9, 40, 9, 122, 9,
1970
+ 122, 34, 92, 9, 44,
1971
+ 9, 44, 9, 122, 9, 122,
1972
+ 9, 44, 10, 10, 92,
1973
+ 92, 9, 122, 48, 122,
1974
+ 10, 122, 34, 34, 34, 92,
1975
+ 10, 10, 92, 92, 9,
1976
+ 122, 9, 122, 34, 92,
1977
+ 10, 10, 92, 92, 10, 122,
1978
+ 10, 122, 48, 122, 9,
1979
+ 122, 9, 40, 9, 122,
1980
+ 9, 122, 34, 92, 9, 44,
1981
+ 9, 44, 9, 122, 9,
1982
+ 122, 9, 44, 92, 92,
1983
+ 9, 122, 0, 0, 0, 0,
1984
+ 0, 0, 0, 0, 0,
1985
+ 0, 0
1986
+ ]
1987
+
1988
+ class << self
1989
+ attr_accessor :_bel_key_spans
1990
+ private :_bel_key_spans, :_bel_key_spans=
1991
+ end
1992
+ self._bel_key_spans = [
1993
+ 0, 75, 114, 32, 114, 114, 59, 36,
1994
+ 36, 114, 114, 36, 1, 1, 114, 75,
1995
+ 113, 1, 59, 1, 1, 114, 114, 59,
1996
+ 1, 1, 113, 113, 75, 114, 32, 114,
1997
+ 114, 59, 36, 36, 114, 114, 36, 1,
1998
+ 114, 0, 0, 0, 0, 0
1999
+ ]
2000
+
2001
+ class << self
2002
+ attr_accessor :_bel_index_offsets
2003
+ private :_bel_index_offsets, :_bel_index_offsets=
2004
+ end
2005
+ self._bel_index_offsets = [
2006
+ 0, 0, 76, 191, 224, 339, 454, 514,
2007
+ 551, 588, 703, 818, 855, 857, 859, 974,
2008
+ 1050, 1164, 1166, 1226, 1228, 1230, 1345, 1460,
2009
+ 1520, 1522, 1524, 1638, 1752, 1828, 1943, 1976,
2010
+ 2091, 2206, 2266, 2303, 2340, 2455, 2570, 2607,
2011
+ 2609, 2724, 2725, 2726, 2727, 2728
2012
+ ]
2013
+
2014
+ class << self
2015
+ attr_accessor :_bel_indicies
2016
+ private :_bel_indicies, :_bel_indicies=
2017
+ end
2018
+ self._bel_indicies = [
2019
+ 1, 1, 1, 1, 1, 1, 1, 1,
2020
+ 1, 1, 0, 0, 0, 0, 0, 0,
2021
+ 0, 1, 1, 1, 1, 1, 1, 1,
2022
+ 1, 1, 1, 1, 1, 1, 1, 1,
2023
+ 1, 1, 1, 1, 1, 1, 1, 1,
2024
+ 1, 1, 1, 0, 0, 0, 0, 1,
2025
+ 0, 1, 1, 1, 1, 1, 1, 1,
2026
+ 1, 1, 1, 1, 1, 1, 1, 1,
2027
+ 1, 1, 1, 1, 1, 1, 1, 1,
2028
+ 1, 1, 1, 0, 2, 0, 0, 0,
2029
+ 0, 0, 0, 0, 0, 0, 0, 0,
2030
+ 0, 0, 0, 0, 0, 0, 0, 0,
2031
+ 0, 0, 0, 2, 0, 0, 0, 0,
2032
+ 0, 0, 0, 3, 0, 0, 0, 0,
2033
+ 0, 0, 0, 4, 4, 4, 4, 4,
2034
+ 4, 4, 4, 4, 4, 0, 0, 0,
2035
+ 0, 0, 0, 0, 4, 4, 4, 4,
2036
+ 4, 4, 4, 4, 4, 4, 4, 4,
2037
+ 4, 4, 4, 4, 4, 4, 4, 4,
2038
+ 4, 4, 4, 4, 4, 4, 0, 0,
2039
+ 0, 0, 4, 0, 4, 4, 4, 4,
2040
+ 4, 4, 4, 4, 4, 4, 4, 4,
2041
+ 4, 4, 4, 4, 4, 4, 4, 4,
2042
+ 4, 4, 4, 4, 4, 4, 0, 5,
2043
+ 6, 6, 6, 6, 6, 6, 6, 6,
2044
+ 6, 6, 6, 6, 6, 6, 6, 6,
2045
+ 6, 6, 6, 6, 6, 6, 5, 6,
2046
+ 6, 6, 6, 6, 6, 6, 7, 6,
2047
+ 9, 8, 8, 8, 8, 8, 8, 8,
2048
+ 8, 8, 8, 8, 8, 8, 8, 8,
2049
+ 8, 8, 8, 8, 8, 8, 8, 9,
2050
+ 8, 10, 8, 8, 8, 8, 8, 8,
2051
+ 8, 8, 8, 8, 8, 8, 8, 11,
2052
+ 11, 11, 11, 11, 11, 11, 11, 11,
2053
+ 11, 8, 8, 8, 8, 8, 8, 8,
2054
+ 11, 11, 11, 11, 11, 11, 11, 11,
2055
+ 11, 11, 11, 11, 11, 11, 11, 11,
2056
+ 11, 11, 11, 11, 11, 11, 11, 11,
2057
+ 11, 11, 8, 8, 8, 8, 11, 8,
2058
+ 11, 11, 11, 11, 11, 11, 11, 11,
2059
+ 11, 11, 11, 11, 11, 11, 11, 11,
2060
+ 11, 11, 11, 11, 11, 11, 11, 11,
2061
+ 11, 11, 8, 9, 12, 12, 12, 12,
2062
+ 12, 12, 12, 12, 12, 12, 12, 12,
2063
+ 12, 12, 12, 12, 12, 12, 12, 12,
2064
+ 12, 12, 9, 12, 10, 12, 12, 12,
2065
+ 12, 12, 12, 12, 12, 12, 12, 12,
2066
+ 12, 12, 13, 13, 13, 13, 13, 13,
2067
+ 13, 13, 13, 13, 12, 12, 12, 12,
2068
+ 12, 12, 12, 13, 13, 13, 13, 13,
2069
+ 13, 13, 13, 13, 13, 13, 13, 13,
2070
+ 13, 13, 13, 13, 13, 13, 13, 13,
2071
+ 13, 13, 13, 13, 13, 12, 12, 12,
2072
+ 12, 13, 12, 13, 13, 13, 13, 13,
2073
+ 13, 13, 13, 13, 13, 13, 13, 13,
2074
+ 13, 13, 13, 13, 13, 13, 13, 13,
2075
+ 13, 13, 13, 13, 13, 12, 15, 14,
2076
+ 14, 14, 14, 14, 14, 14, 14, 14,
2077
+ 14, 14, 14, 14, 14, 14, 14, 14,
2078
+ 14, 14, 14, 14, 14, 14, 14, 14,
2079
+ 14, 14, 14, 14, 14, 14, 14, 14,
2080
+ 14, 14, 14, 14, 14, 14, 14, 14,
2081
+ 14, 14, 14, 14, 14, 14, 14, 14,
2082
+ 14, 14, 14, 14, 14, 14, 14, 14,
2083
+ 16, 14, 18, 17, 17, 17, 17, 17,
2084
+ 17, 17, 17, 17, 17, 17, 17, 17,
2085
+ 17, 17, 17, 17, 17, 17, 17, 17,
2086
+ 17, 18, 17, 17, 17, 17, 17, 17,
2087
+ 17, 17, 19, 17, 17, 20, 17, 21,
2088
+ 6, 6, 6, 6, 6, 6, 6, 6,
2089
+ 6, 6, 6, 6, 6, 6, 6, 6,
2090
+ 6, 6, 6, 6, 6, 6, 21, 6,
2091
+ 6, 6, 6, 6, 6, 6, 6, 6,
2092
+ 6, 6, 22, 6, 22, 8, 8, 8,
2093
+ 8, 8, 8, 8, 8, 8, 8, 8,
2094
+ 8, 8, 8, 8, 8, 8, 8, 8,
2095
+ 8, 8, 8, 22, 8, 10, 8, 8,
2096
+ 8, 8, 8, 8, 8, 8, 8, 8,
2097
+ 8, 8, 8, 11, 11, 11, 11, 11,
2098
+ 11, 11, 11, 11, 11, 8, 8, 8,
2099
+ 8, 8, 8, 8, 11, 11, 11, 11,
2100
+ 11, 11, 11, 11, 11, 11, 11, 11,
2101
+ 11, 11, 11, 11, 11, 11, 11, 11,
2102
+ 11, 11, 11, 11, 11, 11, 8, 8,
2103
+ 8, 8, 11, 8, 11, 11, 11, 11,
2104
+ 11, 11, 11, 11, 11, 11, 11, 11,
2105
+ 11, 11, 11, 11, 11, 11, 11, 11,
2106
+ 11, 11, 11, 11, 11, 11, 8, 23,
2107
+ 0, 0, 0, 0, 0, 0, 0, 0,
2108
+ 0, 0, 0, 0, 0, 0, 0, 0,
2109
+ 0, 0, 0, 0, 0, 0, 23, 0,
2110
+ 0, 0, 0, 0, 0, 0, 24, 25,
2111
+ 0, 0, 26, 0, 0, 0, 27, 27,
2112
+ 27, 27, 27, 27, 27, 27, 27, 27,
2113
+ 28, 0, 0, 0, 0, 0, 0, 27,
2114
+ 27, 27, 27, 27, 27, 27, 27, 27,
2115
+ 27, 27, 27, 27, 27, 27, 27, 27,
2116
+ 27, 27, 27, 27, 27, 27, 27, 27,
2117
+ 27, 0, 0, 0, 0, 27, 0, 27,
2118
+ 27, 27, 27, 27, 27, 27, 27, 27,
2119
+ 27, 27, 27, 27, 27, 27, 27, 27,
2120
+ 27, 27, 27, 27, 27, 27, 27, 27,
2121
+ 27, 0, 21, 6, 6, 6, 6, 6,
2122
+ 6, 6, 6, 6, 6, 6, 6, 6,
2123
+ 6, 6, 6, 6, 6, 6, 6, 6,
2124
+ 6, 21, 6, 6, 6, 6, 6, 6,
2125
+ 6, 6, 29, 6, 6, 22, 6, 30,
2126
+ 6, 16, 14, 23, 0, 0, 0, 0,
2127
+ 0, 0, 0, 0, 0, 0, 0, 0,
2128
+ 0, 0, 0, 0, 0, 0, 0, 0,
2129
+ 0, 0, 23, 0, 0, 0, 0, 0,
2130
+ 0, 0, 0, 25, 0, 0, 26, 0,
2131
+ 0, 0, 31, 31, 31, 31, 31, 31,
2132
+ 31, 31, 31, 31, 0, 0, 0, 0,
2133
+ 0, 0, 0, 31, 31, 31, 31, 31,
2134
+ 31, 31, 31, 31, 31, 31, 31, 31,
2135
+ 31, 31, 31, 31, 31, 31, 31, 31,
2136
+ 31, 31, 31, 31, 31, 0, 0, 0,
2137
+ 0, 31, 0, 31, 31, 31, 31, 31,
2138
+ 31, 31, 31, 31, 31, 31, 31, 31,
2139
+ 31, 31, 31, 31, 31, 31, 31, 31,
2140
+ 31, 31, 31, 31, 31, 0, 33, 33,
2141
+ 33, 33, 33, 33, 33, 33, 33, 33,
2142
+ 32, 32, 32, 32, 32, 32, 32, 33,
2143
+ 33, 33, 33, 33, 33, 33, 33, 33,
2144
+ 33, 33, 33, 33, 33, 33, 33, 33,
2145
+ 33, 33, 33, 33, 33, 33, 33, 33,
2146
+ 33, 32, 32, 32, 32, 33, 32, 33,
2147
+ 33, 33, 33, 33, 33, 33, 33, 33,
2148
+ 33, 33, 33, 33, 33, 33, 33, 33,
2149
+ 33, 33, 33, 33, 33, 33, 33, 33,
2150
+ 33, 32, 34, 32, 32, 32, 32, 32,
2151
+ 32, 32, 32, 32, 32, 32, 32, 32,
2152
+ 32, 32, 32, 32, 32, 32, 32, 32,
2153
+ 32, 32, 32, 32, 32, 32, 32, 32,
2154
+ 32, 32, 32, 32, 32, 32, 32, 32,
2155
+ 35, 35, 35, 35, 35, 35, 35, 35,
2156
+ 35, 35, 32, 32, 32, 32, 32, 32,
2157
+ 32, 35, 35, 35, 35, 35, 35, 35,
2158
+ 35, 35, 35, 35, 35, 35, 35, 35,
2159
+ 35, 35, 35, 35, 35, 35, 35, 35,
2160
+ 35, 35, 35, 32, 32, 32, 32, 35,
2161
+ 32, 35, 35, 35, 35, 35, 35, 35,
2162
+ 35, 35, 35, 35, 35, 35, 35, 35,
2163
+ 35, 35, 35, 35, 35, 35, 35, 35,
2164
+ 35, 35, 35, 32, 37, 36, 39, 38,
2165
+ 38, 38, 38, 38, 38, 38, 38, 38,
2166
+ 38, 38, 38, 38, 38, 38, 38, 38,
2167
+ 38, 38, 38, 38, 38, 38, 38, 38,
2168
+ 38, 38, 38, 38, 38, 38, 38, 38,
2169
+ 38, 38, 38, 38, 38, 38, 38, 38,
2170
+ 38, 38, 38, 38, 38, 38, 38, 38,
2171
+ 38, 38, 38, 38, 38, 38, 38, 38,
2172
+ 40, 38, 41, 36, 40, 38, 42, 8,
2173
+ 8, 8, 8, 8, 8, 8, 8, 8,
2174
+ 8, 8, 8, 8, 8, 8, 8, 8,
2175
+ 8, 8, 8, 8, 8, 42, 8, 43,
2176
+ 8, 8, 8, 8, 8, 8, 8, 8,
2177
+ 8, 8, 8, 8, 8, 44, 44, 44,
2178
+ 44, 44, 44, 44, 44, 44, 44, 8,
2179
+ 8, 8, 8, 8, 8, 8, 44, 44,
2180
+ 44, 44, 44, 44, 44, 44, 44, 44,
2181
+ 44, 44, 44, 44, 44, 44, 44, 44,
2182
+ 44, 44, 44, 44, 44, 44, 44, 44,
2183
+ 8, 8, 8, 8, 44, 8, 44, 44,
2184
+ 44, 44, 44, 44, 44, 44, 44, 44,
2185
+ 44, 44, 44, 44, 44, 44, 44, 44,
2186
+ 44, 44, 44, 44, 44, 44, 44, 44,
2187
+ 8, 42, 12, 12, 12, 12, 12, 12,
2188
+ 12, 12, 12, 12, 12, 12, 12, 12,
2189
+ 12, 12, 12, 12, 12, 12, 12, 12,
2190
+ 42, 12, 43, 12, 12, 12, 12, 12,
2191
+ 12, 12, 12, 12, 12, 12, 12, 12,
2192
+ 45, 45, 45, 45, 45, 45, 45, 45,
2193
+ 45, 45, 12, 12, 12, 12, 12, 12,
2194
+ 12, 45, 45, 45, 45, 45, 45, 45,
2195
+ 45, 45, 45, 45, 45, 45, 45, 45,
2196
+ 45, 45, 45, 45, 45, 45, 45, 45,
2197
+ 45, 45, 45, 12, 12, 12, 12, 45,
2198
+ 12, 45, 45, 45, 45, 45, 45, 45,
2199
+ 45, 45, 45, 45, 45, 45, 45, 45,
2200
+ 45, 45, 45, 45, 45, 45, 45, 45,
2201
+ 45, 45, 45, 12, 47, 46, 46, 46,
2202
+ 46, 46, 46, 46, 46, 46, 46, 46,
2203
+ 46, 46, 46, 46, 46, 46, 46, 46,
2204
+ 46, 46, 46, 46, 46, 46, 46, 46,
2205
+ 46, 46, 46, 46, 46, 46, 46, 46,
2206
+ 46, 46, 46, 46, 46, 46, 46, 46,
2207
+ 46, 46, 46, 46, 46, 46, 46, 46,
2208
+ 46, 46, 46, 46, 46, 46, 48, 46,
2209
+ 49, 17, 48, 46, 50, 0, 0, 0,
2210
+ 0, 0, 0, 0, 0, 0, 0, 0,
2211
+ 0, 0, 0, 0, 0, 0, 0, 0,
2212
+ 0, 0, 0, 0, 0, 0, 0, 0,
2213
+ 0, 0, 0, 0, 0, 0, 0, 0,
2214
+ 0, 0, 51, 51, 51, 51, 51, 51,
2215
+ 51, 51, 51, 51, 0, 0, 0, 0,
2216
+ 0, 0, 0, 51, 51, 51, 51, 51,
2217
+ 51, 51, 51, 51, 51, 51, 51, 51,
2218
+ 51, 51, 51, 51, 51, 51, 51, 51,
2219
+ 51, 51, 51, 51, 51, 0, 0, 0,
2220
+ 0, 51, 0, 51, 51, 51, 51, 51,
2221
+ 51, 51, 51, 51, 51, 51, 51, 51,
2222
+ 51, 51, 51, 51, 51, 51, 51, 51,
2223
+ 51, 51, 51, 51, 51, 0, 50, 0,
2224
+ 0, 0, 0, 0, 0, 0, 0, 0,
2225
+ 0, 0, 0, 0, 0, 0, 0, 0,
2226
+ 0, 0, 0, 0, 0, 0, 0, 0,
2227
+ 0, 0, 0, 0, 0, 0, 0, 0,
2228
+ 0, 0, 0, 0, 52, 52, 52, 52,
2229
+ 52, 52, 52, 52, 52, 52, 53, 0,
2230
+ 0, 0, 0, 0, 0, 52, 52, 52,
2231
+ 52, 52, 52, 52, 52, 52, 52, 52,
2232
+ 52, 52, 52, 52, 52, 52, 52, 52,
2233
+ 52, 52, 52, 52, 52, 52, 52, 0,
2234
+ 0, 0, 0, 52, 0, 52, 52, 52,
2235
+ 52, 52, 52, 52, 52, 52, 52, 52,
2236
+ 52, 52, 52, 52, 52, 52, 52, 52,
2237
+ 52, 52, 52, 52, 52, 52, 52, 0,
2238
+ 54, 54, 54, 54, 54, 54, 54, 54,
2239
+ 54, 54, 0, 0, 0, 0, 0, 0,
2240
+ 0, 54, 54, 54, 54, 54, 54, 54,
2241
+ 54, 54, 54, 54, 54, 54, 54, 54,
2242
+ 54, 54, 54, 54, 54, 54, 54, 54,
2243
+ 54, 54, 54, 0, 0, 0, 0, 54,
2244
+ 0, 54, 54, 54, 54, 54, 54, 54,
2245
+ 54, 54, 54, 54, 54, 54, 54, 54,
2246
+ 54, 54, 54, 54, 54, 54, 54, 54,
2247
+ 54, 54, 54, 0, 55, 0, 0, 0,
2248
+ 0, 0, 0, 0, 0, 0, 0, 0,
2249
+ 0, 0, 0, 0, 0, 0, 0, 0,
2250
+ 0, 0, 0, 55, 0, 0, 0, 0,
2251
+ 0, 0, 0, 56, 0, 0, 0, 0,
2252
+ 0, 0, 0, 57, 57, 57, 57, 57,
2253
+ 57, 57, 57, 57, 57, 0, 0, 0,
2254
+ 0, 0, 0, 0, 57, 57, 57, 57,
2255
+ 57, 57, 57, 57, 57, 57, 57, 57,
2256
+ 57, 57, 57, 57, 57, 57, 57, 57,
2257
+ 57, 57, 57, 57, 57, 57, 0, 0,
2258
+ 0, 0, 57, 0, 57, 57, 57, 57,
2259
+ 57, 57, 57, 57, 57, 57, 57, 57,
2260
+ 57, 57, 57, 57, 57, 57, 57, 57,
2261
+ 57, 57, 57, 57, 57, 57, 0, 58,
2262
+ 6, 6, 6, 6, 6, 6, 6, 6,
2263
+ 6, 6, 6, 6, 6, 6, 6, 6,
2264
+ 6, 6, 6, 6, 6, 6, 58, 6,
2265
+ 6, 6, 6, 6, 6, 6, 59, 6,
2266
+ 60, 8, 8, 8, 8, 8, 8, 8,
2267
+ 8, 8, 8, 8, 8, 8, 8, 8,
2268
+ 8, 8, 8, 8, 8, 8, 8, 60,
2269
+ 8, 61, 8, 8, 8, 8, 8, 8,
2270
+ 8, 8, 8, 8, 8, 8, 8, 62,
2271
+ 62, 62, 62, 62, 62, 62, 62, 62,
2272
+ 62, 8, 8, 8, 8, 8, 8, 8,
2273
+ 62, 62, 62, 62, 62, 62, 62, 62,
2274
+ 62, 62, 62, 62, 62, 62, 62, 62,
2275
+ 62, 62, 62, 62, 62, 62, 62, 62,
2276
+ 62, 62, 8, 8, 8, 8, 62, 8,
2277
+ 62, 62, 62, 62, 62, 62, 62, 62,
2278
+ 62, 62, 62, 62, 62, 62, 62, 62,
2279
+ 62, 62, 62, 62, 62, 62, 62, 62,
2280
+ 62, 62, 8, 60, 12, 12, 12, 12,
2281
+ 12, 12, 12, 12, 12, 12, 12, 12,
2282
+ 12, 12, 12, 12, 12, 12, 12, 12,
2283
+ 12, 12, 60, 12, 61, 12, 12, 12,
2284
+ 12, 12, 12, 12, 12, 12, 12, 12,
2285
+ 12, 12, 63, 63, 63, 63, 63, 63,
2286
+ 63, 63, 63, 63, 12, 12, 12, 12,
2287
+ 12, 12, 12, 63, 63, 63, 63, 63,
2288
+ 63, 63, 63, 63, 63, 63, 63, 63,
2289
+ 63, 63, 63, 63, 63, 63, 63, 63,
2290
+ 63, 63, 63, 63, 63, 12, 12, 12,
2291
+ 12, 63, 12, 63, 63, 63, 63, 63,
2292
+ 63, 63, 63, 63, 63, 63, 63, 63,
2293
+ 63, 63, 63, 63, 63, 63, 63, 63,
2294
+ 63, 63, 63, 63, 63, 12, 65, 64,
2295
+ 64, 64, 64, 64, 64, 64, 64, 64,
2296
+ 64, 64, 64, 64, 64, 64, 64, 64,
2297
+ 64, 64, 64, 64, 64, 64, 64, 64,
2298
+ 64, 64, 64, 64, 64, 64, 64, 64,
2299
+ 64, 64, 64, 64, 64, 64, 64, 64,
2300
+ 64, 64, 64, 64, 64, 64, 64, 64,
2301
+ 64, 64, 64, 64, 64, 64, 64, 64,
2302
+ 66, 64, 67, 17, 17, 17, 17, 17,
2303
+ 17, 17, 17, 17, 17, 17, 17, 17,
2304
+ 17, 17, 17, 17, 17, 17, 17, 17,
2305
+ 17, 67, 17, 17, 17, 17, 17, 17,
2306
+ 17, 17, 68, 17, 17, 69, 17, 70,
2307
+ 6, 6, 6, 6, 6, 6, 6, 6,
2308
+ 6, 6, 6, 6, 6, 6, 6, 6,
2309
+ 6, 6, 6, 6, 6, 6, 70, 6,
2310
+ 6, 6, 6, 6, 6, 6, 6, 6,
2311
+ 6, 6, 71, 6, 71, 8, 8, 8,
2312
+ 8, 8, 8, 8, 8, 8, 8, 8,
2313
+ 8, 8, 8, 8, 8, 8, 8, 8,
2314
+ 8, 8, 8, 71, 8, 61, 8, 8,
2315
+ 8, 8, 8, 8, 8, 8, 8, 8,
2316
+ 8, 8, 8, 62, 62, 62, 62, 62,
2317
+ 62, 62, 62, 62, 62, 8, 8, 8,
2318
+ 8, 8, 8, 8, 62, 62, 62, 62,
2319
+ 62, 62, 62, 62, 62, 62, 62, 62,
2320
+ 62, 62, 62, 62, 62, 62, 62, 62,
2321
+ 62, 62, 62, 62, 62, 62, 8, 8,
2322
+ 8, 8, 62, 8, 62, 62, 62, 62,
2323
+ 62, 62, 62, 62, 62, 62, 62, 62,
2324
+ 62, 62, 62, 62, 62, 62, 62, 62,
2325
+ 62, 62, 62, 62, 62, 62, 8, 72,
2326
+ 0, 0, 0, 0, 0, 0, 0, 0,
2327
+ 0, 0, 0, 0, 0, 0, 0, 0,
2328
+ 0, 0, 0, 0, 0, 0, 72, 0,
2329
+ 0, 0, 0, 0, 0, 0, 73, 74,
2330
+ 0, 0, 75, 0, 0, 0, 76, 76,
2331
+ 76, 76, 76, 76, 76, 76, 76, 76,
2332
+ 77, 0, 0, 0, 0, 0, 0, 76,
2333
+ 76, 76, 76, 76, 76, 76, 76, 76,
2334
+ 76, 76, 76, 76, 76, 76, 76, 76,
2335
+ 76, 76, 76, 76, 76, 76, 76, 76,
2336
+ 76, 0, 0, 0, 0, 76, 0, 76,
2337
+ 76, 76, 76, 76, 76, 76, 76, 76,
2338
+ 76, 76, 76, 76, 76, 76, 76, 76,
2339
+ 76, 76, 76, 76, 76, 76, 76, 76,
2340
+ 76, 0, 70, 6, 6, 6, 6, 6,
2341
+ 6, 6, 6, 6, 6, 6, 6, 6,
2342
+ 6, 6, 6, 6, 6, 6, 6, 6,
2343
+ 6, 70, 6, 6, 6, 6, 6, 6,
2344
+ 6, 6, 78, 6, 6, 71, 6, 66,
2345
+ 64, 72, 0, 0, 0, 0, 0, 0,
2346
+ 0, 0, 0, 0, 0, 0, 0, 0,
2347
+ 0, 0, 0, 0, 0, 0, 0, 0,
2348
+ 72, 0, 0, 0, 0, 0, 0, 0,
2349
+ 0, 74, 0, 0, 75, 0, 0, 0,
2350
+ 79, 79, 79, 79, 79, 79, 79, 79,
2351
+ 79, 79, 0, 0, 0, 0, 0, 0,
2352
+ 0, 79, 79, 79, 79, 79, 79, 79,
2353
+ 79, 79, 79, 79, 79, 79, 79, 79,
2354
+ 79, 79, 79, 79, 79, 79, 79, 79,
2355
+ 79, 79, 79, 0, 0, 0, 0, 79,
2356
+ 0, 79, 79, 79, 79, 79, 79, 79,
2357
+ 79, 79, 79, 79, 79, 79, 79, 79,
2358
+ 79, 79, 79, 79, 79, 79, 79, 79,
2359
+ 79, 79, 79, 0, 6, 6, 6, 6,
2360
+ 6, 0
2361
+ ]
2362
+
2363
+ class << self
2364
+ attr_accessor :_bel_trans_targs
2365
+ private :_bel_trans_targs, :_bel_trans_targs=
2366
+ end
2367
+ self._bel_trans_targs = [
2368
+ 0, 2, 3, 4, 2, 3, 0, 4,
2369
+ 0, 5, 6, 10, 0, 14, 6, 7,
2370
+ 13, 0, 8, 12, 9, 8, 9, 8,
2371
+ 11, 12, 9, 10, 5, 12, 41, 14,
2372
+ 0, 16, 42, 16, 0, 18, 18, 19,
2373
+ 20, 43, 22, 23, 27, 26, 23, 24,
2374
+ 25, 44, 44, 26, 27, 22, 29, 30,
2375
+ 31, 29, 30, 31, 32, 33, 37, 40,
2376
+ 33, 34, 39, 35, 45, 36, 35, 36,
2377
+ 35, 38, 45, 36, 37, 32, 45, 40
2378
+ ]
2379
+
2380
+ class << self
2381
+ attr_accessor :_bel_trans_actions
2382
+ private :_bel_trans_actions, :_bel_trans_actions=
2383
+ end
2384
+ self._bel_trans_actions = [
2385
+ 1, 2, 3, 4, 5, 0, 0, 6,
2386
+ 7, 0, 8, 9, 10, 11, 13, 13,
2387
+ 13, 12, 14, 14, 14, 0, 0, 15,
2388
+ 16, 15, 15, 5, 17, 0, 18, 19,
2389
+ 20, 11, 21, 19, 22, 8, 13, 13,
2390
+ 13, 23, 0, 8, 11, 11, 13, 13,
2391
+ 13, 24, 25, 19, 19, 17, 26, 3,
2392
+ 4, 5, 0, 6, 0, 8, 9, 11,
2393
+ 13, 13, 13, 14, 27, 14, 0, 0,
2394
+ 15, 16, 28, 15, 5, 17, 29, 19
2395
+ ]
2396
+
2397
+ class << self
2398
+ attr_accessor :_bel_eof_actions
2399
+ private :_bel_eof_actions, :_bel_eof_actions=
2400
+ end
2401
+ self._bel_eof_actions = [
2402
+ 0, 1, 1, 0, 7, 10, 12, 12,
2403
+ 0, 7, 1, 0, 0, 12, 1, 20,
2404
+ 20, 22, 22, 22, 22, 7, 10, 12,
2405
+ 12, 12, 1, 1, 1, 1, 0, 7,
2406
+ 10, 12, 12, 0, 7, 1, 0, 12,
2407
+ 1, 0, 0, 0, 0, 0
2408
+ ]
2409
+
2410
+ class << self
2411
+ attr_accessor :bel_start
2412
+ end
2413
+ self.bel_start = 1;
2414
+ class << self
2415
+ attr_accessor :bel_first_final
2416
+ end
2417
+ self.bel_first_final = 41;
2418
+ class << self
2419
+ attr_accessor :bel_error
2420
+ end
2421
+ self.bel_error = 0;
2422
+
2423
+ class << self
2424
+ attr_accessor :bel_en_ident
2425
+ end
2426
+ self.bel_en_ident = 15;
2427
+ class << self
2428
+ attr_accessor :bel_en_string
2429
+ end
2430
+ self.bel_en_string = 17;
2431
+ class << self
2432
+ attr_accessor :bel_en_bel_parameter
2433
+ end
2434
+ self.bel_en_bel_parameter = 21;
2435
+ class << self
2436
+ attr_accessor :bel_en_inner_term
2437
+ end
2438
+ self.bel_en_inner_term = 28;
2439
+ class << self
2440
+ attr_accessor :bel_en_term
2441
+ end
2442
+ self.bel_en_term = 1;
2443
+
2444
+
2445
+ begin
2446
+ p ||= 0
2447
+ pe ||= data.length
2448
+ cs = bel_start
2449
+ top = 0
2450
+ end
2451
+
2452
+ begin
2453
+ testEof = false
2454
+ _slen, _trans, _keys, _inds, _acts, _nacts = nil
2455
+ _goto_level = 0
2456
+ _resume = 10
2457
+ _eof_trans = 15
2458
+ _again = 20
2459
+ _test_eof = 30
2460
+ _out = 40
2461
+ while true
2462
+ if _goto_level <= 0
2463
+ if p == pe
2464
+ _goto_level = _test_eof
2465
+ next
2466
+ end
2467
+ if cs == 0
2468
+ _goto_level = _out
2469
+ next
2470
+ end
2471
+ end
2472
+ if _goto_level <= _resume
2473
+ _keys = cs << 1
2474
+ _inds = _bel_index_offsets[cs]
2475
+ _slen = _bel_key_spans[cs]
2476
+ _wide = data[p].ord
2477
+ _trans = if ( _slen > 0 &&
2478
+ _bel_trans_keys[_keys] <= _wide &&
2479
+ _wide <= _bel_trans_keys[_keys + 1]
2480
+ ) then
2481
+ _bel_indicies[ _inds + _wide - _bel_trans_keys[_keys] ]
2482
+ else
2483
+ _bel_indicies[ _inds + _slen ]
2484
+ end
2485
+ cs = _bel_trans_targs[_trans]
2486
+ if _bel_trans_actions[_trans] != 0
2487
+ case _bel_trans_actions[_trans]
2488
+ when 19 then
2489
+ begin
2490
+
2491
+ (@buffers[:ident] ||= []) << data[p].ord
2492
+ end
2493
+ when 1 then
2494
+ begin
2495
+
2496
+ unless @buffers[:ident].is_a?(::AST::Node)
2497
+ @buffers[:ident] ||= []
2498
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2499
+ end
2500
+ end
2501
+ when 13 then
2502
+ begin
2503
+
2504
+ (@buffers[:string] ||= []) << data[p].ord
2505
+ end
2506
+ when 12 then
2507
+ begin
2508
+
2509
+ @buffers[:string] ||= []
2510
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2511
+ end
2512
+ when 6 then
2513
+ begin
2514
+
2515
+ fx = @buffers[:function]
2516
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
2517
+ end
2518
+ when 29 then
2519
+ begin
2520
+
2521
+ inner_term = @buffers[:term_stack].pop
2522
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
2523
+ begin
2524
+ top -= 1
2525
+ cs = stack[top]
2526
+ _goto_level = _again
2527
+ next
2528
+ end
2529
+
2530
+ end
2531
+ when 18 then
2532
+ begin
2533
+
2534
+ yield @buffers[:term_stack][-1]
2535
+ end
2536
+ when 11 then
2537
+ begin
2538
+
2539
+ @buffers[:ident] = []
2540
+ end
2541
+ begin
2542
+
2543
+ (@buffers[:ident] ||= []) << data[p].ord
2544
+ end
2545
+ when 5 then
2546
+ begin
2547
+
2548
+ (@buffers[:ident] ||= []) << data[p].ord
2549
+ end
2550
+ begin
2551
+
2552
+ @buffers[:function] << data[p].ord
2553
+ end
2554
+ when 21 then
2555
+ begin
2556
+
2557
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2558
+ end
2559
+ begin
2560
+
2561
+ yield @buffers[:ident]
2562
+ end
2563
+ when 17 then
2564
+ begin
2565
+
2566
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2567
+ end
2568
+ begin
2569
+
2570
+ @buffers[:parameter] = parameter(prefix(@buffers[:ident]))
2571
+ end
2572
+ when 3 then
2573
+ begin
2574
+
2575
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2576
+ end
2577
+ begin
2578
+
2579
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
2580
+ end
2581
+ when 16 then
2582
+ begin
2583
+
2584
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2585
+ end
2586
+ begin
2587
+
2588
+ p -= @buffers[:function].length + 1
2589
+ begin
2590
+ stack[top] = cs
2591
+ top+= 1
2592
+ cs = 28
2593
+ _goto_level = _again
2594
+ next
2595
+ end
2596
+
2597
+ end
2598
+ when 20 then
2599
+ begin
2600
+
2601
+ unless @buffers[:ident].is_a?(::AST::Node)
2602
+ @buffers[:ident] ||= []
2603
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2604
+ end
2605
+ end
2606
+ begin
2607
+
2608
+ @buffers[:ident] ||= []
2609
+ yield @buffers[:ident]
2610
+ end
2611
+ when 7 then
2612
+ begin
2613
+
2614
+ unless @buffers[:ident].is_a?(::AST::Node)
2615
+ @buffers[:ident] ||= []
2616
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2617
+ end
2618
+ end
2619
+ begin
2620
+
2621
+ @buffers[:string] ||= []
2622
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2623
+ end
2624
+ when 8 then
2625
+ begin
2626
+
2627
+ @buffers[:string] = []
2628
+ end
2629
+ begin
2630
+
2631
+ (@buffers[:string] ||= []) << data[p].ord
2632
+ end
2633
+ when 23 then
2634
+ begin
2635
+
2636
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
2637
+ end
2638
+ begin
2639
+
2640
+ yield @buffers[:string]
2641
+ end
2642
+ when 10 then
2643
+ begin
2644
+
2645
+ @buffers[:string] ||= []
2646
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2647
+ end
2648
+ begin
2649
+
2650
+ unless @buffers[:ident].is_a?(::AST::Node)
2651
+ @buffers[:ident] ||= []
2652
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2653
+ end
2654
+ end
2655
+ when 22 then
2656
+ begin
2657
+
2658
+ @buffers[:string] ||= []
2659
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2660
+ end
2661
+ begin
2662
+
2663
+ @buffers[:string] ||= []
2664
+ yield @buffers[:string]
2665
+ end
2666
+ when 25 then
2667
+ begin
2668
+
2669
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2670
+ end
2671
+ begin
2672
+
2673
+ @buffers[:parameter] ||= parameter(prefix(nil))
2674
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
2675
+ end
2676
+ begin
2677
+
2678
+ yield @buffers[:parameter]
2679
+ end
2680
+ when 15 then
2681
+ begin
2682
+
2683
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2684
+ end
2685
+ begin
2686
+
2687
+ @buffers[:parameter] ||= parameter(prefix(nil))
2688
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
2689
+ end
2690
+ begin
2691
+
2692
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
2693
+ @buffers[:parameter] = nil
2694
+ end
2695
+ when 4 then
2696
+ begin
2697
+
2698
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2699
+ end
2700
+ begin
2701
+
2702
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
2703
+ end
2704
+ begin
2705
+
2706
+ fx = @buffers[:function]
2707
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
2708
+ end
2709
+ when 24 then
2710
+ begin
2711
+
2712
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
2713
+ end
2714
+ begin
2715
+
2716
+ @buffers[:parameter] ||= parameter(prefix(nil))
2717
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
2718
+ end
2719
+ begin
2720
+
2721
+ yield @buffers[:parameter]
2722
+ end
2723
+ when 14 then
2724
+ begin
2725
+
2726
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
2727
+ end
2728
+ begin
2729
+
2730
+ @buffers[:parameter] ||= parameter(prefix(nil))
2731
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
2732
+ end
2733
+ begin
2734
+
2735
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
2736
+ @buffers[:parameter] = nil
2737
+ end
2738
+ when 9 then
2739
+ begin
2740
+
2741
+ @buffers[:ident] = []
2742
+ end
2743
+ begin
2744
+
2745
+ (@buffers[:ident] ||= []) << data[p].ord
2746
+ end
2747
+ begin
2748
+
2749
+ @buffers[:function] = []
2750
+ end
2751
+ begin
2752
+
2753
+ @buffers[:function] << data[p].ord
2754
+ end
2755
+ when 28 then
2756
+ begin
2757
+
2758
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
2759
+ end
2760
+ begin
2761
+
2762
+ @buffers[:parameter] ||= parameter(prefix(nil))
2763
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
2764
+ end
2765
+ begin
2766
+
2767
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
2768
+ @buffers[:parameter] = nil
2769
+ end
2770
+ begin
2771
+
2772
+ inner_term = @buffers[:term_stack].pop
2773
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
2774
+ begin
2775
+ top -= 1
2776
+ cs = stack[top]
2777
+ _goto_level = _again
2778
+ next
2779
+ end
2780
+
2781
+ end
2782
+ when 27 then
2783
+ begin
2784
+
2785
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
2786
+ end
2787
+ begin
2788
+
2789
+ @buffers[:parameter] ||= parameter(prefix(nil))
2790
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
2791
+ end
2792
+ begin
2793
+
2794
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
2795
+ @buffers[:parameter] = nil
2796
+ end
2797
+ begin
2798
+
2799
+ inner_term = @buffers[:term_stack].pop
2800
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
2801
+ begin
2802
+ top -= 1
2803
+ cs = stack[top]
2804
+ _goto_level = _again
2805
+ next
2806
+ end
2807
+
2808
+ end
2809
+ when 2 then
2810
+ begin
2811
+
2812
+ @buffers[:term_stack] = [ term() ]
2813
+ end
2814
+ begin
2815
+
2816
+ @buffers[:function] = []
2817
+ end
2818
+ begin
2819
+
2820
+ @buffers[:ident] = []
2821
+ end
2822
+ begin
2823
+
2824
+ (@buffers[:ident] ||= []) << data[p].ord
2825
+ end
2826
+ begin
2827
+
2828
+ @buffers[:function] << data[p].ord
2829
+ end
2830
+ when 26 then
2831
+ begin
2832
+
2833
+ @buffers[:term_stack] << term()
2834
+ end
2835
+ begin
2836
+
2837
+ @buffers[:function] = []
2838
+ end
2839
+ begin
2840
+
2841
+ @buffers[:ident] = []
2842
+ end
2843
+ begin
2844
+
2845
+ (@buffers[:ident] ||= []) << data[p].ord
2846
+ end
2847
+ begin
2848
+
2849
+ @buffers[:function] << data[p].ord
2850
+ end
2851
+ end
2852
+ end
2853
+ end
2854
+ if _goto_level <= _again
2855
+ if cs == 0
2856
+ _goto_level = _out
2857
+ next
2858
+ end
2859
+ p += 1
2860
+ if p != pe
2861
+ _goto_level = _resume
2862
+ next
2863
+ end
2864
+ end
2865
+ if _goto_level <= _test_eof
2866
+ if p == eof
2867
+ case _bel_eof_actions[cs]
2868
+ when 1 then
2869
+ begin
2870
+
2871
+ unless @buffers[:ident].is_a?(::AST::Node)
2872
+ @buffers[:ident] ||= []
2873
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2874
+ end
2875
+ end
2876
+ when 12 then
2877
+ begin
2878
+
2879
+ @buffers[:string] ||= []
2880
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2881
+ end
2882
+ when 20 then
2883
+ begin
2884
+
2885
+ unless @buffers[:ident].is_a?(::AST::Node)
2886
+ @buffers[:ident] ||= []
2887
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2888
+ end
2889
+ end
2890
+ begin
2891
+
2892
+ @buffers[:ident] ||= []
2893
+ yield @buffers[:ident]
2894
+ end
2895
+ when 7 then
2896
+ begin
2897
+
2898
+ unless @buffers[:ident].is_a?(::AST::Node)
2899
+ @buffers[:ident] ||= []
2900
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2901
+ end
2902
+ end
2903
+ begin
2904
+
2905
+ @buffers[:string] ||= []
2906
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2907
+ end
2908
+ when 10 then
2909
+ begin
2910
+
2911
+ @buffers[:string] ||= []
2912
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2913
+ end
2914
+ begin
2915
+
2916
+ unless @buffers[:ident].is_a?(::AST::Node)
2917
+ @buffers[:ident] ||= []
2918
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
2919
+ end
2920
+ end
2921
+ when 22 then
2922
+ begin
2923
+
2924
+ @buffers[:string] ||= []
2925
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
2926
+ end
2927
+ begin
2928
+
2929
+ @buffers[:string] ||= []
2930
+ yield @buffers[:string]
2931
+ end
2932
+ end
2933
+ end
2934
+
2935
+ end
2936
+ if _goto_level <= _out
2937
+ break
2938
+ end
2939
+ end
2940
+ end
2941
+
2942
+
2943
+ =end
2944
+ # end: ragel
2945
+
2946
+ require_relative '../ast/node'
2947
+ require_relative '../mixin/buffer'
2948
+ require_relative '../nonblocking_io_wrapper'
2949
+
2950
+ module BELParser
2951
+ module Parsers
2952
+ module Expression
2953
+ module Term
2954
+
2955
+ class << self
2956
+
2957
+ MAX_LENGTH = 1024 * 128 # 128K
2958
+
2959
+ def parse(content)
2960
+ return nil unless content
2961
+
2962
+ Parser.new(content).each do |obj|
2963
+ yield obj
2964
+ end
2965
+ end
2966
+ end
2967
+
2968
+ private
2969
+
2970
+ class Parser
2971
+ include Enumerable
2972
+ include BELParser::Parsers::Buffer
2973
+ include BELParser::Parsers::AST::Sexp
2974
+
2975
+ def initialize(content)
2976
+ @content = content
2977
+ # begin: ragel
2978
+
2979
+ class << self
2980
+ attr_accessor :_bel_trans_keys
2981
+ private :_bel_trans_keys, :_bel_trans_keys=
2982
+ end
2983
+ self._bel_trans_keys = [
2984
+ 0, 0, 48, 122, 9, 122,
2985
+ 9, 40, 9, 122, 9,
2986
+ 122, 34, 92, 9, 44,
2987
+ 9, 44, 9, 122, 9, 122,
2988
+ 9, 44, 10, 10, 92,
2989
+ 92, 9, 122, 48, 122,
2990
+ 10, 122, 34, 34, 34, 92,
2991
+ 10, 10, 92, 92, 9,
2992
+ 122, 9, 122, 34, 92,
2993
+ 10, 10, 92, 92, 10, 122,
2994
+ 10, 122, 48, 122, 9,
2995
+ 122, 9, 40, 9, 122,
2996
+ 9, 122, 34, 92, 9, 44,
2997
+ 9, 44, 9, 122, 9,
2998
+ 122, 9, 44, 92, 92,
2999
+ 9, 122, 0, 0, 0, 0,
3000
+ 0, 0, 0, 0, 0,
3001
+ 0, 0
3002
+ ]
3003
+
3004
+ class << self
3005
+ attr_accessor :_bel_key_spans
3006
+ private :_bel_key_spans, :_bel_key_spans=
3007
+ end
3008
+ self._bel_key_spans = [
3009
+ 0, 75, 114, 32, 114, 114, 59, 36,
3010
+ 36, 114, 114, 36, 1, 1, 114, 75,
3011
+ 113, 1, 59, 1, 1, 114, 114, 59,
3012
+ 1, 1, 113, 113, 75, 114, 32, 114,
3013
+ 114, 59, 36, 36, 114, 114, 36, 1,
3014
+ 114, 0, 0, 0, 0, 0
3015
+ ]
3016
+
3017
+ class << self
3018
+ attr_accessor :_bel_index_offsets
3019
+ private :_bel_index_offsets, :_bel_index_offsets=
3020
+ end
3021
+ self._bel_index_offsets = [
3022
+ 0, 0, 76, 191, 224, 339, 454, 514,
3023
+ 551, 588, 703, 818, 855, 857, 859, 974,
3024
+ 1050, 1164, 1166, 1226, 1228, 1230, 1345, 1460,
3025
+ 1520, 1522, 1524, 1638, 1752, 1828, 1943, 1976,
3026
+ 2091, 2206, 2266, 2303, 2340, 2455, 2570, 2607,
3027
+ 2609, 2724, 2725, 2726, 2727, 2728
3028
+ ]
3029
+
3030
+ class << self
3031
+ attr_accessor :_bel_indicies
3032
+ private :_bel_indicies, :_bel_indicies=
3033
+ end
3034
+ self._bel_indicies = [
3035
+ 1, 1, 1, 1, 1, 1, 1, 1,
3036
+ 1, 1, 0, 0, 0, 0, 0, 0,
3037
+ 0, 1, 1, 1, 1, 1, 1, 1,
3038
+ 1, 1, 1, 1, 1, 1, 1, 1,
3039
+ 1, 1, 1, 1, 1, 1, 1, 1,
3040
+ 1, 1, 1, 0, 0, 0, 0, 1,
3041
+ 0, 1, 1, 1, 1, 1, 1, 1,
3042
+ 1, 1, 1, 1, 1, 1, 1, 1,
3043
+ 1, 1, 1, 1, 1, 1, 1, 1,
3044
+ 1, 1, 1, 0, 2, 0, 0, 0,
3045
+ 0, 0, 0, 0, 0, 0, 0, 0,
3046
+ 0, 0, 0, 0, 0, 0, 0, 0,
3047
+ 0, 0, 0, 2, 0, 0, 0, 0,
3048
+ 0, 0, 0, 3, 0, 0, 0, 0,
3049
+ 0, 0, 0, 4, 4, 4, 4, 4,
3050
+ 4, 4, 4, 4, 4, 0, 0, 0,
3051
+ 0, 0, 0, 0, 4, 4, 4, 4,
3052
+ 4, 4, 4, 4, 4, 4, 4, 4,
3053
+ 4, 4, 4, 4, 4, 4, 4, 4,
3054
+ 4, 4, 4, 4, 4, 4, 0, 0,
3055
+ 0, 0, 4, 0, 4, 4, 4, 4,
3056
+ 4, 4, 4, 4, 4, 4, 4, 4,
3057
+ 4, 4, 4, 4, 4, 4, 4, 4,
3058
+ 4, 4, 4, 4, 4, 4, 0, 5,
3059
+ 6, 6, 6, 6, 6, 6, 6, 6,
3060
+ 6, 6, 6, 6, 6, 6, 6, 6,
3061
+ 6, 6, 6, 6, 6, 6, 5, 6,
3062
+ 6, 6, 6, 6, 6, 6, 7, 6,
3063
+ 9, 8, 8, 8, 8, 8, 8, 8,
3064
+ 8, 8, 8, 8, 8, 8, 8, 8,
3065
+ 8, 8, 8, 8, 8, 8, 8, 9,
3066
+ 8, 10, 8, 8, 8, 8, 8, 8,
3067
+ 8, 8, 8, 8, 8, 8, 8, 11,
3068
+ 11, 11, 11, 11, 11, 11, 11, 11,
3069
+ 11, 8, 8, 8, 8, 8, 8, 8,
3070
+ 11, 11, 11, 11, 11, 11, 11, 11,
3071
+ 11, 11, 11, 11, 11, 11, 11, 11,
3072
+ 11, 11, 11, 11, 11, 11, 11, 11,
3073
+ 11, 11, 8, 8, 8, 8, 11, 8,
3074
+ 11, 11, 11, 11, 11, 11, 11, 11,
3075
+ 11, 11, 11, 11, 11, 11, 11, 11,
3076
+ 11, 11, 11, 11, 11, 11, 11, 11,
3077
+ 11, 11, 8, 9, 12, 12, 12, 12,
3078
+ 12, 12, 12, 12, 12, 12, 12, 12,
3079
+ 12, 12, 12, 12, 12, 12, 12, 12,
3080
+ 12, 12, 9, 12, 10, 12, 12, 12,
3081
+ 12, 12, 12, 12, 12, 12, 12, 12,
3082
+ 12, 12, 13, 13, 13, 13, 13, 13,
3083
+ 13, 13, 13, 13, 12, 12, 12, 12,
3084
+ 12, 12, 12, 13, 13, 13, 13, 13,
3085
+ 13, 13, 13, 13, 13, 13, 13, 13,
3086
+ 13, 13, 13, 13, 13, 13, 13, 13,
3087
+ 13, 13, 13, 13, 13, 12, 12, 12,
3088
+ 12, 13, 12, 13, 13, 13, 13, 13,
3089
+ 13, 13, 13, 13, 13, 13, 13, 13,
3090
+ 13, 13, 13, 13, 13, 13, 13, 13,
3091
+ 13, 13, 13, 13, 13, 12, 15, 14,
3092
+ 14, 14, 14, 14, 14, 14, 14, 14,
3093
+ 14, 14, 14, 14, 14, 14, 14, 14,
3094
+ 14, 14, 14, 14, 14, 14, 14, 14,
3095
+ 14, 14, 14, 14, 14, 14, 14, 14,
3096
+ 14, 14, 14, 14, 14, 14, 14, 14,
3097
+ 14, 14, 14, 14, 14, 14, 14, 14,
3098
+ 14, 14, 14, 14, 14, 14, 14, 14,
3099
+ 16, 14, 18, 17, 17, 17, 17, 17,
3100
+ 17, 17, 17, 17, 17, 17, 17, 17,
3101
+ 17, 17, 17, 17, 17, 17, 17, 17,
3102
+ 17, 18, 17, 17, 17, 17, 17, 17,
3103
+ 17, 17, 19, 17, 17, 20, 17, 21,
3104
+ 6, 6, 6, 6, 6, 6, 6, 6,
3105
+ 6, 6, 6, 6, 6, 6, 6, 6,
3106
+ 6, 6, 6, 6, 6, 6, 21, 6,
3107
+ 6, 6, 6, 6, 6, 6, 6, 6,
3108
+ 6, 6, 22, 6, 22, 8, 8, 8,
3109
+ 8, 8, 8, 8, 8, 8, 8, 8,
3110
+ 8, 8, 8, 8, 8, 8, 8, 8,
3111
+ 8, 8, 8, 22, 8, 10, 8, 8,
3112
+ 8, 8, 8, 8, 8, 8, 8, 8,
3113
+ 8, 8, 8, 11, 11, 11, 11, 11,
3114
+ 11, 11, 11, 11, 11, 8, 8, 8,
3115
+ 8, 8, 8, 8, 11, 11, 11, 11,
3116
+ 11, 11, 11, 11, 11, 11, 11, 11,
3117
+ 11, 11, 11, 11, 11, 11, 11, 11,
3118
+ 11, 11, 11, 11, 11, 11, 8, 8,
3119
+ 8, 8, 11, 8, 11, 11, 11, 11,
3120
+ 11, 11, 11, 11, 11, 11, 11, 11,
3121
+ 11, 11, 11, 11, 11, 11, 11, 11,
3122
+ 11, 11, 11, 11, 11, 11, 8, 23,
3123
+ 0, 0, 0, 0, 0, 0, 0, 0,
3124
+ 0, 0, 0, 0, 0, 0, 0, 0,
3125
+ 0, 0, 0, 0, 0, 0, 23, 0,
3126
+ 0, 0, 0, 0, 0, 0, 24, 25,
3127
+ 0, 0, 26, 0, 0, 0, 27, 27,
3128
+ 27, 27, 27, 27, 27, 27, 27, 27,
3129
+ 28, 0, 0, 0, 0, 0, 0, 27,
3130
+ 27, 27, 27, 27, 27, 27, 27, 27,
3131
+ 27, 27, 27, 27, 27, 27, 27, 27,
3132
+ 27, 27, 27, 27, 27, 27, 27, 27,
3133
+ 27, 0, 0, 0, 0, 27, 0, 27,
3134
+ 27, 27, 27, 27, 27, 27, 27, 27,
3135
+ 27, 27, 27, 27, 27, 27, 27, 27,
3136
+ 27, 27, 27, 27, 27, 27, 27, 27,
3137
+ 27, 0, 21, 6, 6, 6, 6, 6,
3138
+ 6, 6, 6, 6, 6, 6, 6, 6,
3139
+ 6, 6, 6, 6, 6, 6, 6, 6,
3140
+ 6, 21, 6, 6, 6, 6, 6, 6,
3141
+ 6, 6, 29, 6, 6, 22, 6, 30,
3142
+ 6, 16, 14, 23, 0, 0, 0, 0,
3143
+ 0, 0, 0, 0, 0, 0, 0, 0,
3144
+ 0, 0, 0, 0, 0, 0, 0, 0,
3145
+ 0, 0, 23, 0, 0, 0, 0, 0,
3146
+ 0, 0, 0, 25, 0, 0, 26, 0,
3147
+ 0, 0, 31, 31, 31, 31, 31, 31,
3148
+ 31, 31, 31, 31, 0, 0, 0, 0,
3149
+ 0, 0, 0, 31, 31, 31, 31, 31,
3150
+ 31, 31, 31, 31, 31, 31, 31, 31,
3151
+ 31, 31, 31, 31, 31, 31, 31, 31,
3152
+ 31, 31, 31, 31, 31, 0, 0, 0,
3153
+ 0, 31, 0, 31, 31, 31, 31, 31,
3154
+ 31, 31, 31, 31, 31, 31, 31, 31,
3155
+ 31, 31, 31, 31, 31, 31, 31, 31,
3156
+ 31, 31, 31, 31, 31, 0, 33, 33,
3157
+ 33, 33, 33, 33, 33, 33, 33, 33,
3158
+ 32, 32, 32, 32, 32, 32, 32, 33,
3159
+ 33, 33, 33, 33, 33, 33, 33, 33,
3160
+ 33, 33, 33, 33, 33, 33, 33, 33,
3161
+ 33, 33, 33, 33, 33, 33, 33, 33,
3162
+ 33, 32, 32, 32, 32, 33, 32, 33,
3163
+ 33, 33, 33, 33, 33, 33, 33, 33,
3164
+ 33, 33, 33, 33, 33, 33, 33, 33,
3165
+ 33, 33, 33, 33, 33, 33, 33, 33,
3166
+ 33, 32, 34, 32, 32, 32, 32, 32,
3167
+ 32, 32, 32, 32, 32, 32, 32, 32,
3168
+ 32, 32, 32, 32, 32, 32, 32, 32,
3169
+ 32, 32, 32, 32, 32, 32, 32, 32,
3170
+ 32, 32, 32, 32, 32, 32, 32, 32,
3171
+ 35, 35, 35, 35, 35, 35, 35, 35,
3172
+ 35, 35, 32, 32, 32, 32, 32, 32,
3173
+ 32, 35, 35, 35, 35, 35, 35, 35,
3174
+ 35, 35, 35, 35, 35, 35, 35, 35,
3175
+ 35, 35, 35, 35, 35, 35, 35, 35,
3176
+ 35, 35, 35, 32, 32, 32, 32, 35,
3177
+ 32, 35, 35, 35, 35, 35, 35, 35,
3178
+ 35, 35, 35, 35, 35, 35, 35, 35,
3179
+ 35, 35, 35, 35, 35, 35, 35, 35,
3180
+ 35, 35, 35, 32, 37, 36, 39, 38,
3181
+ 38, 38, 38, 38, 38, 38, 38, 38,
3182
+ 38, 38, 38, 38, 38, 38, 38, 38,
3183
+ 38, 38, 38, 38, 38, 38, 38, 38,
3184
+ 38, 38, 38, 38, 38, 38, 38, 38,
3185
+ 38, 38, 38, 38, 38, 38, 38, 38,
3186
+ 38, 38, 38, 38, 38, 38, 38, 38,
3187
+ 38, 38, 38, 38, 38, 38, 38, 38,
3188
+ 40, 38, 41, 36, 40, 38, 42, 8,
3189
+ 8, 8, 8, 8, 8, 8, 8, 8,
3190
+ 8, 8, 8, 8, 8, 8, 8, 8,
3191
+ 8, 8, 8, 8, 8, 42, 8, 43,
3192
+ 8, 8, 8, 8, 8, 8, 8, 8,
3193
+ 8, 8, 8, 8, 8, 44, 44, 44,
3194
+ 44, 44, 44, 44, 44, 44, 44, 8,
3195
+ 8, 8, 8, 8, 8, 8, 44, 44,
3196
+ 44, 44, 44, 44, 44, 44, 44, 44,
3197
+ 44, 44, 44, 44, 44, 44, 44, 44,
3198
+ 44, 44, 44, 44, 44, 44, 44, 44,
3199
+ 8, 8, 8, 8, 44, 8, 44, 44,
3200
+ 44, 44, 44, 44, 44, 44, 44, 44,
3201
+ 44, 44, 44, 44, 44, 44, 44, 44,
3202
+ 44, 44, 44, 44, 44, 44, 44, 44,
3203
+ 8, 42, 12, 12, 12, 12, 12, 12,
3204
+ 12, 12, 12, 12, 12, 12, 12, 12,
3205
+ 12, 12, 12, 12, 12, 12, 12, 12,
3206
+ 42, 12, 43, 12, 12, 12, 12, 12,
3207
+ 12, 12, 12, 12, 12, 12, 12, 12,
3208
+ 45, 45, 45, 45, 45, 45, 45, 45,
3209
+ 45, 45, 12, 12, 12, 12, 12, 12,
3210
+ 12, 45, 45, 45, 45, 45, 45, 45,
3211
+ 45, 45, 45, 45, 45, 45, 45, 45,
3212
+ 45, 45, 45, 45, 45, 45, 45, 45,
3213
+ 45, 45, 45, 12, 12, 12, 12, 45,
3214
+ 12, 45, 45, 45, 45, 45, 45, 45,
3215
+ 45, 45, 45, 45, 45, 45, 45, 45,
3216
+ 45, 45, 45, 45, 45, 45, 45, 45,
3217
+ 45, 45, 45, 12, 47, 46, 46, 46,
3218
+ 46, 46, 46, 46, 46, 46, 46, 46,
3219
+ 46, 46, 46, 46, 46, 46, 46, 46,
3220
+ 46, 46, 46, 46, 46, 46, 46, 46,
3221
+ 46, 46, 46, 46, 46, 46, 46, 46,
3222
+ 46, 46, 46, 46, 46, 46, 46, 46,
3223
+ 46, 46, 46, 46, 46, 46, 46, 46,
3224
+ 46, 46, 46, 46, 46, 46, 48, 46,
3225
+ 49, 17, 48, 46, 50, 0, 0, 0,
3226
+ 0, 0, 0, 0, 0, 0, 0, 0,
3227
+ 0, 0, 0, 0, 0, 0, 0, 0,
3228
+ 0, 0, 0, 0, 0, 0, 0, 0,
3229
+ 0, 0, 0, 0, 0, 0, 0, 0,
3230
+ 0, 0, 51, 51, 51, 51, 51, 51,
3231
+ 51, 51, 51, 51, 0, 0, 0, 0,
3232
+ 0, 0, 0, 51, 51, 51, 51, 51,
3233
+ 51, 51, 51, 51, 51, 51, 51, 51,
3234
+ 51, 51, 51, 51, 51, 51, 51, 51,
3235
+ 51, 51, 51, 51, 51, 0, 0, 0,
3236
+ 0, 51, 0, 51, 51, 51, 51, 51,
3237
+ 51, 51, 51, 51, 51, 51, 51, 51,
3238
+ 51, 51, 51, 51, 51, 51, 51, 51,
3239
+ 51, 51, 51, 51, 51, 0, 50, 0,
3240
+ 0, 0, 0, 0, 0, 0, 0, 0,
3241
+ 0, 0, 0, 0, 0, 0, 0, 0,
3242
+ 0, 0, 0, 0, 0, 0, 0, 0,
3243
+ 0, 0, 0, 0, 0, 0, 0, 0,
3244
+ 0, 0, 0, 0, 52, 52, 52, 52,
3245
+ 52, 52, 52, 52, 52, 52, 53, 0,
3246
+ 0, 0, 0, 0, 0, 52, 52, 52,
3247
+ 52, 52, 52, 52, 52, 52, 52, 52,
3248
+ 52, 52, 52, 52, 52, 52, 52, 52,
3249
+ 52, 52, 52, 52, 52, 52, 52, 0,
3250
+ 0, 0, 0, 52, 0, 52, 52, 52,
3251
+ 52, 52, 52, 52, 52, 52, 52, 52,
3252
+ 52, 52, 52, 52, 52, 52, 52, 52,
3253
+ 52, 52, 52, 52, 52, 52, 52, 0,
3254
+ 54, 54, 54, 54, 54, 54, 54, 54,
3255
+ 54, 54, 0, 0, 0, 0, 0, 0,
3256
+ 0, 54, 54, 54, 54, 54, 54, 54,
3257
+ 54, 54, 54, 54, 54, 54, 54, 54,
3258
+ 54, 54, 54, 54, 54, 54, 54, 54,
3259
+ 54, 54, 54, 0, 0, 0, 0, 54,
3260
+ 0, 54, 54, 54, 54, 54, 54, 54,
3261
+ 54, 54, 54, 54, 54, 54, 54, 54,
3262
+ 54, 54, 54, 54, 54, 54, 54, 54,
3263
+ 54, 54, 54, 0, 55, 0, 0, 0,
3264
+ 0, 0, 0, 0, 0, 0, 0, 0,
3265
+ 0, 0, 0, 0, 0, 0, 0, 0,
3266
+ 0, 0, 0, 55, 0, 0, 0, 0,
3267
+ 0, 0, 0, 56, 0, 0, 0, 0,
3268
+ 0, 0, 0, 57, 57, 57, 57, 57,
3269
+ 57, 57, 57, 57, 57, 0, 0, 0,
3270
+ 0, 0, 0, 0, 57, 57, 57, 57,
3271
+ 57, 57, 57, 57, 57, 57, 57, 57,
3272
+ 57, 57, 57, 57, 57, 57, 57, 57,
3273
+ 57, 57, 57, 57, 57, 57, 0, 0,
3274
+ 0, 0, 57, 0, 57, 57, 57, 57,
3275
+ 57, 57, 57, 57, 57, 57, 57, 57,
3276
+ 57, 57, 57, 57, 57, 57, 57, 57,
3277
+ 57, 57, 57, 57, 57, 57, 0, 58,
3278
+ 6, 6, 6, 6, 6, 6, 6, 6,
3279
+ 6, 6, 6, 6, 6, 6, 6, 6,
3280
+ 6, 6, 6, 6, 6, 6, 58, 6,
3281
+ 6, 6, 6, 6, 6, 6, 59, 6,
3282
+ 60, 8, 8, 8, 8, 8, 8, 8,
3283
+ 8, 8, 8, 8, 8, 8, 8, 8,
3284
+ 8, 8, 8, 8, 8, 8, 8, 60,
3285
+ 8, 61, 8, 8, 8, 8, 8, 8,
3286
+ 8, 8, 8, 8, 8, 8, 8, 62,
3287
+ 62, 62, 62, 62, 62, 62, 62, 62,
3288
+ 62, 8, 8, 8, 8, 8, 8, 8,
3289
+ 62, 62, 62, 62, 62, 62, 62, 62,
3290
+ 62, 62, 62, 62, 62, 62, 62, 62,
3291
+ 62, 62, 62, 62, 62, 62, 62, 62,
3292
+ 62, 62, 8, 8, 8, 8, 62, 8,
3293
+ 62, 62, 62, 62, 62, 62, 62, 62,
3294
+ 62, 62, 62, 62, 62, 62, 62, 62,
3295
+ 62, 62, 62, 62, 62, 62, 62, 62,
3296
+ 62, 62, 8, 60, 12, 12, 12, 12,
3297
+ 12, 12, 12, 12, 12, 12, 12, 12,
3298
+ 12, 12, 12, 12, 12, 12, 12, 12,
3299
+ 12, 12, 60, 12, 61, 12, 12, 12,
3300
+ 12, 12, 12, 12, 12, 12, 12, 12,
3301
+ 12, 12, 63, 63, 63, 63, 63, 63,
3302
+ 63, 63, 63, 63, 12, 12, 12, 12,
3303
+ 12, 12, 12, 63, 63, 63, 63, 63,
3304
+ 63, 63, 63, 63, 63, 63, 63, 63,
3305
+ 63, 63, 63, 63, 63, 63, 63, 63,
3306
+ 63, 63, 63, 63, 63, 12, 12, 12,
3307
+ 12, 63, 12, 63, 63, 63, 63, 63,
3308
+ 63, 63, 63, 63, 63, 63, 63, 63,
3309
+ 63, 63, 63, 63, 63, 63, 63, 63,
3310
+ 63, 63, 63, 63, 63, 12, 65, 64,
3311
+ 64, 64, 64, 64, 64, 64, 64, 64,
3312
+ 64, 64, 64, 64, 64, 64, 64, 64,
3313
+ 64, 64, 64, 64, 64, 64, 64, 64,
3314
+ 64, 64, 64, 64, 64, 64, 64, 64,
3315
+ 64, 64, 64, 64, 64, 64, 64, 64,
3316
+ 64, 64, 64, 64, 64, 64, 64, 64,
3317
+ 64, 64, 64, 64, 64, 64, 64, 64,
3318
+ 66, 64, 67, 17, 17, 17, 17, 17,
3319
+ 17, 17, 17, 17, 17, 17, 17, 17,
3320
+ 17, 17, 17, 17, 17, 17, 17, 17,
3321
+ 17, 67, 17, 17, 17, 17, 17, 17,
3322
+ 17, 17, 68, 17, 17, 69, 17, 70,
3323
+ 6, 6, 6, 6, 6, 6, 6, 6,
3324
+ 6, 6, 6, 6, 6, 6, 6, 6,
3325
+ 6, 6, 6, 6, 6, 6, 70, 6,
3326
+ 6, 6, 6, 6, 6, 6, 6, 6,
3327
+ 6, 6, 71, 6, 71, 8, 8, 8,
3328
+ 8, 8, 8, 8, 8, 8, 8, 8,
3329
+ 8, 8, 8, 8, 8, 8, 8, 8,
3330
+ 8, 8, 8, 71, 8, 61, 8, 8,
3331
+ 8, 8, 8, 8, 8, 8, 8, 8,
3332
+ 8, 8, 8, 62, 62, 62, 62, 62,
3333
+ 62, 62, 62, 62, 62, 8, 8, 8,
3334
+ 8, 8, 8, 8, 62, 62, 62, 62,
3335
+ 62, 62, 62, 62, 62, 62, 62, 62,
3336
+ 62, 62, 62, 62, 62, 62, 62, 62,
3337
+ 62, 62, 62, 62, 62, 62, 8, 8,
3338
+ 8, 8, 62, 8, 62, 62, 62, 62,
3339
+ 62, 62, 62, 62, 62, 62, 62, 62,
3340
+ 62, 62, 62, 62, 62, 62, 62, 62,
3341
+ 62, 62, 62, 62, 62, 62, 8, 72,
3342
+ 0, 0, 0, 0, 0, 0, 0, 0,
3343
+ 0, 0, 0, 0, 0, 0, 0, 0,
3344
+ 0, 0, 0, 0, 0, 0, 72, 0,
3345
+ 0, 0, 0, 0, 0, 0, 73, 74,
3346
+ 0, 0, 75, 0, 0, 0, 76, 76,
3347
+ 76, 76, 76, 76, 76, 76, 76, 76,
3348
+ 77, 0, 0, 0, 0, 0, 0, 76,
3349
+ 76, 76, 76, 76, 76, 76, 76, 76,
3350
+ 76, 76, 76, 76, 76, 76, 76, 76,
3351
+ 76, 76, 76, 76, 76, 76, 76, 76,
3352
+ 76, 0, 0, 0, 0, 76, 0, 76,
3353
+ 76, 76, 76, 76, 76, 76, 76, 76,
3354
+ 76, 76, 76, 76, 76, 76, 76, 76,
3355
+ 76, 76, 76, 76, 76, 76, 76, 76,
3356
+ 76, 0, 70, 6, 6, 6, 6, 6,
3357
+ 6, 6, 6, 6, 6, 6, 6, 6,
3358
+ 6, 6, 6, 6, 6, 6, 6, 6,
3359
+ 6, 70, 6, 6, 6, 6, 6, 6,
3360
+ 6, 6, 78, 6, 6, 71, 6, 66,
3361
+ 64, 72, 0, 0, 0, 0, 0, 0,
3362
+ 0, 0, 0, 0, 0, 0, 0, 0,
3363
+ 0, 0, 0, 0, 0, 0, 0, 0,
3364
+ 72, 0, 0, 0, 0, 0, 0, 0,
3365
+ 0, 74, 0, 0, 75, 0, 0, 0,
3366
+ 79, 79, 79, 79, 79, 79, 79, 79,
3367
+ 79, 79, 0, 0, 0, 0, 0, 0,
3368
+ 0, 79, 79, 79, 79, 79, 79, 79,
3369
+ 79, 79, 79, 79, 79, 79, 79, 79,
3370
+ 79, 79, 79, 79, 79, 79, 79, 79,
3371
+ 79, 79, 79, 0, 0, 0, 0, 79,
3372
+ 0, 79, 79, 79, 79, 79, 79, 79,
3373
+ 79, 79, 79, 79, 79, 79, 79, 79,
3374
+ 79, 79, 79, 79, 79, 79, 79, 79,
3375
+ 79, 79, 79, 0, 6, 6, 6, 6,
3376
+ 6, 0
3377
+ ]
3378
+
3379
+ class << self
3380
+ attr_accessor :_bel_trans_targs
3381
+ private :_bel_trans_targs, :_bel_trans_targs=
3382
+ end
3383
+ self._bel_trans_targs = [
3384
+ 0, 2, 3, 4, 2, 3, 0, 4,
3385
+ 0, 5, 6, 10, 0, 14, 6, 7,
3386
+ 13, 0, 8, 12, 9, 8, 9, 8,
3387
+ 11, 12, 9, 10, 5, 12, 41, 14,
3388
+ 0, 16, 42, 16, 0, 18, 18, 19,
3389
+ 20, 43, 22, 23, 27, 26, 23, 24,
3390
+ 25, 44, 44, 26, 27, 22, 29, 30,
3391
+ 31, 29, 30, 31, 32, 33, 37, 40,
3392
+ 33, 34, 39, 35, 45, 36, 35, 36,
3393
+ 35, 38, 45, 36, 37, 32, 45, 40
3394
+ ]
3395
+
3396
+ class << self
3397
+ attr_accessor :_bel_trans_actions
3398
+ private :_bel_trans_actions, :_bel_trans_actions=
3399
+ end
3400
+ self._bel_trans_actions = [
3401
+ 1, 2, 3, 4, 5, 0, 0, 6,
3402
+ 7, 0, 8, 9, 10, 11, 13, 13,
3403
+ 13, 12, 14, 14, 14, 0, 0, 15,
3404
+ 16, 15, 15, 5, 17, 0, 18, 19,
3405
+ 20, 11, 21, 19, 22, 8, 13, 13,
3406
+ 13, 23, 0, 8, 11, 11, 13, 13,
3407
+ 13, 24, 25, 19, 19, 17, 26, 3,
3408
+ 4, 5, 0, 6, 0, 8, 9, 11,
3409
+ 13, 13, 13, 14, 27, 14, 0, 0,
3410
+ 15, 16, 28, 15, 5, 17, 29, 19
3411
+ ]
3412
+
3413
+ class << self
3414
+ attr_accessor :_bel_eof_actions
3415
+ private :_bel_eof_actions, :_bel_eof_actions=
3416
+ end
3417
+ self._bel_eof_actions = [
3418
+ 0, 1, 1, 0, 7, 10, 12, 12,
3419
+ 0, 7, 1, 0, 0, 12, 1, 20,
3420
+ 20, 22, 22, 22, 22, 7, 10, 12,
3421
+ 12, 12, 1, 1, 1, 1, 0, 7,
3422
+ 10, 12, 12, 0, 7, 1, 0, 12,
3423
+ 1, 0, 0, 0, 0, 0
3424
+ ]
3425
+
3426
+ class << self
3427
+ attr_accessor :bel_start
3428
+ end
3429
+ self.bel_start = 1;
3430
+ class << self
3431
+ attr_accessor :bel_first_final
3432
+ end
3433
+ self.bel_first_final = 41;
3434
+ class << self
3435
+ attr_accessor :bel_error
3436
+ end
3437
+ self.bel_error = 0;
3438
+
3439
+ class << self
3440
+ attr_accessor :bel_en_ident
3441
+ end
3442
+ self.bel_en_ident = 15;
3443
+ class << self
3444
+ attr_accessor :bel_en_string
3445
+ end
3446
+ self.bel_en_string = 17;
3447
+ class << self
3448
+ attr_accessor :bel_en_bel_parameter
3449
+ end
3450
+ self.bel_en_bel_parameter = 21;
3451
+ class << self
3452
+ attr_accessor :bel_en_inner_term
3453
+ end
3454
+ self.bel_en_inner_term = 28;
3455
+ class << self
3456
+ attr_accessor :bel_en_term
3457
+ end
3458
+ self.bel_en_term = 1;
3459
+
3460
+
3461
+ # end: ragel
3462
+ end
3463
+
3464
+ def each
3465
+ @buffers = {}
3466
+ stack = []
3467
+ data = @content.unpack('C*')
3468
+ p = 0
3469
+ pe = data.length
3470
+ eof = data.length
3471
+
3472
+ # begin: ragel
3473
+
3474
+ begin
3475
+ p ||= 0
3476
+ pe ||= data.length
3477
+ cs = bel_start
3478
+ top = 0
3479
+ end
3480
+
3481
+
3482
+ begin
3483
+ testEof = false
3484
+ _slen, _trans, _keys, _inds, _acts, _nacts = nil
3485
+ _goto_level = 0
3486
+ _resume = 10
3487
+ _eof_trans = 15
3488
+ _again = 20
3489
+ _test_eof = 30
3490
+ _out = 40
3491
+ while true
3492
+ if _goto_level <= 0
3493
+ if p == pe
3494
+ _goto_level = _test_eof
3495
+ next
3496
+ end
3497
+ if cs == 0
3498
+ _goto_level = _out
3499
+ next
3500
+ end
3501
+ end
3502
+ if _goto_level <= _resume
3503
+ _keys = cs << 1
3504
+ _inds = _bel_index_offsets[cs]
3505
+ _slen = _bel_key_spans[cs]
3506
+ _wide = data[p].ord
3507
+ _trans = if ( _slen > 0 &&
3508
+ _bel_trans_keys[_keys] <= _wide &&
3509
+ _wide <= _bel_trans_keys[_keys + 1]
3510
+ ) then
3511
+ _bel_indicies[ _inds + _wide - _bel_trans_keys[_keys] ]
3512
+ else
3513
+ _bel_indicies[ _inds + _slen ]
3514
+ end
3515
+ cs = _bel_trans_targs[_trans]
3516
+ if _bel_trans_actions[_trans] != 0
3517
+ case _bel_trans_actions[_trans]
3518
+ when 19 then
3519
+ begin
3520
+
3521
+ (@buffers[:ident] ||= []) << data[p].ord
3522
+ end
3523
+ when 1 then
3524
+ begin
3525
+
3526
+ unless @buffers[:ident].is_a?(::AST::Node)
3527
+ @buffers[:ident] ||= []
3528
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3529
+ end
3530
+ end
3531
+ when 13 then
3532
+ begin
3533
+
3534
+ (@buffers[:string] ||= []) << data[p].ord
3535
+ end
3536
+ when 12 then
3537
+ begin
3538
+
3539
+ @buffers[:string] ||= []
3540
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3541
+ end
3542
+ when 6 then
3543
+ begin
3544
+
3545
+ fx = @buffers[:function]
3546
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
3547
+ end
3548
+ when 29 then
3549
+ begin
3550
+
3551
+ inner_term = @buffers[:term_stack].pop
3552
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
3553
+ begin
3554
+ top -= 1
3555
+ cs = stack[top]
3556
+ _goto_level = _again
3557
+ next
3558
+ end
3559
+
3560
+ end
3561
+ when 18 then
3562
+ begin
3563
+
3564
+ yield @buffers[:term_stack][-1]
3565
+ end
3566
+ when 11 then
3567
+ begin
3568
+
3569
+ @buffers[:ident] = []
3570
+ end
3571
+ begin
3572
+
3573
+ (@buffers[:ident] ||= []) << data[p].ord
3574
+ end
3575
+ when 5 then
3576
+ begin
3577
+
3578
+ (@buffers[:ident] ||= []) << data[p].ord
3579
+ end
3580
+ begin
3581
+
3582
+ @buffers[:function] << data[p].ord
3583
+ end
3584
+ when 21 then
3585
+ begin
3586
+
3587
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3588
+ end
3589
+ begin
3590
+
3591
+ yield @buffers[:ident]
3592
+ end
3593
+ when 17 then
3594
+ begin
3595
+
3596
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3597
+ end
3598
+ begin
3599
+
3600
+ @buffers[:parameter] = parameter(prefix(@buffers[:ident]))
3601
+ end
3602
+ when 3 then
3603
+ begin
3604
+
3605
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3606
+ end
3607
+ begin
3608
+
3609
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
3610
+ end
3611
+ when 16 then
3612
+ begin
3613
+
3614
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3615
+ end
3616
+ begin
3617
+
3618
+ p -= @buffers[:function].length + 1
3619
+ begin
3620
+ stack[top] = cs
3621
+ top+= 1
3622
+ cs = 28
3623
+ _goto_level = _again
3624
+ next
3625
+ end
3626
+
3627
+ end
3628
+ when 20 then
3629
+ begin
3630
+
3631
+ unless @buffers[:ident].is_a?(::AST::Node)
3632
+ @buffers[:ident] ||= []
3633
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3634
+ end
3635
+ end
3636
+ begin
3637
+
3638
+ @buffers[:ident] ||= []
3639
+ yield @buffers[:ident]
3640
+ end
3641
+ when 7 then
3642
+ begin
3643
+
3644
+ unless @buffers[:ident].is_a?(::AST::Node)
3645
+ @buffers[:ident] ||= []
3646
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3647
+ end
3648
+ end
3649
+ begin
3650
+
3651
+ @buffers[:string] ||= []
3652
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3653
+ end
3654
+ when 8 then
3655
+ begin
3656
+
3657
+ @buffers[:string] = []
3658
+ end
3659
+ begin
3660
+
3661
+ (@buffers[:string] ||= []) << data[p].ord
3662
+ end
3663
+ when 23 then
3664
+ begin
3665
+
3666
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
3667
+ end
3668
+ begin
3669
+
3670
+ yield @buffers[:string]
3671
+ end
3672
+ when 10 then
3673
+ begin
3674
+
3675
+ @buffers[:string] ||= []
3676
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3677
+ end
3678
+ begin
3679
+
3680
+ unless @buffers[:ident].is_a?(::AST::Node)
3681
+ @buffers[:ident] ||= []
3682
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3683
+ end
3684
+ end
3685
+ when 22 then
3686
+ begin
3687
+
3688
+ @buffers[:string] ||= []
3689
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3690
+ end
3691
+ begin
3692
+
3693
+ @buffers[:string] ||= []
3694
+ yield @buffers[:string]
3695
+ end
3696
+ when 25 then
3697
+ begin
3698
+
3699
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3700
+ end
3701
+ begin
3702
+
3703
+ @buffers[:parameter] ||= parameter(prefix(nil))
3704
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
3705
+ end
3706
+ begin
3707
+
3708
+ yield @buffers[:parameter]
3709
+ end
3710
+ when 15 then
3711
+ begin
3712
+
3713
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3714
+ end
3715
+ begin
3716
+
3717
+ @buffers[:parameter] ||= parameter(prefix(nil))
3718
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
3719
+ end
3720
+ begin
3721
+
3722
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
3723
+ @buffers[:parameter] = nil
3724
+ end
3725
+ when 4 then
3726
+ begin
3727
+
3728
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3729
+ end
3730
+ begin
3731
+
3732
+ @buffers[:function] = identifier(utf8_string(@buffers[:function]))
3733
+ end
3734
+ begin
3735
+
3736
+ fx = @buffers[:function]
3737
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << function(fx)
3738
+ end
3739
+ when 24 then
3740
+ begin
3741
+
3742
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
3743
+ end
3744
+ begin
3745
+
3746
+ @buffers[:parameter] ||= parameter(prefix(nil))
3747
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
3748
+ end
3749
+ begin
3750
+
3751
+ yield @buffers[:parameter]
3752
+ end
3753
+ when 14 then
3754
+ begin
3755
+
3756
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
3757
+ end
3758
+ begin
3759
+
3760
+ @buffers[:parameter] ||= parameter(prefix(nil))
3761
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
3762
+ end
3763
+ begin
3764
+
3765
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
3766
+ @buffers[:parameter] = nil
3767
+ end
3768
+ when 9 then
3769
+ begin
3770
+
3771
+ @buffers[:ident] = []
3772
+ end
3773
+ begin
3774
+
3775
+ (@buffers[:ident] ||= []) << data[p].ord
3776
+ end
3777
+ begin
3778
+
3779
+ @buffers[:function] = []
3780
+ end
3781
+ begin
3782
+
3783
+ @buffers[:function] << data[p].ord
3784
+ end
3785
+ when 28 then
3786
+ begin
3787
+
3788
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]))
3789
+ end
3790
+ begin
3791
+
3792
+ @buffers[:parameter] ||= parameter(prefix(nil))
3793
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:ident])
3794
+ end
3795
+ begin
3796
+
3797
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
3798
+ @buffers[:parameter] = nil
3799
+ end
3800
+ begin
3801
+
3802
+ inner_term = @buffers[:term_stack].pop
3803
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
3804
+ begin
3805
+ top -= 1
3806
+ cs = stack[top]
3807
+ _goto_level = _again
3808
+ next
3809
+ end
3810
+
3811
+ end
3812
+ when 27 then
3813
+ begin
3814
+
3815
+ @buffers[:string] = string(utf8_string(@buffers[:string]))
3816
+ end
3817
+ begin
3818
+
3819
+ @buffers[:parameter] ||= parameter(prefix(nil))
3820
+ @buffers[:parameter] = @buffers[:parameter] << value(@buffers[:string])
3821
+ end
3822
+ begin
3823
+
3824
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(@buffers[:parameter])
3825
+ @buffers[:parameter] = nil
3826
+ end
3827
+ begin
3828
+
3829
+ inner_term = @buffers[:term_stack].pop
3830
+ @buffers[:term_stack][-1] = @buffers[:term_stack][-1] << argument(inner_term)
3831
+ begin
3832
+ top -= 1
3833
+ cs = stack[top]
3834
+ _goto_level = _again
3835
+ next
3836
+ end
3837
+
3838
+ end
3839
+ when 2 then
3840
+ begin
3841
+
3842
+ @buffers[:term_stack] = [ term() ]
3843
+ end
3844
+ begin
3845
+
3846
+ @buffers[:function] = []
3847
+ end
3848
+ begin
3849
+
3850
+ @buffers[:ident] = []
3851
+ end
3852
+ begin
3853
+
3854
+ (@buffers[:ident] ||= []) << data[p].ord
3855
+ end
3856
+ begin
3857
+
3858
+ @buffers[:function] << data[p].ord
3859
+ end
3860
+ when 26 then
3861
+ begin
3862
+
3863
+ @buffers[:term_stack] << term()
3864
+ end
3865
+ begin
3866
+
3867
+ @buffers[:function] = []
3868
+ end
3869
+ begin
3870
+
3871
+ @buffers[:ident] = []
3872
+ end
3873
+ begin
3874
+
3875
+ (@buffers[:ident] ||= []) << data[p].ord
3876
+ end
3877
+ begin
3878
+
3879
+ @buffers[:function] << data[p].ord
3880
+ end
3881
+ end
3882
+ end
3883
+ end
3884
+ if _goto_level <= _again
3885
+ if cs == 0
3886
+ _goto_level = _out
3887
+ next
3888
+ end
3889
+ p += 1
3890
+ if p != pe
3891
+ _goto_level = _resume
3892
+ next
3893
+ end
3894
+ end
3895
+ if _goto_level <= _test_eof
3896
+ if p == eof
3897
+ case _bel_eof_actions[cs]
3898
+ when 1 then
3899
+ begin
3900
+
3901
+ unless @buffers[:ident].is_a?(::AST::Node)
3902
+ @buffers[:ident] ||= []
3903
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3904
+ end
3905
+ end
3906
+ when 12 then
3907
+ begin
3908
+
3909
+ @buffers[:string] ||= []
3910
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3911
+ end
3912
+ when 20 then
3913
+ begin
3914
+
3915
+ unless @buffers[:ident].is_a?(::AST::Node)
3916
+ @buffers[:ident] ||= []
3917
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3918
+ end
3919
+ end
3920
+ begin
3921
+
3922
+ @buffers[:ident] ||= []
3923
+ yield @buffers[:ident]
3924
+ end
3925
+ when 7 then
3926
+ begin
3927
+
3928
+ unless @buffers[:ident].is_a?(::AST::Node)
3929
+ @buffers[:ident] ||= []
3930
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3931
+ end
3932
+ end
3933
+ begin
3934
+
3935
+ @buffers[:string] ||= []
3936
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3937
+ end
3938
+ when 10 then
3939
+ begin
3940
+
3941
+ @buffers[:string] ||= []
3942
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3943
+ end
3944
+ begin
3945
+
3946
+ unless @buffers[:ident].is_a?(::AST::Node)
3947
+ @buffers[:ident] ||= []
3948
+ @buffers[:ident] = identifier(utf8_string(@buffers[:ident]).sub(/\n$/, ''))
3949
+ end
3950
+ end
3951
+ when 22 then
3952
+ begin
3953
+
3954
+ @buffers[:string] ||= []
3955
+ @buffers[:string] = string(utf8_string(@buffers[:string]).sub(/\n$/, ''))
3956
+ end
3957
+ begin
3958
+
3959
+ @buffers[:string] ||= []
3960
+ yield @buffers[:string]
3961
+ end
3962
+ end
3963
+ end
3964
+
3965
+ end
3966
+ if _goto_level <= _out
3967
+ break
3968
+ end
3969
+ end
3970
+ end
3971
+
3972
+ # end: ragel
3973
+ end
3974
+ end
3975
+ end
3976
+ end
3977
+ end
3978
+ end
3979
+
3980
+ if __FILE__ == $0
3981
+ $stdin.each_line do |line|
3982
+ BELParser::Parsers::Expression::Term.parse(line) { |obj|
3983
+ puts obj.inspect
3984
+ }
3985
+ end
3986
+ end
3987
+
3988
+ # vim: ft=ruby ts=2 sw=2:
3989
+ # encoding: utf-8