parser: closure syntax use '!' instead of 'with'
[nit.git] / src / parser / lexer.nit
1 # Lexer and its tokens.
2 # This file was generated by SableCC (http://www.sablecc.org/).
3 package lexer
4
5 intrude import parser_nodes
6
7 redef class Token
8 readable writable var _text: String
9
10 fun parser_index: Int is abstract
11
12 redef fun to_s: String do
13 return "'{_text}'"
14 end
15 end
16
17 redef class TEol
18 redef fun parser_index: Int
19 do
20 return 0
21 end
22
23 init init_tk(text: String, loc: Location)
24 do
25 _text = text
26 _location = loc
27 end
28 end
29
30 redef class TComment
31 redef fun parser_index: Int
32 do
33 return 1
34 end
35
36 init init_tk(text: String, loc: Location)
37 do
38 _text = text
39 _location = loc
40 end
41 end
42
43 redef class TKwpackage
44 redef fun parser_index: Int
45 do
46 return 2
47 end
48
49 init init_tk(loc: Location)
50 do
51 _text = once "package"
52 _location = loc
53 end
54 end
55
56 redef class TKwimport
57 redef fun parser_index: Int
58 do
59 return 3
60 end
61
62 init init_tk(loc: Location)
63 do
64 _text = once "import"
65 _location = loc
66 end
67 end
68
69 redef class TKwclass
70 redef fun parser_index: Int
71 do
72 return 4
73 end
74
75 init init_tk(loc: Location)
76 do
77 _text = once "class"
78 _location = loc
79 end
80 end
81
82 redef class TKwabstract
83 redef fun parser_index: Int
84 do
85 return 5
86 end
87
88 init init_tk(loc: Location)
89 do
90 _text = once "abstract"
91 _location = loc
92 end
93 end
94
95 redef class TKwinterface
96 redef fun parser_index: Int
97 do
98 return 6
99 end
100
101 init init_tk(loc: Location)
102 do
103 _text = once "interface"
104 _location = loc
105 end
106 end
107
108 redef class TKwuniversal
109 redef fun parser_index: Int
110 do
111 return 7
112 end
113
114 init init_tk(loc: Location)
115 do
116 _text = once "universal"
117 _location = loc
118 end
119 end
120
121 redef class TKwspecial
122 redef fun parser_index: Int
123 do
124 return 8
125 end
126
127 init init_tk(loc: Location)
128 do
129 _text = once "special"
130 _location = loc
131 end
132 end
133
134 redef class TKwend
135 redef fun parser_index: Int
136 do
137 return 9
138 end
139
140 init init_tk(loc: Location)
141 do
142 _text = once "end"
143 _location = loc
144 end
145 end
146
147 redef class TKwmeth
148 redef fun parser_index: Int
149 do
150 return 10
151 end
152
153 init init_tk(loc: Location)
154 do
155 _text = once "fun"
156 _location = loc
157 end
158 end
159
160 redef class TKwtype
161 redef fun parser_index: Int
162 do
163 return 11
164 end
165
166 init init_tk(loc: Location)
167 do
168 _text = once "type"
169 _location = loc
170 end
171 end
172
173 redef class TKwinit
174 redef fun parser_index: Int
175 do
176 return 12
177 end
178
179 init init_tk(loc: Location)
180 do
181 _text = once "init"
182 _location = loc
183 end
184 end
185
186 redef class TKwredef
187 redef fun parser_index: Int
188 do
189 return 13
190 end
191
192 init init_tk(loc: Location)
193 do
194 _text = once "redef"
195 _location = loc
196 end
197 end
198
199 redef class TKwis
200 redef fun parser_index: Int
201 do
202 return 14
203 end
204
205 init init_tk(loc: Location)
206 do
207 _text = once "is"
208 _location = loc
209 end
210 end
211
212 redef class TKwdo
213 redef fun parser_index: Int
214 do
215 return 15
216 end
217
218 init init_tk(loc: Location)
219 do
220 _text = once "do"
221 _location = loc
222 end
223 end
224
225 redef class TKwreadable
226 redef fun parser_index: Int
227 do
228 return 16
229 end
230
231 init init_tk(loc: Location)
232 do
233 _text = once "readable"
234 _location = loc
235 end
236 end
237
238 redef class TKwwritable
239 redef fun parser_index: Int
240 do
241 return 17
242 end
243
244 init init_tk(loc: Location)
245 do
246 _text = once "writable"
247 _location = loc
248 end
249 end
250
251 redef class TKwvar
252 redef fun parser_index: Int
253 do
254 return 18
255 end
256
257 init init_tk(loc: Location)
258 do
259 _text = once "var"
260 _location = loc
261 end
262 end
263
264 redef class TKwintern
265 redef fun parser_index: Int
266 do
267 return 19
268 end
269
270 init init_tk(loc: Location)
271 do
272 _text = once "intern"
273 _location = loc
274 end
275 end
276
277 redef class TKwextern
278 redef fun parser_index: Int
279 do
280 return 20
281 end
282
283 init init_tk(loc: Location)
284 do
285 _text = once "extern"
286 _location = loc
287 end
288 end
289
290 redef class TKwprotected
291 redef fun parser_index: Int
292 do
293 return 21
294 end
295
296 init init_tk(loc: Location)
297 do
298 _text = once "protected"
299 _location = loc
300 end
301 end
302
303 redef class TKwprivate
304 redef fun parser_index: Int
305 do
306 return 22
307 end
308
309 init init_tk(loc: Location)
310 do
311 _text = once "private"
312 _location = loc
313 end
314 end
315
316 redef class TKwintrude
317 redef fun parser_index: Int
318 do
319 return 23
320 end
321
322 init init_tk(loc: Location)
323 do
324 _text = once "intrude"
325 _location = loc
326 end
327 end
328
329 redef class TKwif
330 redef fun parser_index: Int
331 do
332 return 24
333 end
334
335 init init_tk(loc: Location)
336 do
337 _text = once "if"
338 _location = loc
339 end
340 end
341
342 redef class TKwthen
343 redef fun parser_index: Int
344 do
345 return 25
346 end
347
348 init init_tk(loc: Location)
349 do
350 _text = once "then"
351 _location = loc
352 end
353 end
354
355 redef class TKwelse
356 redef fun parser_index: Int
357 do
358 return 26
359 end
360
361 init init_tk(loc: Location)
362 do
363 _text = once "else"
364 _location = loc
365 end
366 end
367
368 redef class TKwwhile
369 redef fun parser_index: Int
370 do
371 return 27
372 end
373
374 init init_tk(loc: Location)
375 do
376 _text = once "while"
377 _location = loc
378 end
379 end
380
381 redef class TKwfor
382 redef fun parser_index: Int
383 do
384 return 28
385 end
386
387 init init_tk(loc: Location)
388 do
389 _text = once "for"
390 _location = loc
391 end
392 end
393
394 redef class TKwin
395 redef fun parser_index: Int
396 do
397 return 29
398 end
399
400 init init_tk(loc: Location)
401 do
402 _text = once "in"
403 _location = loc
404 end
405 end
406
407 redef class TKwand
408 redef fun parser_index: Int
409 do
410 return 30
411 end
412
413 init init_tk(loc: Location)
414 do
415 _text = once "and"
416 _location = loc
417 end
418 end
419
420 redef class TKwor
421 redef fun parser_index: Int
422 do
423 return 31
424 end
425
426 init init_tk(loc: Location)
427 do
428 _text = once "or"
429 _location = loc
430 end
431 end
432
433 redef class TKwnot
434 redef fun parser_index: Int
435 do
436 return 32
437 end
438
439 init init_tk(loc: Location)
440 do
441 _text = once "not"
442 _location = loc
443 end
444 end
445
446 redef class TKwreturn
447 redef fun parser_index: Int
448 do
449 return 33
450 end
451
452 init init_tk(loc: Location)
453 do
454 _text = once "return"
455 _location = loc
456 end
457 end
458
459 redef class TKwcontinue
460 redef fun parser_index: Int
461 do
462 return 34
463 end
464
465 init init_tk(loc: Location)
466 do
467 _text = once "continue"
468 _location = loc
469 end
470 end
471
472 redef class TKwbreak
473 redef fun parser_index: Int
474 do
475 return 35
476 end
477
478 init init_tk(loc: Location)
479 do
480 _text = once "break"
481 _location = loc
482 end
483 end
484
485 redef class TKwabort
486 redef fun parser_index: Int
487 do
488 return 36
489 end
490
491 init init_tk(loc: Location)
492 do
493 _text = once "abort"
494 _location = loc
495 end
496 end
497
498 redef class TKwassert
499 redef fun parser_index: Int
500 do
501 return 37
502 end
503
504 init init_tk(loc: Location)
505 do
506 _text = once "assert"
507 _location = loc
508 end
509 end
510
511 redef class TKwnew
512 redef fun parser_index: Int
513 do
514 return 38
515 end
516
517 init init_tk(loc: Location)
518 do
519 _text = once "new"
520 _location = loc
521 end
522 end
523
524 redef class TKwisa
525 redef fun parser_index: Int
526 do
527 return 39
528 end
529
530 init init_tk(loc: Location)
531 do
532 _text = once "isa"
533 _location = loc
534 end
535 end
536
537 redef class TKwonce
538 redef fun parser_index: Int
539 do
540 return 40
541 end
542
543 init init_tk(loc: Location)
544 do
545 _text = once "once"
546 _location = loc
547 end
548 end
549
550 redef class TKwsuper
551 redef fun parser_index: Int
552 do
553 return 41
554 end
555
556 init init_tk(loc: Location)
557 do
558 _text = once "super"
559 _location = loc
560 end
561 end
562
563 redef class TKwself
564 redef fun parser_index: Int
565 do
566 return 42
567 end
568
569 init init_tk(loc: Location)
570 do
571 _text = once "self"
572 _location = loc
573 end
574 end
575
576 redef class TKwtrue
577 redef fun parser_index: Int
578 do
579 return 43
580 end
581
582 init init_tk(loc: Location)
583 do
584 _text = once "true"
585 _location = loc
586 end
587 end
588
589 redef class TKwfalse
590 redef fun parser_index: Int
591 do
592 return 44
593 end
594
595 init init_tk(loc: Location)
596 do
597 _text = once "false"
598 _location = loc
599 end
600 end
601
602 redef class TKwnull
603 redef fun parser_index: Int
604 do
605 return 45
606 end
607
608 init init_tk(loc: Location)
609 do
610 _text = once "null"
611 _location = loc
612 end
613 end
614
615 redef class TKwas
616 redef fun parser_index: Int
617 do
618 return 46
619 end
620
621 init init_tk(loc: Location)
622 do
623 _text = once "as"
624 _location = loc
625 end
626 end
627
628 redef class TKwnullable
629 redef fun parser_index: Int
630 do
631 return 47
632 end
633
634 init init_tk(loc: Location)
635 do
636 _text = once "nullable"
637 _location = loc
638 end
639 end
640
641 redef class TKwisset
642 redef fun parser_index: Int
643 do
644 return 48
645 end
646
647 init init_tk(loc: Location)
648 do
649 _text = once "isset"
650 _location = loc
651 end
652 end
653
654 redef class TKwlabel
655 redef fun parser_index: Int
656 do
657 return 49
658 end
659
660 init init_tk(loc: Location)
661 do
662 _text = once "label"
663 _location = loc
664 end
665 end
666
667 redef class TOpar
668 redef fun parser_index: Int
669 do
670 return 50
671 end
672
673 init init_tk(loc: Location)
674 do
675 _text = once "("
676 _location = loc
677 end
678 end
679
680 redef class TCpar
681 redef fun parser_index: Int
682 do
683 return 51
684 end
685
686 init init_tk(loc: Location)
687 do
688 _text = once ")"
689 _location = loc
690 end
691 end
692
693 redef class TObra
694 redef fun parser_index: Int
695 do
696 return 52
697 end
698
699 init init_tk(loc: Location)
700 do
701 _text = once "["
702 _location = loc
703 end
704 end
705
706 redef class TCbra
707 redef fun parser_index: Int
708 do
709 return 53
710 end
711
712 init init_tk(loc: Location)
713 do
714 _text = once "]"
715 _location = loc
716 end
717 end
718
719 redef class TComma
720 redef fun parser_index: Int
721 do
722 return 54
723 end
724
725 init init_tk(loc: Location)
726 do
727 _text = once ","
728 _location = loc
729 end
730 end
731
732 redef class TColumn
733 redef fun parser_index: Int
734 do
735 return 55
736 end
737
738 init init_tk(loc: Location)
739 do
740 _text = once ":"
741 _location = loc
742 end
743 end
744
745 redef class TQuad
746 redef fun parser_index: Int
747 do
748 return 56
749 end
750
751 init init_tk(loc: Location)
752 do
753 _text = once "::"
754 _location = loc
755 end
756 end
757
758 redef class TAssign
759 redef fun parser_index: Int
760 do
761 return 57
762 end
763
764 init init_tk(loc: Location)
765 do
766 _text = once "="
767 _location = loc
768 end
769 end
770
771 redef class TPluseq
772 redef fun parser_index: Int
773 do
774 return 58
775 end
776
777 init init_tk(loc: Location)
778 do
779 _text = once "+="
780 _location = loc
781 end
782 end
783
784 redef class TMinuseq
785 redef fun parser_index: Int
786 do
787 return 59
788 end
789
790 init init_tk(loc: Location)
791 do
792 _text = once "-="
793 _location = loc
794 end
795 end
796
797 redef class TDotdotdot
798 redef fun parser_index: Int
799 do
800 return 60
801 end
802
803 init init_tk(loc: Location)
804 do
805 _text = once "..."
806 _location = loc
807 end
808 end
809
810 redef class TDotdot
811 redef fun parser_index: Int
812 do
813 return 61
814 end
815
816 init init_tk(loc: Location)
817 do
818 _text = once ".."
819 _location = loc
820 end
821 end
822
823 redef class TDot
824 redef fun parser_index: Int
825 do
826 return 62
827 end
828
829 init init_tk(loc: Location)
830 do
831 _text = once "."
832 _location = loc
833 end
834 end
835
836 redef class TPlus
837 redef fun parser_index: Int
838 do
839 return 63
840 end
841
842 init init_tk(loc: Location)
843 do
844 _text = once "+"
845 _location = loc
846 end
847 end
848
849 redef class TMinus
850 redef fun parser_index: Int
851 do
852 return 64
853 end
854
855 init init_tk(loc: Location)
856 do
857 _text = once "-"
858 _location = loc
859 end
860 end
861
862 redef class TStar
863 redef fun parser_index: Int
864 do
865 return 65
866 end
867
868 init init_tk(loc: Location)
869 do
870 _text = once "*"
871 _location = loc
872 end
873 end
874
875 redef class TSlash
876 redef fun parser_index: Int
877 do
878 return 66
879 end
880
881 init init_tk(loc: Location)
882 do
883 _text = once "/"
884 _location = loc
885 end
886 end
887
888 redef class TPercent
889 redef fun parser_index: Int
890 do
891 return 67
892 end
893
894 init init_tk(loc: Location)
895 do
896 _text = once "%"
897 _location = loc
898 end
899 end
900
901 redef class TEq
902 redef fun parser_index: Int
903 do
904 return 68
905 end
906
907 init init_tk(loc: Location)
908 do
909 _text = once "=="
910 _location = loc
911 end
912 end
913
914 redef class TNe
915 redef fun parser_index: Int
916 do
917 return 69
918 end
919
920 init init_tk(loc: Location)
921 do
922 _text = once "!="
923 _location = loc
924 end
925 end
926
927 redef class TLt
928 redef fun parser_index: Int
929 do
930 return 70
931 end
932
933 init init_tk(loc: Location)
934 do
935 _text = once "<"
936 _location = loc
937 end
938 end
939
940 redef class TLe
941 redef fun parser_index: Int
942 do
943 return 71
944 end
945
946 init init_tk(loc: Location)
947 do
948 _text = once "<="
949 _location = loc
950 end
951 end
952
953 redef class TGt
954 redef fun parser_index: Int
955 do
956 return 72
957 end
958
959 init init_tk(loc: Location)
960 do
961 _text = once ">"
962 _location = loc
963 end
964 end
965
966 redef class TGe
967 redef fun parser_index: Int
968 do
969 return 73
970 end
971
972 init init_tk(loc: Location)
973 do
974 _text = once ">="
975 _location = loc
976 end
977 end
978
979 redef class TStarship
980 redef fun parser_index: Int
981 do
982 return 74
983 end
984
985 init init_tk(loc: Location)
986 do
987 _text = once "<=>"
988 _location = loc
989 end
990 end
991
992 redef class TBang
993 redef fun parser_index: Int
994 do
995 return 75
996 end
997
998 init init_tk(loc: Location)
999 do
1000 _text = once "!"
1001 _location = loc
1002 end
1003 end
1004
1005 redef class TClassid
1006 redef fun parser_index: Int
1007 do
1008 return 76
1009 end
1010
1011 init init_tk(text: String, loc: Location)
1012 do
1013 _text = text
1014 _location = loc
1015 end
1016 end
1017
1018 redef class TId
1019 redef fun parser_index: Int
1020 do
1021 return 77
1022 end
1023
1024 init init_tk(text: String, loc: Location)
1025 do
1026 _text = text
1027 _location = loc
1028 end
1029 end
1030
1031 redef class TAttrid
1032 redef fun parser_index: Int
1033 do
1034 return 78
1035 end
1036
1037 init init_tk(text: String, loc: Location)
1038 do
1039 _text = text
1040 _location = loc
1041 end
1042 end
1043
1044 redef class TNumber
1045 redef fun parser_index: Int
1046 do
1047 return 79
1048 end
1049
1050 init init_tk(text: String, loc: Location)
1051 do
1052 _text = text
1053 _location = loc
1054 end
1055 end
1056
1057 redef class TFloat
1058 redef fun parser_index: Int
1059 do
1060 return 80
1061 end
1062
1063 init init_tk(text: String, loc: Location)
1064 do
1065 _text = text
1066 _location = loc
1067 end
1068 end
1069
1070 redef class TChar
1071 redef fun parser_index: Int
1072 do
1073 return 81
1074 end
1075
1076 init init_tk(text: String, loc: Location)
1077 do
1078 _text = text
1079 _location = loc
1080 end
1081 end
1082
1083 redef class TString
1084 redef fun parser_index: Int
1085 do
1086 return 82
1087 end
1088
1089 init init_tk(text: String, loc: Location)
1090 do
1091 _text = text
1092 _location = loc
1093 end
1094 end
1095
1096 redef class TStartString
1097 redef fun parser_index: Int
1098 do
1099 return 83
1100 end
1101
1102 init init_tk(text: String, loc: Location)
1103 do
1104 _text = text
1105 _location = loc
1106 end
1107 end
1108
1109 redef class TMidString
1110 redef fun parser_index: Int
1111 do
1112 return 84
1113 end
1114
1115 init init_tk(text: String, loc: Location)
1116 do
1117 _text = text
1118 _location = loc
1119 end
1120 end
1121
1122 redef class TEndString
1123 redef fun parser_index: Int
1124 do
1125 return 85
1126 end
1127
1128 init init_tk(text: String, loc: Location)
1129 do
1130 _text = text
1131 _location = loc
1132 end
1133 end
1134
1135
1136 redef class EOF
1137 redef fun parser_index: Int
1138 do
1139 return 86
1140 end
1141
1142 init(loc: Location)
1143 do
1144 _text = ""
1145 _location = loc
1146 end
1147 end
1148
1149 redef class AError
1150 readable writable var _message: String
1151
1152 init init_error(message: String, loc: Location)
1153 do
1154 init(loc)
1155 _message = message
1156 end
1157 end
1158
1159
1160 # The lexer extract NIT tokens from an input stream.
1161 # It is better user with the Parser
1162 class Lexer
1163 # Last peeked token
1164 var _token: nullable Token
1165
1166 # Lexer current state
1167 var _state: Int = 0
1168
1169 # Name of the stream (as given to tokens)
1170 readable var _filename: String
1171
1172 # Input stream where character are read
1173 var _stream: IStream
1174
1175 # Pushback buffer to store unread character
1176 var _stream_buf: Buffer
1177
1178 # Number of character stored in the pushback buffer
1179 var _stream_pos: Int
1180
1181 # Current line number in the input stream
1182 var _line: Int = 0
1183
1184 # Current column in the input stream
1185 var _pos: Int = 0
1186
1187 # Was the last character a cariage-return?
1188 var _cr: Bool = false
1189
1190 # If the end of stream?
1191 var _eof: Bool = false
1192
1193 # Current working text read from the input stream
1194 var _text: Buffer
1195
1196 # Constante state values
1197 private fun state_initial: Int do return 0 end
1198
1199 # Create a new lexer for a stream (and a name)
1200 init(stream: IStream, fname: String)
1201 do
1202 _filename = fname
1203 _text = new Buffer
1204 _stream = stream
1205 _stream_pos = -1
1206 _stream_buf = new Buffer
1207 build_goto_table
1208 build_accept_table
1209 end
1210
1211 # Give the next token (but do not consume it)
1212 fun peek: Token
1213 do
1214 while _token == null do
1215 _token = get_token
1216 end
1217 return _token.as(not null)
1218 end
1219
1220 # Give and consume the next token
1221 fun next: Token
1222 do
1223 var result = _token
1224 while result == null do
1225 result = get_token
1226 end
1227 _token = null
1228 return result.as(not null)
1229 end
1230
1231 # Get a token, or null if it is discarded
1232 private fun get_token: nullable Token
1233 do
1234 var dfa_state = 0
1235
1236 var start_pos = _pos
1237 var start_line = _line
1238
1239 var accept_state = -1
1240 var accept_token = -1
1241 var accept_length = -1
1242 var accept_pos = -1
1243 var accept_line = -1
1244
1245 var goto_table = _goto_table[_state]
1246 var accept = _accept_table[_state]
1247 var text = _text
1248 text.clear
1249
1250 while true do
1251 var c = get_char
1252
1253 if c != -1 then
1254 var cr = _cr
1255 var line = _line
1256 var pos = _pos
1257 if c == 10 then
1258 if cr then
1259 cr = false
1260 else
1261 line = line + 1
1262 pos = 0
1263 end
1264 else if c == 13 then
1265 line = line + 1
1266 pos = 0
1267 cr = true
1268 else
1269 pos = pos + 1
1270 cr = false
1271 end
1272
1273 text.add(c.ascii)
1274
1275 var first_loop = true # aka until
1276 while dfa_state < -1 or first_loop do
1277 var old_state = dfa_state
1278 if dfa_state < -1 then
1279 old_state = -2 - dfa_state
1280 end
1281
1282 dfa_state = -1
1283
1284 var tmp0 = goto_table[old_state]
1285 var low = 0
1286 var high = tmp0.length - 1
1287
1288 if high >= 0 then
1289 var tmp1 = tmp0.intern_items
1290 while low <= high do
1291 var middle = (low + high) / 2
1292 var tmp2 = tmp1[middle].intern_items
1293
1294 if c < tmp2[0] then
1295 high = middle - 1
1296 else if c > tmp2[1] then
1297 low = middle + 1
1298 else
1299 dfa_state = tmp2[2]
1300 low = high + 1 # aka break
1301 end
1302 end
1303 end
1304 first_loop = false # aka until
1305 end
1306
1307 _cr = cr
1308 _line = line
1309 _pos = pos
1310 else
1311 dfa_state = -1
1312 end
1313
1314 if dfa_state >= 0 then
1315 if accept[dfa_state] != -1 then
1316 accept_state = dfa_state
1317 accept_token = accept[dfa_state]
1318 accept_length = text.length
1319 accept_pos = _pos
1320 accept_line = _line
1321 end
1322 else
1323 if accept_state != -1 then
1324 if accept_token == 0 then
1325 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1326 push_back(accept_length)
1327 _pos = accept_pos
1328 _line = accept_line
1329 return null
1330 end
1331 if accept_token == 1 then
1332 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1333 var token_text = text.substring(0, accept_length)
1334 var token = new TEol.init_tk(token_text, location)
1335 push_back(accept_length)
1336 _pos = accept_pos
1337 _line = accept_line
1338 return token
1339 end
1340 if accept_token == 2 then
1341 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1342 var token_text = text.substring(0, accept_length)
1343 var token = new TComment.init_tk(token_text, location)
1344 push_back(accept_length)
1345 _pos = accept_pos
1346 _line = accept_line
1347 return token
1348 end
1349 if accept_token == 3 then
1350 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1351 var token = new TKwpackage.init_tk(location)
1352 push_back(accept_length)
1353 _pos = accept_pos
1354 _line = accept_line
1355 return token
1356 end
1357 if accept_token == 4 then
1358 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1359 var token = new TKwimport.init_tk(location)
1360 push_back(accept_length)
1361 _pos = accept_pos
1362 _line = accept_line
1363 return token
1364 end
1365 if accept_token == 5 then
1366 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1367 var token = new TKwclass.init_tk(location)
1368 push_back(accept_length)
1369 _pos = accept_pos
1370 _line = accept_line
1371 return token
1372 end
1373 if accept_token == 6 then
1374 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1375 var token = new TKwabstract.init_tk(location)
1376 push_back(accept_length)
1377 _pos = accept_pos
1378 _line = accept_line
1379 return token
1380 end
1381 if accept_token == 7 then
1382 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1383 var token = new TKwinterface.init_tk(location)
1384 push_back(accept_length)
1385 _pos = accept_pos
1386 _line = accept_line
1387 return token
1388 end
1389 if accept_token == 8 then
1390 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1391 var token = new TKwuniversal.init_tk(location)
1392 push_back(accept_length)
1393 _pos = accept_pos
1394 _line = accept_line
1395 return token
1396 end
1397 if accept_token == 9 then
1398 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1399 var token = new TKwspecial.init_tk(location)
1400 push_back(accept_length)
1401 _pos = accept_pos
1402 _line = accept_line
1403 return token
1404 end
1405 if accept_token == 10 then
1406 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1407 var token = new TKwend.init_tk(location)
1408 push_back(accept_length)
1409 _pos = accept_pos
1410 _line = accept_line
1411 return token
1412 end
1413 if accept_token == 11 then
1414 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1415 var token = new TKwmeth.init_tk(location)
1416 push_back(accept_length)
1417 _pos = accept_pos
1418 _line = accept_line
1419 return token
1420 end
1421 if accept_token == 12 then
1422 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1423 var token = new TKwtype.init_tk(location)
1424 push_back(accept_length)
1425 _pos = accept_pos
1426 _line = accept_line
1427 return token
1428 end
1429 if accept_token == 13 then
1430 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1431 var token = new TKwinit.init_tk(location)
1432 push_back(accept_length)
1433 _pos = accept_pos
1434 _line = accept_line
1435 return token
1436 end
1437 if accept_token == 14 then
1438 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1439 var token = new TKwredef.init_tk(location)
1440 push_back(accept_length)
1441 _pos = accept_pos
1442 _line = accept_line
1443 return token
1444 end
1445 if accept_token == 15 then
1446 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1447 var token = new TKwis.init_tk(location)
1448 push_back(accept_length)
1449 _pos = accept_pos
1450 _line = accept_line
1451 return token
1452 end
1453 if accept_token == 16 then
1454 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1455 var token = new TKwdo.init_tk(location)
1456 push_back(accept_length)
1457 _pos = accept_pos
1458 _line = accept_line
1459 return token
1460 end
1461 if accept_token == 17 then
1462 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1463 var token = new TKwreadable.init_tk(location)
1464 push_back(accept_length)
1465 _pos = accept_pos
1466 _line = accept_line
1467 return token
1468 end
1469 if accept_token == 18 then
1470 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1471 var token = new TKwwritable.init_tk(location)
1472 push_back(accept_length)
1473 _pos = accept_pos
1474 _line = accept_line
1475 return token
1476 end
1477 if accept_token == 19 then
1478 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1479 var token = new TKwvar.init_tk(location)
1480 push_back(accept_length)
1481 _pos = accept_pos
1482 _line = accept_line
1483 return token
1484 end
1485 if accept_token == 20 then
1486 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1487 var token = new TKwintern.init_tk(location)
1488 push_back(accept_length)
1489 _pos = accept_pos
1490 _line = accept_line
1491 return token
1492 end
1493 if accept_token == 21 then
1494 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1495 var token = new TKwextern.init_tk(location)
1496 push_back(accept_length)
1497 _pos = accept_pos
1498 _line = accept_line
1499 return token
1500 end
1501 if accept_token == 22 then
1502 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1503 var token = new TKwprotected.init_tk(location)
1504 push_back(accept_length)
1505 _pos = accept_pos
1506 _line = accept_line
1507 return token
1508 end
1509 if accept_token == 23 then
1510 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1511 var token = new TKwprivate.init_tk(location)
1512 push_back(accept_length)
1513 _pos = accept_pos
1514 _line = accept_line
1515 return token
1516 end
1517 if accept_token == 24 then
1518 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1519 var token = new TKwintrude.init_tk(location)
1520 push_back(accept_length)
1521 _pos = accept_pos
1522 _line = accept_line
1523 return token
1524 end
1525 if accept_token == 25 then
1526 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1527 var token = new TKwif.init_tk(location)
1528 push_back(accept_length)
1529 _pos = accept_pos
1530 _line = accept_line
1531 return token
1532 end
1533 if accept_token == 26 then
1534 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1535 var token = new TKwthen.init_tk(location)
1536 push_back(accept_length)
1537 _pos = accept_pos
1538 _line = accept_line
1539 return token
1540 end
1541 if accept_token == 27 then
1542 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1543 var token = new TKwelse.init_tk(location)
1544 push_back(accept_length)
1545 _pos = accept_pos
1546 _line = accept_line
1547 return token
1548 end
1549 if accept_token == 28 then
1550 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1551 var token = new TKwwhile.init_tk(location)
1552 push_back(accept_length)
1553 _pos = accept_pos
1554 _line = accept_line
1555 return token
1556 end
1557 if accept_token == 29 then
1558 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1559 var token = new TKwfor.init_tk(location)
1560 push_back(accept_length)
1561 _pos = accept_pos
1562 _line = accept_line
1563 return token
1564 end
1565 if accept_token == 30 then
1566 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1567 var token = new TKwin.init_tk(location)
1568 push_back(accept_length)
1569 _pos = accept_pos
1570 _line = accept_line
1571 return token
1572 end
1573 if accept_token == 31 then
1574 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1575 var token = new TKwand.init_tk(location)
1576 push_back(accept_length)
1577 _pos = accept_pos
1578 _line = accept_line
1579 return token
1580 end
1581 if accept_token == 32 then
1582 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1583 var token = new TKwor.init_tk(location)
1584 push_back(accept_length)
1585 _pos = accept_pos
1586 _line = accept_line
1587 return token
1588 end
1589 if accept_token == 33 then
1590 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1591 var token = new TKwnot.init_tk(location)
1592 push_back(accept_length)
1593 _pos = accept_pos
1594 _line = accept_line
1595 return token
1596 end
1597 if accept_token == 34 then
1598 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1599 var token = new TKwreturn.init_tk(location)
1600 push_back(accept_length)
1601 _pos = accept_pos
1602 _line = accept_line
1603 return token
1604 end
1605 if accept_token == 35 then
1606 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1607 var token = new TKwcontinue.init_tk(location)
1608 push_back(accept_length)
1609 _pos = accept_pos
1610 _line = accept_line
1611 return token
1612 end
1613 if accept_token == 36 then
1614 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1615 var token = new TKwbreak.init_tk(location)
1616 push_back(accept_length)
1617 _pos = accept_pos
1618 _line = accept_line
1619 return token
1620 end
1621 if accept_token == 37 then
1622 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1623 var token = new TKwabort.init_tk(location)
1624 push_back(accept_length)
1625 _pos = accept_pos
1626 _line = accept_line
1627 return token
1628 end
1629 if accept_token == 38 then
1630 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1631 var token = new TKwassert.init_tk(location)
1632 push_back(accept_length)
1633 _pos = accept_pos
1634 _line = accept_line
1635 return token
1636 end
1637 if accept_token == 39 then
1638 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1639 var token = new TKwnew.init_tk(location)
1640 push_back(accept_length)
1641 _pos = accept_pos
1642 _line = accept_line
1643 return token
1644 end
1645 if accept_token == 40 then
1646 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1647 var token = new TKwisa.init_tk(location)
1648 push_back(accept_length)
1649 _pos = accept_pos
1650 _line = accept_line
1651 return token
1652 end
1653 if accept_token == 41 then
1654 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1655 var token = new TKwonce.init_tk(location)
1656 push_back(accept_length)
1657 _pos = accept_pos
1658 _line = accept_line
1659 return token
1660 end
1661 if accept_token == 42 then
1662 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1663 var token = new TKwsuper.init_tk(location)
1664 push_back(accept_length)
1665 _pos = accept_pos
1666 _line = accept_line
1667 return token
1668 end
1669 if accept_token == 43 then
1670 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1671 var token = new TKwself.init_tk(location)
1672 push_back(accept_length)
1673 _pos = accept_pos
1674 _line = accept_line
1675 return token
1676 end
1677 if accept_token == 44 then
1678 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1679 var token = new TKwtrue.init_tk(location)
1680 push_back(accept_length)
1681 _pos = accept_pos
1682 _line = accept_line
1683 return token
1684 end
1685 if accept_token == 45 then
1686 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1687 var token = new TKwfalse.init_tk(location)
1688 push_back(accept_length)
1689 _pos = accept_pos
1690 _line = accept_line
1691 return token
1692 end
1693 if accept_token == 46 then
1694 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1695 var token = new TKwnull.init_tk(location)
1696 push_back(accept_length)
1697 _pos = accept_pos
1698 _line = accept_line
1699 return token
1700 end
1701 if accept_token == 47 then
1702 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1703 var token = new TKwas.init_tk(location)
1704 push_back(accept_length)
1705 _pos = accept_pos
1706 _line = accept_line
1707 return token
1708 end
1709 if accept_token == 48 then
1710 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1711 var token = new TKwnullable.init_tk(location)
1712 push_back(accept_length)
1713 _pos = accept_pos
1714 _line = accept_line
1715 return token
1716 end
1717 if accept_token == 49 then
1718 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1719 var token = new TKwisset.init_tk(location)
1720 push_back(accept_length)
1721 _pos = accept_pos
1722 _line = accept_line
1723 return token
1724 end
1725 if accept_token == 50 then
1726 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1727 var token = new TKwlabel.init_tk(location)
1728 push_back(accept_length)
1729 _pos = accept_pos
1730 _line = accept_line
1731 return token
1732 end
1733 if accept_token == 51 then
1734 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1735 var token = new TOpar.init_tk(location)
1736 push_back(accept_length)
1737 _pos = accept_pos
1738 _line = accept_line
1739 return token
1740 end
1741 if accept_token == 52 then
1742 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1743 var token = new TCpar.init_tk(location)
1744 push_back(accept_length)
1745 _pos = accept_pos
1746 _line = accept_line
1747 return token
1748 end
1749 if accept_token == 53 then
1750 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1751 var token = new TObra.init_tk(location)
1752 push_back(accept_length)
1753 _pos = accept_pos
1754 _line = accept_line
1755 return token
1756 end
1757 if accept_token == 54 then
1758 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1759 var token = new TCbra.init_tk(location)
1760 push_back(accept_length)
1761 _pos = accept_pos
1762 _line = accept_line
1763 return token
1764 end
1765 if accept_token == 55 then
1766 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1767 var token = new TComma.init_tk(location)
1768 push_back(accept_length)
1769 _pos = accept_pos
1770 _line = accept_line
1771 return token
1772 end
1773 if accept_token == 56 then
1774 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1775 var token = new TColumn.init_tk(location)
1776 push_back(accept_length)
1777 _pos = accept_pos
1778 _line = accept_line
1779 return token
1780 end
1781 if accept_token == 57 then
1782 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1783 var token = new TQuad.init_tk(location)
1784 push_back(accept_length)
1785 _pos = accept_pos
1786 _line = accept_line
1787 return token
1788 end
1789 if accept_token == 58 then
1790 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1791 var token = new TAssign.init_tk(location)
1792 push_back(accept_length)
1793 _pos = accept_pos
1794 _line = accept_line
1795 return token
1796 end
1797 if accept_token == 59 then
1798 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1799 var token = new TPluseq.init_tk(location)
1800 push_back(accept_length)
1801 _pos = accept_pos
1802 _line = accept_line
1803 return token
1804 end
1805 if accept_token == 60 then
1806 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1807 var token = new TMinuseq.init_tk(location)
1808 push_back(accept_length)
1809 _pos = accept_pos
1810 _line = accept_line
1811 return token
1812 end
1813 if accept_token == 61 then
1814 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1815 var token = new TDotdotdot.init_tk(location)
1816 push_back(accept_length)
1817 _pos = accept_pos
1818 _line = accept_line
1819 return token
1820 end
1821 if accept_token == 62 then
1822 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1823 var token = new TDotdot.init_tk(location)
1824 push_back(accept_length)
1825 _pos = accept_pos
1826 _line = accept_line
1827 return token
1828 end
1829 if accept_token == 63 then
1830 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1831 var token = new TDot.init_tk(location)
1832 push_back(accept_length)
1833 _pos = accept_pos
1834 _line = accept_line
1835 return token
1836 end
1837 if accept_token == 64 then
1838 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1839 var token = new TPlus.init_tk(location)
1840 push_back(accept_length)
1841 _pos = accept_pos
1842 _line = accept_line
1843 return token
1844 end
1845 if accept_token == 65 then
1846 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1847 var token = new TMinus.init_tk(location)
1848 push_back(accept_length)
1849 _pos = accept_pos
1850 _line = accept_line
1851 return token
1852 end
1853 if accept_token == 66 then
1854 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1855 var token = new TStar.init_tk(location)
1856 push_back(accept_length)
1857 _pos = accept_pos
1858 _line = accept_line
1859 return token
1860 end
1861 if accept_token == 67 then
1862 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1863 var token = new TSlash.init_tk(location)
1864 push_back(accept_length)
1865 _pos = accept_pos
1866 _line = accept_line
1867 return token
1868 end
1869 if accept_token == 68 then
1870 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1871 var token = new TPercent.init_tk(location)
1872 push_back(accept_length)
1873 _pos = accept_pos
1874 _line = accept_line
1875 return token
1876 end
1877 if accept_token == 69 then
1878 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1879 var token = new TEq.init_tk(location)
1880 push_back(accept_length)
1881 _pos = accept_pos
1882 _line = accept_line
1883 return token
1884 end
1885 if accept_token == 70 then
1886 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1887 var token = new TNe.init_tk(location)
1888 push_back(accept_length)
1889 _pos = accept_pos
1890 _line = accept_line
1891 return token
1892 end
1893 if accept_token == 71 then
1894 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1895 var token = new TLt.init_tk(location)
1896 push_back(accept_length)
1897 _pos = accept_pos
1898 _line = accept_line
1899 return token
1900 end
1901 if accept_token == 72 then
1902 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1903 var token = new TLe.init_tk(location)
1904 push_back(accept_length)
1905 _pos = accept_pos
1906 _line = accept_line
1907 return token
1908 end
1909 if accept_token == 73 then
1910 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1911 var token = new TGt.init_tk(location)
1912 push_back(accept_length)
1913 _pos = accept_pos
1914 _line = accept_line
1915 return token
1916 end
1917 if accept_token == 74 then
1918 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1919 var token = new TGe.init_tk(location)
1920 push_back(accept_length)
1921 _pos = accept_pos
1922 _line = accept_line
1923 return token
1924 end
1925 if accept_token == 75 then
1926 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1927 var token = new TStarship.init_tk(location)
1928 push_back(accept_length)
1929 _pos = accept_pos
1930 _line = accept_line
1931 return token
1932 end
1933 if accept_token == 76 then
1934 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1935 var token = new TBang.init_tk(location)
1936 push_back(accept_length)
1937 _pos = accept_pos
1938 _line = accept_line
1939 return token
1940 end
1941 if accept_token == 77 then
1942 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1943 var token_text = text.substring(0, accept_length)
1944 var token = new TClassid.init_tk(token_text, location)
1945 push_back(accept_length)
1946 _pos = accept_pos
1947 _line = accept_line
1948 return token
1949 end
1950 if accept_token == 78 then
1951 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1952 var token_text = text.substring(0, accept_length)
1953 var token = new TId.init_tk(token_text, location)
1954 push_back(accept_length)
1955 _pos = accept_pos
1956 _line = accept_line
1957 return token
1958 end
1959 if accept_token == 79 then
1960 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1961 var token_text = text.substring(0, accept_length)
1962 var token = new TAttrid.init_tk(token_text, location)
1963 push_back(accept_length)
1964 _pos = accept_pos
1965 _line = accept_line
1966 return token
1967 end
1968 if accept_token == 80 then
1969 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1970 var token_text = text.substring(0, accept_length)
1971 var token = new TNumber.init_tk(token_text, location)
1972 push_back(accept_length)
1973 _pos = accept_pos
1974 _line = accept_line
1975 return token
1976 end
1977 if accept_token == 81 then
1978 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1979 var token_text = text.substring(0, accept_length)
1980 var token = new TFloat.init_tk(token_text, location)
1981 push_back(accept_length)
1982 _pos = accept_pos
1983 _line = accept_line
1984 return token
1985 end
1986 if accept_token == 82 then
1987 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1988 var token_text = text.substring(0, accept_length)
1989 var token = new TChar.init_tk(token_text, location)
1990 push_back(accept_length)
1991 _pos = accept_pos
1992 _line = accept_line
1993 return token
1994 end
1995 if accept_token == 83 then
1996 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
1997 var token_text = text.substring(0, accept_length)
1998 var token = new TString.init_tk(token_text, location)
1999 push_back(accept_length)
2000 _pos = accept_pos
2001 _line = accept_line
2002 return token
2003 end
2004 if accept_token == 84 then
2005 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
2006 var token_text = text.substring(0, accept_length)
2007 var token = new TStartString.init_tk(token_text, location)
2008 push_back(accept_length)
2009 _pos = accept_pos
2010 _line = accept_line
2011 return token
2012 end
2013 if accept_token == 85 then
2014 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
2015 var token_text = text.substring(0, accept_length)
2016 var token = new TMidString.init_tk(token_text, location)
2017 push_back(accept_length)
2018 _pos = accept_pos
2019 _line = accept_line
2020 return token
2021 end
2022 if accept_token == 86 then
2023 var location = new Location(_filename, start_line + 1, accept_line + 1, start_pos + 1, accept_pos)
2024 var token_text = text.substring(0, accept_length)
2025 var token = new TEndString.init_tk(token_text, location)
2026 push_back(accept_length)
2027 _pos = accept_pos
2028 _line = accept_line
2029 return token
2030 end
2031 else
2032 var location = new Location(_filename, start_line + 1, start_line + 1, start_pos + 1, start_pos + 1)
2033 if text.length > 0 then
2034 var token = new AError.init_error("Syntax error: unknown token {text}.", location)
2035 return token
2036 else
2037 var token = new EOF(location)
2038 return token
2039 end
2040 end
2041 end
2042 end
2043 return null
2044 end
2045
2046 # Read the next character.
2047 # The character is read from the stream of from the pushback buffer.
2048 private fun get_char: Int
2049 do
2050 if _eof then
2051 return -1
2052 end
2053
2054 var result: Int
2055
2056 var sp = _stream_pos
2057 if sp >= 0 then
2058 var res = _stream_buf[_stream_pos]
2059 _stream_pos = sp - 1
2060 result = res.ascii
2061 else
2062 result = _stream.read_char
2063 end
2064
2065 if result == -1 then
2066 _eof = true
2067 end
2068
2069 return result
2070 end
2071
2072 # Unread some characters.
2073 # Unread characters are stored in the pushback buffer.
2074 private fun push_back(accept_length: Int)
2075 do
2076 var length = _text.length
2077 var i = length - 1
2078 while i >= accept_length do
2079 _eof = false
2080 _stream_pos = _stream_pos + 1
2081 _stream_buf[_stream_pos] = _text[i]
2082 i = i - 1
2083 end
2084 end
2085
2086 var _goto_table: Array[Array[Array[Array[Int]]]]
2087 private fun build_goto_table
2088 do
2089 _goto_table = once [
2090 [
2091 [
2092 [9, 9, 1],
2093 [10, 10, 2],
2094 [13, 13, 3],
2095 [32, 32, 4],
2096 [33, 33, 5],
2097 [34, 34, 6],
2098 [35, 35, 7],
2099 [37, 37, 8],
2100 [39, 39, 9],
2101 [40, 40, 10],
2102 [41, 41, 11],
2103 [42, 42, 12],
2104 [43, 43, 13],
2105 [44, 44, 14],
2106 [45, 45, 15],
2107 [46, 46, 16],
2108 [47, 47, 17],
2109 [48, 57, 18],
2110 [58, 58, 19],
2111 [60, 60, 20],
2112 [61, 61, 21],
2113 [62, 62, 22],
2114 [65, 90, 23],
2115 [91, 91, 24],
2116 [93, 93, 25],
2117 [95, 95, 26],
2118 [97, 97, 27],
2119 [98, 98, 28],
2120 [99, 99, 29],
2121 [100, 100, 30],
2122 [101, 101, 31],
2123 [102, 102, 32],
2124 [103, 104, 33],
2125 [105, 105, 34],
2126 [106, 107, 33],
2127 [108, 108, 35],
2128 [109, 109, 33],
2129 [110, 110, 36],
2130 [111, 111, 37],
2131 [112, 112, 38],
2132 [113, 113, 33],
2133 [114, 114, 39],
2134 [115, 115, 40],
2135 [116, 116, 41],
2136 [117, 117, 42],
2137 [118, 118, 43],
2138 [119, 119, 44],
2139 [120, 122, 33],
2140 [125, 125, 45]
2141 ],
2142 [
2143 [9, 9, 1],
2144 [32, 32, 4]
2145 ],
2146 nil_array,
2147 [
2148 [10, 10, 46]
2149 ],
2150 [
2151 [9, 32, -3]
2152 ],
2153 [
2154 [61, 61, 47]
2155 ],
2156 [
2157 [0, 9, 48],
2158 [11, 12, 48],
2159 [14, 33, 48],
2160 [34, 34, 49],
2161 [35, 91, 48],
2162 [92, 92, 50],
2163 [93, 122, 48],
2164 [123, 123, 51],
2165 [124, 255, 48]
2166 ],
2167 [
2168 [0, 9, 52],
2169 [10, 10, 53],
2170 [11, 12, 52],
2171 [13, 13, 54],
2172 [14, 255, 52]
2173 ],
2174 nil_array,
2175 [
2176 [0, 9, 55],
2177 [11, 12, 55],
2178 [14, 38, 55],
2179 [39, 39, 56],
2180 [40, 255, 55]
2181 ],
2182 nil_array,
2183 nil_array,
2184 nil_array,
2185 [
2186 [61, 61, 57]
2187 ],
2188 nil_array,
2189 [
2190 [61, 61, 58]
2191 ],
2192 [
2193 [46, 46, 59],
2194 [48, 57, 60]
2195 ],
2196 nil_array,
2197 [
2198 [46, 46, 61],
2199 [48, 57, 18]
2200 ],
2201 [
2202 [58, 58, 62]
2203 ],
2204 [
2205 [61, 61, 63]
2206 ],
2207 [
2208 [61, 61, 64]
2209 ],
2210 [
2211 [61, 61, 65]
2212 ],
2213 [
2214 [48, 57, 66],
2215 [65, 90, 67],
2216 [95, 95, 68],
2217 [97, 122, 69]
2218 ],
2219 nil_array,
2220 nil_array,
2221 [
2222 [97, 122, 70]
2223 ],
2224 [
2225 [48, 57, 71],
2226 [65, 90, 72],
2227 [95, 95, 73],
2228 [97, 97, 74],
2229 [98, 98, 75],
2230 [99, 109, 74],
2231 [110, 110, 76],
2232 [111, 114, 74],
2233 [115, 115, 77],
2234 [116, 122, 74]
2235 ],
2236 [
2237 [48, 95, -29],
2238 [97, 113, 74],
2239 [114, 114, 78],
2240 [115, 122, 74]
2241 ],
2242 [
2243 [48, 95, -29],
2244 [97, 107, 74],
2245 [108, 108, 79],
2246 [109, 110, 74],
2247 [111, 111, 80],
2248 [112, 122, 74]
2249 ],
2250 [
2251 [48, 95, -29],
2252 [97, 110, 74],
2253 [111, 111, 81],
2254 [112, 122, 74]
2255 ],
2256 [
2257 [48, 107, -31],
2258 [108, 108, 82],
2259 [109, 109, 74],
2260 [110, 110, 83],
2261 [111, 119, 74],
2262 [120, 120, 84],
2263 [121, 122, 74]
2264 ],
2265 [
2266 [48, 95, -29],
2267 [97, 97, 85],
2268 [98, 110, 74],
2269 [111, 111, 86],
2270 [112, 116, 74],
2271 [117, 117, 87],
2272 [118, 122, 74]
2273 ],
2274 [
2275 [48, 95, -29],
2276 [97, 122, 74]
2277 ],
2278 [
2279 [48, 95, -29],
2280 [97, 101, 74],
2281 [102, 102, 88],
2282 [103, 108, 74],
2283 [109, 109, 89],
2284 [110, 110, 90],
2285 [111, 114, 74],
2286 [115, 115, 91],
2287 [116, 122, 74]
2288 ],
2289 [
2290 [48, 95, -29],
2291 [97, 97, 92],
2292 [98, 122, 74]
2293 ],
2294 [
2295 [48, 95, -29],
2296 [97, 100, 74],
2297 [101, 101, 93],
2298 [102, 110, 74],
2299 [111, 111, 94],
2300 [112, 116, 74],
2301 [117, 117, 95],
2302 [118, 122, 74]
2303 ],
2304 [
2305 [48, 95, -29],
2306 [97, 109, 74],
2307 [110, 110, 96],
2308 [111, 113, 74],
2309 [114, 114, 97],
2310 [115, 122, 74]
2311 ],
2312 [
2313 [48, 95, -29],
2314 [97, 97, 98],
2315 [98, 113, 74],
2316 [114, 114, 99],
2317 [115, 122, 74]
2318 ],
2319 [
2320 [48, 100, -38],
2321 [101, 101, 100],
2322 [102, 122, 74]
2323 ],
2324 [
2325 [48, 100, -38],
2326 [101, 101, 101],
2327 [102, 111, 74],
2328 [112, 112, 102],
2329 [113, 116, 74],
2330 [117, 117, 103],
2331 [118, 122, 74]
2332 ],
2333 [
2334 [48, 95, -29],
2335 [97, 103, 74],
2336 [104, 104, 104],
2337 [105, 113, 74],
2338 [114, 114, 105],
2339 [115, 120, 74],
2340 [121, 121, 106],
2341 [122, 122, 74]
2342 ],
2343 [
2344 [48, 109, -39],
2345 [110, 110, 107],
2346 [111, 122, 74]
2347 ],
2348 [
2349 [48, 95, -29],
2350 [97, 97, 108],
2351 [98, 122, 74]
2352 ],
2353 [
2354 [48, 103, -43],
2355 [104, 104, 109],
2356 [105, 113, 74],
2357 [114, 114, 110],
2358 [115, 122, 74]
2359 ],
2360 [
2361 [0, 9, 111],
2362 [11, 12, 111],
2363 [14, 33, 111],
2364 [34, 34, 112],
2365 [35, 91, 111],
2366 [92, 92, 113],
2367 [93, 122, 111],
2368 [123, 123, 114],
2369 [124, 255, 111]
2370 ],
2371 nil_array,
2372 nil_array,
2373 [
2374 [0, 255, -8]
2375 ],
2376 nil_array,
2377 [
2378 [0, 9, 115],
2379 [11, 12, 115],
2380 [14, 255, 115]
2381 ],
2382 nil_array,
2383 [
2384 [0, 255, -9]
2385 ],
2386 nil_array,
2387 [
2388 [10, 10, 116]
2389 ],
2390 [
2391 [0, 255, -11]
2392 ],
2393 nil_array,
2394 nil_array,
2395 nil_array,
2396 [
2397 [46, 46, 117]
2398 ],
2399 [
2400 [48, 57, 60]
2401 ],
2402 [
2403 [48, 57, 60]
2404 ],
2405 nil_array,
2406 [
2407 [62, 62, 118]
2408 ],
2409 nil_array,
2410 nil_array,
2411 [
2412 [48, 122, -25]
2413 ],
2414 [
2415 [48, 122, -25]
2416 ],
2417 [
2418 [48, 122, -25]
2419 ],
2420 [
2421 [48, 122, -25]
2422 ],
2423 [
2424 [48, 57, 119],
2425 [65, 90, 120],
2426 [95, 95, 121],
2427 [97, 122, 122]
2428 ],
2429 [
2430 [48, 122, -35]
2431 ],
2432 [
2433 [48, 122, -35]
2434 ],
2435 [
2436 [48, 122, -35]
2437 ],
2438 [
2439 [48, 122, -35]
2440 ],
2441 [
2442 [48, 110, -32],
2443 [111, 111, 123],
2444 [112, 114, 74],
2445 [115, 115, 124],
2446 [116, 122, 74]
2447 ],
2448 [
2449 [48, 95, -29],
2450 [97, 99, 74],
2451 [100, 100, 125],
2452 [101, 122, 74]
2453 ],
2454 [
2455 [48, 95, -29],
2456 [97, 114, 74],
2457 [115, 115, 126],
2458 [116, 122, 74]
2459 ],
2460 [
2461 [48, 100, -38],
2462 [101, 101, 127],
2463 [102, 122, 74]
2464 ],
2465 [
2466 [48, 95, -29],
2467 [97, 97, 128],
2468 [98, 122, 74]
2469 ],
2470 [
2471 [48, 109, -39],
2472 [110, 110, 129],
2473 [111, 122, 74]
2474 ],
2475 [
2476 [48, 122, -35]
2477 ],
2478 [
2479 [48, 114, -79],
2480 [115, 115, 130],
2481 [116, 122, 74]
2482 ],
2483 [
2484 [48, 99, -78],
2485 [100, 100, 131],
2486 [101, 122, 74]
2487 ],
2488 [
2489 [48, 95, -29],
2490 [97, 115, 74],
2491 [116, 116, 132],
2492 [117, 122, 74]
2493 ],
2494 [
2495 [48, 107, -31],
2496 [108, 108, 133],
2497 [109, 122, 74]
2498 ],
2499 [
2500 [48, 113, -30],
2501 [114, 114, 134],
2502 [115, 122, 74]
2503 ],
2504 [
2505 [48, 109, -39],
2506 [110, 110, 135],
2507 [111, 122, 74]
2508 ],
2509 [
2510 [48, 122, -35]
2511 ],
2512 [
2513 [48, 95, -29],
2514 [97, 111, 74],
2515 [112, 112, 136],
2516 [113, 122, 74]
2517 ],
2518 [
2519 [48, 95, -29],
2520 [97, 104, 74],
2521 [105, 105, 137],
2522 [106, 115, 74],
2523 [116, 116, 138],
2524 [117, 122, 74]
2525 ],
2526 [
2527 [48, 95, -29],
2528 [97, 97, 139],
2529 [98, 114, 74],
2530 [115, 115, 140],
2531 [116, 122, 74]
2532 ],
2533 [
2534 [48, 97, -29],
2535 [98, 98, 141],
2536 [99, 122, 74]
2537 ],
2538 [
2539 [48, 95, -29],
2540 [97, 118, 74],
2541 [119, 119, 142],
2542 [120, 122, 74]
2543 ],
2544 [
2545 [48, 115, -86],
2546 [116, 116, 143],
2547 [117, 122, 74]
2548 ],
2549 [
2550 [48, 107, -31],
2551 [108, 108, 144],
2552 [109, 122, 74]
2553 ],
2554 [
2555 [48, 95, -29],
2556 [97, 98, 74],
2557 [99, 99, 145],
2558 [100, 122, 74]
2559 ],
2560 [
2561 [48, 122, -35]
2562 ],
2563 [
2564 [48, 98, -98],
2565 [99, 99, 146],
2566 [100, 122, 74]
2567 ],
2568 [
2569 [48, 104, -92],
2570 [105, 105, 147],
2571 [106, 110, 74],
2572 [111, 111, 148],
2573 [112, 122, 74]
2574 ],
2575 [
2576 [48, 95, -29],
2577 [97, 97, 149],
2578 [98, 99, 74],
2579 [100, 100, 150],
2580 [101, 115, 74],
2581 [116, 116, 151],
2582 [117, 122, 74]
2583 ],
2584 [
2585 [48, 107, -31],
2586 [108, 108, 152],
2587 [109, 122, 74]
2588 ],
2589 [
2590 [48, 100, -38],
2591 [101, 101, 153],
2592 [102, 122, 74]
2593 ],
2594 [
2595 [48, 111, -91],
2596 [112, 112, 154],
2597 [113, 122, 74]
2598 ],
2599 [
2600 [48, 100, -38],
2601 [101, 101, 155],
2602 [102, 122, 74]
2603 ],
2604 [
2605 [48, 95, -29],
2606 [97, 116, 74],
2607 [117, 117, 156],
2608 [118, 122, 74]
2609 ],
2610 [
2611 [48, 111, -91],
2612 [112, 112, 157],
2613 [113, 122, 74]
2614 ],
2615 [
2616 [48, 104, -92],
2617 [105, 105, 158],
2618 [106, 122, 74]
2619 ],
2620 [
2621 [48, 113, -30],
2622 [114, 114, 159],
2623 [115, 122, 74]
2624 ],
2625 [
2626 [48, 104, -92],
2627 [105, 105, 160],
2628 [106, 122, 74]
2629 ],
2630 [
2631 [48, 104, -92],
2632 [105, 105, 161],
2633 [106, 122, 74]
2634 ],
2635 [
2636 [0, 255, -47]
2637 ],
2638 nil_array,
2639 [
2640 [0, 9, 162],
2641 [11, 12, 162],
2642 [14, 255, 162]
2643 ],
2644 nil_array,
2645 [
2646 [0, 255, -8]
2647 ],
2648 nil_array,
2649 nil_array,
2650 nil_array,
2651 [
2652 [48, 122, -72]
2653 ],
2654 [
2655 [48, 122, -72]
2656 ],
2657 [
2658 [48, 122, -72]
2659 ],
2660 [
2661 [48, 122, -72]
2662 ],
2663 [
2664 [48, 113, -30],
2665 [114, 114, 163],
2666 [115, 122, 74]
2667 ],
2668 [
2669 [48, 115, -86],
2670 [116, 116, 164],
2671 [117, 122, 74]
2672 ],
2673 [
2674 [48, 122, -35]
2675 ],
2676 [
2677 [48, 100, -38],
2678 [101, 101, 165],
2679 [102, 122, 74]
2680 ],
2681 [
2682 [48, 95, -29],
2683 [97, 97, 166],
2684 [98, 122, 74]
2685 ],
2686 [
2687 [48, 114, -79],
2688 [115, 115, 167],
2689 [116, 122, 74]
2690 ],
2691 [
2692 [48, 115, -86],
2693 [116, 116, 168],
2694 [117, 122, 74]
2695 ],
2696 [
2697 [48, 100, -38],
2698 [101, 101, 169],
2699 [102, 122, 74]
2700 ],
2701 [
2702 [48, 122, -35]
2703 ],
2704 [
2705 [48, 100, -38],
2706 [101, 101, 170],
2707 [102, 122, 74]
2708 ],
2709 [
2710 [48, 114, -79],
2711 [115, 115, 171],
2712 [116, 122, 74]
2713 ],
2714 [
2715 [48, 122, -35]
2716 ],
2717 [
2718 [48, 122, -35]
2719 ],
2720 [
2721 [48, 110, -32],
2722 [111, 111, 172],
2723 [112, 122, 74]
2724 ],
2725 [
2726 [48, 115, -86],
2727 [116, 116, 173],
2728 [117, 122, 74]
2729 ],
2730 [
2731 [48, 100, -38],
2732 [101, 101, 174],
2733 [102, 113, 74],
2734 [114, 114, 175],
2735 [115, 122, 74]
2736 ],
2737 [
2738 [48, 122, -35]
2739 ],
2740 [
2741 [48, 100, -38],
2742 [101, 101, 176],
2743 [102, 122, 74]
2744 ],
2745 [
2746 [48, 100, -38],
2747 [101, 101, 177],
2748 [102, 122, 74]
2749 ],
2750 [
2751 [48, 122, -35]
2752 ],
2753 [
2754 [48, 122, -35]
2755 ],
2756 [
2757 [48, 107, -31],
2758 [108, 108, 178],
2759 [109, 122, 74]
2760 ],
2761 [
2762 [48, 100, -38],
2763 [101, 101, 179],
2764 [102, 122, 74]
2765 ],
2766 [
2767 [48, 95, -29],
2768 [97, 106, 74],
2769 [107, 107, 180],
2770 [108, 122, 74]
2771 ],
2772 [
2773 [48, 95, -29],
2774 [97, 117, 74],
2775 [118, 118, 181],
2776 [119, 122, 74]
2777 ],
2778 [
2779 [48, 115, -86],
2780 [116, 116, 182],
2781 [117, 122, 74]
2782 ],
2783 [
2784 [48, 99, -78],
2785 [100, 100, 183],
2786 [101, 122, 74]
2787 ],
2788 [
2789 [48, 100, -38],
2790 [101, 101, 184],
2791 [102, 122, 74]
2792 ],
2793 [
2794 [48, 116, -107],
2795 [117, 117, 185],
2796 [118, 122, 74]
2797 ],
2798 [
2799 [48, 101, -36],
2800 [102, 102, 186],
2801 [103, 122, 74]
2802 ],
2803 [
2804 [48, 98, -98],
2805 [99, 99, 187],
2806 [100, 122, 74]
2807 ],
2808 [
2809 [48, 100, -38],
2810 [101, 101, 188],
2811 [102, 122, 74]
2812 ],
2813 [
2814 [48, 109, -39],
2815 [110, 110, 189],
2816 [111, 122, 74]
2817 ],
2818 [
2819 [48, 100, -38],
2820 [101, 101, 190],
2821 [102, 122, 74]
2822 ],
2823 [
2824 [48, 100, -38],
2825 [101, 101, 191],
2826 [102, 122, 74]
2827 ],
2828 [
2829 [48, 117, -149],
2830 [118, 118, 192],
2831 [119, 122, 74]
2832 ],
2833 [
2834 [48, 122, -35]
2835 ],
2836 [
2837 [48, 107, -31],
2838 [108, 108, 193],
2839 [109, 122, 74]
2840 ],
2841 [
2842 [48, 115, -86],
2843 [116, 116, 194],
2844 [117, 122, 74]
2845 ],
2846 [
2847 [0, 255, -47]
2848 ],
2849 [
2850 [48, 115, -86],
2851 [116, 116, 195],
2852 [117, 122, 74]
2853 ],
2854 [
2855 [48, 113, -30],
2856 [114, 114, 196],
2857 [115, 122, 74]
2858 ],
2859 [
2860 [48, 113, -30],
2861 [114, 114, 197],
2862 [115, 122, 74]
2863 ],
2864 [
2865 [48, 106, -148],
2866 [107, 107, 198],
2867 [108, 122, 74]
2868 ],
2869 [
2870 [48, 114, -79],
2871 [115, 115, 199],
2872 [116, 122, 74]
2873 ],
2874 [
2875 [48, 104, -92],
2876 [105, 105, 200],
2877 [106, 122, 74]
2878 ],
2879 [
2880 [48, 122, -35]
2881 ],
2882 [
2883 [48, 113, -30],
2884 [114, 114, 201],
2885 [115, 122, 74]
2886 ],
2887 [
2888 [48, 100, -38],
2889 [101, 101, 202],
2890 [102, 122, 74]
2891 ],
2892 [
2893 [48, 113, -30],
2894 [114, 114, 203],
2895 [115, 122, 74]
2896 ],
2897 [
2898 [48, 122, -35]
2899 ],
2900 [
2901 [48, 113, -30],
2902 [114, 114, 204],
2903 [115, 122, 74]
2904 ],
2905 [
2906 [48, 116, -107],
2907 [117, 117, 205],
2908 [118, 122, 74]
2909 ],
2910 [
2911 [48, 115, -86],
2912 [116, 116, 206],
2913 [117, 122, 74]
2914 ],
2915 [
2916 [48, 107, -31],
2917 [108, 108, 207],
2918 [109, 122, 74]
2919 ],
2920 [
2921 [48, 95, -29],
2922 [97, 97, 208],
2923 [98, 122, 74]
2924 ],
2925 [
2926 [48, 122, -35]
2927 ],
2928 [
2929 [48, 95, -29],
2930 [97, 97, 209],
2931 [98, 122, 74]
2932 ],
2933 [
2934 [48, 95, -29],
2935 [97, 97, 210],
2936 [98, 122, 74]
2937 ],
2938 [
2939 [48, 100, -38],
2940 [101, 101, 211],
2941 [102, 122, 74]
2942 ],
2943 [
2944 [48, 95, -29],
2945 [97, 97, 212],
2946 [98, 122, 74]
2947 ],
2948 [
2949 [48, 101, -36],
2950 [102, 102, 213],
2951 [103, 122, 74]
2952 ],
2953 [
2954 [48, 113, -30],
2955 [114, 114, 214],
2956 [115, 122, 74]
2957 ],
2958 [
2959 [48, 122, -35]
2960 ],
2961 [
2962 [48, 104, -92],
2963 [105, 105, 215],
2964 [106, 122, 74]
2965 ],
2966 [
2967 [48, 113, -30],
2968 [114, 114, 216],
2969 [115, 122, 74]
2970 ],
2971 [
2972 [48, 122, -35]
2973 ],
2974 [
2975 [48, 122, -35]
2976 ],
2977 [
2978 [48, 122, -35]
2979 ],
2980 [
2981 [48, 100, -38],
2982 [101, 101, 217],
2983 [102, 122, 74]
2984 ],
2985 [
2986 [48, 100, -38],
2987 [101, 101, 218],
2988 [102, 122, 74]
2989 ],
2990 [
2991 [48, 95, -29],
2992 [97, 97, 219],
2993 [98, 122, 74]
2994 ],
2995 [
2996 [48, 122, -35]
2997 ],
2998 [
2999 [48, 95, -29],
3000 [97, 97, 220],
3001 [98, 122, 74]
3002 ],
3003 [
3004 [48, 115, -86],
3005 [116, 116, 221],
3006 [117, 122, 74]
3007 ],
3008 [
3009 [48, 122, -35]
3010 ],
3011 [
3012 [48, 122, -35]
3013 ],
3014 [
3015 [48, 109, -39],
3016 [110, 110, 222],
3017 [111, 122, 74]
3018 ],
3019 [
3020 [48, 109, -39],
3021 [110, 110, 223],
3022 [111, 122, 74]
3023 ],
3024 [
3025 [48, 122, -35]
3026 ],
3027 [
3028 [48, 115, -86],
3029 [116, 116, 224],
3030 [117, 122, 74]
3031 ],
3032 [
3033 [48, 101, -36],
3034 [102, 102, 225],
3035 [103, 109, 74],
3036 [110, 110, 226],
3037 [111, 122, 74]
3038 ],
3039 [
3040 [48, 99, -78],
3041 [100, 100, 227],
3042 [101, 122, 74]
3043 ],
3044 [
3045 [48, 122, -35]
3046 ],
3047 [
3048 [48, 122, -35]
3049 ],
3050 [
3051 [48, 97, -29],
3052 [98, 98, 228],
3053 [99, 122, 74]
3054 ],
3055 [
3056 [48, 95, -29],
3057 [97, 102, 74],
3058 [103, 103, 229],
3059 [104, 122, 74]
3060 ],
3061 [
3062 [48, 115, -86],
3063 [116, 116, 230],
3064 [117, 122, 74]
3065 ],
3066 [
3067 [48, 98, -98],
3068 [99, 99, 231],
3069 [100, 122, 74]
3070 ],
3071 [
3072 [48, 97, -29],
3073 [98, 98, 232],
3074 [99, 122, 74]
3075 ],
3076 [
3077 [48, 122, -35]
3078 ],
3079 [
3080 [48, 109, -39],
3081 [110, 110, 233],
3082 [111, 122, 74]
3083 ],
3084 [
3085 [48, 95, -29],
3086 [97, 97, 234],
3087 [98, 122, 74]
3088 ],
3089 [
3090 [48, 122, -35]
3091 ],
3092 [
3093 [48, 113, -30],
3094 [114, 114, 235],
3095 [115, 122, 74]
3096 ],
3097 [
3098 [48, 122, -35]
3099 ],
3100 [
3101 [48, 97, -29],
3102 [98, 98, 236],
3103 [99, 122, 74]
3104 ],
3105 [
3106 [48, 98, -98],
3107 [99, 99, 237],
3108 [100, 122, 74]
3109 ],
3110 [
3111 [48, 122, -35]
3112 ],
3113 [
3114 [48, 116, -107],
3115 [117, 117, 238],
3116 [118, 122, 74]
3117 ],
3118 [
3119 [48, 122, -35]
3120 ],
3121 [
3122 [48, 122, -35]
3123 ],
3124 [
3125 [48, 95, -29],
3126 [97, 97, 239],
3127 [98, 122, 74]
3128 ],
3129 [
3130 [48, 122, -35]
3131 ],
3132 [
3133 [48, 100, -38],
3134 [101, 101, 240],
3135 [102, 122, 74]
3136 ],
3137 [
3138 [48, 107, -31],
3139 [108, 108, 241],
3140 [109, 122, 74]
3141 ],
3142 [
3143 [48, 100, -38],
3144 [101, 101, 242],
3145 [102, 122, 74]
3146 ],
3147 [
3148 [48, 100, -38],
3149 [101, 101, 243],
3150 [102, 122, 74]
3151 ],
3152 [
3153 [48, 115, -86],
3154 [116, 116, 244],
3155 [117, 122, 74]
3156 ],
3157 [
3158 [48, 107, -31],
3159 [108, 108, 245],
3160 [109, 122, 74]
3161 ],
3162 [
3163 [48, 122, -35]
3164 ],
3165 [
3166 [48, 107, -31],
3167 [108, 108, 246],
3168 [109, 122, 74]
3169 ],
3170 [
3171 [48, 114, -79],
3172 [115, 115, 247],
3173 [116, 122, 74]
3174 ],
3175 [
3176 [48, 107, -31],
3177 [108, 108, 248],
3178 [109, 122, 74]
3179 ],
3180 [
3181 [48, 115, -86],
3182 [116, 116, 249],
3183 [117, 122, 74]
3184 ],
3185 [
3186 [48, 100, -38],
3187 [101, 101, 250],
3188 [102, 122, 74]
3189 ],
3190 [
3191 [48, 98, -98],
3192 [99, 99, 251],
3193 [100, 122, 74]
3194 ],
3195 [
3196 [48, 122, -35]
3197 ],
3198 [
3199 [48, 100, -38],
3200 [101, 101, 252],
3201 [102, 122, 74]
3202 ],
3203 [
3204 [48, 122, -35]
3205 ],
3206 [
3207 [48, 122, -35]
3208 ],
3209 [
3210 [48, 100, -38],
3211 [101, 101, 253],
3212 [102, 122, 74]
3213 ],
3214 [
3215 [48, 100, -38],
3216 [101, 101, 254],
3217 [102, 122, 74]
3218 ],
3219 [
3220 [48, 122, -35]
3221 ],
3222 [
3223 [48, 95, -29],
3224 [97, 97, 255],
3225 [98, 122, 74]
3226 ],
3227 [
3228 [48, 100, -38],
3229 [101, 101, 256],
3230 [102, 122, 74]
3231 ],
3232 [
3233 [48, 122, -35]
3234 ],
3235 [
3236 [48, 122, -35]
3237 ],
3238 [
3239 [48, 100, -38],
3240 [101, 101, 257],
3241 [102, 122, 74]
3242 ],
3243 [
3244 [48, 122, -35]
3245 ],
3246 [
3247 [48, 99, -78],
3248 [100, 100, 258],
3249 [101, 122, 74]
3250 ],
3251 [
3252 [48, 122, -35]
3253 ],
3254 [
3255 [48, 107, -31],
3256 [108, 108, 259],
3257 [109, 122, 74]
3258 ],
3259 [
3260 [48, 122, -35]
3261 ],
3262 [
3263 [48, 122, -35]
3264 ],
3265 [
3266 [48, 122, -35]
3267 ],
3268 [
3269 [48, 122, -35]
3270 ]
3271 ]
3272 ]
3273 end
3274
3275 private fun nil_array: Array[Array[Int]]
3276 do
3277 return once new Array[Array[Int]]
3278 end
3279
3280 var _accept_table: Array[Array[Int]]
3281 private fun build_accept_table do
3282 _accept_table = once [
3283 [
3284 -1,0,1,1,0,76,-1,-1,68,-1,51,52,66,64,55,65,63,67,80,56,71,58,73,77,53,54,-1,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,-1,1,70,-1,83,-1,84,-1,2,2,-1,82,59,60,62,81,-1,57,72,69,74,77,77,77,77,79,78,78,78,78,78,78,47,78,78,78,16,78,78,78,78,78,78,25,78,30,15,78,78,78,78,78,32,78,78,78,78,78,78,78,78,78,78,78,78,78,-1,86,-1,85,-1,2,61,75,79,79,79,79,78,78,31,78,78,78,78,78,10,78,78,29,11,78,78,78,40,78,78,39,33,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,19,78,78,-1,78,78,78,78,78,78,27,78,78,78,13,78,78,78,78,46,41,78,78,78,78,78,78,43,78,78,26,44,12,78,78,78,37,78,78,36,5,78,78,45,78,78,78,49,50,78,78,78,78,78,14,78,78,42,78,28,78,78,38,78,21,4,78,20,78,78,78,78,78,78,34,78,78,78,78,78,78,24,78,3,23,78,78,9,78,78,6,35,78,48,78,17,78,18,7,22,8
3285
3286 ]
3287 ]
3288 end
3289 end
3290