gherkin
Version:
A fast Gherkin lexer/parser based on the Ragel State Machine Compiler.
1,031 lines (966 loc) • 32.6 kB
JavaScript
/* line 1 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
;(function() {
/* line 117 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
/* line 11 "js/lib/gherkin/lexer/it.js" */
const _lexer_actions = [
0, 1, 0, 1, 1, 1, 2, 1,
3, 1, 4, 1, 5, 1, 6, 1,
7, 1, 8, 1, 9, 1, 10, 1,
11, 1, 14, 1, 15, 1, 16, 1,
17, 1, 18, 1, 19, 1, 20, 1,
21, 2, 2, 16, 2, 11, 0, 2,
12, 13, 2, 15, 0, 2, 15, 1,
2, 15, 14, 2, 15, 17, 2, 16,
4, 2, 16, 5, 2, 16, 6, 2,
16, 7, 2, 16, 8, 2, 16, 14,
2, 18, 19, 2, 20, 0, 2, 20,
1, 2, 20, 14, 2, 20, 17, 3,
3, 12, 13, 3, 9, 12, 13, 3,
10, 12, 13, 3, 11, 12, 13, 3,
12, 13, 16, 3, 15, 12, 13, 4,
2, 12, 13, 16, 4, 15, 0, 12,
13
];
const _lexer_key_offsets = [
0, 0, 19, 37, 38, 39, 43, 48,
53, 58, 63, 67, 71, 73, 74, 75,
76, 77, 78, 79, 80, 81, 82, 83,
84, 85, 86, 87, 88, 89, 90, 92,
97, 104, 109, 110, 111, 112, 113, 114,
115, 116, 117, 118, 119, 120, 121, 122,
123, 124, 139, 141, 143, 145, 147, 149,
151, 153, 155, 157, 159, 161, 163, 165,
167, 169, 187, 188, 189, 190, 192, 193,
194, 195, 196, 197, 198, 199, 206, 208,
210, 212, 214, 216, 218, 220, 222, 224,
226, 228, 230, 232, 233, 234, 235, 236,
237, 238, 239, 240, 241, 242, 243, 244,
245, 246, 247, 258, 260, 262, 264, 266,
268, 270, 272, 274, 276, 278, 280, 282,
284, 286, 288, 290, 292, 294, 296, 298,
300, 302, 304, 306, 308, 310, 312, 314,
316, 318, 320, 322, 324, 326, 328, 330,
332, 334, 336, 338, 341, 343, 345, 347,
349, 351, 353, 355, 357, 359, 361, 363,
365, 367, 369, 371, 373, 375, 376, 377,
378, 379, 380, 382, 383, 384, 385, 386,
387, 388, 389, 390, 406, 408, 410, 412,
414, 416, 418, 420, 422, 424, 426, 428,
430, 432, 434, 436, 438, 440, 442, 444,
446, 448, 450, 452, 454, 456, 458, 460,
462, 464, 466, 468, 470, 472, 474, 476,
478, 480, 482, 484, 486, 488, 490, 492,
494, 496, 498, 500, 502, 505, 507, 509,
511, 513, 515, 517, 519, 521, 523, 525,
527, 529, 531, 533, 535, 537, 539, 540,
541, 542, 543, 544, 545, 546, 547, 548,
549, 550, 551, 552, 553, 554, 555, 556,
557, 558, 559, 560, 575, 577, 579, 581,
583, 585, 587, 589, 591, 593, 595, 597,
599, 601, 603, 605, 607, 609, 611, 613,
615, 617, 619, 621, 623, 625, 627, 629,
631, 633, 635, 637, 639, 641, 643, 645,
647, 649, 651, 653, 655, 657, 659, 661,
663, 665, 667, 669, 673, 679, 682, 684,
690, 708, 710, 712, 714, 716, 718, 720,
722, 724, 726, 728, 730, 732, 734, 736,
738, 740, 742, 744, 746, 748, 750, 752,
754, 756, 758, 760, 763, 765, 767, 769,
771, 773, 775, 777, 779, 781, 783, 785,
787, 789, 791, 793, 795, 797, 799, 800,
801
];
const _lexer_trans_keys = [
10, 32, 34, 35, 37, 42, 64, 65,
67, 68, 69, 70, 77, 81, 83, 124,
239, 9, 13, 10, 32, 34, 35, 37,
42, 64, 65, 67, 68, 69, 70, 77,
81, 83, 124, 9, 13, 34, 34, 10,
32, 9, 13, 10, 32, 34, 9, 13,
10, 32, 34, 9, 13, 10, 32, 34,
9, 13, 10, 32, 34, 9, 13, 10,
32, 9, 13, 10, 32, 9, 13, 10,
13, 10, 95, 70, 69, 65, 84, 85,
82, 69, 95, 69, 78, 68, 95, 37,
32, 10, 10, 13, 13, 32, 64, 9,
10, 9, 10, 13, 32, 64, 11, 12,
10, 32, 64, 9, 13, 108, 108, 111,
114, 97, 111, 110, 116, 101, 115, 116,
111, 58, 10, 10, 10, 32, 35, 37,
42, 64, 65, 68, 69, 70, 77, 81,
83, 9, 13, 10, 95, 10, 70, 10,
69, 10, 65, 10, 84, 10, 85, 10,
82, 10, 69, 10, 95, 10, 69, 10,
78, 10, 68, 10, 95, 10, 37, 10,
32, 10, 32, 34, 35, 37, 42, 64,
65, 67, 68, 69, 70, 77, 81, 83,
124, 9, 13, 97, 116, 111, 32, 115,
101, 109, 112, 105, 58, 10, 10, 10,
32, 35, 70, 124, 9, 13, 10, 117,
10, 110, 10, 122, 10, 105, 10, 111,
10, 110, 10, 97, 10, 108, 10, 105,
10, 116, -61, 10, -96, 10, 10, 58,
117, 110, 122, 105, 111, 110, 97, 108,
105, 116, -61, -96, 58, 10, 10, 10,
32, 35, 37, 64, 67, 69, 70, 83,
9, 13, 10, 95, 10, 70, 10, 69,
10, 65, 10, 84, 10, 85, 10, 82,
10, 69, 10, 95, 10, 69, 10, 78,
10, 68, 10, 95, 10, 37, 10, 111,
10, 110, 10, 116, 10, 101, 10, 115,
10, 116, 10, 111, 10, 58, 10, 115,
10, 101, 10, 109, 10, 112, 10, 105,
10, 117, 10, 110, 10, 122, 10, 105,
10, 111, 10, 110, 10, 97, 10, 108,
10, 105, 10, 116, -61, 10, -96, 10,
10, 99, 10, 101, 104, 10, 110, 10,
97, 10, 114, 10, 105, 10, 101, 10,
109, 10, 97, 10, 32, 10, 100, 10,
101, 10, 108, 10, 108, 10, 111, 10,
32, 10, 115, 10, 99, 10, 101, 117,
97, 110, 100, 99, 101, 104, 110, 97,
114, 105, 111, 58, 10, 10, 10, 32,
35, 37, 42, 64, 65, 67, 68, 69,
70, 77, 81, 83, 9, 13, 10, 95,
10, 70, 10, 69, 10, 65, 10, 84,
10, 85, 10, 82, 10, 69, 10, 95,
10, 69, 10, 78, 10, 68, 10, 95,
10, 37, 10, 32, 10, 108, 10, 108,
10, 111, 10, 114, 10, 97, 10, 111,
10, 110, 10, 116, 10, 101, 10, 115,
10, 116, 10, 111, 10, 58, 10, 97,
10, 116, 10, 111, 10, 117, 10, 110,
10, 122, 10, 105, 10, 111, 10, 110,
10, 97, 10, 108, 10, 105, 10, 116,
-61, 10, -96, 10, 10, 117, 10, 97,
10, 110, 10, 100, 10, 99, 10, 101,
104, 10, 110, 10, 97, 10, 114, 10,
105, 10, 101, 10, 109, 10, 97, 10,
32, 10, 100, 10, 101, 10, 108, 10,
108, 10, 111, 10, 32, 10, 115, 10,
99, 10, 101, 101, 109, 97, 32, 100,
101, 108, 108, 111, 32, 115, 99, 101,
110, 97, 114, 105, 111, 58, 10, 10,
10, 32, 35, 37, 42, 64, 65, 68,
69, 70, 77, 81, 83, 9, 13, 10,
95, 10, 70, 10, 69, 10, 65, 10,
84, 10, 85, 10, 82, 10, 69, 10,
95, 10, 69, 10, 78, 10, 68, 10,
95, 10, 37, 10, 32, 10, 108, 10,
108, 10, 111, 10, 114, 10, 97, 10,
97, 10, 116, 10, 111, 10, 117, 10,
110, 10, 122, 10, 105, 10, 111, 10,
110, 10, 97, 10, 108, 10, 105, 10,
116, -61, 10, -96, 10, 10, 58, 10,
117, 10, 97, 10, 110, 10, 100, 10,
99, 10, 101, 10, 110, 10, 97, 10,
114, 10, 105, 10, 111, 32, 124, 9,
13, 10, 32, 92, 124, 9, 13, 10,
92, 124, 10, 92, 10, 32, 92, 124,
9, 13, 10, 32, 34, 35, 37, 42,
64, 65, 67, 68, 69, 70, 77, 81,
83, 124, 9, 13, 10, 108, 10, 108,
10, 111, 10, 114, 10, 97, 10, 97,
10, 116, 10, 111, 10, 117, 10, 110,
10, 122, 10, 105, 10, 111, 10, 110,
10, 97, 10, 108, 10, 105, 10, 116,
-61, 10, -96, 10, 10, 58, 10, 117,
10, 97, 10, 110, 10, 100, 10, 99,
10, 101, 104, 10, 110, 10, 97, 10,
114, 10, 105, 10, 111, 10, 101, 10,
109, 10, 97, 10, 32, 10, 100, 10,
101, 10, 108, 10,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, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 1, 1, 0, 0, 1,
1, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0
];
const _lexer_index_offsets = [
0, 0, 19, 37, 39, 41, 45, 50,
55, 60, 65, 69, 73, 76, 78, 80,
82, 84, 86, 88, 90, 92, 94, 96,
98, 100, 102, 104, 106, 108, 110, 113,
118, 125, 130, 132, 134, 136, 138, 140,
142, 144, 146, 148, 150, 152, 154, 156,
158, 160, 175, 178, 181, 184, 187, 190,
193, 196, 199, 202, 205, 208, 211, 214,
217, 220, 238, 240, 242, 244, 247, 249,
251, 253, 255, 257, 259, 261, 268, 271,
274, 277, 280, 283, 286, 289, 292, 295,
298, 301, 304, 307, 309, 311, 313, 315,
317, 319, 321, 323, 325, 327, 329, 331,
333, 335, 337, 348, 351, 354, 357, 360,
363, 366, 369, 372, 375, 378, 381, 384,
387, 390, 393, 396, 399, 402, 405, 408,
411, 414, 417, 420, 423, 426, 429, 432,
435, 438, 441, 444, 447, 450, 453, 456,
459, 462, 465, 468, 472, 475, 478, 481,
484, 487, 490, 493, 496, 499, 502, 505,
508, 511, 514, 517, 520, 523, 525, 527,
529, 531, 533, 536, 538, 540, 542, 544,
546, 548, 550, 552, 568, 571, 574, 577,
580, 583, 586, 589, 592, 595, 598, 601,
604, 607, 610, 613, 616, 619, 622, 625,
628, 631, 634, 637, 640, 643, 646, 649,
652, 655, 658, 661, 664, 667, 670, 673,
676, 679, 682, 685, 688, 691, 694, 697,
700, 703, 706, 709, 712, 716, 719, 722,
725, 728, 731, 734, 737, 740, 743, 746,
749, 752, 755, 758, 761, 764, 767, 769,
771, 773, 775, 777, 779, 781, 783, 785,
787, 789, 791, 793, 795, 797, 799, 801,
803, 805, 807, 809, 824, 827, 830, 833,
836, 839, 842, 845, 848, 851, 854, 857,
860, 863, 866, 869, 872, 875, 878, 881,
884, 887, 890, 893, 896, 899, 902, 905,
908, 911, 914, 917, 920, 923, 926, 929,
932, 935, 938, 941, 944, 947, 950, 953,
956, 959, 962, 965, 969, 975, 979, 982,
988, 1006, 1009, 1012, 1015, 1018, 1021, 1024,
1027, 1030, 1033, 1036, 1039, 1042, 1045, 1048,
1051, 1054, 1057, 1060, 1063, 1066, 1069, 1072,
1075, 1078, 1081, 1084, 1088, 1091, 1094, 1097,
1100, 1103, 1106, 1109, 1112, 1115, 1118, 1121,
1124, 1127, 1130, 1133, 1136, 1139, 1142, 1144,
1146
];
const _lexer_indicies = [
2, 1, 3, 4, 5, 6, 7, 8,
9, 10, 11, 12, 13, 14, 15, 16,
17, 1, 0, 2, 1, 3, 4, 5,
6, 7, 8, 9, 10, 11, 12, 13,
14, 15, 16, 1, 0, 18, 0, 19,
0, 20, 19, 19, 0, 23, 22, 24,
22, 21, 27, 26, 28, 26, 25, 27,
26, 29, 26, 25, 27, 26, 30, 26,
25, 32, 31, 31, 0, 2, 33, 33,
0, 35, 36, 34, 2, 0, 37, 0,
38, 0, 39, 0, 40, 0, 41, 0,
42, 0, 43, 0, 44, 0, 45, 0,
46, 0, 47, 0, 48, 0, 49, 0,
50, 0, 51, 0, 0, 52, 54, 55,
53, 0, 0, 0, 0, 56, 57, 58,
57, 57, 60, 59, 56, 2, 61, 7,
61, 0, 62, 0, 63, 0, 64, 0,
65, 0, 66, 0, 67, 0, 68, 0,
69, 0, 70, 0, 71, 0, 72, 0,
73, 0, 74, 0, 76, 75, 78, 77,
78, 79, 80, 81, 82, 80, 83, 84,
82, 85, 86, 87, 88, 79, 77, 78,
89, 77, 78, 90, 77, 78, 91, 77,
78, 92, 77, 78, 93, 77, 78, 94,
77, 78, 95, 77, 78, 96, 77, 78,
97, 77, 78, 98, 77, 78, 99, 77,
78, 100, 77, 78, 101, 77, 78, 102,
77, 78, 103, 77, 105, 104, 106, 107,
108, 109, 110, 111, 112, 113, 114, 115,
116, 117, 118, 119, 104, 0, 120, 0,
121, 0, 66, 0, 51, 122, 0, 123,
0, 124, 0, 125, 0, 126, 0, 127,
0, 129, 128, 131, 130, 131, 132, 133,
134, 133, 132, 130, 131, 135, 130, 131,
136, 130, 131, 137, 130, 131, 138, 130,
131, 139, 130, 131, 140, 130, 131, 141,
130, 131, 142, 130, 131, 143, 130, 131,
144, 130, 145, 131, 130, 146, 131, 130,
131, 147, 130, 148, 0, 149, 0, 150,
0, 151, 0, 152, 0, 153, 0, 154,
0, 155, 0, 156, 0, 157, 0, 158,
0, 159, 0, 160, 0, 162, 161, 164,
163, 164, 165, 166, 167, 166, 168, 169,
170, 171, 165, 163, 164, 172, 163, 164,
173, 163, 164, 174, 163, 164, 175, 163,
164, 176, 163, 164, 177, 163, 164, 178,
163, 164, 179, 163, 164, 180, 163, 164,
181, 163, 164, 182, 163, 164, 183, 163,
164, 184, 163, 164, 185, 163, 164, 186,
163, 164, 187, 163, 164, 188, 163, 164,
189, 163, 164, 190, 163, 164, 191, 163,
164, 192, 163, 164, 193, 163, 164, 194,
163, 164, 195, 163, 164, 196, 163, 164,
197, 163, 164, 192, 163, 164, 198, 163,
164, 199, 163, 164, 200, 163, 164, 201,
163, 164, 202, 163, 164, 203, 163, 164,
204, 163, 164, 205, 163, 164, 206, 163,
164, 207, 163, 208, 164, 163, 192, 164,
163, 164, 209, 163, 164, 210, 211, 163,
164, 212, 163, 164, 213, 163, 164, 214,
163, 164, 191, 163, 164, 215, 163, 164,
216, 163, 164, 217, 163, 164, 218, 163,
164, 219, 163, 164, 220, 163, 164, 221,
163, 164, 222, 163, 164, 223, 163, 164,
224, 163, 164, 225, 163, 164, 226, 163,
164, 210, 163, 227, 0, 228, 0, 229,
0, 121, 0, 230, 0, 231, 232, 0,
233, 0, 234, 0, 235, 0, 236, 0,
237, 0, 238, 0, 240, 239, 242, 241,
242, 243, 244, 245, 246, 244, 247, 248,
249, 246, 250, 251, 252, 253, 243, 241,
242, 254, 241, 242, 255, 241, 242, 256,
241, 242, 257, 241, 242, 258, 241, 242,
259, 241, 242, 260, 241, 242, 261, 241,
242, 262, 241, 242, 263, 241, 242, 264,
241, 242, 265, 241, 242, 266, 241, 242,
267, 241, 242, 268, 241, 242, 269, 241,
242, 270, 241, 242, 271, 241, 242, 272,
241, 242, 273, 241, 242, 274, 241, 242,
275, 241, 242, 276, 241, 242, 277, 241,
242, 278, 241, 242, 279, 241, 242, 280,
241, 242, 268, 241, 242, 281, 241, 242,
282, 241, 242, 273, 241, 242, 283, 241,
242, 284, 241, 242, 285, 241, 242, 286,
241, 242, 287, 241, 242, 288, 241, 242,
289, 241, 242, 290, 241, 242, 291, 241,
242, 292, 241, 293, 242, 241, 280, 242,
241, 242, 294, 241, 242, 295, 241, 242,
296, 241, 242, 282, 241, 242, 297, 241,
242, 298, 299, 241, 242, 300, 241, 242,
301, 241, 242, 302, 241, 242, 279, 241,
242, 303, 241, 242, 304, 241, 242, 305,
241, 242, 306, 241, 242, 307, 241, 242,
308, 241, 242, 309, 241, 242, 310, 241,
242, 311, 241, 242, 312, 241, 242, 313,
241, 242, 314, 241, 242, 298, 241, 315,
0, 316, 0, 317, 0, 318, 0, 319,
0, 320, 0, 321, 0, 322, 0, 323,
0, 324, 0, 325, 0, 326, 0, 327,
0, 328, 0, 329, 0, 330, 0, 331,
0, 332, 0, 333, 0, 335, 334, 337,
336, 337, 338, 339, 340, 341, 339, 342,
343, 341, 344, 345, 346, 347, 338, 336,
337, 348, 336, 337, 349, 336, 337, 350,
336, 337, 351, 336, 337, 352, 336, 337,
353, 336, 337, 354, 336, 337, 355, 336,
337, 356, 336, 337, 357, 336, 337, 358,
336, 337, 359, 336, 337, 360, 336, 337,
361, 336, 337, 362, 336, 337, 363, 336,
337, 364, 336, 337, 365, 336, 337, 366,
336, 337, 367, 336, 337, 368, 336, 337,
369, 336, 337, 367, 336, 337, 370, 336,
337, 371, 336, 337, 372, 336, 337, 373,
336, 337, 374, 336, 337, 375, 336, 337,
376, 336, 337, 377, 336, 337, 378, 336,
337, 379, 336, 380, 337, 336, 381, 337,
336, 337, 362, 336, 337, 382, 336, 337,
383, 336, 337, 384, 336, 337, 369, 336,
337, 385, 336, 337, 386, 336, 337, 387,
336, 337, 388, 336, 337, 389, 336, 337,
390, 336, 337, 381, 336, 391, 392, 391,
0, 395, 394, 396, 397, 394, 393, 0,
399, 400, 398, 0, 399, 398, 395, 401,
399, 400, 401, 398, 395, 402, 403, 404,
405, 406, 407, 408, 409, 410, 411, 412,
413, 414, 415, 416, 402, 0, 78, 417,
77, 78, 418, 77, 78, 419, 77, 78,
420, 77, 78, 421, 77, 78, 422, 77,
78, 423, 77, 78, 421, 77, 78, 424,
77, 78, 425, 77, 78, 426, 77, 78,
427, 77, 78, 428, 77, 78, 429, 77,
78, 430, 77, 78, 431, 77, 78, 432,
77, 78, 433, 77, 434, 78, 77, 435,
78, 77, 78, 103, 77, 78, 436, 77,
78, 437, 77, 78, 438, 77, 78, 423,
77, 78, 439, 77, 78, 440, 441, 77,
78, 442, 77, 78, 443, 77, 78, 444,
77, 78, 445, 77, 78, 435, 77, 78,
446, 77, 78, 447, 77, 78, 448, 77,
78, 449, 77, 78, 450, 77, 78, 451,
77, 78, 452, 77, 78, 453, 77, 78,
454, 77, 78, 455, 77, 78, 456, 77,
78, 457, 77, 78, 440, 77, 458, 0,
1, 0, 459, 0
];
const _lexer_trans_targs = [
0, 2, 2, 3, 12, 14, 28, 31,
34, 39, 66, 69, 91, 38, 165, 169,
315, 366, 4, 5, 6, 7, 7, 7,
8, 7, 7, 7, 8, 9, 10, 11,
2, 11, 12, 2, 13, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25,
26, 27, 368, 29, 30, 30, 2, 13,
32, 33, 2, 32, 31, 33, 35, 36,
37, 38, 28, 40, 41, 42, 43, 44,
45, 46, 47, 48, 49, 48, 49, 49,
2, 50, 64, 321, 326, 329, 325, 342,
346, 51, 52, 53, 54, 55, 56, 57,
58, 59, 60, 61, 62, 63, 2, 65,
2, 2, 3, 12, 14, 28, 31, 34,
39, 66, 69, 91, 38, 165, 169, 315,
67, 68, 70, 71, 72, 73, 74, 75,
76, 77, 76, 77, 77, 2, 78, 79,
80, 81, 82, 83, 84, 85, 86, 87,
88, 89, 90, 65, 92, 93, 94, 95,
96, 97, 98, 99, 100, 101, 102, 103,
104, 105, 106, 105, 106, 106, 2, 107,
121, 129, 134, 146, 108, 109, 110, 111,
112, 113, 114, 115, 116, 117, 118, 119,
120, 2, 122, 123, 124, 125, 126, 127,
128, 65, 130, 131, 132, 133, 135, 136,
137, 138, 139, 140, 141, 142, 143, 144,
145, 147, 148, 152, 149, 150, 151, 153,
154, 155, 156, 157, 158, 159, 160, 161,
162, 163, 164, 166, 167, 168, 170, 171,
246, 172, 173, 174, 175, 176, 177, 178,
179, 178, 179, 179, 2, 180, 194, 195,
200, 208, 211, 199, 223, 227, 181, 182,
183, 184, 185, 186, 187, 188, 189, 190,
191, 192, 193, 2, 65, 196, 197, 198,
199, 194, 201, 202, 203, 204, 205, 206,
207, 209, 210, 212, 213, 214, 215, 216,
217, 218, 219, 220, 221, 222, 224, 225,
226, 228, 229, 233, 230, 231, 232, 234,
235, 236, 237, 238, 239, 240, 241, 242,
243, 244, 245, 247, 248, 249, 250, 251,
252, 253, 254, 255, 256, 257, 258, 259,
260, 261, 262, 263, 264, 265, 266, 267,
266, 267, 267, 2, 268, 282, 283, 288,
291, 287, 304, 308, 269, 270, 271, 272,
273, 274, 275, 276, 277, 278, 279, 280,
281, 2, 65, 284, 285, 286, 287, 282,
289, 290, 292, 293, 294, 295, 296, 297,
298, 299, 300, 301, 302, 303, 305, 306,
307, 309, 310, 311, 312, 313, 314, 315,
316, 317, 319, 320, 318, 316, 317, 318,
316, 319, 320, 3, 12, 14, 28, 31,
34, 39, 66, 69, 91, 38, 165, 169,
315, 322, 323, 324, 325, 64, 327, 328,
330, 331, 332, 333, 334, 335, 336, 337,
338, 339, 340, 341, 343, 344, 345, 347,
348, 353, 349, 350, 351, 352, 354, 355,
356, 357, 358, 359, 360, 361, 362, 363,
364, 365, 367, 0
];
const _lexer_trans_actions = [
39, 0, 47, 3, 1, 0, 25, 1,
25, 25, 25, 25, 25, 25, 25, 25,
31, 0, 0, 0, 47, 5, 41, 119,
41, 0, 29, 111, 29, 29, 0, 7,
95, 0, 0, 103, 21, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 50, 0, 99, 19,
0, 23, 107, 23, 44, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 50, 124, 0, 47, 0,
65, 29, 77, 77, 77, 77, 77, 77,
77, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 11, 11,
27, 115, 53, 50, 27, 56, 50, 56,
56, 56, 56, 56, 56, 56, 56, 59,
0, 0, 0, 0, 0, 0, 0, 0,
50, 124, 0, 47, 0, 74, 77, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 17, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 50, 124, 0, 47, 0, 62, 29,
77, 77, 77, 77, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 9, 0, 0, 0, 0, 0, 0,
0, 9, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 50,
124, 0, 47, 0, 68, 29, 77, 77,
77, 77, 77, 77, 77, 77, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 13, 13, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 50, 124,
0, 47, 0, 71, 29, 77, 77, 77,
77, 77, 77, 77, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 15, 15, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 33, 33, 47, 33, 80, 0, 0,
35, 0, 0, 86, 83, 37, 89, 83,
89, 89, 89, 89, 89, 89, 89, 89,
92, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0
];
const _lexer_eof_actions = [
0, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39,
39
];
const lexer_start = 1;
const lexer_first_final = 368;
const lexer_error = 0;
const lexer_en_main = 1;
/* line 120 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
/* line 121 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
/* line 122 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
var Lexer = function(listener) {
// Check that listener has the required functions
var events = ['comment', 'tag', 'feature', 'background', 'scenario', 'scenario_outline', 'examples', 'step', 'doc_string', 'row', 'eof'];
for(e in events) {
var event = events[e];
if(typeof listener[event] != 'function') {
"Error. No " + event + " function exists on " + JSON.stringify(listener);
}
}
this.listener = listener;
};
Lexer.prototype.scan = function(data) {
var ending = "\n%_FEATURE_END_%";
if(typeof data == 'string') {
data = this.stringToBytes(data + ending);
} else if(typeof Buffer != 'undefined' && Buffer.isBuffer(data)) {
// Node.js
var buf = new Buffer(data.length + ending.length);
data.copy(buf, 0, 0);
new Buffer(ending).copy(buf, data.length, 0);
data = buf;
}
var eof = pe = data.length;
var p = 0;
this.line_number = 1;
this.last_newline = 0;
/* line 698 "js/lib/gherkin/lexer/it.js" */
{
this.cs = lexer_start;
} /* JSCodeGen::writeInit */
/* line 153 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
/* line 705 "js/lib/gherkin/lexer/it.js" */
{
var _klen, _trans, _keys, _ps, _widec, _acts, _nacts;
var _goto_level, _resume, _eof_trans, _again, _test_eof;
var _out;
_klen = _trans = _keys = _acts = _nacts = null;
_goto_level = 0;
_resume = 10;
_eof_trans = 15;
_again = 20;
_test_eof = 30;
_out = 40;
while (true) {
_trigger_goto = false;
if (_goto_level <= 0) {
if (p == pe) {
_goto_level = _test_eof;
continue;
}
if ( this.cs == 0) {
_goto_level = _out;
continue;
}
}
if (_goto_level <= _resume) {
_keys = _lexer_key_offsets[ this.cs];
_trans = _lexer_index_offsets[ this.cs];
_klen = _lexer_single_lengths[ this.cs];
_break_match = false;
do {
if (_klen > 0) {
_lower = _keys;
_upper = _keys + _klen - 1;
while (true) {
if (_upper < _lower) { break; }
_mid = _lower + ( (_upper - _lower) >> 1 );
if ( data[p] < _lexer_trans_keys[_mid]) {
_upper = _mid - 1;
} else if ( data[p] > _lexer_trans_keys[_mid]) {
_lower = _mid + 1;
} else {
_trans += (_mid - _keys);
_break_match = true;
break;
};
} /* while */
if (_break_match) { break; }
_keys += _klen;
_trans += _klen;
}
_klen = _lexer_range_lengths[ this.cs];
if (_klen > 0) {
_lower = _keys;
_upper = _keys + (_klen << 1) - 2;
while (true) {
if (_upper < _lower) { break; }
_mid = _lower + (((_upper-_lower) >> 1) & ~1);
if ( data[p] < _lexer_trans_keys[_mid]) {
_upper = _mid - 2;
} else if ( data[p] > _lexer_trans_keys[_mid+1]) {
_lower = _mid + 2;
} else {
_trans += ((_mid - _keys) >> 1);
_break_match = true;
break;
}
} /* while */
if (_break_match) { break; }
_trans += _klen
}
} while (false);
_trans = _lexer_indicies[_trans];
this.cs = _lexer_trans_targs[_trans];
if (_lexer_trans_actions[_trans] != 0) {
_acts = _lexer_trans_actions[_trans];
_nacts = _lexer_actions[_acts];
_acts += 1;
while (_nacts > 0) {
_nacts -= 1;
_acts += 1;
switch (_lexer_actions[_acts - 1]) {
case 0:
/* line 6 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.content_start = p;
this.current_line = this.line_number;
this.start_col = p - this.last_newline - (this.keyword+':').length;
break;
case 1:
/* line 12 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.current_line = this.line_number;
this.start_col = p - this.last_newline;
break;
case 2:
/* line 17 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.content_start = p;
break;
case 3:
/* line 21 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
var con = this.unindent(
this.start_col,
this.bytesToString(data.slice(this.content_start, this.next_keyword_start-1)).replace(/(\r?\n)?([\t ])*$/, '').replace(/\\\"\\\"\\\"/mg, '"""')
);
this.listener.doc_string(con, this.current_line);
break;
case 4:
/* line 29 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
p = this.store_keyword_content('feature', data, p, eof);
break;
case 5:
/* line 33 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
p = this.store_keyword_content('background', data, p, eof);
break;
case 6:
/* line 37 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
p = this.store_keyword_content('scenario', data, p, eof);
break;
case 7:
/* line 41 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
p = this.store_keyword_content('scenario_outline', data, p, eof);
break;
case 8:
/* line 45 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
p = this.store_keyword_content('examples', data, p, eof);
break;
case 9:
/* line 49 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
var con = this.bytesToString(data.slice(this.content_start, p)).trim();
this.listener.step(this.keyword, con, this.current_line);
break;
case 10:
/* line 54 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
var con = this.bytesToString(data.slice(this.content_start, p)).trim();
this.listener.comment(con, this.line_number);
this.keyword_start = null;
break;
case 11:
/* line 60 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
var con = this.bytesToString(data.slice(this.content_start, p)).trim();
this.listener.tag(con, this.line_number);
this.keyword_start = null;
break;
case 12:
/* line 66 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.line_number++;
break;
case 13:
/* line 70 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.last_newline = p + 1;
break;
case 14:
/* line 74 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.keyword_start = this.keyword_start || p;
break;
case 15:
/* line 78 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.keyword = this.bytesToString(data.slice(this.keyword_start, p)).replace(/:$/, '');
this.keyword_start = null;
break;
case 16:
/* line 83 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.next_keyword_start = p;
break;
case 17:
/* line 87 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
p = p - 1;
current_row = [];
this.current_line = this.line_number;
break;
case 18:
/* line 93 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.content_start = p;
break;
case 19:
/* line 97 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
var con = this.bytesToString(data.slice(this.content_start, p)).trim();
current_row.push(con.replace(/\\\|/, "|").replace(/\\n/, "\n").replace(/\\\\/, "\\"));
break;
case 20:
/* line 102 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
this.listener.row(current_row, this.current_line);
break;
case 21:
/* line 106 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
if(this.cs < lexer_first_final) {
var content = this.current_line_content(data, p);
throw "Lexing error on line " + this.line_number + ": '" + content + "'. See http://wiki.github.com/cucumber/gherkin/lexingerror for more information.";
} else {
this.listener.eof();
}
break;
/* line 921 "js/lib/gherkin/lexer/it.js" */
} /* action switch */
}
}
if (_trigger_goto) {
continue;
}
}
if (_goto_level <= _again) {
if ( this.cs == 0) {
_goto_level = _out;
continue;
}
p += 1;
if (p != pe) {
_goto_level = _resume;
continue;
}
}
if (_goto_level <= _test_eof) {
if (p == eof) {
__acts = _lexer_eof_actions[ this.cs];
__nacts = _lexer_actions[__acts];
__acts += 1;
while (__nacts > 0) {
__nacts -= 1;
__acts += 1;
switch (_lexer_actions[__acts - 1]) {
case 21:
/* line 106 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
if(this.cs < lexer_first_final) {
var content = this.current_line_content(data, p);
throw "Lexing error on line " + this.line_number + ": '" + content + "'. See http://wiki.github.com/cucumber/gherkin/lexingerror for more information.";
} else {
this.listener.eof();
}
break;
/* line 960 "js/lib/gherkin/lexer/it.js" */
} /* eof action switch */
}
if (_trigger_goto) {
continue;
}
}
}
if (_goto_level <= _out) {
break;
}
}
}
/* line 154 "/Users/ahellesoy/scm/gherkin/tasks/../ragel/i18n/it.js.rl" */
};
Lexer.prototype.bytesToString = function(bytes) {
if(typeof bytes.write == 'function') {
// Node.js
return bytes.toString('utf-8');
} else {
var result = "";
for(var b in bytes) {
result += String.fromCharCode(bytes[b]);
}
return result;
}
};
Lexer.prototype.stringToBytes = function(string) {
var bytes = [];
for(var i = 0; i < string.length; i++) {
bytes[i] = string.charCodeAt(i);
}
return bytes;
};
Lexer.prototype.unindent = function(startcol, text) {
startcol = startcol || 0;
return text.replace(new RegExp('^[\t ]{0,' + startcol + '}', 'gm'), '');
};
Lexer.prototype.store_keyword_content = function(event, data, p, eof) {
var end_point = (!this.next_keyword_start || (p == eof)) ? p : this.next_keyword_start;
var content = this.unindent(this.start_col + 2, this.bytesToString(data.slice(this.content_start, end_point))).replace(/\s+$/,"");
var content_lines = content.split("\n")
var name = content_lines.shift() || "";
name = name.trim();
var description = content_lines.join("\n");
this.listener[event](this.keyword, name, description, this.current_line);
var nks = this.next_keyword_start;
this.next_keyword_start = null;
return nks ? nks - 1 : p;
};
Lexer.prototype.current_line_content = function(data, p) {
var rest = data.slice(this.last_newline, -1);
var end = rest.indexOf(10) || -1;
return this.bytesToString(rest.slice(0, end)).trim();
};
// Node.js export
if(typeof exports !== 'undefined') {
exports.Lexer = Lexer;
}
// Require.js export
if (typeof define !== 'undefined' && define.amd) {
define('gherkin/lexer/it', [], function() {return Lexer});
}
})();