Mercurial > ~dholland > hg > ag > index.cgi
comparison tests/agcl/oldagsrc/good/pgg24ts.cpp @ 0:13d2b8934445
Import AnaGram (near-)release tree into Mercurial.
author | David A. Holland |
---|---|
date | Sat, 22 Dec 2007 17:52:45 -0500 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:13d2b8934445 |
---|---|
1 /* | |
2 AnaGram Syntax Analyzer. | |
3 Copyright (c) Jerome T. Holland, 1989, 1990, 1991, 1992 | |
4 All Rights Reserved. | |
5 */ | |
6 | |
7 //#define INCLUDE_LOGGING | |
8 | |
9 #include "assert.h" //ASSERT | |
10 #include "config.h" | |
11 #include "csexp.h" | |
12 #include "data.h" //DATA | |
13 #include "error.h" | |
14 #include "log.hpp" | |
15 #include "myalloc.h" | |
16 #include "rproc.h" | |
17 #include "stk.h" //STK | |
18 #include "symbol.h" | |
19 #include "token.h" | |
20 #include "tree.h" | |
21 #include "tsd.h" | |
22 #include "ut.h" //UT | |
23 #include <ctype.h> //CTYPE | |
24 #include <stdio.h> //STDIO | |
25 #include <stdlib.h> //STDLIB | |
26 #include <string.h> //STRING | |
27 | |
28 #include "pgg24.h" //PGG | |
29 | |
30 #undef MODULE | |
31 #define MODULE 3 | |
32 | |
33 | |
34 /* | |
35 * AnaGram, A System for Syntax Directed Programming | |
36 * File generated by: ... | |
37 * | |
38 * AnaGram Parsing Engine | |
39 * Copyright 1993-2002 Parsifal Software. All Rights Reserved. | |
40 * | |
41 * This software is provided 'as-is', without any express or implied | |
42 * warranty. In no event will the authors be held liable for any damages | |
43 * arising from the use of this software. | |
44 * | |
45 * Permission is granted to anyone to use this software for any purpose, | |
46 * including commercial applications, and to alter it and redistribute it | |
47 * freely, subject to the following restrictions: | |
48 * | |
49 * 1. The origin of this software must not be misrepresented; you must not | |
50 * claim that you wrote the original software. If you use this software | |
51 * in a product, an acknowledgment in the product documentation would be | |
52 * appreciated but is not required. | |
53 * 2. Altered source versions must be plainly marked as such, and must not be | |
54 * misrepresented as being the original software. | |
55 * 3. This notice may not be removed or altered from any source distribution. | |
56 */ | |
57 | |
58 #ifndef PGG24TS_H | |
59 #include "pgg24ts.h" | |
60 #endif | |
61 | |
62 #ifndef PGG24TS_H | |
63 #error Mismatched header file | |
64 #endif | |
65 | |
66 #include <ctype.h> | |
67 #include <stdio.h> | |
68 | |
69 #define RULE_CONTEXT (&((PCB).cs[(PCB).ssx])) | |
70 #define ERROR_CONTEXT ((PCB).cs[(PCB).error_frame_ssx]) | |
71 #define CONTEXT ((PCB).cs[(PCB).ssx]) | |
72 | |
73 | |
74 #define CHANGE_REDUCTION(x) pgg_change_reduction(pgg_##x##_token) | |
75 int pgg_change_reduction(pgg_token_type); | |
76 | |
77 static void ag_delete_wrappers(void); | |
78 #ifndef DELETE_WRAPPERS | |
79 #define DELETE_WRAPPERS ag_delete_wrappers() | |
80 #endif | |
81 #define TOKEN_NAMES pgg_token_names | |
82 const char *const pgg_token_names[242] = { | |
83 "syntax definition", | |
84 "", | |
85 "\"->\"", | |
86 "", | |
87 "", | |
88 "", | |
89 "", | |
90 "','", | |
91 "", | |
92 "", | |
93 "", | |
94 "\"...\"", | |
95 "", | |
96 "'='", | |
97 "", | |
98 "'!'", | |
99 "", | |
100 "'{'", | |
101 "", | |
102 "'['", | |
103 "", | |
104 "'('", | |
105 "", | |
106 "'-'", | |
107 "", | |
108 "'+'", | |
109 "", | |
110 "']'", | |
111 "", | |
112 "'}'", | |
113 "", | |
114 "')'", | |
115 "", | |
116 "single quote", | |
117 "", | |
118 "'~'", | |
119 "", | |
120 "'|'", | |
121 "syntax definition", | |
122 "", | |
123 "", | |
124 "complete statements", | |
125 "statement", | |
126 "", | |
127 "eof", | |
128 "production", | |
129 "definition", | |
130 "embedded c", | |
131 "configuration section", | |
132 "", | |
133 "", | |
134 "left hand side", | |
135 "right hand side", | |
136 "", | |
137 "", | |
138 "", | |
139 "token name list", | |
140 "type definition", | |
141 "", | |
142 "name", | |
143 "'$'", | |
144 "", | |
145 "", | |
146 "vp rule spec", | |
147 "", | |
148 "", | |
149 "reduction procedure", | |
150 "vp rules", | |
151 "grammar rule", | |
152 "", | |
153 "init grammar rule", | |
154 "rule element", | |
155 "parameter name", | |
156 "c expression", | |
157 "';'", | |
158 "type name", | |
159 "", | |
160 "", | |
161 "", | |
162 "\"::\"", | |
163 "", | |
164 "", | |
165 "", | |
166 "", | |
167 "template field head", | |
168 "'>'", | |
169 "'<'", | |
170 "", | |
171 "", | |
172 "'*'", | |
173 "", | |
174 "", | |
175 "letter", | |
176 "", | |
177 "", | |
178 "\"enum\"", | |
179 "blank char", | |
180 "c comment", | |
181 "continuation", | |
182 "comment", | |
183 "", | |
184 "carriage return", | |
185 "", | |
186 "newline", | |
187 "", | |
188 "vertical space", | |
189 "\"//\"", | |
190 "", | |
191 "", | |
192 "", | |
193 "character", | |
194 "signed number", | |
195 "'^'", | |
196 "", | |
197 "quoted character", | |
198 "char const", | |
199 "", | |
200 "", | |
201 "", | |
202 "decimal number", | |
203 "'0'", | |
204 "octal number", | |
205 "\"0x\"", | |
206 "\"0X\"", | |
207 "", | |
208 "hex number", | |
209 "", | |
210 "", | |
211 "", | |
212 "hex digit", | |
213 "", | |
214 "token", | |
215 "mid rule action", | |
216 "", | |
217 "virtual production", | |
218 "", | |
219 "", | |
220 "'&'", | |
221 "", | |
222 "", | |
223 "escape sequence", | |
224 "octal escape", | |
225 "", | |
226 "hex escape", | |
227 "character range", | |
228 "\"..\"", | |
229 "enum definition", | |
230 "enum statement", | |
231 "keyword string", | |
232 "keyword string head", | |
233 "string", | |
234 "double quote", | |
235 "", | |
236 "", | |
237 "", | |
238 "string char", | |
239 "simple string char", | |
240 "\"\\\\a\"", | |
241 "\"\\\\b\"", | |
242 "\"\\\\f\"", | |
243 "\"\\\\n\"", | |
244 "\"\\\\r\"", | |
245 "\"\\\\t\"", | |
246 "\"\\\\v\"", | |
247 "\"\\\\\\\\\"", | |
248 "\"\\\\?\"", | |
249 "\"\\\\\\'\"", | |
250 "\"\\\\\\\"\"", | |
251 "", | |
252 "backslash", | |
253 "", | |
254 "\"\\\\x\"", | |
255 "any digit", | |
256 "nonoctal digit", | |
257 "':'", | |
258 "", | |
259 "", | |
260 "configuration parameters", | |
261 "configuration parameter list", | |
262 "", | |
263 "configuration parameter", | |
264 "attribute statement", | |
265 "keyword kluge", | |
266 "\"distinguish\"", | |
267 "\"left\"", | |
268 "token list", | |
269 "\"right\"", | |
270 "\"nonassoc\"", | |
271 "\"sticky\"", | |
272 "\"subgrammar\"", | |
273 "\"hidden\"", | |
274 "", | |
275 "", | |
276 "\"disregard\"", | |
277 "\"lexeme\"", | |
278 "\"reserve\"", | |
279 "\"keywords\"", | |
280 "\"rename\"", | |
281 "\"macro\"", | |
282 "macro name", | |
283 "", | |
284 "tokens", | |
285 "'\\?'", | |
286 "\"}...\"", | |
287 "\"]...\"", | |
288 "\"?...\"", | |
289 "\"}/...\"", | |
290 "\"]/...\"", | |
291 "embedded c head", | |
292 "", | |
293 "", | |
294 "", | |
295 "", | |
296 "c code first", | |
297 "", | |
298 "", | |
299 "c character constant", | |
300 "c string constant", | |
301 "", | |
302 "simple c char", | |
303 "", | |
304 "", | |
305 "", | |
306 "", | |
307 "\"\\\\\\n\"", | |
308 "", | |
309 "\"*/\"", | |
310 "\"/*\"", | |
311 "", | |
312 "c literal elem", | |
313 "", | |
314 "", | |
315 "", | |
316 "", | |
317 "", | |
318 "", | |
319 "", | |
320 "", | |
321 "", | |
322 "", | |
323 "", | |
324 "", | |
325 | |
326 }; | |
327 | |
328 | |
329 #line - "pgg24ts.syn" | |
330 int null_warning(int n) { | |
331 extern void warning_here(const char *,...); | |
332 if (n == 0) log_error("Null character in keyword string"); | |
333 return n; | |
334 } | |
335 #line - "pgg24ts.cpp" | |
336 #line - "pgg24ts.syn" | |
337 pgg_pcb_type pgcb; | |
338 //#define PCB pgcb | |
339 | |
340 #define PARSER_STACK_OVERFLOW parse_stack_overflow() | |
341 #define SYNTAX_ERROR log_syntax_error() | |
342 #define GET_CONTEXT CONTEXT.y = PCB.line, CONTEXT.x = PCB.column; | |
343 | |
344 #define REDUCTION_TOKEN_ERROR reduction_token_error() | |
345 | |
346 extern AgStack< AgStack<RuleElement> > ruleElementStack; | |
347 | |
348 AgStack<CSegment> cSegmentStack; | |
349 int nPrologueSegments; | |
350 | |
351 CSegment::CSegment() | |
352 : begin(PCB.pointer), end(PCB.pointer), line(PCB.line) | |
353 { | |
354 LOGSECTION("CSegment::CSegment"); | |
355 // Nothing to do | |
356 } | |
357 | |
358 class PggErrorHandler : public ConfigParam::ErrorHandler { | |
359 void badParam(const char *s){log_error(s);} | |
360 } pggErrorHandler; | |
361 | |
362 | |
363 void reduction_token_error(void) { | |
364 #ifdef INCLUDE_LOGGING | |
365 LOGSECTION("reduction_token_error"); | |
366 LOGV(PCB.sn) LCV(PCB.ssx) LCV(PCB.reduction_token); | |
367 for (int i = 0; i < PCB.ssx; i++) LOGV(i) LCV(PCB.ss[i]); | |
368 #endif | |
369 assert(0); | |
370 } | |
371 | |
372 extern AgString infile_name; | |
373 | |
374 Error::Error(AgString msg, int contextFlag) | |
375 : file(infile_name), | |
376 line(contextFlag? ERROR_CONTEXT.y : PCB.line), | |
377 column(contextFlag? ERROR_CONTEXT.x : PCB.column), | |
378 key(warn), | |
379 message(msg) | |
380 { | |
381 LOGSECTION("Error::Error(AgString, int)"); | |
382 LOGV(PCB.line) LCV(PCB.column) LCV(contextFlag) LCV(msg.pointer()); | |
383 LOGV(ERROR_CONTEXT.x) LCV(ERROR_CONTEXT.y); | |
384 // Nothing here | |
385 } | |
386 | |
387 Error::Error(int l, int c, AgString msg) | |
388 : file(infile_name), | |
389 line(l), | |
390 column(c), | |
391 key(warn), | |
392 message(msg) | |
393 { | |
394 LOGSECTION("Error::Error(int, int, AgString)"); | |
395 // Nothing here | |
396 } | |
397 | |
398 extern tsd *rename_macro_list; | |
399 extern int parse_abort_flag; | |
400 | |
401 void parse_stack_overflow(void) { | |
402 reset_stk(); | |
403 log_error("Nesting too deep. Analysis aborted."); | |
404 errorList.top().setFatal(); | |
405 parse_abort_flag = 1; | |
406 PCB.exit_flag = AG_SEMANTIC_ERROR_CODE; | |
407 } | |
408 | |
409 extern int character_seen; | |
410 extern int enum_base; | |
411 extern unsigned char *input_base; | |
412 extern int precedence_level; | |
413 extern int syntax_error_flag; | |
414 | |
415 Expressionss2(void); | |
416 | |
417 void acs(int); | |
418 void aws(int); | |
419 void atkn(Token); | |
420 void definition_1(Expression); | |
421 void definition_2(int); | |
422 void definition_3(int); | |
423 int form_element_1(Expression); | |
424 int form_spec_2(int, int); | |
425 int form1(void); | |
426 int form2(void); | |
427 int head_list_1(int); | |
428 int head_list_2(int); | |
429 static int head_list_3(int); | |
430 void ics(void); | |
431 int identify_node(Expression); | |
432 void iws(void); | |
433 int makeRule(const AgIndexedContainer<RuleElement> &); | |
434 int mid_line(int); | |
435 int null_warning(int); | |
436 int proc_spec_4(int); | |
437 void production(int); | |
438 void range(int, int); | |
439 void scs(int); | |
440 static void set_prec(int,int); | |
441 void sws(int); | |
442 int vp_form3(int); | |
443 int vp_s(void); | |
444 int vp_1(void); | |
445 int vp_2(void); | |
446 int vp_3(void); | |
447 int vp_4(void); | |
448 int vp_5(int); | |
449 int vp_6(int); | |
450 int vp_7(int); | |
451 int vp_8(int); | |
452 int vp_8a(int); | |
453 int vp_9(void); | |
454 int vp_10(void); | |
455 | |
456 int *disregard_list = NULL; | |
457 int n_disregard_list = 0; | |
458 | |
459 static void disregard(int tn) { | |
460 LOGSECTION("disregard"); | |
461 iws(); | |
462 if (n_disregard_list) { | |
463 int *p = disregard_list; | |
464 while (n_disregard_list--) aws(*p++); | |
465 DEALLOCATE(disregard_list); | |
466 } | |
467 xws(tn); | |
468 disregard_list = build_list(); | |
469 n_disregard_list = fis(); | |
470 } | |
471 | |
472 static void log_syntax_error(void) { | |
473 LOGSECTION("log_syntax_error"); | |
474 | |
475 #ifdef INCLUDE_LOGGING | |
476 { | |
477 LOGV(PCB.sn) LCV(PCB.ssx) LCV(PCB.token_number); | |
478 for (int i = 0; i < PCB.ssx; i++) LOGV(i) LCV(PCB.ss[i]); | |
479 } | |
480 #endif | |
481 int flag = PCB.error_frame_token == pgg_c_comment_token || | |
482 PCB.error_frame_token == pgg_embedded_c_token; | |
483 LOGV(flag); | |
484 reset_stk(); | |
485 | |
486 #ifdef INCLUDE_LOGGING | |
487 { | |
488 LOGV(PCB.sn) LCV(PCB.ssx) LCV(PCB.token_number); | |
489 for (int i = 0; i < PCB.ssx; i++) LOGV(i) LCV(PCB.ss[i]); | |
490 } | |
491 #endif | |
492 ssprintf("%s in %s", PCB.error_message, pgg_token_names[PCB.error_frame_token]); | |
493 LOGS(string_base); | |
494 errorList.push(Error(string_base, flag && PCB.token_number == pgg_eof_token)); | |
495 rcs(); | |
496 #ifdef INCLUDE_LOGGING | |
497 { | |
498 LOGV(PCB.sn) LCV(PCB.ssx) LCV(PCB.token_number); | |
499 for (int i = 0; i < PCB.ssx; i++) LOGV(i) LCV(PCB.ss[i]); | |
500 } | |
501 #endif | |
502 LOGS("error logged"); | |
503 errorList.top().setFatal(); | |
504 LOGS("fatal flag set"); | |
505 syntax_error_flag++; | |
506 #ifdef INCLUDE_LOGGING | |
507 { | |
508 LOGV(PCB.sn) LCV(PCB.ssx) LCV(PCB.token_number); | |
509 for (int i = 0; i < PCB.ssx; i++) LOGV(i) LCV(PCB.ss[i]); | |
510 } | |
511 #endif | |
512 if (errorList.size() < 50) return; | |
513 log_error("Too many errors. Parse aborted."); | |
514 errorList.top().setFatal(); | |
515 PCB.exit_flag = AG_SYNTAX_ERROR_CODE; | |
516 } | |
517 | |
518 static int head_list_3(int type) { | |
519 LOGSECTION("head_list_3"); | |
520 LOGV(type); | |
521 int i, n = tis(); | |
522 for (i = 0; i < n; i ++) { | |
523 Token token(list_base[i]); | |
524 int ptt = token->value_type; | |
525 LOGV(ptt) LCV(type); | |
526 if (ptt && ptt != type) { | |
527 ssprintf("Type Redefinition of T%03d: ", (int) token); | |
528 atkn(token); | |
529 log_error(); | |
530 } | |
531 token->value_type = type; | |
532 /* | |
533 if (ptt == 0 && token->rp_arg && type == void_token_type) { | |
534 //ssprintf("Void token, %s, used as parameter", dict_str(tkn_dict,token->token_name)); | |
535 ssprintf("Void token, %s, used as parameter", token->token_name->string.pointer()); | |
536 log_error(); | |
537 } | |
538 */ | |
539 } | |
540 return type; | |
541 } | |
542 | |
543 static void set_prec(int left, int right){ | |
544 LOGSECTION("set_prec"); | |
545 int n = tis(); | |
546 precedence_level++; | |
547 while (n--) { | |
548 Token token(list_base[n]); | |
549 token->left_associative = left; | |
550 token->right_associative = right; | |
551 token->precedence_level = precedence_level; | |
552 } | |
553 rws(); | |
554 } | |
555 | |
556 static void set_sticky(void){ | |
557 LOGSECTION("set_sticky"); | |
558 int n = tis(); | |
559 while (n--) { | |
560 Token token(list_base[n]); | |
561 token->sticky = 1; | |
562 } | |
563 rws(); | |
564 } | |
565 | |
566 static void set_subgrammar(void){ | |
567 LOGSECTION("set_subgrammar"); | |
568 int n = tis(); | |
569 while (n--) { | |
570 Token token = list_base[n]; | |
571 token->subgrammar = 1; | |
572 } | |
573 rws(); | |
574 } | |
575 | |
576 void set_hidden(void) { | |
577 LOGSECTION("set_hidden"); | |
578 int *lb = list_base; | |
579 int n = tis(); | |
580 //while (n--) map_token_number[*lb++].fine_structure = 1; | |
581 while (n--) Token(*lb++)->fine_structure = 1; | |
582 rws(); | |
583 } | |
584 | |
585 void set_lexeme(void) { | |
586 LOGSECTION("set_lexeme"); | |
587 int n = tis(); | |
588 while (n--) { | |
589 Token token = list_base[n]; | |
590 token->lexeme = 1; | |
591 } | |
592 rws(); | |
593 } | |
594 | |
595 void set_reserved_words(void) { | |
596 LOGSECTION("set_reserved_words"); | |
597 int n = tis(); | |
598 while (n--) { | |
599 Token(list_base[n])->reserved_word = 1; | |
600 } | |
601 rws(); | |
602 } | |
603 | |
604 void parse(void) { | |
605 pgcb.pointer = input_base; | |
606 pgg(&pgcb); | |
607 } | |
608 #line - "pgg24ts.cpp" | |
609 | |
610 #ifndef CONVERT_CASE | |
611 #define CONVERT_CASE(c) (c) | |
612 #endif | |
613 #ifndef TAB_SPACING | |
614 #define TAB_SPACING 8 | |
615 #endif | |
616 | |
617 static inline void ag_rp_1(int t) { | |
618 #line - "pgg24ts.syn" | |
619 production(t); | |
620 #line - "pgg24ts.cpp" | |
621 } | |
622 | |
623 static inline void ag_rp_2(void) { | |
624 #line - "pgg24ts.syn" | |
625 nPrologueSegments = 1; | |
626 #line - "pgg24ts.cpp" | |
627 } | |
628 | |
629 static inline void ag_rp_4(int t) { | |
630 #line - "pgg24ts.syn" | |
631 production(t); | |
632 #line - "pgg24ts.cpp" | |
633 } | |
634 | |
635 static inline int ag_rp_5(int type) { | |
636 #line - "pgg24ts.syn" | |
637 return iws(),type; | |
638 #line - "pgg24ts.cpp" | |
639 } | |
640 | |
641 static inline int ag_rp_6(int type) { | |
642 #line - "pgg24ts.syn" | |
643 return concat_list(),type; | |
644 #line - "pgg24ts.cpp" | |
645 } | |
646 | |
647 static inline int ag_rp_7(void) { | |
648 #line - "pgg24ts.syn" | |
649 return 0; | |
650 #line - "pgg24ts.cpp" | |
651 } | |
652 | |
653 static inline int ag_rp_8(int d) { | |
654 #line - "pgg24ts.syn" | |
655 return head_list_3(d); | |
656 #line - "pgg24ts.cpp" | |
657 } | |
658 | |
659 static inline void ag_rp_9(int x) { | |
660 #line - "pgg24ts.syn" | |
661 sws(head_list_2(x)); | |
662 #line - "pgg24ts.cpp" | |
663 } | |
664 | |
665 static inline void ag_rp_10(int x) { | |
666 #line - "pgg24ts.syn" | |
667 aws(head_list_2(x)); | |
668 #line - "pgg24ts.cpp" | |
669 } | |
670 | |
671 static inline int ag_rp_11(void) { | |
672 #line - "pgg24ts.syn" | |
673 return 0; | |
674 #line - "pgg24ts.cpp" | |
675 } | |
676 | |
677 static inline int ag_rp_12(void) { | |
678 #line - "pgg24ts.syn" | |
679 return 1; | |
680 #line - "pgg24ts.cpp" | |
681 } | |
682 | |
683 static inline int ag_rp_13(void) { | |
684 #line - "pgg24ts.syn" | |
685 return Cast::create(); | |
686 #line - "pgg24ts.cpp" | |
687 } | |
688 | |
689 static inline void ag_rp_14(int n) { | |
690 #line - "pgg24ts.syn" | |
691 sws(n); | |
692 #line - "pgg24ts.cpp" | |
693 } | |
694 | |
695 static inline void ag_rp_15(int n) { | |
696 #line - "pgg24ts.syn" | |
697 aws(n); | |
698 #line - "pgg24ts.cpp" | |
699 } | |
700 | |
701 static inline void ag_rp_16(int pn) { | |
702 #line - "pgg24ts.syn" | |
703 sws((iws(),vp_form3(pn))); | |
704 #line - "pgg24ts.cpp" | |
705 } | |
706 | |
707 static inline int ag_rp_17(int s) { | |
708 #line - "pgg24ts.syn" | |
709 return vp_form3(s); | |
710 #line - "pgg24ts.cpp" | |
711 } | |
712 | |
713 static inline void ag_rp_18(int n) { | |
714 #line - "pgg24ts.syn" | |
715 sws(form_spec_2(form1(),n)); | |
716 #line - "pgg24ts.cpp" | |
717 } | |
718 | |
719 static inline void ag_rp_19(int n) { | |
720 #line - "pgg24ts.syn" | |
721 sws(n); | |
722 #line - "pgg24ts.cpp" | |
723 } | |
724 | |
725 static inline void ag_rp_20(int n) { | |
726 #line - "pgg24ts.syn" | |
727 aws(n); | |
728 #line - "pgg24ts.cpp" | |
729 } | |
730 | |
731 static inline int ag_rp_21(int s) { | |
732 #line - "pgg24ts.syn" | |
733 return form_spec_2(makeRule(ruleElementStack.pop()),s); | |
734 #line - "pgg24ts.cpp" | |
735 } | |
736 | |
737 static inline void ag_rp_22(int e, int p) { | |
738 #line - "pgg24ts.syn" | |
739 ruleElementStack.top().push(RuleElement(e,p)); | |
740 #line - "pgg24ts.cpp" | |
741 } | |
742 | |
743 static inline void ag_rp_23(int e, int p) { | |
744 #line - "pgg24ts.syn" | |
745 ruleElementStack.top().push(RuleElement(e,p)); | |
746 #line - "pgg24ts.cpp" | |
747 } | |
748 | |
749 static inline void ag_rp_24(void) { | |
750 #line - "pgg24ts.syn" | |
751 ruleElementStack.push(AgStack<RuleElement>()); | |
752 #line - "pgg24ts.cpp" | |
753 } | |
754 | |
755 static inline int ag_rp_25(void) { | |
756 #line - "pgg24ts.syn" | |
757 return 0; | |
758 #line - "pgg24ts.cpp" | |
759 } | |
760 | |
761 static inline int ag_rp_26(void) { | |
762 #line - "pgg24ts.syn" | |
763 return proc_spec_4(0); | |
764 #line - "pgg24ts.cpp" | |
765 } | |
766 | |
767 static inline int ag_rp_27(void) { | |
768 #line - "pgg24ts.syn" | |
769 return proc_spec_4(1); | |
770 #line - "pgg24ts.cpp" | |
771 } | |
772 | |
773 static inline void ag_rp_28(void) { | |
774 #line - "pgg24ts.syn" | |
775 concat_string(); | |
776 #line - "pgg24ts.cpp" | |
777 } | |
778 | |
779 static inline void ag_rp_29(void) { | |
780 #line - "pgg24ts.syn" | |
781 sss("::"); | |
782 #line - "pgg24ts.cpp" | |
783 } | |
784 | |
785 static inline void ag_rp_30(void) { | |
786 #line - "pgg24ts.syn" | |
787 concat_string(); | |
788 #line - "pgg24ts.cpp" | |
789 } | |
790 | |
791 static inline void ag_rp_31(void) { | |
792 #line - "pgg24ts.syn" | |
793 ass("::"); | |
794 #line - "pgg24ts.cpp" | |
795 } | |
796 | |
797 static inline void ag_rp_32(void) { | |
798 #line - "pgg24ts.syn" | |
799 concat_string(); | |
800 #line - "pgg24ts.cpp" | |
801 } | |
802 | |
803 static inline void ag_rp_33(void) { | |
804 #line - "pgg24ts.syn" | |
805 concat_string(); | |
806 #line - "pgg24ts.cpp" | |
807 } | |
808 | |
809 static inline void ag_rp_34(void) { | |
810 #line - "pgg24ts.syn" | |
811 acs('>'), concat_string(); | |
812 #line - "pgg24ts.cpp" | |
813 } | |
814 | |
815 static inline void ag_rp_35(void) { | |
816 #line - "pgg24ts.syn" | |
817 acs('<'); | |
818 #line - "pgg24ts.cpp" | |
819 } | |
820 | |
821 static inline void ag_rp_36(void) { | |
822 #line - "pgg24ts.syn" | |
823 acs(','), concat_string(); | |
824 #line - "pgg24ts.cpp" | |
825 } | |
826 | |
827 static inline void ag_rp_37(void) { | |
828 #line - "pgg24ts.syn" | |
829 scs('('); | |
830 #line - "pgg24ts.cpp" | |
831 } | |
832 | |
833 static inline void ag_rp_38(void) { | |
834 #line - "pgg24ts.syn" | |
835 concat_string(), acs(')'); | |
836 #line - "pgg24ts.cpp" | |
837 } | |
838 | |
839 static inline void ag_rp_39(void) { | |
840 #line - "pgg24ts.syn" | |
841 sss(" *"); | |
842 #line - "pgg24ts.cpp" | |
843 } | |
844 | |
845 static inline void ag_rp_40(void) { | |
846 #line - "pgg24ts.syn" | |
847 concat_string(); | |
848 #line - "pgg24ts.cpp" | |
849 } | |
850 | |
851 static inline void ag_rp_41(void) { | |
852 #line - "pgg24ts.syn" | |
853 concat_string(); | |
854 #line - "pgg24ts.cpp" | |
855 } | |
856 | |
857 static inline void ag_rp_42(int c) { | |
858 #line - "pgg24ts.syn" | |
859 scs(c); | |
860 #line - "pgg24ts.cpp" | |
861 } | |
862 | |
863 static inline void ag_rp_43(int c) { | |
864 #line - "pgg24ts.syn" | |
865 acs(c); | |
866 #line - "pgg24ts.cpp" | |
867 } | |
868 | |
869 static inline void ag_rp_44(int c) { | |
870 #line - "pgg24ts.syn" | |
871 acs(' '), acs(c); | |
872 #line - "pgg24ts.cpp" | |
873 } | |
874 | |
875 static inline void ag_rp_45(int c) { | |
876 #line - "pgg24ts.syn" | |
877 sss("enum "), acs(c); | |
878 #line - "pgg24ts.cpp" | |
879 } | |
880 | |
881 static inline void ag_rp_46(int c) { | |
882 #line - "pgg24ts.syn" | |
883 acs(c); | |
884 #line - "pgg24ts.cpp" | |
885 } | |
886 | |
887 static inline void ag_rp_47(int c) { | |
888 #line - "pgg24ts.syn" | |
889 acs(' '), acs(c); | |
890 #line - "pgg24ts.cpp" | |
891 } | |
892 | |
893 static inline int ag_rp_48(int x) { | |
894 #line - "pgg24ts.syn" | |
895 return x & 0x1f; | |
896 #line - "pgg24ts.cpp" | |
897 } | |
898 | |
899 static inline int ag_rp_49(int c) { | |
900 #line - "pgg24ts.syn" | |
901 return (character_seen=1),c; | |
902 #line - "pgg24ts.cpp" | |
903 } | |
904 | |
905 static inline int ag_rp_50(int s, int n) { | |
906 #line - "pgg24ts.syn" | |
907 return s*n; | |
908 #line - "pgg24ts.cpp" | |
909 } | |
910 | |
911 static inline int ag_rp_51(void) { | |
912 #line - "pgg24ts.syn" | |
913 return 1; | |
914 #line - "pgg24ts.cpp" | |
915 } | |
916 | |
917 static inline int ag_rp_52(void) { | |
918 #line - "pgg24ts.syn" | |
919 return -1; | |
920 #line - "pgg24ts.cpp" | |
921 } | |
922 | |
923 static inline int ag_rp_53(int n) { | |
924 #line - "pgg24ts.syn" | |
925 return n; | |
926 #line - "pgg24ts.cpp" | |
927 } | |
928 | |
929 static inline int ag_rp_54(int n) { | |
930 #line - "pgg24ts.syn" | |
931 return n; | |
932 #line - "pgg24ts.cpp" | |
933 } | |
934 | |
935 static inline int ag_rp_55(int d) { | |
936 #line - "pgg24ts.syn" | |
937 return d - '0'; | |
938 #line - "pgg24ts.cpp" | |
939 } | |
940 | |
941 static inline int ag_rp_56(int n, int d) { | |
942 #line - "pgg24ts.syn" | |
943 return 10*n + d - '0'; | |
944 #line - "pgg24ts.cpp" | |
945 } | |
946 | |
947 static inline int ag_rp_57(void) { | |
948 #line - "pgg24ts.syn" | |
949 return 0; | |
950 #line - "pgg24ts.cpp" | |
951 } | |
952 | |
953 static inline int ag_rp_58(int n, int d) { | |
954 #line - "pgg24ts.syn" | |
955 return 8*n + d - '0'; | |
956 #line - "pgg24ts.cpp" | |
957 } | |
958 | |
959 static inline int ag_rp_59(int d) { | |
960 #line - "pgg24ts.syn" | |
961 return d; | |
962 #line - "pgg24ts.cpp" | |
963 } | |
964 | |
965 static inline int ag_rp_60(int n, int d) { | |
966 #line - "pgg24ts.syn" | |
967 return 16*n + d; | |
968 #line - "pgg24ts.cpp" | |
969 } | |
970 | |
971 static inline int ag_rp_61(int d) { | |
972 #line - "pgg24ts.syn" | |
973 return d-'0'; | |
974 #line - "pgg24ts.cpp" | |
975 } | |
976 | |
977 static inline int ag_rp_62(int d) { | |
978 #line - "pgg24ts.syn" | |
979 return (d&7)+9; | |
980 #line - "pgg24ts.cpp" | |
981 } | |
982 | |
983 static inline int ag_rp_63(int p) { | |
984 #line - "pgg24ts.syn" | |
985 return vp_8a(p); | |
986 #line - "pgg24ts.cpp" | |
987 } | |
988 | |
989 static inline int ag_rp_64(Expression &n) { | |
990 #line - "pgg24ts.syn" | |
991 return form_element_1(n); | |
992 #line - "pgg24ts.cpp" | |
993 } | |
994 | |
995 static inline Expression ag_rp_65(Expression &u, Expression &i) { | |
996 #line - "pgg24ts.syn" | |
997 return new CharSetUnion(u,i); | |
998 #line - "pgg24ts.cpp" | |
999 } | |
1000 | |
1001 static inline Expression ag_rp_66(Expression &u, Expression &i) { | |
1002 #line - "pgg24ts.syn" | |
1003 return new CharSetDifference(u,i); | |
1004 #line - "pgg24ts.cpp" | |
1005 } | |
1006 | |
1007 static inline Expression ag_rp_67(Expression &i, Expression &n) { | |
1008 #line - "pgg24ts.syn" | |
1009 return new CharSetIntersection(i,n); | |
1010 #line - "pgg24ts.cpp" | |
1011 } | |
1012 | |
1013 static inline Expression ag_rp_68(Expression &n) { | |
1014 #line - "pgg24ts.syn" | |
1015 return new CharSetComplement(n); | |
1016 #line - "pgg24ts.cpp" | |
1017 } | |
1018 | |
1019 static inline Expression ag_rp_69(int c) { | |
1020 #line - "pgg24ts.syn" | |
1021 return new IndividualCode(c); | |
1022 #line - "pgg24ts.cpp" | |
1023 } | |
1024 | |
1025 static inline Expression ag_rp_70(int c) { | |
1026 #line - "pgg24ts.syn" | |
1027 return new IndividualChar(c); | |
1028 #line - "pgg24ts.cpp" | |
1029 } | |
1030 | |
1031 static inline Expression ag_rp_71(void) { | |
1032 #line - "pgg24ts.syn" | |
1033 return ss2(); | |
1034 #line - "pgg24ts.cpp" | |
1035 } | |
1036 | |
1037 static inline Expression ag_rp_72(Expression &x) { | |
1038 #line - "pgg24ts.syn" | |
1039 return x; | |
1040 #line - "pgg24ts.cpp" | |
1041 } | |
1042 | |
1043 static inline Expression ag_rp_73(int l, int r) { | |
1044 #line - "pgg24ts.syn" | |
1045 return (character_seen=1),new CharRange(l,r); | |
1046 #line - "pgg24ts.cpp" | |
1047 } | |
1048 | |
1049 static inline Expression ag_rp_74(int l, int r) { | |
1050 #line - "pgg24ts.syn" | |
1051 return new CodeRange(l,r); | |
1052 #line - "pgg24ts.cpp" | |
1053 } | |
1054 | |
1055 static inline void ag_rp_75(Expression &n) { | |
1056 #line - "pgg24ts.syn" | |
1057 definition_1(n); | |
1058 #line - "pgg24ts.cpp" | |
1059 } | |
1060 | |
1061 static inline void ag_rp_76(int p) { | |
1062 #line - "pgg24ts.syn" | |
1063 definition_2(p); | |
1064 #line - "pgg24ts.cpp" | |
1065 } | |
1066 | |
1067 static inline void ag_rp_77(int p) { | |
1068 #line - "pgg24ts.syn" | |
1069 definition_2(vp_8a(p)); | |
1070 #line - "pgg24ts.cpp" | |
1071 } | |
1072 | |
1073 static inline void ag_rp_78(void) { | |
1074 #line - "pgg24ts.syn" | |
1075 definition_3(enum_base++); | |
1076 #line - "pgg24ts.cpp" | |
1077 } | |
1078 | |
1079 static inline void ag_rp_79(int n) { | |
1080 #line - "pgg24ts.syn" | |
1081 definition_3(enum_base = n), enum_base++; | |
1082 #line - "pgg24ts.cpp" | |
1083 } | |
1084 | |
1085 static inline void ag_rp_80(int n) { | |
1086 #line - "pgg24ts.syn" | |
1087 definition_3(enum_base = n), enum_base++; | |
1088 #line - "pgg24ts.cpp" | |
1089 } | |
1090 | |
1091 static inline void ag_rp_81(void) { | |
1092 #line - "pgg24ts.syn" | |
1093 ics(); | |
1094 #line - "pgg24ts.cpp" | |
1095 } | |
1096 | |
1097 static inline int ag_rp_82(int n) { | |
1098 #line - "pgg24ts.syn" | |
1099 return null_warning(n); | |
1100 #line - "pgg24ts.cpp" | |
1101 } | |
1102 | |
1103 static inline int ag_rp_83(void) { | |
1104 #line - "pgg24ts.syn" | |
1105 return '\a'; | |
1106 #line - "pgg24ts.cpp" | |
1107 } | |
1108 | |
1109 static inline int ag_rp_84(void) { | |
1110 #line - "pgg24ts.syn" | |
1111 return '\b'; | |
1112 #line - "pgg24ts.cpp" | |
1113 } | |
1114 | |
1115 static inline int ag_rp_85(void) { | |
1116 #line - "pgg24ts.syn" | |
1117 return '\f'; | |
1118 #line - "pgg24ts.cpp" | |
1119 } | |
1120 | |
1121 static inline int ag_rp_86(void) { | |
1122 #line - "pgg24ts.syn" | |
1123 return '\n'; | |
1124 #line - "pgg24ts.cpp" | |
1125 } | |
1126 | |
1127 static inline int ag_rp_87(void) { | |
1128 #line - "pgg24ts.syn" | |
1129 return '\r'; | |
1130 #line - "pgg24ts.cpp" | |
1131 } | |
1132 | |
1133 static inline int ag_rp_88(void) { | |
1134 #line - "pgg24ts.syn" | |
1135 return '\t'; | |
1136 #line - "pgg24ts.cpp" | |
1137 } | |
1138 | |
1139 static inline int ag_rp_89(void) { | |
1140 #line - "pgg24ts.syn" | |
1141 return '\v'; | |
1142 #line - "pgg24ts.cpp" | |
1143 } | |
1144 | |
1145 static inline int ag_rp_90(void) { | |
1146 #line - "pgg24ts.syn" | |
1147 return '\\'; | |
1148 #line - "pgg24ts.cpp" | |
1149 } | |
1150 | |
1151 static inline int ag_rp_91(void) { | |
1152 #line - "pgg24ts.syn" | |
1153 return '\?'; | |
1154 #line - "pgg24ts.cpp" | |
1155 } | |
1156 | |
1157 static inline int ag_rp_92(void) { | |
1158 #line - "pgg24ts.syn" | |
1159 return '\''; | |
1160 #line - "pgg24ts.cpp" | |
1161 } | |
1162 | |
1163 static inline int ag_rp_93(void) { | |
1164 #line - "pgg24ts.syn" | |
1165 return '"'; | |
1166 #line - "pgg24ts.cpp" | |
1167 } | |
1168 | |
1169 static inline int ag_rp_94(int n) { | |
1170 #line - "pgg24ts.syn" | |
1171 return n&7; | |
1172 #line - "pgg24ts.cpp" | |
1173 } | |
1174 | |
1175 static inline int ag_rp_95(int n, int d) { | |
1176 #line - "pgg24ts.syn" | |
1177 return n*8 + (d&7); | |
1178 #line - "pgg24ts.cpp" | |
1179 } | |
1180 | |
1181 static inline int ag_rp_96(int n, int d) { | |
1182 #line - "pgg24ts.syn" | |
1183 return n*8 + (d&7); | |
1184 #line - "pgg24ts.cpp" | |
1185 } | |
1186 | |
1187 static inline int ag_rp_97(int x) { | |
1188 #line - "pgg24ts.syn" | |
1189 return x; | |
1190 #line - "pgg24ts.cpp" | |
1191 } | |
1192 | |
1193 static inline void ag_rp_98(int c) { | |
1194 #line - "pgg24ts.syn" | |
1195 acs(c); | |
1196 #line - "pgg24ts.cpp" | |
1197 } | |
1198 | |
1199 static inline void ag_rp_99(int c) { | |
1200 #line - "pgg24ts.syn" | |
1201 acs(c); | |
1202 #line - "pgg24ts.cpp" | |
1203 } | |
1204 | |
1205 static inline void ag_rp_100(int c) { | |
1206 #line - "pgg24ts.syn" | |
1207 acs(c); | |
1208 #line - "pgg24ts.cpp" | |
1209 } | |
1210 | |
1211 static inline void ag_rp_101(int c) { | |
1212 #line - "pgg24ts.syn" | |
1213 acs(c); | |
1214 #line - "pgg24ts.cpp" | |
1215 } | |
1216 | |
1217 static inline void ag_rp_102(int c) { | |
1218 #line - "pgg24ts.syn" | |
1219 acs(c); | |
1220 #line - "pgg24ts.cpp" | |
1221 } | |
1222 | |
1223 static inline void ag_rp_103(int c) { | |
1224 #line - "pgg24ts.syn" | |
1225 acs(null_warning(c)); | |
1226 #line - "pgg24ts.cpp" | |
1227 } | |
1228 | |
1229 static inline void ag_rp_104(int c) { | |
1230 #line - "pgg24ts.syn" | |
1231 acs(null_warning(c)); | |
1232 #line - "pgg24ts.cpp" | |
1233 } | |
1234 | |
1235 static inline void ag_rp_105(int c) { | |
1236 #line - "pgg24ts.syn" | |
1237 acs(null_warning(c)); | |
1238 #line - "pgg24ts.cpp" | |
1239 } | |
1240 | |
1241 static inline void ag_rp_106(int c) { | |
1242 #line - "pgg24ts.syn" | |
1243 acs(null_warning(c)); | |
1244 #line - "pgg24ts.cpp" | |
1245 } | |
1246 | |
1247 static inline int ag_rp_107(void) { | |
1248 #line - "pgg24ts.syn" | |
1249 return 0; | |
1250 #line - "pgg24ts.cpp" | |
1251 } | |
1252 | |
1253 static inline int ag_rp_108(void) { | |
1254 #line - "pgg24ts.syn" | |
1255 return cVariableList << buildAgString(); | |
1256 #line - "pgg24ts.cpp" | |
1257 } | |
1258 | |
1259 static inline void ag_rp_109(int c) { | |
1260 #line - "pgg24ts.syn" | |
1261 scs(c); | |
1262 #line - "pgg24ts.cpp" | |
1263 } | |
1264 | |
1265 static inline void ag_rp_110(int c) { | |
1266 #line - "pgg24ts.syn" | |
1267 acs(c); | |
1268 #line - "pgg24ts.cpp" | |
1269 } | |
1270 | |
1271 static inline void ag_rp_111(void) { | |
1272 #line - "pgg24ts.syn" | |
1273 ConfigParam::set(1, pggErrorHandler); | |
1274 #line - "pgg24ts.cpp" | |
1275 } | |
1276 | |
1277 static inline void ag_rp_112(void) { | |
1278 #line - "pgg24ts.syn" | |
1279 ConfigParam::set(0, pggErrorHandler); | |
1280 #line - "pgg24ts.cpp" | |
1281 } | |
1282 | |
1283 static inline void ag_rp_113(void) { | |
1284 #line - "pgg24ts.syn" | |
1285 ConfigParam::set(pggErrorHandler); | |
1286 #line - "pgg24ts.cpp" | |
1287 } | |
1288 | |
1289 static inline void ag_rp_114(void) { | |
1290 #line - "pgg24ts.syn" | |
1291 ConfigParam::set(pggErrorHandler); | |
1292 #line - "pgg24ts.cpp" | |
1293 } | |
1294 | |
1295 static inline void ag_rp_115(void) { | |
1296 #line - "pgg24ts.syn" | |
1297 ConfigParam::set(pggErrorHandler); | |
1298 #line - "pgg24ts.cpp" | |
1299 } | |
1300 | |
1301 static inline void ag_rp_116(int n) { | |
1302 #line - "pgg24ts.syn" | |
1303 ConfigParam::set(n, pggErrorHandler); | |
1304 #line - "pgg24ts.cpp" | |
1305 } | |
1306 | |
1307 static inline void ag_rp_117(void) { | |
1308 #line - "pgg24ts.syn" | |
1309 concat_string(), ConfigParam::set(1, pggErrorHandler); | |
1310 #line - "pgg24ts.cpp" | |
1311 } | |
1312 | |
1313 static inline void ag_rp_118(void) { | |
1314 #line - "pgg24ts.syn" | |
1315 sss("distinguish "); | |
1316 #line - "pgg24ts.cpp" | |
1317 } | |
1318 | |
1319 static inline void ag_rp_119(void) { | |
1320 #line - "pgg24ts.syn" | |
1321 set_prec(1,0); | |
1322 #line - "pgg24ts.cpp" | |
1323 } | |
1324 | |
1325 static inline void ag_rp_120(void) { | |
1326 #line - "pgg24ts.syn" | |
1327 set_prec(0,1); | |
1328 #line - "pgg24ts.cpp" | |
1329 } | |
1330 | |
1331 static inline void ag_rp_121(void) { | |
1332 #line - "pgg24ts.syn" | |
1333 set_prec(0,0); | |
1334 #line - "pgg24ts.cpp" | |
1335 } | |
1336 | |
1337 static inline void ag_rp_122(void) { | |
1338 #line - "pgg24ts.syn" | |
1339 set_sticky(); | |
1340 #line - "pgg24ts.cpp" | |
1341 } | |
1342 | |
1343 static inline void ag_rp_123(void) { | |
1344 #line - "pgg24ts.syn" | |
1345 set_subgrammar(); | |
1346 #line - "pgg24ts.cpp" | |
1347 } | |
1348 | |
1349 static inline void ag_rp_124(void) { | |
1350 #line - "pgg24ts.syn" | |
1351 set_hidden(); | |
1352 #line - "pgg24ts.cpp" | |
1353 } | |
1354 | |
1355 static inline void ag_rp_125(int t) { | |
1356 #line - "pgg24ts.syn" | |
1357 disregard(t); | |
1358 #line - "pgg24ts.cpp" | |
1359 } | |
1360 | |
1361 static inline void ag_rp_126(void) { | |
1362 #line - "pgg24ts.syn" | |
1363 set_lexeme(); | |
1364 #line - "pgg24ts.cpp" | |
1365 } | |
1366 | |
1367 static inline void ag_rp_127(void) { | |
1368 #line - "pgg24ts.syn" | |
1369 set_reserved_words(); | |
1370 #line - "pgg24ts.cpp" | |
1371 } | |
1372 | |
1373 static inline void ag_rp_128(int oldName, int newName) { | |
1374 #line - "pgg24ts.syn" | |
1375 at(rename_macro_list,oldName,newName); | |
1376 #line - "pgg24ts.cpp" | |
1377 } | |
1378 | |
1379 static inline int ag_rp_129(void) { | |
1380 #line - "pgg24ts.syn" | |
1381 return (PCB).pointer-input_base-1; | |
1382 #line - "pgg24ts.cpp" | |
1383 } | |
1384 | |
1385 static inline void ag_rp_130(Expression &n) { | |
1386 #line - "pgg24ts.syn" | |
1387 distinguishSets.push(ParseTree(n)); | |
1388 #line - "pgg24ts.cpp" | |
1389 } | |
1390 | |
1391 static inline void ag_rp_131(Expression &n) { | |
1392 #line - "pgg24ts.syn" | |
1393 distinguishSets.push(ParseTree(n)); | |
1394 #line - "pgg24ts.cpp" | |
1395 } | |
1396 | |
1397 static inline void ag_rp_132(int t) { | |
1398 #line - "pgg24ts.syn" | |
1399 sws(t); | |
1400 #line - "pgg24ts.cpp" | |
1401 } | |
1402 | |
1403 static inline void ag_rp_133(int t) { | |
1404 #line - "pgg24ts.syn" | |
1405 aws(t); | |
1406 #line - "pgg24ts.cpp" | |
1407 } | |
1408 | |
1409 static inline int ag_rp_134(void) { | |
1410 #line - "pgg24ts.syn" | |
1411 return vp_s(); | |
1412 #line - "pgg24ts.cpp" | |
1413 } | |
1414 | |
1415 static inline int ag_rp_135(void) { | |
1416 #line - "pgg24ts.syn" | |
1417 return vp_5(vp_s()); | |
1418 #line - "pgg24ts.cpp" | |
1419 } | |
1420 | |
1421 static inline int ag_rp_136(void) { | |
1422 #line - "pgg24ts.syn" | |
1423 return vp_1(); | |
1424 #line - "pgg24ts.cpp" | |
1425 } | |
1426 | |
1427 static inline int ag_rp_137(void) { | |
1428 #line - "pgg24ts.syn" | |
1429 return vp_2(); | |
1430 #line - "pgg24ts.cpp" | |
1431 } | |
1432 | |
1433 static inline int ag_rp_138(void) { | |
1434 #line - "pgg24ts.syn" | |
1435 return vp_3(); | |
1436 #line - "pgg24ts.cpp" | |
1437 } | |
1438 | |
1439 static inline int ag_rp_139(void) { | |
1440 #line - "pgg24ts.syn" | |
1441 return vp_4(); | |
1442 #line - "pgg24ts.cpp" | |
1443 } | |
1444 | |
1445 static inline int ag_rp_140(Expression &n) { | |
1446 #line - "pgg24ts.syn" | |
1447 return vp_5(form_element_1(n)); | |
1448 #line - "pgg24ts.cpp" | |
1449 } | |
1450 | |
1451 static inline int ag_rp_141(Expression &n) { | |
1452 #line - "pgg24ts.syn" | |
1453 return vp_6(form_element_1(n)); | |
1454 #line - "pgg24ts.cpp" | |
1455 } | |
1456 | |
1457 static inline int ag_rp_142(Expression &n) { | |
1458 #line - "pgg24ts.syn" | |
1459 return vp_7(form_element_1(n)); | |
1460 #line - "pgg24ts.cpp" | |
1461 } | |
1462 | |
1463 static inline int ag_rp_143(void) { | |
1464 #line - "pgg24ts.syn" | |
1465 return vp_9(); | |
1466 #line - "pgg24ts.cpp" | |
1467 } | |
1468 | |
1469 static inline int ag_rp_144(void) { | |
1470 #line - "pgg24ts.syn" | |
1471 return vp_10(); | |
1472 #line - "pgg24ts.cpp" | |
1473 } | |
1474 | |
1475 static inline int ag_rp_145(void) { | |
1476 #line - "pgg24ts.syn" | |
1477 return mid_line(proc_spec_4(0)); | |
1478 #line - "pgg24ts.cpp" | |
1479 } | |
1480 | |
1481 static inline int ag_rp_146(void) { | |
1482 #line - "pgg24ts.syn" | |
1483 return mid_line(proc_spec_4(1)); | |
1484 #line - "pgg24ts.cpp" | |
1485 } | |
1486 | |
1487 static inline void ag_rp_147(unsigned char * y) { | |
1488 #line - "pgg24ts.syn" | |
1489 cSegmentStack.top().end = y; | |
1490 #line - "pgg24ts.cpp" | |
1491 } | |
1492 | |
1493 static inline void ag_rp_148(void) { | |
1494 #line - "pgg24ts.syn" | |
1495 cSegmentStack.push(CSegment()); | |
1496 #line - "pgg24ts.cpp" | |
1497 } | |
1498 | |
1499 static inline unsigned char * ag_rp_149(void) { | |
1500 #line - "pgg24ts.syn" | |
1501 return PCB.pointer; | |
1502 #line - "pgg24ts.cpp" | |
1503 } | |
1504 | |
1505 static inline unsigned char * ag_rp_150(void) { | |
1506 #line - "pgg24ts.syn" | |
1507 return PCB.pointer; | |
1508 #line - "pgg24ts.cpp" | |
1509 } | |
1510 | |
1511 static inline void ag_rp_151(void) { | |
1512 #line - "pgg24ts.syn" | |
1513 cSegmentStack.push(CSegment()); | |
1514 #line - "pgg24ts.cpp" | |
1515 } | |
1516 | |
1517 static inline void ag_rp_152(void) { | |
1518 #line - "pgg24ts.syn" | |
1519 cSegmentStack.top().end = PCB.pointer; | |
1520 #line - "pgg24ts.cpp" | |
1521 } | |
1522 | |
1523 static void ag_rp_153(void) { | |
1524 #line - "pgg24ts.syn" | |
1525 if (nest_comments) PCB.reduction_token = pgg_c_comment_head_token; | |
1526 #line - "pgg24ts.cpp" | |
1527 } | |
1528 | |
1529 | |
1530 #define READ_COUNTS | |
1531 #define WRITE_COUNTS | |
1532 #undef V | |
1533 #define V(i,t) (*t (&(PCB).vs[(PCB).ssx + i])) | |
1534 #undef VS | |
1535 #define VS(i) (PCB).vs[(PCB).ssx + i] | |
1536 | |
1537 #ifndef GET_CONTEXT | |
1538 #define GET_CONTEXT CONTEXT = (PCB).input_context | |
1539 #endif | |
1540 | |
1541 typedef enum { | |
1542 ag_action_1, | |
1543 ag_action_2, | |
1544 ag_action_3, | |
1545 ag_action_4, | |
1546 ag_action_5, | |
1547 ag_action_6, | |
1548 ag_action_7, | |
1549 ag_action_8, | |
1550 ag_action_9, | |
1551 ag_action_10, | |
1552 ag_action_11, | |
1553 ag_action_12 | |
1554 } ag_parser_action; | |
1555 | |
1556 | |
1557 #ifndef NULL_VALUE_INITIALIZER | |
1558 #define NULL_VALUE_INITIALIZER = { 0 } | |
1559 #endif | |
1560 | |
1561 | |
1562 static const char ag_wdf[] = { | |
1563 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, | |
1564 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1565 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1566 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1567 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1568 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1569 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, | |
1570 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1571 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1572 0, 4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1573 0, 0, 4, 0, 0, 0 | |
1574 }; | |
1575 | |
1576 #undef VW | |
1577 #define VW(i,t) *(t) (&(PCB).vs[(PCB).ssx + (i)]) | |
1578 #undef VNO | |
1579 #define VNO new(&(PCB).vs[(PCB).ssx]) | |
1580 #undef VRO | |
1581 #define VRO(to,v) ag_replace_object((to) &(PCB).vs[(PCB).ssx], v) | |
1582 #undef VWD | |
1583 #define VWD(i,t) ag_delete_object((t) &(PCB).vs[(PCB).ssx + (i)]); | |
1584 #undef VDO | |
1585 #define VDO(to, v) ag_delete_object((to) &(PCB).vs[(PCB).ssx], v) | |
1586 | |
1587 template <class NewObject, class OldObject> | |
1588 static inline void ag_replace_object(AgObjectWrapper<OldObject> *p, const NewObject &o) { | |
1589 delete p; | |
1590 new(p) AgObjectWrapper<NewObject >(o); | |
1591 } | |
1592 | |
1593 template <class Object> | |
1594 static inline void ag_delete_object(AgObjectWrapper<Object> *p) { | |
1595 delete p; | |
1596 } | |
1597 | |
1598 template <class NewObject, class OldObject> | |
1599 static inline const NewObject &ag_delete_object(AgObjectWrapper<OldObject> *p, const NewObject &o) { | |
1600 delete p; | |
1601 return o; | |
1602 } | |
1603 | |
1604 | |
1605 #undef AG_WRAP_4 | |
1606 #define AG_WRAP_4 AgObjectWrapper<Expression > | |
1607 | |
1608 static void ag_delete_wrappers(void) { | |
1609 if ((PCB).ag_resynch_active) return; | |
1610 (PCB).ag_resynch_active = 1; | |
1611 int sn = (PCB).sn; | |
1612 int sx = (PCB).ssx; | |
1613 while (sx--) { | |
1614 switch (ag_wdf[sn]) { | |
1615 case 4: ag_delete_object((AG_WRAP_4 *) &(PCB).vs[sx]); break; | |
1616 default: break; | |
1617 } | |
1618 sn = (PCB).ss[sx]; | |
1619 } | |
1620 } | |
1621 | |
1622 static pgg_vs_type const ag_null_value NULL_VALUE_INITIALIZER; | |
1623 | |
1624 static const unsigned char ag_rpx[] = { | |
1625 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1626 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 2, 0, 0, 1, 0, 3, | |
1627 0, 4, 0, 5, 0, 0, 0, 0, 0, 0, 0, 6, 7, 8, 9, 10, 11, 12, | |
1628 13, 0, 14, 15, 0, 0, 0, 16, 17, 18, 0, 19, 20, 21, 22, 23, 24, 25, | |
1629 26, 0, 0, 0, 0, 27, 0, 28, 29, 30, 31, 0, 0, 32, 33, 34, 35, 36, | |
1630 37, 38, 0, 39, 0, 40, 41, 42, 43, 44, 45, 46, 0, 0, 0, 0, 0, 0, | |
1631 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1632 0, 47, 48, 49, 0, 0, 50, 51, 0, 52, 0, 0, 53, 54, 55, 56, 57, 58, | |
1633 59, 60, 61, 0, 62, 63, 0, 0, 64, 65, 0, 66, 0, 67, 0, 0, 0, 0, | |
1634 0, 0, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 0, 0, 0, 0, | |
1635 0, 0, 80, 0, 0, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, | |
1636 94, 95, 0, 0, 96, 97, 98, 99,100,101,102,103,104,105,106,107,108,109, | |
1637 0, 0, 0, 0, 0, 0, 0,110,111,112,113,114,115, 0,116,117,118,119, | |
1638 120,121,122,123, 0, 0,124,125,126,127,128, 0, 0, 0, 0, 0,129,130, | |
1639 0,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146, 0, | |
1640 0, 0, 0, 0,147,148,149, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1641 0, 0,150,151, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,152 | |
1642 }; | |
1643 | |
1644 static const unsigned char ag_key_itt[] = { | |
1645 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1646 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, | |
1647 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1648 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1649 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1650 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1651 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1652 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1653 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1654 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1655 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, | |
1656 0 | |
1657 }; | |
1658 | |
1659 static const unsigned short ag_key_pt[] = { | |
1660 0, 11, 0,145,0 | |
1661 }; | |
1662 | |
1663 static const unsigned char ag_key_ch[] = { | |
1664 0, 42, 47,255, 47,255, 42, 47,255, 46,255, 46,255, 42, 47,255, 88,120, | |
1665 255, 46, 47,255,114,116,255,115,255,105,255,102,120,255,101,255,110,115, | |
1666 255,101,105,255,116,117,255, 46, 47,255, 45, 46, 47, 48, 58, 63, 93,100, | |
1667 101,104,108,110,114,115,125,255, 47,255, 42, 47,255,114,116,255,115,255, | |
1668 105,255,102,120,255,101,255,110,115,255,101,105,255,116,117,255, 47,100, | |
1669 101,104,108,110,114,115,255, 42, 47,255, 88,120,255, 47, 48, 58,255, 58, | |
1670 255, 42, 47,255, 46, 47,255, 46, 47,255, 45, 46, 47, 58, 63, 93,125,255, | |
1671 45, 47,255, 42, 47,255, 88,120,255, 47, 48, 58, 92,125,255, 47,255, 47, | |
1672 58,255, 42, 47,255, 88,120,255, 47, 48,255,114,116,255,115,255,105,255, | |
1673 102,120,255,101,255,110,115,255,101,105,255,116,117,255, 47,100,101,104, | |
1674 108,110,114,115,255, 42, 47,255, 88,120,255, 47, 48, 58, 92,255, 88,120, | |
1675 255, 48,255, 42, 47,255, 45, 47,255, 88,120,255, 47, 48,255, 88,120,255, | |
1676 47, 48, 58, 92,125,255, 47, 58,255,114,116,255,115,255,105,255,102,120, | |
1677 255,101,255,110,115,255,101,105,255,116,117,255,100,101,104,108,110,114, | |
1678 115,255, 42, 47,255, 46, 47,255, 46, 47,255, 47, 93,125,255, 42, 47,255, | |
1679 47, 92,255, 92,255, 42, 47,255, 88,120,255, 47, 48,125,255, 34, 39, 63, | |
1680 92, 97, 98,102,110,114,116,118,120,255, 92,255, 88,120,255, 48,125,255, | |
1681 46, 47,255, 46, 47,255, 47, 93,125,255, 46,255, 46,255, 46, 47,255, 46, | |
1682 47,255, 46, 47, 63, 93,125,255, 46, 47,255, 46, 47,255, 46, 47, 63, 93, | |
1683 125,255, 46, 47, 63,255, 46, 47,255, 46, 47,255, 93,125,255, 46, 47,255, | |
1684 93,255, 46, 47,255,125,255,125,255, 46,255, 46,255, 42, 47,255, 46, 47, | |
1685 255, 46, 47,255, 46, 47, 63, 93,125,255, 47,107,255, 47,109,255, 88,120, | |
1686 255, 47, 48,255, 88,120,255, 48, 58,255, 47, 92,255, 42, 47,255, 46, 47, | |
1687 255, 46, 47,255, 46, 47, 63, 93,125,255 | |
1688 }; | |
1689 | |
1690 static const unsigned char ag_key_act[] = { | |
1691 0,0,0,4,2,4,3,3,4,5,4,6,4,0,0,4,0,0,4,3,3,4,3,3,4,2,4,2,4,3,3,4,2,4,3, | |
1692 3,4,2,3,4,3,3,4,3,3,4,3,2,2,2,3,3,2,2,3,3,2,3,2,2,2,4,3,4,0,0,4,3,3,4, | |
1693 2,4,2,4,3,3,4,2,4,3,3,4,2,3,4,3,3,4,2,2,3,3,2,3,2,2,4,0,0,4,0,0,4,2,2, | |
1694 3,4,3,4,0,0,4,3,3,4,3,3,4,3,7,2,3,3,2,2,4,3,3,4,0,0,4,0,0,4,2,2,3,3,3, | |
1695 4,3,4,3,3,4,0,0,4,0,0,4,2,2,4,3,3,4,2,4,2,4,3,3,4,2,4,3,3,4,2,3,4,3,3, | |
1696 4,3,2,3,3,2,3,2,2,4,0,0,4,0,0,4,2,2,3,3,4,0,0,4,2,4,0,0,4,3,2,4,0,0,4, | |
1697 3,2,4,0,0,4,3,2,3,3,3,4,3,3,4,3,3,4,2,4,2,4,3,3,4,2,4,3,3,4,2,3,4,3,3, | |
1698 4,2,3,3,2,3,2,2,4,0,0,4,3,3,4,3,3,4,2,2,2,4,0,0,4,2,3,4,3,4,0,0,4,0,0, | |
1699 4,2,2,3,4,0,0,0,0,0,0,0,0,0,0,0,0,4,2,4,0,0,4,2,3,4,3,3,4,3,3,4,3,2,2, | |
1700 4,5,4,6,4,3,3,4,3,3,4,2,3,3,2,2,4,3,3,4,3,3,4,7,3,3,2,2,4,7,3,3,4,3,3, | |
1701 4,3,3,4,2,2,4,3,3,4,2,4,3,3,4,2,4,3,4,5,4,6,4,0,0,4,3,3,4,3,3,4,2,2,3, | |
1702 2,2,4,3,3,4,3,3,4,0,0,4,3,2,4,0,0,4,2,3,4,3,3,4,0,0,4,3,3,4,3,3,4,7,2, | |
1703 3,2,2,4 | |
1704 }; | |
1705 | |
1706 static const unsigned char ag_key_parm[] = { | |
1707 0,227,106, 0, 0, 0,226,227, 0, 0, 0, 2, 0,227,106, 0,123,122, | |
1708 0,204,207, 0,193,183, 0, 0, 0, 0, 0,184,194, 0, 0, 0,197,195, | |
1709 0, 0,186, 0,188,189, 0,203,206, 0, 2, 0, 0, 0, 79,205, 0, 0, | |
1710 95,190, 0,187, 0, 0, 0, 0,106, 0,227,106, 0,193,183, 0, 0, 0, | |
1711 0, 0,184,194, 0, 0, 0,197,195, 0, 0,186, 0,188,189, 0, 0, 0, | |
1712 95,190, 0,187, 0, 0, 0,227,106, 0,123,122, 0, 0, 0, 79, 0, 79, | |
1713 0,227,106, 0,204,207, 0,203,206, 0, 2, 0, 0, 79,205, 0, 0, 0, | |
1714 2,106, 0,227,106, 0,123,122, 0, 0, 0, 79,224,203, 0,227, 0,106, | |
1715 79, 0,227,106, 0,123,122, 0, 0, 0, 0,193,183, 0, 0, 0, 0, 0, | |
1716 184,194, 0, 0, 0,197,195, 0, 0,186, 0,188,189, 0,106, 0, 95,190, | |
1717 0,187, 0, 0, 0,227,106, 0,123,122, 0, 0, 0, 79,224, 0,123,122, | |
1718 0, 0, 0,227,106, 0, 2, 0, 0,123,122, 0,106, 0, 0,123,122, 0, | |
1719 227, 0, 79,224,203, 0,227, 79, 0,193,183, 0, 0, 0, 0, 0,184,194, | |
1720 0, 0, 0,197,195, 0, 0,186, 0,188,189, 0, 0, 95,190, 0,187, 0, | |
1721 0, 0,227,106, 0,204,207, 0,203,206, 0, 0, 0, 0, 0,227,106, 0, | |
1722 0,224, 0,224, 0,227,106, 0,123,122, 0, 0, 0,203, 0,167,166,165, | |
1723 164,157,158,159,160,161,162,163,171, 0, 0, 0,123,122, 0, 0,203, 0, | |
1724 204,207, 0,203,206, 0,106, 0, 0, 0, 0, 0, 2, 0,204,207, 0,203, | |
1725 206, 0, 0,106,205, 0, 0, 0,204,207, 0,203,206, 0, 0,106,205, 0, | |
1726 0, 0, 0,106,205, 0,204,207, 0,203,206, 0, 0, 0, 0,204,207, 0, | |
1727 0, 0,203,206, 0, 0, 0,203, 0, 0, 0, 2, 0,227,106, 0,204,207, | |
1728 0,203,206, 0, 0, 0,205, 0, 0, 0,227,196, 0,227,198, 0,123,122, | |
1729 0,227, 0, 0,123,122, 0, 0, 79, 0,227,224, 0,227,106, 0,204,207, | |
1730 0,203,206, 0, 0, 0,205, 0, 0, 0 | |
1731 }; | |
1732 | |
1733 static const unsigned short ag_key_jmp[] = { | |
1734 0, 0, 0, 0, 1, 0, 0, 2, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, | |
1735 0, 12, 15, 0, 19, 25, 0, 22, 0, 25, 0, 43, 45, 0, 29, 0, 57, 61, | |
1736 0, 34, 66, 0, 70, 75, 0, 84, 87, 0, 4, 11, 13, 16, 6, 8, 19, 27, | |
1737 33, 37, 32, 49, 37, 40, 43, 0, 91, 0, 0, 0, 0, 93, 99, 0, 67, 0, | |
1738 70, 0,117,119, 0, 74, 0,131,135, 0, 79,140, 0,144,149, 0, 64, 72, | |
1739 107,111, 77,123, 82, 85, 0, 0, 0, 0, 0, 0, 0, 97,100,158, 0,160, | |
1740 0, 0, 0, 0,173,176, 0,180,183, 0,162,164,109,167,169,112,115, 0, | |
1741 187,189, 0, 0, 0, 0, 0, 0, 0,129,132,191,193,195, 0,199, 0,201, | |
1742 203, 0, 0, 0, 0, 0, 0, 0,146,149, 0,207,213, 0,155, 0,158, 0, | |
1743 231,233, 0,162, 0,245,249, 0,167,254, 0,258,263, 0,205,160,221,225, | |
1744 165,237,170,173, 0, 0, 0, 0, 0, 0, 0,185,188,272,274, 0, 0, 0, | |
1745 0,196, 0, 0, 0, 0,276,201, 0, 0, 0, 0,278,207, 0, 0, 0, 0, | |
1746 280,213,282,284,286, 0,290,292, 0,294,300, 0,225, 0,228, 0,318,320, | |
1747 0,232, 0,332,336, 0,237,341, 0,345,350, 0,230,308,312,235,324,240, | |
1748 243, 0, 0, 0, 0,359,362, 0,366,369, 0,254,257,260, 0, 0, 0, 0, | |
1749 267,373, 0,375, 0, 0, 0, 0, 0, 0, 0,275,278,377, 0, 0, 0, 0, | |
1750 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,285, 0, 0, 0, 0,300,381, 0, | |
1751 387,390, 0,394,397, 0,385,306,309, 0, 0, 0,316, 0,407,410, 0,414, | |
1752 417, 0,318,401,403,320,323, 0,430,433, 0,437,440, 0,421,424,426,332, | |
1753 335, 0,444,447,449, 0,453,456, 0,460,463, 0,348,351, 0,467,470, 0, | |
1754 357, 0,474,477, 0,362, 0,481, 0, 0, 0,369, 0, 0, 0, 0,489,492, | |
1755 0,496,499, 0,371,373,485,376,379, 0,503,505, 0,513,515, 0, 0, 0, | |
1756 0,520,394, 0, 0, 0, 0,400,522, 0,524,526, 0, 0, 0, 0,535,538, | |
1757 0,542,545, 0,528,409,531,412,415, 0 | |
1758 }; | |
1759 | |
1760 static const unsigned short ag_key_index[] = { | |
1761 4, 6, 46, 62, 0, 0, 0, 88, 0, 0, 0, 0, 0,103,107, 4,118, 0, | |
1762 126, 88, 4,126,126, 62, 62, 62, 62, 0, 0, 0, 0,135,141,143, 0, 0, | |
1763 4,118,126,126,152, 0,176, 0, 0, 0, 0, 0, 0, 4, 0,191,199,204, | |
1764 152,210, 4, 4, 4,204, 62, 62, 0,216,141,141, 0,222,107, 62, 4,246, | |
1765 263, 0, 0, 0, 0, 0, 4,263,270,273,152,281,298,199,303,312,152,152, | |
1766 199, 0,298,152,199,326,199,338,344,199, 62,273, 62,152,199, 62, 4,204, | |
1767 216, 0,141, 4, 62, 0, 62, 0,141,141,141,141,141, 62, 62,141,141,141, | |
1768 141,141,141, 4, 0,141, 0, 62, 62, 0, 0, 0, 4,273, 0, 0, 0,298, | |
1769 298,298,298,298,354,360,365,367,367,263, 0,382,382,382,382, 0, 0,152, | |
1770 152,263,263,263,199,199,338,312,199, 0, 0, 0,222, 4,388,391,388,141, | |
1771 397, 0, 0,199, 0, 4, 0,141,403, 88, 0, 4, 0, 0,406,263,298,263, | |
1772 263,263,199,263,263,382,382,298,418,418,199,199,338,338, 4,312,263,141, | |
1773 141,141,199, 62, 62, 0, 0, 0, 0,141,141, 62,199,263,199,141,199,298, | |
1774 62,141, 0, 62 | |
1775 }; | |
1776 | |
1777 static const unsigned char ag_key_ends[] = { | |
1778 47,0, 42,0, 62,0, 58,0, 46,46,46,0, 46,46,0, 46,46,46,0, | |
1779 101,103,97,114,100,0, 105,110,103,117,105,115,104,0, 110,117,109,0, | |
1780 105,100,100,101,110,0, 116,0, 101,109,101,0, | |
1781 111,110,97,115,115,111,99,0, 97,109,101,0, 101,114,118,101,0, | |
1782 103,104,116,0, 105,99,107,121,0, 98,103,114,97,109,109,97,114,0, | |
1783 46,46,0, 46,46,46,0, 47,0, 101,103,97,114,100,0, | |
1784 105,110,103,117,105,115,104,0, 110,117,109,0, 105,100,100,101,110,0, | |
1785 116,0, 101,109,101,0, 111,110,97,115,115,111,99,0, 97,109,101,0, | |
1786 101,114,118,101,0, 103,104,116,0, 105,99,107,121,0, | |
1787 98,103,114,97,109,109,97,114,0, 58,0, 58,0, 62,0, 46,46,0, 58,0, | |
1788 46,46,46,0, 46,46,0, 46,46,46,0, 46,46,0, 46,46,46,0, 62,0, | |
1789 47,0, 58,0, 10,0, 46,46,46,0, 42,0, 47,0, 58,0, 47,0, | |
1790 101,103,97,114,100,0, 105,110,103,117,105,115,104,0, 110,117,109,0, | |
1791 105,100,100,101,110,0, 116,0, 101,109,101,0, | |
1792 111,110,97,115,115,111,99,0, 97,109,101,0, 101,114,118,101,0, | |
1793 103,104,116,0, 105,99,107,121,0, 98,103,114,97,109,109,97,114,0, | |
1794 58,0, 10,0, 62,0, 47,0, 42,0, 58,0, 10,0, 46,46,46,0, 42,0, | |
1795 58,0, 101,103,97,114,100,0, 105,110,103,117,105,115,104,0, | |
1796 110,117,109,0, 105,100,100,101,110,0, 116,0, 101,109,101,0, | |
1797 111,110,97,115,115,111,99,0, 97,109,101,0, 101,114,118,101,0, | |
1798 103,104,116,0, 105,99,107,121,0, 98,103,114,97,109,109,97,114,0, | |
1799 46,46,0, 46,46,46,0, 46,46,0, 46,46,46,0, 10,0, 10,0, | |
1800 46,46,46,0, 46,46,46,0, 47,0, 46,46,0, 46,46,46,0, 46,46,0, | |
1801 46,46,46,0, 47,0, 46,46,46,0, 46,46,0, 46,46,46,0, 46,46,0, | |
1802 46,46,46,0, 46,46,0, 47,0, 46,46,46,0, 46,46,0, 46,46,46,0, | |
1803 46,46,0, 46,46,46,0, 46,46,0, 47,0, 46,46,46,0, 46,46,0, | |
1804 46,46,46,0, 46,46,0, 46,46,46,0, 46,46,0, 46,46,46,0, 46,46,0, | |
1805 46,46,46,0, 46,46,46,0, 46,46,46,0, 46,46,0, 46,46,46,0, | |
1806 46,46,0, 46,46,46,0, 42,0, 101,121,119,111,114,100,115,0, 42,0, | |
1807 97,99,114,111,0, 42,0, 58,0, 42,0, 10,0, 46,46,0, 46,46,46,0, | |
1808 46,46,0, 46,46,46,0, 46,46,0, 46,46,46,0, | |
1809 }; | |
1810 | |
1811 #define AG_TCV(x) ag_tcv[(x)] | |
1812 | |
1813 static const unsigned char ag_tcv[] = { | |
1814 44,240,240,240,240,240,240,240,240, 96,103,105,105,101,240,240,240,240, | |
1815 240,240,240,240,240,240,240,240, 44,240,240,240,240,240, 96, 15,151,241, | |
1816 60,241,137, 33, 21, 31, 89, 25, 7, 23,241,241,120,238,238,238,238,238, | |
1817 238,238,239,239,174, 74, 86, 13, 85,202,241,130,130,130,130,130,130,237, | |
1818 237,237,237,237,237,237,237,237,237,237,237,237,237,237,237,237,237,237, | |
1819 237, 19,169, 27,112,237,241,130,130,130,130,130,130,237,237,237,237,237, | |
1820 237,237,237,237,237,237,237,237,237,237,237,237,237,237,237, 17, 37, 29, | |
1821 35,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240, | |
1822 240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240, | |
1823 240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240, | |
1824 240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240, | |
1825 240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240, | |
1826 240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240, | |
1827 240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240, | |
1828 240,240,240,240 | |
1829 }; | |
1830 | |
1831 #ifndef SYNTAX_ERROR | |
1832 #define SYNTAX_ERROR fprintf(stderr,"%s, line %d, column %d\n", \ | |
1833 (PCB).error_message, (PCB).line, (PCB).column) | |
1834 #endif | |
1835 | |
1836 #ifndef FIRST_LINE | |
1837 #define FIRST_LINE 1 | |
1838 #endif | |
1839 | |
1840 #ifndef FIRST_COLUMN | |
1841 #define FIRST_COLUMN 1 | |
1842 #endif | |
1843 | |
1844 #ifndef PARSER_STACK_OVERFLOW | |
1845 #define PARSER_STACK_OVERFLOW {fprintf(stderr, \ | |
1846 "\nParser stack overflow, line %d, column %d\n",\ | |
1847 (PCB).line, (PCB).column);} | |
1848 #endif | |
1849 | |
1850 #ifndef REDUCTION_TOKEN_ERROR | |
1851 #define REDUCTION_TOKEN_ERROR {fprintf(stderr, \ | |
1852 "\nReduction token error, line %d, column %d\n", \ | |
1853 (PCB).line, (PCB).column);} | |
1854 #endif | |
1855 | |
1856 | |
1857 #ifndef INPUT_CODE | |
1858 #define INPUT_CODE(T) (T) | |
1859 #endif | |
1860 | |
1861 typedef enum | |
1862 {ag_accept_key, ag_set_key, ag_jmp_key, ag_end_key, ag_no_match_key, | |
1863 ag_cf_accept_key, ag_cf_set_key, ag_cf_end_key} key_words; | |
1864 | |
1865 static void ag_get_key_word(int ag_k) { | |
1866 int ag_save = (int) ((PCB).la_ptr - (PCB).pointer); | |
1867 const unsigned char *ag_p; | |
1868 int ag_ch; | |
1869 while (1) { | |
1870 switch (ag_key_act[ag_k]) { | |
1871 case ag_cf_end_key: { | |
1872 const unsigned char *sp = ag_key_ends + ag_key_jmp[ag_k]; | |
1873 do { | |
1874 if ((ag_ch = *sp++) == 0) { | |
1875 int ag_k1 = ag_key_parm[ag_k]; | |
1876 int ag_k2 = ag_key_pt[ag_k1]; | |
1877 if (ag_key_itt[ag_k2 + CONVERT_CASE(*(PCB).la_ptr)]) goto ag_fail; | |
1878 (PCB).token_number = (pgg_token_type) ag_key_pt[ag_k1 + 1]; | |
1879 return; | |
1880 } | |
1881 } while (CONVERT_CASE(*(PCB).la_ptr++) == ag_ch); | |
1882 goto ag_fail; | |
1883 } | |
1884 case ag_end_key: { | |
1885 const unsigned char *sp = ag_key_ends + ag_key_jmp[ag_k]; | |
1886 do { | |
1887 if ((ag_ch = *sp++) == 0) { | |
1888 (PCB).token_number = (pgg_token_type) ag_key_parm[ag_k]; | |
1889 return; | |
1890 } | |
1891 } while (CONVERT_CASE(*(PCB).la_ptr++) == ag_ch); | |
1892 } | |
1893 case ag_no_match_key: | |
1894 ag_fail: | |
1895 (PCB).la_ptr = (PCB).pointer + ag_save; | |
1896 return; | |
1897 case ag_cf_set_key: { | |
1898 int ag_k1 = ag_key_parm[ag_k]; | |
1899 int ag_k2 = ag_key_pt[ag_k1]; | |
1900 ag_k = ag_key_jmp[ag_k]; | |
1901 if (ag_key_itt[ag_k2 + CONVERT_CASE(*(PCB).la_ptr)]) break; | |
1902 ag_save = (int) ((PCB).la_ptr - (PCB).pointer); | |
1903 (PCB).token_number = (pgg_token_type) ag_key_pt[ag_k1+1]; | |
1904 break; | |
1905 } | |
1906 case ag_set_key: | |
1907 ag_save = (int) ((PCB).la_ptr - (PCB).pointer); | |
1908 (PCB).token_number = (pgg_token_type) ag_key_parm[ag_k]; | |
1909 case ag_jmp_key: | |
1910 ag_k = ag_key_jmp[ag_k]; | |
1911 break; | |
1912 case ag_accept_key: | |
1913 (PCB).token_number = (pgg_token_type) ag_key_parm[ag_k]; | |
1914 return; | |
1915 case ag_cf_accept_key: { | |
1916 int ag_k1 = ag_key_parm[ag_k]; | |
1917 int ag_k2 = ag_key_pt[ag_k1]; | |
1918 if (ag_key_itt[ag_k2 + CONVERT_CASE(*(PCB).la_ptr)]) | |
1919 (PCB).la_ptr = (PCB).pointer + ag_save; | |
1920 else (PCB).token_number = (pgg_token_type) ag_key_pt[ag_k1+1]; | |
1921 return; | |
1922 } | |
1923 } | |
1924 ag_ch = CONVERT_CASE(*(PCB).la_ptr++); | |
1925 ag_p = &ag_key_ch[ag_k]; | |
1926 if (ag_ch <= 255) while (*ag_p < ag_ch) ag_p++; | |
1927 if (ag_ch > 255 || *ag_p != ag_ch) { | |
1928 (PCB).la_ptr = (PCB).pointer + ag_save; | |
1929 return; | |
1930 } | |
1931 ag_k = (int) (ag_p - ag_key_ch); | |
1932 } | |
1933 } | |
1934 | |
1935 | |
1936 #ifndef AG_NEWLINE | |
1937 #define AG_NEWLINE 10 | |
1938 #endif | |
1939 | |
1940 #ifndef AG_RETURN | |
1941 #define AG_RETURN 13 | |
1942 #endif | |
1943 | |
1944 #ifndef AG_FORMFEED | |
1945 #define AG_FORMFEED 12 | |
1946 #endif | |
1947 | |
1948 #ifndef AG_TABCHAR | |
1949 #define AG_TABCHAR 9 | |
1950 #endif | |
1951 | |
1952 static void ag_track(void) { | |
1953 int ag_k = (int) ((PCB).la_ptr - (PCB).pointer); | |
1954 while (ag_k--) { | |
1955 switch (*(PCB).pointer++) { | |
1956 case AG_NEWLINE: | |
1957 (PCB).column = 1, (PCB).line++; | |
1958 case AG_RETURN: | |
1959 case AG_FORMFEED: | |
1960 break; | |
1961 case AG_TABCHAR: | |
1962 (PCB).column += (TAB_SPACING) - ((PCB).column - 1) % (TAB_SPACING); | |
1963 break; | |
1964 default: | |
1965 (PCB).column++; | |
1966 } | |
1967 } | |
1968 } | |
1969 | |
1970 | |
1971 static void ag_prot(void) { | |
1972 int ag_k; | |
1973 ag_k = 128 - ++(PCB).btsx; | |
1974 if (ag_k <= (PCB).ssx) { | |
1975 (PCB).exit_flag = AG_STACK_ERROR_CODE; | |
1976 PARSER_STACK_OVERFLOW; | |
1977 return; | |
1978 } | |
1979 (PCB).bts[(PCB).btsx] = (PCB).sn; | |
1980 (PCB).bts[ag_k] = (PCB).ssx; | |
1981 (PCB).vs[ag_k] = (PCB).vs[(PCB).ssx]; | |
1982 (PCB).ss[ag_k] = (PCB).ss[(PCB).ssx]; | |
1983 (PCB).cs[ag_k] = (PCB).cs[(PCB).ssx]; | |
1984 } | |
1985 | |
1986 static void ag_undo(void) { | |
1987 if ((PCB).drt == -1) return; | |
1988 while ((PCB).btsx) { | |
1989 int ag_k = 128 - (PCB).btsx; | |
1990 (PCB).sn = (PCB).bts[(PCB).btsx--]; | |
1991 (PCB).ssx = (PCB).bts[ag_k]; | |
1992 (PCB).vs[(PCB).ssx] = (PCB).vs[ag_k]; | |
1993 (PCB).ss[(PCB).ssx] = (PCB).ss[ag_k]; | |
1994 (PCB).cs[(PCB).ssx] = (PCB).cs[ag_k]; | |
1995 } | |
1996 (PCB).token_number = (pgg_token_type) (PCB).drt; | |
1997 (PCB).ssx = (PCB).dssx; | |
1998 (PCB).sn = (PCB).dsn; | |
1999 (PCB).drt = -1; | |
2000 } | |
2001 | |
2002 | |
2003 | |
2004 static const int ag_rtt[] = { | |
2005 97,225, 0 | |
2006 }; | |
2007 | |
2008 static const unsigned char ag_tstt[] = { | |
2009 237,227,130,106,103,101,96,21,19,17,0,3,4,5,38,97,225, | |
2010 241,240,239,238,237,227,226,202,174,169,151,137,130,120,112,105,103,101,96, | |
2011 89,86,85,74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,97,225, | |
2012 227,96,0,3,97,225, | |
2013 237,130,106,103,101,21,19,17,0,39,40,99,102, | |
2014 241,240,239,238,237,202,174,169,151,137,130,120,112,105,103,101,96,89,86,85, | |
2015 74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,108,109, | |
2016 103,0, | |
2017 103,101,0,102, | |
2018 237,227,197,195,194,193,190,189,188,187,186,184,183,130,106,105,103,101,96, | |
2019 95,35,27,21,19,17,0,3,97,99,102,104,225, | |
2020 237,130,21,19,17,0,20,41,45,46,47,48,51,56,57,58,59,91,208, | |
2021 241,240,239,238,237,202,174,169,151,137,130,120,112,105,96,89,86,85,74,60, | |
2022 37,35,33,31,29,27,25,23,21,19,17,15,13,7,0, | |
2023 103,0, | |
2024 103,101,0,102, | |
2025 103,0, | |
2026 239,238,237,227,130,123,122,120,112,106,103,101,96,89,79,35,33,25,23,21,0,3, | |
2027 4,8,9,97,98,99,100,102,225, | |
2028 237,130,79,0,59,61,75,91, | |
2029 241,240,239,238,237,227,202,174,169,151,137,130,120,112,106,105,103,101,96, | |
2030 89,86,85,74,60,37,35,33,31,29,27,25,23,21,19,15,13,7,0,102,210,211,212, | |
2031 239,238,237,227,207,206,205,204,203,202,174,137,130,120,106,103,101,96,89, | |
2032 86,85,79,60,44,37,31,29,27,25,23,21,13,11,7,2,0,3,4,5,97,225, | |
2033 237,130,0,56,58,59,91, | |
2034 7,0,6, | |
2035 237,227,197,195,194,193,190,189,188,187,186,184,183,130,106,103,101,96,95, | |
2036 35,27,0,3,4,5,97,177,225, | |
2037 241,240,239,238,237,227,202,174,169,151,137,130,120,112,106,105,96,89,86,85, | |
2038 74,60,37,35,33,31,29,27,25,23,21,19,15,13,7,0,97,99,209,213,216,217,225, | |
2039 60,13,0,12, | |
2040 2,0,1,52, | |
2041 106,103,101,0,39,99,102, | |
2042 106,103,101,0,39,99,102, | |
2043 106,103,101,0,39,99,102, | |
2044 106,103,101,0,39,99,102, | |
2045 237,130,44,21,19,17,0,20,42,43,45,46,47,48,49,50,51,56,57,58,59,91,208, | |
2046 103,0, | |
2047 103,0, | |
2048 103,101,0,100,102, | |
2049 241,240,239,238,237,227,224,203,202,174,169,151,137,130,123,122,120,112,106, | |
2050 105,103,101,96,89,86,85,79,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7, | |
2051 0,3,97,98,99,100,102,225, | |
2052 237,227,130,96,0,80, | |
2053 106,103,101,89,86,85,79,31,27,21,7,0,76,77,84, | |
2054 31,0, | |
2055 103,0, | |
2056 241,240,239,238,237,227,202,174,169,151,137,130,120,112,106,105,103,101,96, | |
2057 89,86,85,74,60,37,35,33,31,29,27,25,23,21,19,15,13,7,0,102,210, | |
2058 239,238,237,227,130,120,96,0,3,97,225, | |
2059 60,0, | |
2060 7,0,6, | |
2061 239,238,237,227,151,130,123,122,120,112,106,103,101,96,35,33,29,25,23,21,19, | |
2062 17,15,0,3,4,8,9,97,98,99,100,102,225, | |
2063 237,130,0,58,59,91, | |
2064 237,197,195,194,193,190,189,188,187,186,184,183,130,106,103,101,95,35,27,0, | |
2065 39,40,99,102, | |
2066 27,0,26, | |
2067 241,240,239,238,237,202,174,169,151,137,130,120,112,105,96,89,86,85,74,60, | |
2068 37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,231,232,233, | |
2069 241,240,239,238,237,202,174,169,151,137,130,120,112,105,96,89,86,85,74,60, | |
2070 37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,234,235,236, | |
2071 151,0, | |
2072 33,0, | |
2073 103,101,0,102, | |
2074 241,240,239,238,237,227,202,174,169,151,137,130,120,112,106,105,103,101,96, | |
2075 89,86,85,74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,214, | |
2076 29,0,28, | |
2077 241,240,239,238,237,227,224,202,174,169,151,137,130,123,122,120,112,106,105, | |
2078 103,101,96,89,86,85,79,60,37,35,33,31,27,25,23,21,19,17,15,13,7,0,3,4,8, | |
2079 9,97,98,99,100,102,225, | |
2080 239,238,237,151,130,123,122,120,112,35,33,25,23,21,19,17,15,0,14,16,18,20, | |
2081 22,24,34,59,91,110,111,114,116,118,132,133,134,135,136,138,144,148,149, | |
2082 227,106,103,101,96,44,7,2,0,3,4,5,97,225, | |
2083 239,238,237,227,151,130,123,122,120,112,106,103,101,96,44,37,35,33,25,23,21, | |
2084 19,17,15,13,0,3,4,5,97,225, | |
2085 239,238,237,151,130,123,122,120,112,106,103,101,44,37,35,33,25,23,21,19,17, | |
2086 15,13,0,12,55,66,68,69,70, | |
2087 237,227,130,106,105,103,101,96,44,21,19,17,0,3,97,99,102,104,225, | |
2088 237,227,130,106,105,103,101,96,44,21,19,17,0,3,97,99,102,104,225, | |
2089 237,227,130,106,105,103,101,96,44,21,19,17,0,3,97,99,102,104,225, | |
2090 237,227,130,106,105,103,101,96,44,37,21,19,17,2,0,1,3,36,52,53,54,97,99,102, | |
2091 104,225, | |
2092 106,103,101,44,0,39,99,102, | |
2093 106,103,101,44,0,39,99,102, | |
2094 44,0, | |
2095 227,96,0,3,4,97,225, | |
2096 237,227,130,96,0,3,4,5,97,225, | |
2097 237,227,130,96,0,81, | |
2098 89,21,0,20,78,82,83,87,88,90, | |
2099 237,227,130,96,79,0,3,4,5,97,225, | |
2100 237,130,79,0,59,61,75,91, | |
2101 106,103,101,89,85,31,27,21,7,0, | |
2102 237,227,130,106,103,101,96,0,3,4,8,9,97,98,99,100,102,225, | |
2103 237,197,195,194,193,190,189,188,187,186,184,183,130,95,35,27,0,34,59,91,94, | |
2104 147,178,179,180,181,182,191, | |
2105 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2106 241,240,239,238,237,202,174,169,151,137,130,120,112,105,103,101,96,89,86,85, | |
2107 74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,230, | |
2108 241,240,239,238,237,202,174,169,137,130,120,112,105,96,89,86,85,74,60,37,35, | |
2109 33,31,29,27,25,23,21,19,17,15,13,7,0,231, | |
2110 241,240,239,238,237,202,174,169,151,137,130,120,112,105,103,101,96,89,86,85, | |
2111 74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,230, | |
2112 241,240,239,238,237,202,174,169,151,137,130,120,112,105,96,89,86,85,74,60, | |
2113 37,35,31,29,27,25,23,21,19,17,15,13,7,0,234, | |
2114 103,0, | |
2115 241,240,239,238,237,227,202,174,169,151,137,130,120,112,106,105,103,101,96, | |
2116 89,86,85,74,60,37,35,33,31,27,25,23,21,19,17,15,13,7,0,97,99,216,217, | |
2117 218,225, | |
2118 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2119 241,240,239,238,237,227,224,202,174,169,151,137,130,120,112,106,105,103,101, | |
2120 96,89,86,85,60,37,35,33,31,27,25,23,21,19,17,15,13,7,0,3,4,8,9,97,98,99, | |
2121 100,102,225, | |
2122 241,240,239,238,237,224,202,174,169,151,137,130,120,112,105,89,86,85,60,37, | |
2123 35,33,31,27,25,23,21,19,17,15,13,7,0,47,73,208,220, | |
2124 239,238,237,227,151,130,123,122,120,112,106,103,101,96,35,33,25,23,21,19,17, | |
2125 15,0,3,4,8,9,97,98,99,100,102,225, | |
2126 239,238,237,227,203,151,130,123,122,120,112,106,103,101,96,37,35,33,29,25, | |
2127 23,21,19,17,15,13,0,3,4,8,9,97,98,99,100,102,225, | |
2128 241,240,239,238,237,202,174,171,169,167,166,165,164,163,162,161,160,159,158, | |
2129 157,137,130,120,112,105,96,89,86,85,74,60,37,35,33,31,29,27,25,23,21,19, | |
2130 17,15,13,7,0,140,141,142,143,150,152,153,154,155,168,170, | |
2131 239,238,237,151,130,123,122,120,112,35,33,25,23,21,19,17,15,0,62,63,68,70, | |
2132 239,238,237,203,151,130,123,122,120,112,37,35,33,29,25,23,21,19,17,15,13,0, | |
2133 12,62,63,65,66,67,68,70, | |
2134 202,0, | |
2135 239,238,237,227,130,123,122,120,112,106,103,101,96,35,33,25,23,21,0,3,4,8,9, | |
2136 97,98,99,100,102,225, | |
2137 239,238,237,227,130,123,122,120,112,106,103,101,96,35,33,25,23,21,0,3,4,8,9, | |
2138 97,98,99,100,102,225, | |
2139 239,238,123,122,120,0,117,119,124, | |
2140 241,239,238,237,202,174,169,151,137,130,120,112,89,86,85,74,60,37,35,33,31, | |
2141 29,27,25,23,21,19,17,15,13,7,0, | |
2142 241,240,239,238,237,202,174,171,169,167,166,165,164,163,162,161,160,159,158, | |
2143 157,151,137,130,120,112,105,96,89,86,85,74,60,37,35,31,29,27,25,23,21, | |
2144 19,17,15,13,7,0,115,140,141,142,143,168,170, | |
2145 239,238,237,227,130,123,122,120,112,106,103,101,96,35,33,25,23,21,0,3,4,8,9, | |
2146 97,98,99,100,102,225, | |
2147 239,238,237,130,123,122,120,112,35,33,25,23,21,0,20,22,24,34,59,91,110,111, | |
2148 114,116,118,133,135,136,138,144, | |
2149 145,0, | |
2150 239,238,237,130,123,122,120,112,35,33,25,23,21,0,20,22,24,34,59,91,110,111, | |
2151 114,116,118,136,138,144, | |
2152 137,0, | |
2153 205,202,25,23,11,0,10,22,24, | |
2154 239,238,237,151,130,123,122,120,112,35,33,25,23,21,19,17,15,0,14,16,18,20, | |
2155 22,24,34,59,71,91,110,111,114,116,118,131,132,133,134,135,136,138,144, | |
2156 148,149, | |
2157 106,103,101,44,37,13,7,0,6,12,66, | |
2158 241,240,239,238,237,224,202,174,169,151,137,130,120,112,105,89,86,85,60,37, | |
2159 35,33,31,27,25,23,21,19,17,15,13,7,0,47,73,208,220, | |
2160 37,0,36,53, | |
2161 239,238,237,227,151,130,123,122,120,112,106,103,101,96,35,33,25,23,21,19,17, | |
2162 15,0,3,4,8,9,97,98,99,100,102,225, | |
2163 239,238,237,151,130,123,122,120,112,35,33,25,23,21,19,17,15,0,68,69,70, | |
2164 37,0,36,53, | |
2165 237,227,130,106,105,103,101,96,44,21,19,17,0,3,97,99,102,104,225, | |
2166 237,227,130,106,105,103,101,96,44,37,21,19,17,2,0,1,3,36,52,53,54,97,99,102, | |
2167 104,225, | |
2168 227,96,0,3,97,225, | |
2169 237,130,0,59,91, | |
2170 237,227,130,96,0,3,4,5,97,225, | |
2171 237,227,130,106,103,101,96,89,85,31,27,21,7,0,3,4,5,97,225, | |
2172 237,130,0,59,91, | |
2173 89,21,0,20,78,82,83,87,88,90, | |
2174 89,21,0,20,83,87,88,90, | |
2175 85,7,0, | |
2176 227,96,0,3,4,97,225, | |
2177 227,96,0,3,4,97,225, | |
2178 227,96,0,3,4,97,225, | |
2179 227,96,0,3,4,97,185,225, | |
2180 227,96,0,3,4,97,225, | |
2181 106,103,101,29,7,0,6,98,99,100,102,192,200, | |
2182 106,103,101,29,7,0,6,98,99,100,102,192,200, | |
2183 227,96,0,3,4,97,185,225, | |
2184 227,96,0,3,4,97,185,225, | |
2185 227,96,0,3,4,97,185,225, | |
2186 227,96,0,3,4,97,185,225, | |
2187 227,96,0,3,4,97,185,225, | |
2188 227,96,0,3,4,97,185,225, | |
2189 227,106,103,101,96,0,3,4,8,97,98,99,100,102,225, | |
2190 237,130,0,59,91, | |
2191 239,238,237,227,130,120,96,13,0,3,4,5,97,225, | |
2192 237,130,0,59,91, | |
2193 13,0,12, | |
2194 106,103,101,27,0,39,40,99,102, | |
2195 151,0, | |
2196 33,0, | |
2197 103,101,0,102, | |
2198 241,240,239,238,237,227,202,174,169,151,137,130,120,112,106,105,103,101,96, | |
2199 89,86,85,74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,214, | |
2200 241,240,239,238,237,224,202,174,169,151,137,130,120,112,105,89,86,85,60,37, | |
2201 35,33,31,27,25,23,21,19,15,13,7,0,216,217,221,222, | |
2202 74,0, | |
2203 238,120,0, | |
2204 239,238,130,120,0,125,129, | |
2205 238,120,0, | |
2206 238,120,0, | |
2207 239,130,0, | |
2208 239,238,130,120,0, | |
2209 241,240,237,202,174,171,169,167,166,165,164,163,162,161,160,159,158,157,151, | |
2210 137,112,105,96,89,86,85,74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7, | |
2211 0,140,141,142,143,155,168,170, | |
2212 207,206,204,203,37,29,27,13,7,0,6,12,66, | |
2213 207,204,37,27,0,26,36,64, | |
2214 206,37,0,36,64, | |
2215 37,0,36,64, | |
2216 203,29,0,28, | |
2217 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2218 239,238,130,120,0,125,129, | |
2219 238,227,207,206,205,204,203,202,174,145,137,120,106,103,101,96,44,37,31,29, | |
2220 27,25,23,13,11,7,0,121, | |
2221 239,238,120,0, | |
2222 227,207,206,205,204,203,202,174,145,137,106,103,101,96,44,37,31,29,27,25,23, | |
2223 13,11,7,0,3,4,5,97,225, | |
2224 227,207,206,205,204,203,202,174,145,137,106,103,101,96,44,37,31,29,27,25,23, | |
2225 13,11,7,0,3,4,5,97,225, | |
2226 33,23,0,32, | |
2227 31,25,23,0,22,24,30, | |
2228 239,238,227,123,122,120,112,106,103,101,96,25,23,0,3,4,8,9,97,98,99,100,102, | |
2229 225, | |
2230 239,238,237,227,130,123,122,120,112,106,103,101,96,35,33,25,23,21,0,3,4,8,9, | |
2231 97,98,99,100,102,225, | |
2232 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2233 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2234 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2235 239,238,237,130,123,122,120,112,35,33,25,23,21,0,20,22,24,34,59,91,110,111, | |
2236 114,116,118,135,136,138,144, | |
2237 239,238,237,130,123,122,120,112,35,33,25,23,21,0,20,22,24,34,59,91,110,111, | |
2238 114,116,118,135,136,138,144, | |
2239 205,202,25,23,11,0,10,22,24, | |
2240 207,206,204,203,174,106,103,101,44,37,29,27,13,7,0,72, | |
2241 239,238,237,151,130,123,122,120,112,35,33,25,23,21,19,17,15,0,14,16,18,20, | |
2242 22,24,34,59,71,91,110,111,114,116,118,131,132,133,134,135,136,138,144, | |
2243 148,149, | |
2244 74,0, | |
2245 237,130,0,59,91, | |
2246 31,0,30, | |
2247 237,227,130,96,79,0,3,4,5,97,225, | |
2248 227,106,103,101,96,89,85,31,27,21,7,0,3,4,5,97,225, | |
2249 227,196,96,0,3,97,225, | |
2250 227,198,96,0,3,97,225, | |
2251 227,196,96,0,3,97,225, | |
2252 227,96,17,0,3,16,97,225, | |
2253 239,238,237,227,151,130,123,122,120,112,96,35,33,25,23,21,19,17,0,3,16,18, | |
2254 20,22,24,34,59,91,97,110,111,114,116,118,131,133,134,135,136,138,144, | |
2255 148,149,225, | |
2256 29,0,28, | |
2257 237,130,0,59,91,146, | |
2258 239,238,237,130,123,122,120,112,35,33,29,25,23,21,0,20,22,24,34,59,91,110, | |
2259 111,114,116,118,133,135,136,138,144, | |
2260 17,0,16, | |
2261 239,238,237,227,130,120,106,103,101,96,17,0,3,97,98,99,100,102,225, | |
2262 13,0,12, | |
2263 239,238,237,227,130,120,96,0,3,97,225, | |
2264 239,238,237,151,130,123,122,120,79,25,23,0,22,24,59,61,75,91,111,116,118, | |
2265 148,149, | |
2266 237,227,197,195,194,193,190,189,188,187,186,184,183,130,106,105,103,101,96, | |
2267 95,35,27,0,3,34,59,91,94,97,99,102,104,147,180,181,182,191,225, | |
2268 103,0, | |
2269 241,240,239,238,237,227,202,174,169,151,137,130,120,112,106,105,103,101,96, | |
2270 89,86,85,74,60,37,35,33,31,29,27,25,23,21,19,17,15,13,7,0,97,99,216,217, | |
2271 218,225, | |
2272 151,0, | |
2273 33,0, | |
2274 241,240,239,238,237,227,224,202,174,169,151,137,130,120,112,105,96,89,86,85, | |
2275 60,37,35,33,31,27,25,23,21,19,15,13,7,0,3,97,216,217,222,225, | |
2276 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2277 239,238,130,120,0,129, | |
2278 227,207,206,204,203,202,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2279 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2280 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2281 239,238,237,151,130,123,122,120,112,35,33,25,23,21,19,17,15,0,63,68,70, | |
2282 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2283 227,207,206,204,203,174,106,103,101,96,44,37,29,27,13,7,0,3,4,5,97,225, | |
2284 239,238,130,120,0,129, | |
2285 238,120,0, | |
2286 241,240,239,238,237,202,174,171,169,167,166,165,164,163,162,161,160,159,158, | |
2287 157,151,137,130,120,112,105,96,89,86,85,74,60,37,35,31,29,27,25,23,21, | |
2288 19,17,15,13,7,0,115,140,141,142,143,168,170, | |
2289 227,207,206,205,204,203,202,174,137,106,103,101,96,44,37,31,29,27,25,23,13, | |
2290 11,7,0,3,4,5,97,225, | |
2291 227,207,206,205,204,203,202,174,137,106,103,101,96,85,44,37,31,29,27,25,23, | |
2292 13,11,7,0,3,4,5,97,225, | |
2293 239,238,123,122,120,112,25,23,0,22,24,110,111,116,118, | |
2294 239,238,237,130,123,122,120,112,35,33,25,23,21,0,20,22,24,34,59,91,110,111, | |
2295 114,116,118,136,138,144, | |
2296 137,0, | |
2297 137,0, | |
2298 237,227,130,106,103,101,96,0,3,4,8,9,97,98,99,100,102,225, | |
2299 207,206,204,203,174,106,103,101,44,37,29,27,13,7,0,72, | |
2300 227,207,206,204,203,106,103,101,96,44,37,29,27,0,3,4,5,97,225, | |
2301 227,96,0,3,4,97,225, | |
2302 227,96,0,3,4,97,225, | |
2303 227,96,0,3,4,97,185,225, | |
2304 239,238,237,151,130,123,122,120,112,35,33,25,23,21,19,17,0,16,18,20,22,24, | |
2305 34,59,91,110,111,114,116,118,131,133,134,135,136,138,144,148,149,201, | |
2306 13,0,12, | |
2307 25,23,0,22,24, | |
2308 237,130,0,59,91,146, | |
2309 151,0,148,149, | |
2310 33,0,32, | |
2311 237,130,0,175,176, | |
2312 227,96,17,0,3,16,97,225, | |
2313 237,227,130,96,0,3,97,199,225, | |
2314 106,103,101,29,7,0,6,98,99,100,102,192,200, | |
2315 239,238,123,122,120,112,33,25,23,0,22,24,110,111,114,116,118, | |
2316 239,238,237,227,207,206,204,203,130,120,106,103,101,96,44,37,29,27,13,7,0,3, | |
2317 4,5,97,225, | |
2318 239,238,237,130,123,122,120,112,35,33,25,23,21,0,20,22,24,34,59,91,110,111, | |
2319 114,116,118,133,135,136,138,144, | |
2320 239,238,237,227,130,120,96,0,3,4,97,225, | |
2321 239,238,237,151,130,123,122,120,112,35,33,29,25,23,21,19,17,0,16,18,20,22, | |
2322 24,34,59,91,110,111,114,116,118,131,133,134,135,136,138,144,148,149, | |
2323 241,240,239,238,237,202,174,171,169,167,166,165,164,163,162,161,160,159,158, | |
2324 157,151,137,130,120,112,105,96,89,86,85,74,60,37,35,31,29,27,25,23,21, | |
2325 19,17,15,13,7,0,115,140,141,142,143,168,170, | |
2326 25,23,0,22,24, | |
2327 237,227,130,96,0,3,97,199,225, | |
2328 33,0,32, | |
2329 239,238,237,130,120,0, | |
2330 | |
2331 }; | |
2332 | |
2333 | |
2334 static unsigned const char ag_astt[3977] = { | |
2335 5,1,5,8,8,8,1,5,5,5,7,1,1,1,0,1,1,3,3,3,3,3,1,3,3,3,3,3,3,3,3,3,3,3,3,3,3, | |
2336 3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,7,2,1,1,9,5,3,3,1,8,8,1,8,1,8,8,8,7,1, | |
2337 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, | |
2338 1,1,7,1,3,3,7,8,1,7,1,5,1,5,5,5,5,5,5,5,5,5,5,5,5,1,9,8,1,9,5,5,5,5,5,5,7, | |
2339 3,3,1,1,3,1,2,2,1,1,1,7,1,1,1,1,1,1,1,1,1,2,1,1,1,9,9,9,9,9,9,9,9,9,9,9,9, | |
2340 9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,5,3,7,8,1,7,1,3,7,5,5,5,1,5,5, | |
2341 5,5,5,1,8,1,1,5,5,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1,2,2,1,7,1,1,1,1,5,5,5,5, | |
2342 5,5,5,5,5,5,5,5,5,5,5,5,8,1,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,7,1,1,1, | |
2343 2,10,10,10,1,5,5,5,5,5,5,5,5,10,10,5,5,5,1,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, | |
2344 5,7,1,1,3,1,1,2,2,7,1,2,1,1,1,4,1,5,1,5,5,5,5,5,5,5,5,5,5,5,5,8,8,8,1,5,5, | |
2345 5,7,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,4,1,1, | |
2346 1,1,1,1,1,1,7,1,1,1,1,1,1,1,1,1,4,1,1,4,1,3,1,8,1,7,1,1,1,1,8,1,7,1,1,1,1, | |
2347 8,1,7,1,1,1,1,8,1,7,1,1,1,2,2,8,1,1,1,7,1,1,1,1,1,1,1,3,1,1,1,1,2,1,1,1,3, | |
2348 7,1,7,8,1,7,3,1,5,5,5,5,5,1,5,5,5,5,5,5,5,5,5,5,5,5,1,5,8,1,9,5,5,5,5,5,5, | |
2349 5,5,5,5,5,5,5,5,5,5,5,5,5,7,3,3,3,1,3,1,1,4,4,4,4,7,1,5,5,5,8,1,5,1,5,5,8, | |
2350 5,7,1,1,1,1,7,3,7,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,8,1,5,5,5,5,5,5,5,5,5,5, | |
2351 5,5,5,5,5,5,5,5,5,7,1,3,2,2,2,1,2,2,9,5,3,3,1,1,4,1,4,1,5,5,5,1,5,5,5,5,5, | |
2352 5,1,8,1,1,5,5,5,5,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1,2,2,7,2,1,1,8,8,8,8,8,8, | |
2353 8,8,8,8,8,8,8,1,8,1,8,8,5,7,1,1,1,1,1,7,3,1,1,1,1,1,1,1,1,5,1,1,1,1,1,1,1, | |
2354 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,7,1,1,3,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, | |
2355 1,1,1,1,1,1,1,5,1,1,1,1,1,1,1,1,1,1,1,7,1,1,3,3,7,3,7,8,1,7,1,8,8,8,8,8,8, | |
2356 8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,5,8,8,8,8,8,8,8,8,8,7,1,1,7,2, | |
2357 5,5,5,5,5,1,5,5,5,5,5,5,5,5,5,5,5,1,5,8,1,1,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, | |
2358 5,5,5,7,1,1,3,3,1,3,1,3,1,1,5,5,2,2,2,5,5,5,1,1,1,1,1,1,1,1,1,7,1,1,1,1,2, | |
2359 2,1,2,1,1,1,2,1,2,2,1,2,1,1,1,1,1,1,1,5,5,5,1,5,5,5,7,1,1,2,1,1,5,5,5,1,5, | |
2360 5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,5,5,5,5,5,7,1,1,3,1,1,4,4,4,4,4,4,4,4,4,4,4, | |
2361 4,4,4,4,4,4,4,4,4,4,4,1,7,1,1,2,1,2,1,5,1,5,1,9,8,1,9,5,5,5,5,7,3,3,1,1,3, | |
2362 1,4,1,4,1,9,8,1,9,4,4,4,4,7,3,3,1,1,3,1,5,1,5,1,9,8,1,9,5,5,5,5,7,3,3,1,1, | |
2363 3,1,4,1,4,1,9,8,1,9,4,1,4,4,4,1,7,1,3,1,2,1,1,3,1,1,3,1,1,8,1,5,7,1,1,1,1, | |
2364 8,1,4,7,1,1,1,3,7,1,1,5,1,1,1,1,8,1,8,1,7,1,1,1,1,1,4,4,4,4,7,1,1,1,7,2,2, | |
2365 1,2,1,1,1,5,1,5,1,5,7,1,1,2,1,1,2,2,1,7,1,1,1,1,5,5,5,5,5,5,5,5,5,7,5,1,5, | |
2366 1,8,1,1,7,1,1,2,2,1,2,1,2,1,1,2,1,1,1,1,1,1,1,1,1,1,1,2,1,1,5,7,1,1,1,1,1, | |
2367 1,3,1,1,1,1,1,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,7,1,1,3,1,1,3,3,3,3,3,3,3,3,3, | |
2368 3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,7,3,9,9,9,9,9,9,9,1, | |
2369 9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,5,3,3,3,3,3,3,3,3,3,3,3, | |
2370 3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,7,3,9,9,9,9,9,9,9,1,9, | |
2371 9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,5,3,3,7,9,9,9,9,9,1,9,9,9, | |
2372 1,9,9,9,9,1,9,9,9,9,9,9,9,9,9,9,9,1,9,9,9,9,9,9,1,9,9,9,4,3,1,1,1,3,1,1,5, | |
2373 5,5,5,5,5,5,5,1,5,5,5,5,5,5,7,1,1,3,1,1,5,5,5,5,5,1,5,5,5,5,5,5,5,5,5,1,5, | |
2374 8,1,1,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1,4,4,4,4,4,4, | |
2375 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,1,4,4,4,7,2,1,1,1,5,5,5,1,5,5, | |
2376 5,5,5,5,1,8,1,1,5,5,5,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1,5,5,5,1,5,5,5,5,5,5, | |
2377 5,1,8,1,1,5,5,5,5,5,5,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1,2,2,2,2,2,2,2,1,1,2, | |
2378 2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,7,2, | |
2379 2,2,2,1,1,1,1,2,1,1,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,7,1,2,1,1,4,4,4,4,4, | |
2380 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,1,7,1,1,2,1,2,1,1,1,1,4,5,5,5,1,5,5,5,5,5,1, | |
2381 8,1,1,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1,5,5,5,1,5,5,5,5,5,1,8,1,1,5,5,5,5,5, | |
2382 7,1,1,3,3,1,3,1,3,1,1,2,2,1,1,1,7,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, | |
2383 1,1,1,1,1,1,1,1,1,1,1,1,1,1,7,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,1,1, | |
2384 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,7,1,1,1,1,1,1,1,5,5,5,1,5,5, | |
2385 5,5,5,1,8,1,1,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1,5,5,2,2,5,5,5,1,1,1,1,1,1,7, | |
2386 1,2,2,1,2,1,1,1,2,1,2,1,1,1,1,1,1,4,5,5,2,2,5,5,5,1,1,1,1,1,1,7,1,2,2,1,2, | |
2387 1,1,1,2,1,2,2,2,2,1,5,1,1,1,1,1,4,2,1,1,5,5,2,2,2,5,5,5,1,1,1,1,1,1,1,1,1, | |
2388 7,1,1,1,1,2,2,1,2,1,1,1,1,2,1,2,1,2,1,1,1,1,1,1,1,1,4,4,4,4,4,1,1,7,1,1,2, | |
2389 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,1,4,4,4,7,2,1,1,1, | |
2390 1,5,1,3,5,5,5,1,5,5,5,5,5,5,1,8,1,1,5,5,5,5,5,5,5,5,7,1,1,3,3,1,3,1,3,1,1, | |
2391 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,7,1,2,1,1,5,1,3,5,1,5,1,9,8,1,9,5,5,5,5, | |
2392 7,3,3,1,1,3,1,4,1,4,1,9,8,1,9,4,1,4,4,4,1,7,1,3,1,2,1,1,3,1,1,3,1,1,9,5,3, | |
2393 3,1,2,2,7,2,1,8,1,8,1,7,1,1,1,1,1,5,1,5,5,5,5,1,5,5,5,5,5,5,7,1,1,2,1,1,2, | |
2394 2,5,2,1,1,1,7,2,1,1,1,1,1,1,1,1,5,2,2,1,1,2,1,1,7,1,1,7,1,1,1,1,1,1,7,1,1, | |
2395 1,1,1,1,7,1,1,1,1,1,1,7,1,1,1,2,1,1,1,7,1,1,1,1,1,8,1,8,1,7,1,1,1,1,1,3,1, | |
2396 1,8,1,8,1,7,1,1,1,1,1,3,1,1,1,7,1,1,1,2,1,1,1,7,1,1,1,2,1,1,1,7,1,1,1,2,1, | |
2397 1,1,7,1,1,1,2,1,1,1,7,1,1,1,2,1,1,1,7,1,1,1,2,1,1,1,8,1,1,7,1,1,1,1,1,1,1, | |
2398 1,1,2,2,7,2,1,10,10,10,1,10,10,1,8,7,1,1,1,1,1,2,2,7,2,1,1,4,1,1,8,1,5,7,1, | |
2399 3,1,1,3,7,3,7,8,1,7,1,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8, | |
2400 8,8,8,8,8,8,8,8,8,8,8,8,7,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, | |
2401 1,1,1,1,1,1,1,1,7,1,1,1,1,1,7,2,2,7,2,2,2,2,7,1,2,2,2,5,2,2,5,2,2,5,10,10, | |
2402 10,10,5,2,2,2,2,2,1,1,2,2,2,2,2,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2, | |
2403 2,2,2,2,2,2,2,2,2,7,2,2,2,2,2,1,1,4,4,4,4,4,4,4,1,1,7,1,1,2,1,1,1,1,7,2,1, | |
2404 3,1,1,5,1,3,1,5,1,3,1,1,7,2,1,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,7,1,1,2,1,1,2, | |
2405 2,2,2,7,1,2,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,7,1,10,10, | |
2406 10,5,1,5,5,5,5,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,5,5,5,5,7,1,1,2,1,1,1,5,5,5,5, | |
2407 5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,5,5,5,5,7,1,1,2,1,1,1,1,7,2,1,1,1,7,1,1,2,8, | |
2408 8,1,8,8,8,8,1,8,1,1,8,8,7,1,1,1,1,1,1,1,1,1,1,8,8,8,1,8,8,8,8,8,1,8,1,1,8, | |
2409 8,8,8,8,7,1,1,1,1,1,1,1,1,1,1,1,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,7,1,1,3,1,1, | |
2410 1,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,7,1,1,2,1,1,1,5,5,5,5,5,5,5,5,1,5,5,5,5,5, | |
2411 5,7,1,1,2,1,1,5,5,2,2,5,5,5,1,1,1,1,1,1,7,1,2,2,1,2,1,1,1,2,1,2,1,1,1,1,5, | |
2412 5,2,2,5,5,5,1,1,1,1,1,1,7,1,2,2,1,2,1,1,1,2,1,2,1,1,1,1,1,1,1,1,1,4,2,1,1, | |
2413 4,4,4,4,1,4,4,4,4,4,4,4,4,4,7,2,5,5,2,2,2,5,5,5,1,1,1,1,1,1,1,1,1,7,1,1,1, | |
2414 1,2,2,1,2,1,1,1,1,2,1,2,1,2,1,1,1,1,1,1,1,1,1,7,2,2,7,2,1,1,7,2,5,1,5,1,5, | |
2415 7,1,1,2,1,1,1,5,5,5,1,5,5,5,5,5,5,7,1,1,2,1,1,1,1,9,4,3,3,1,1,1,9,7,3,3,1, | |
2416 1,1,9,7,3,3,1,1,9,1,7,3,1,3,1,5,5,2,1,2,2,5,5,5,1,9,1,1,1,1,1,1,1,7,3,1,1, | |
2417 1,2,2,1,2,1,3,1,1,2,1,2,2,1,2,1,1,1,1,1,1,1,1,7,3,2,2,5,1,1,3,5,5,2,2,5,5, | |
2418 5,1,1,1,5,1,1,1,7,1,2,2,1,2,1,1,1,2,1,2,1,1,1,1,1,1,7,1,2,2,2,1,2,2,1,8,1, | |
2419 9,5,7,3,3,3,1,3,1,1,1,7,1,2,2,2,1,2,2,9,5,3,3,1,5,5,2,2,2,5,5,5,1,1,1,7,2, | |
2420 2,1,2,1,1,2,1,2,2,1,2,1,1,1,1,1,1,1,1,1,1,1,1,2,1,9,8,1,9,1,1,5,7,3,1,1,1, | |
2421 1,3,1,1,3,1,3,3,1,1,1,3,7,9,9,9,9,9,1,9,9,9,1,9,9,9,9,1,9,9,9,9,9,9,9,9,9, | |
2422 9,9,1,9,3,9,9,9,9,9,1,9,9,9,7,3,1,1,1,3,1,3,7,3,7,9,9,9,9,9,1,9,9,9,9,1,9, | |
2423 9,9,9,9,9,9,9,9,9,9,9,1,9,9,9,9,9,9,9,9,9,4,3,3,1,1,3,1,1,5,5,5,5,5,5,5,5, | |
2424 1,5,5,5,5,5,5,7,1,1,2,1,1,2,2,2,2,4,2,1,5,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,7, | |
2425 1,1,3,1,1,1,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,7,1,1,2,1,1,1,5,5,5,5,5,5,5,5,1, | |
2426 5,5,5,5,5,5,7,1,1,2,1,1,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,7,2,1,1,1,5,5,5, | |
2427 5,5,5,5,5,1,5,5,5,5,5,5,7,1,1,2,1,1,1,5,5,5,5,5,5,5,5,1,5,5,5,5,5,5,7,1,1, | |
2428 2,1,1,2,2,2,2,4,2,10,10,4,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1, | |
2429 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,7,1,1,1,1,1,1,1,1,5,5,5,5,5,5,5, | |
2430 5,5,5,5,1,5,5,5,5,5,5,5,5,5,5,7,1,1,3,1,1,1,5,5,5,5,5,5,5,5,5,5,5,1,5,5,5, | |
2431 5,5,5,5,5,5,5,5,7,1,1,3,1,1,5,5,5,5,5,1,1,1,7,2,2,2,2,1,2,5,5,2,2,5,5,5,1, | |
2432 1,1,1,1,1,7,1,2,2,1,2,1,1,1,2,1,2,2,2,2,1,4,1,4,8,1,8,1,8,1,1,7,1,1,1,1,1, | |
2433 1,1,1,1,1,4,4,4,4,1,4,4,4,4,4,4,4,4,4,7,2,1,5,5,5,5,5,5,5,1,5,5,5,5,7,1,1, | |
2434 2,1,1,1,1,7,1,1,1,1,1,1,7,1,1,1,1,1,1,7,1,1,1,2,1,5,5,2,2,2,5,5,5,1,1,1,1, | |
2435 1,1,1,1,7,1,1,1,2,2,1,2,1,1,1,2,1,2,2,1,2,1,1,1,1,1,1,1,1,4,1,1,1,4,1,1,2, | |
2436 2,7,1,1,3,2,7,2,1,1,7,2,2,2,7,2,1,1,9,1,7,3,1,3,1,2,1,2,9,7,3,3,1,1,1,8,1, | |
2437 8,1,7,1,1,1,1,1,3,1,5,5,5,5,5,1,1,1,1,7,2,2,2,2,2,1,2,10,10,10,1,5,5,5,5, | |
2438 10,10,5,5,5,1,5,5,5,5,5,5,7,1,1,3,1,1,5,5,2,2,5,5,5,1,1,1,1,1,1,7,1,2,2,1, | |
2439 2,1,1,1,2,1,2,1,1,1,1,1,9,9,9,1,9,9,1,7,1,1,1,1,5,5,2,2,2,5,5,5,1,1,1,5,1, | |
2440 1,1,1,1,7,1,1,1,2,2,1,2,1,1,1,2,1,2,2,1,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2, | |
2441 2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,7,1, | |
2442 1,1,1,1,1,1,1,1,4,1,1,2,1,2,9,7,3,3,1,1,1,7,2,9,9,9,9,9,4 | |
2443 }; | |
2444 | |
2445 | |
2446 static const unsigned short ag_pstt[] = { | |
2447 3,1,3,3,3,3,2,3,3,3,0,2,2,3,0,2,1, | |
2448 301,301,301,301,301,1,299,301,301,301,301,301,301,301,301,301,301,301,301, | |
2449 301,301,301,301,301,301,301,301,301,301,301,301,301,301,301,301,301,301, | |
2450 301,1,302,1, | |
2451 1,2,4,2,2,1, | |
2452 8,8,4,5,5,8,8,8,3,7,8,6,5, | |
2453 9,9,9,9,9,9,9,9,9,9,9,9,9,9,123,123,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9, | |
2454 4,9,125, | |
2455 118,5, | |
2456 10,10,6,10, | |
2457 24,1,24,24,24,24,24,24,24,24,24,24,24,24,4,120,12,12,119,24,24,24,24,24,24, | |
2458 7,119,119,11,12,119,1, | |
2459 96,96,13,19,15,8,14,27,26,25,24,23,22,18,17,49,21,16,20, | |
2460 122,122,122,122,122,122,122,122,122,122,122,122,122,122,122,122,122,122,122, | |
2461 122,122,122,122,122,122,122,122,122,122,122,122,122,122,122,124, | |
2462 117,10, | |
2463 28,28,11,28, | |
2464 115,12, | |
2465 6,6,6,1,6,6,6,6,6,4,29,29,31,6,6,6,6,6,6,6,13,31,31,14,14,31,14,30,14,29,1, | |
2466 96,96,32,14,33,34,33,16, | |
2467 272,272,272,272,272,272,272,272,272,272,272,272,272,272,272,272,35,35,272, | |
2468 272,272,272,272,272,272,272,272,272,272,272,272,272,272,272,272,272,272, | |
2469 15,35,36,36,274, | |
2470 97,97,97,1,3,3,3,3,3,3,3,3,97,97,3,3,3,37,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3, | |
2471 16,37,37,102,37,1, | |
2472 96,96,17,39,49,38,16, | |
2473 40,47,41, | |
2474 3,1,3,3,3,3,3,3,3,3,3,3,3,3,42,42,42,2,3,3,3,19,2,2,42,2,43,1, | |
2475 49,49,49,49,49,1,49,49,49,44,49,49,49,49,4,49,49,49,49,49,49,49,49,49,45,49, | |
2476 275,49,49,49,49,49,49,49,49,20,49,48,50,49,47,46,1, | |
2477 53,51,51,52, | |
2478 54,37,55,38, | |
2479 4,5,5,23,56,6,5, | |
2480 4,5,5,24,57,6,5, | |
2481 4,5,5,25,58,6,5, | |
2482 4,5,5,26,59,6,5, | |
2483 96,96,62,13,19,15,27,14,62,62,61,60,60,60,32,60,22,18,17,49,21,16,20, | |
2484 116,28, | |
2485 63,29, | |
2486 29,29,30,108,29, | |
2487 105,105,105,105,105,1,105,105,105,105,105,105,105,105,105,105,105,105,4,105, | |
2488 29,29,2,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105, | |
2489 105,105,105,31,2,2,106,30,106,29,1, | |
2490 79,79,79,79,32,64, | |
2491 73,73,73,66,67,73,65,73,73,66,73,33,69,66,68, | |
2492 70,34, | |
2493 269,35, | |
2494 273,273,273,273,273,273,273,273,273,273,273,273,273,273,273,273,35,35,273, | |
2495 273,273,273,273,273,273,273,273,273,273,273,273,273,273,273,273,273,273, | |
2496 36,35,271, | |
2497 98,98,98,1,98,98,2,4,2,2,1, | |
2498 53,51, | |
2499 40,48,41, | |
2500 6,6,6,1,6,6,6,6,6,6,4,29,29,31,6,6,6,6,6,6,6,6,6,40,31,31,8,8,31,8,30,8,29, | |
2501 1, | |
2502 96,96,41,50,38,16, | |
2503 71,71,71,71,71,71,71,71,71,71,71,71,71,4,5,5,71,71,23,42,7,71,6,5, | |
2504 72,43,217, | |
2505 74,74,74,74,74,74,74,73,308,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74, | |
2506 74,74,74,74,74,74,74,74,74,44,74,74,310, | |
2507 76,76,76,76,76,76,76,75,76,76,76,76,76,76,76,76,76,76,76,76,76,76,316,76,76, | |
2508 76,76,76,76,76,76,76,76,76,45,76,76,318, | |
2509 281,46, | |
2510 280,47, | |
2511 77,77,48,77, | |
2512 78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78, | |
2513 78,78,78,282,78,78,78,78,78,78,78,78,78,49,78, | |
2514 79,50,268, | |
2515 6,6,6,6,6,1,6,6,6,6,6,6,6,6,6,6,6,4,6,29,29,31,6,6,6,6,6,6,6,6,6,6,6,6,6,6, | |
2516 6,6,6,6,51,31,31,10,10,31,10,30,10,29,1, | |
2517 130,130,96,182,96,130,130,130,91,93,92,88,89,13,82,83,80,52,81,86,85,94,133, | |
2518 132,96,166,16,95,95,165,90,132,172,98,171,97,97,97,97,87,84, | |
2519 1,3,3,3,2,3,3,3,53,2,2,52,2,1, | |
2520 3,3,3,1,3,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,3,3,3,3,3,54,2,2,5,2,1, | |
2521 69,69,69,69,69,69,69,69,69,70,70,70,70,70,69,69,69,69,69,69,69,69,51,55,101, | |
2522 102,62,100,63,99, | |
2523 31,1,31,4,120,12,12,119,31,31,31,31,56,119,119,11,12,119,1, | |
2524 30,1,30,4,120,12,12,119,30,30,30,30,57,119,119,11,12,119,1, | |
2525 29,1,29,4,120,12,12,119,29,29,29,29,58,119,119,11,12,119,1, | |
2526 28,1,28,4,120,12,12,119,28,103,28,28,28,54,59,55,119,104,39,105,105,119,11, | |
2527 12,119,1, | |
2528 4,5,5,36,60,106,6,5, | |
2529 4,5,5,35,61,107,6,5, | |
2530 27,62, | |
2531 1,108,112,108,108,108,1, | |
2532 109,1,109,2,64,2,2,109,2,1, | |
2533 81,81,81,81,65,110, | |
2534 111,13,66,89,77,114,77,113,112,114, | |
2535 3,1,3,2,3,67,2,2,87,2,1, | |
2536 96,96,32,68,33,115,33,16, | |
2537 74,74,74,76,74,74,74,76,74,69, | |
2538 6,1,6,4,29,29,31,70,31,31,53,53,31,53,30,53,29,1, | |
2539 96,117,118,119,120,123,124,125,126,127,128,116,96,129,93,218,71,132,133,16, | |
2540 131,121,134,220,134,134,130,122, | |
2541 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,72,2,2,17,2,1, | |
2542 305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305, | |
2543 305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,73, | |
2544 305, | |
2545 307,307,307,307,307,307,307,73,307,307,307,307,307,307,307,307,307,307,307, | |
2546 307,307,307,307,307,307,307,307,307,307,307,307,307,307,309,307, | |
2547 313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313, | |
2548 313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,75, | |
2549 313, | |
2550 315,315,315,315,315,315,315,75,315,315,315,315,315,315,315,315,315,315,315, | |
2551 315,315,315,315,315,315,315,315,315,315,315,315,315,315,317,315, | |
2552 279,77, | |
2553 283,283,283,283,283,1,283,283,283,44,283,283,283,283,4,283,283,283,283,283, | |
2554 283,283,283,283,283,283,45,283,283,283,283,283,283,138,283,283,283,276, | |
2555 283,137,136,135,283,1, | |
2556 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,79,2,2,18,2,1, | |
2557 6,6,6,6,6,1,6,6,6,6,6,6,6,6,6,4,6,29,29,31,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, | |
2558 6,80,31,31,11,11,31,11,30,11,29,1, | |
2559 290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290, | |
2560 290,290,290,290,290,290,290,290,290,15,290,290,290,81,266,140,20,139, | |
2561 6,6,6,1,6,6,6,6,6,6,4,29,29,31,6,6,6,6,6,6,6,6,82,31,31,13,13,31,13,30,13, | |
2562 29,1, | |
2563 6,6,6,1,6,6,6,6,6,6,6,4,29,29,31,6,6,6,6,6,6,6,6,6,6,6,83,31,31,12,12,31,12, | |
2564 30,12,29,1, | |
2565 203,203,204,204,203,203,203,142,141,196,195,194,193,192,191,190,189,188,187, | |
2566 186,203,204,204,203,203,203,203,203,203,203,203,203,203,203,203,203,203, | |
2567 203,203,203,203,203,203,203,203,84,203,208,185,210,147,146,145,147,203, | |
2568 144,143, | |
2569 69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,85,149,54,148,99, | |
2570 69,69,69,70,69,69,69,69,69,69,70,69,69,70,69,69,69,69,69,69,51,86,101,150, | |
2571 54,151,57,152,148,99, | |
2572 153,255, | |
2573 6,6,6,1,6,6,6,6,6,4,29,29,31,6,6,6,6,6,88,31,31,16,16,31,16,30,16,29,1, | |
2574 6,6,6,1,6,6,6,6,6,4,29,29,31,6,6,6,6,6,89,31,31,15,15,31,15,30,15,29,1, | |
2575 139,139,154,154,155,90,157,156,154, | |
2576 158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158, | |
2577 158,158,158,158,158,158,158,158,158,158,158,158,91, | |
2578 159,159,159,159,159,159,159,142,141,196,195,194,193,192,191,190,189,188,187, | |
2579 186,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159, | |
2580 159,159,159,159,159,159,159,159,92,159,159,159,159,159,144,143, | |
2581 6,6,6,1,6,6,6,6,6,4,29,29,31,6,6,6,6,6,93,31,31,21,21,31,21,30,21,29,1, | |
2582 130,130,96,96,130,130,130,91,93,92,88,89,13,94,94,133,132,96,166,16,95,95, | |
2583 165,90,132,160,97,97,97,97, | |
2584 161,164, | |
2585 130,130,96,96,130,130,130,91,93,92,88,89,13,96,94,133,132,96,166,16,95,95, | |
2586 165,90,132,157,157,157, | |
2587 162,151, | |
2588 164,165,88,89,163,170,263,166,167, | |
2589 130,130,96,182,96,130,130,130,91,93,92,88,89,13,82,83,80,99,81,86,85,94,133, | |
2590 132,96,166,169,16,95,95,165,90,132,169,148,168,169,97,97,97,97,87,84, | |
2591 70,70,70,70,70,51,40,100,170,101,66, | |
2592 290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290,290, | |
2593 290,290,290,290,290,290,290,290,290,15,290,290,290,101,71,171,20,139, | |
2594 103,43,104,64, | |
2595 6,6,6,1,6,6,6,6,6,6,4,29,29,31,6,6,6,6,6,6,6,6,103,31,31,22,22,31,22,30,22, | |
2596 29,1, | |
2597 69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,104,100,65,99, | |
2598 103,42,104,41, | |
2599 34,1,34,4,120,12,12,119,34,34,34,34,106,119,119,11,12,119,1, | |
2600 33,1,33,4,120,12,12,119,33,103,33,33,33,54,107,55,119,104,39,105,105,119,11, | |
2601 12,119,1, | |
2602 1,2,113,2,2,1, | |
2603 96,96,109,80,16, | |
2604 172,1,172,2,110,2,2,172,2,1, | |
2605 3,1,3,3,3,3,2,3,3,3,3,3,3,111,2,2,91,2,1, | |
2606 96,96,92,93,16, | |
2607 111,13,113,89,173,114,173,113,112,114, | |
2608 111,13,83,89,85,113,112,95, | |
2609 175,174,115, | |
2610 1,176,116,176,176,176,1, | |
2611 1,177,117,177,177,177,1, | |
2612 1,178,118,178,178,178,1, | |
2613 1,179,119,179,179,179,241,1, | |
2614 1,180,120,180,180,180,1, | |
2615 4,29,29,181,40,121,182,181,30,181,29,239,181, | |
2616 4,29,29,181,40,122,183,181,30,181,29,238,181, | |
2617 1,179,123,179,179,179,237,1, | |
2618 1,179,124,179,179,179,236,1, | |
2619 1,179,125,179,179,179,235,1, | |
2620 1,179,126,179,179,179,234,1, | |
2621 1,179,127,179,179,179,233,1, | |
2622 1,179,128,179,179,179,232,1, | |
2623 1,4,29,29,185,129,185,185,184,185,184,30,184,29,1, | |
2624 96,96,130,230,16, | |
2625 100,100,100,1,100,100,187,186,131,187,187,186,187,1, | |
2626 96,96,132,224,16, | |
2627 51,223,188, | |
2628 4,5,5,23,134,189,219,6,5, | |
2629 289,135, | |
2630 288,136, | |
2631 190,190,137,190, | |
2632 191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191, | |
2633 191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191, | |
2634 191,138,191, | |
2635 194,194,194,194,194,194,194,194,194,44,194,194,194,194,194,194,194,194,194, | |
2636 194,194,45,194,194,194,194,194,194,194,194,194,139,193,192,194,194, | |
2637 195,140, | |
2638 197,197,141, | |
2639 145,145,146,145,142,196,143, | |
2640 199,199,201, | |
2641 198,198,200, | |
2642 207,207,180, | |
2643 206,206,206,206,179, | |
2644 205,205,205,205,205,142,141,196,195,194,193,192,191,190,189,188,187,186,197, | |
2645 205,205,205,205,205,205,205,205,205,205,205,205,205,205,205,205,205,205, | |
2646 205,205,205,205,205,147,205,209,185,211,205,144,143, | |
2647 70,70,70,70,70,70,70,51,40,148,170,101,61, | |
2648 198,199,103,72,149,259,200,55, | |
2649 201,103,60,200,55, | |
2650 103,59,200,58, | |
2651 202,79,152,257, | |
2652 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,153,2,2,256,2,1, | |
2653 145,145,146,145,154,203,143, | |
2654 141,141,141,141,141,141,141,141,141,141,141,141,141,141,141,141,141,141,141, | |
2655 141,141,141,141,141,141,141,155,204, | |
2656 140,140,140,134, | |
2657 1,3,3,3,3,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,3,3,3,3,157,2,2,129,2,1, | |
2658 1,3,3,3,3,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,3,3,3,3,158,2,2,127,2,1, | |
2659 206,205,159,128, | |
2660 207,88,89,160,166,167,167, | |
2661 208,208,1,208,208,208,208,4,29,29,31,208,208,161,31,31,208,208,31,208,30, | |
2662 208,29,1, | |
2663 209,209,209,1,209,209,209,209,209,4,29,29,31,209,209,209,209,209,162,31,31, | |
2664 209,209,31,209,30,209,29,1, | |
2665 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,163,2,2,9,2,1, | |
2666 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,164,2,2,262,2,1, | |
2667 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,165,2,2,261,2,1, | |
2668 130,130,96,96,130,130,130,91,93,92,88,89,13,166,94,133,132,96,166,16,95,95, | |
2669 165,90,132,210,210,210,210, | |
2670 130,130,96,96,130,130,130,91,93,92,88,89,13,167,94,133,132,96,166,16,95,95, | |
2671 165,90,132,211,211,211,211, | |
2672 164,165,88,89,163,149,263,166,167, | |
2673 212,212,212,212,212,212,212,212,212,212,212,212,212,212,169,67, | |
2674 130,130,96,182,96,130,130,130,91,93,92,88,89,13,82,83,80,170,81,86,85,94, | |
2675 133,132,96,166,213,16,95,95,165,90,132,213,148,168,213,97,97,97,97,87, | |
2676 84, | |
2677 214,171, | |
2678 96,96,172,82,16, | |
2679 207,173,90, | |
2680 3,1,3,2,3,174,2,2,88,2,1, | |
2681 1,3,3,3,2,3,3,3,3,3,3,175,2,2,86,2,1, | |
2682 1,215,2,231,2,2,1, | |
2683 1,216,2,177,2,2,1, | |
2684 1,217,2,178,2,2,1, | |
2685 1,2,83,179,2,218,2,1, | |
2686 130,130,96,1,182,96,130,130,130,91,2,93,92,88,89,13,82,83,180,2,86,85,94, | |
2687 133,132,96,166,16,2,95,95,165,90,132,240,168,240,97,97,97,97,87,84,1, | |
2688 79,181,249, | |
2689 96,96,247,219,16,177, | |
2690 130,130,96,96,130,130,130,91,93,92,247,88,89,13,183,94,133,132,96,166,16,95, | |
2691 95,165,90,132,220,97,97,97,97, | |
2692 83,184,221, | |
2693 99,99,99,1,99,99,4,29,29,2,105,185,2,2,106,30,106,29,1, | |
2694 51,186,222, | |
2695 101,101,101,1,101,101,2,4,2,2,1, | |
2696 130,130,96,182,96,130,130,130,32,88,89,188,133,132,33,225,33,16,228,90,132, | |
2697 226,84, | |
2698 96,1,117,118,119,120,123,124,125,126,127,128,116,96,4,120,12,12,119,129,93, | |
2699 24,189,119,132,133,16,131,119,11,12,119,121,222,222,130,122,1, | |
2700 287,190, | |
2701 283,283,283,283,283,1,283,283,283,44,283,283,283,283,4,283,283,283,283,283, | |
2702 283,283,283,283,283,283,45,283,285,283,283,283,283,283,138,283,283,283, | |
2703 191,283,137,136,135,283,1, | |
2704 298,192, | |
2705 297,193, | |
2706 293,293,293,293,293,1,293,293,293,293,44,293,293,293,293,293,294,293,293, | |
2707 293,293,293,293,45,293,293,293,293,293,293,293,293,293,291,294,294,193, | |
2708 192,293,1, | |
2709 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,195,2,2,267,2,1, | |
2710 145,145,146,145,202,144, | |
2711 1,3,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,197,2,2,178,2,1, | |
2712 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,198,2,2,265,2,1, | |
2713 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,199,2,2,260,2,1, | |
2714 69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,200,56,148,99, | |
2715 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,201,2,2,264,2,1, | |
2716 1,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,202,2,2,258,2,1, | |
2717 145,145,146,145,138,144, | |
2718 142,142,135, | |
2719 223,223,223,223,223,223,223,142,141,196,195,194,193,192,191,190,189,188,187, | |
2720 186,223,223,223,223,223,223,223,223,223,223,223,223,223,223,223,223,223, | |
2721 223,223,223,223,223,223,223,223,205,223,223,223,223,223,144,143, | |
2722 1,3,3,3,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,3,3,3,3,206,2,2,20,2,1, | |
2723 1,3,3,3,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,3,3,3,3,3,207,2,2,19,2,1, | |
2724 130,130,130,130,130,91,88,89,208,133,132,169,169,90,132, | |
2725 130,130,96,96,130,130,130,91,93,92,88,89,13,209,94,133,132,96,166,16,95,95, | |
2726 165,90,132,155,155,155, | |
2727 162,153, | |
2728 162,152, | |
2729 224,1,224,4,29,29,31,212,31,31,224,224,31,224,30,224,29,1, | |
2730 212,212,212,212,212,212,212,212,212,212,212,212,212,212,213,68, | |
2731 1,3,3,3,3,3,3,3,2,3,3,3,3,214,2,2,72,2,1, | |
2732 1,225,215,225,225,225,1, | |
2733 1,226,216,226,226,226,1, | |
2734 1,179,217,179,179,179,242,1, | |
2735 130,130,96,182,96,130,130,130,91,93,92,88,89,13,82,83,218,86,85,94,133,132, | |
2736 96,166,16,95,95,165,90,132,253,168,253,97,97,97,97,87,84,227, | |
2737 51,173,228, | |
2738 88,89,251,166,167, | |
2739 96,96,221,219,16,176, | |
2740 182,222,227,84, | |
2741 206,223,168, | |
2742 214,214,224,213,229, | |
2743 1,2,83,225,2,230,2,1, | |
2744 244,1,244,2,226,2,2,231,1, | |
2745 4,29,29,181,40,227,232,181,30,181,29,252,181, | |
2746 130,130,130,130,130,91,233,88,89,228,133,132,174,174,175,90,132, | |
2747 215,215,215,1,3,3,3,3,215,215,3,3,3,2,3,3,3,3,3,3,229,2,2,216,2,1, | |
2748 130,130,96,96,130,130,130,91,93,92,88,89,13,230,94,133,132,96,166,16,95,95, | |
2749 165,90,132,234,97,97,97,97, | |
2750 245,245,245,1,245,245,235,231,235,235,235,1, | |
2751 130,130,96,182,96,130,130,130,91,93,92,247,88,89,13,82,83,232,86,85,94,133, | |
2752 132,96,166,16,95,95,165,90,132,254,168,254,97,97,97,97,87,84, | |
2753 236,236,236,236,236,236,236,142,141,196,195,194,193,192,191,190,189,188,187, | |
2754 186,236,236,236,236,236,236,236,236,236,236,236,236,236,236,236,236,236, | |
2755 236,236,236,236,236,236,236,236,233,236,236,236,236,236,144,143, | |
2756 88,89,250,166,167, | |
2757 244,1,244,2,235,2,2,237,1, | |
2758 206,236,128, | |
2759 245,245,245,245,245,243, | |
2760 | |
2761 }; | |
2762 | |
2763 | |
2764 static const unsigned short ag_sbt[] = { | |
2765 0, 17, 58, 64, 77, 116, 118, 122, 154, 173, 208, 210, 214, 216, | |
2766 247, 255, 297, 338, 345, 348, 376, 419, 423, 427, 434, 441, 448, 455, | |
2767 478, 480, 482, 487, 537, 543, 558, 560, 562, 602, 613, 615, 618, 652, | |
2768 658, 682, 685, 723, 761, 763, 765, 769, 809, 812, 863, 904, 918, 949, | |
2769 979, 998,1017,1036,1062,1070,1078,1080,1087,1097,1103,1113,1124,1132, | |
2770 1142,1160,1188,1210,1248,1283,1321,1356,1358,1402,1424,1472,1509,1542, | |
2771 1579,1636,1658,1688,1690,1719,1748,1757,1789,1842,1871,1901,1903,1931, | |
2772 1933,1942,1985,1996,2033,2037,2070,2091,2095,2114,2140,2146,2151,2161, | |
2773 2180,2185,2195,2203,2206,2213,2220,2227,2235,2242,2255,2268,2276,2284, | |
2774 2292,2300,2308,2316,2331,2336,2350,2355,2358,2367,2369,2371,2375,2415, | |
2775 2451,2453,2456,2463,2466,2469,2472,2477,2527,2540,2548,2553,2557,2561, | |
2776 2583,2590,2618,2622,2652,2682,2686,2693,2717,2746,2768,2790,2812,2841, | |
2777 2870,2879,2895,2938,2940,2945,2948,2959,2976,2983,2990,2997,3005,3049, | |
2778 3052,3058,3089,3092,3111,3114,3125,3148,3186,3188,3233,3235,3237,3277, | |
2779 3299,3305,3328,3350,3372,3393,3415,3437,3443,3446,3499,3528,3558,3573, | |
2780 3601,3603,3605,3623,3639,3658,3665,3672,3680,3720,3723,3728,3734,3738, | |
2781 3741,3746,3754,3763,3776,3793,3819,3849,3861,3901,3954,3959,3968,3971, | |
2782 3977 | |
2783 }; | |
2784 | |
2785 | |
2786 static const unsigned short ag_sbe[] = { | |
2787 10, 55, 60, 72, 113, 117, 120, 147, 159, 207, 209, 212, 215, 236, | |
2788 250, 292, 332, 340, 346, 369, 411, 421, 424, 430, 437, 444, 451, 461, | |
2789 479, 481, 484, 529, 541, 554, 559, 561, 599, 609, 614, 616, 641, 654, | |
2790 677, 683, 719, 757, 762, 764, 767, 807, 810, 852, 880, 912, 943, 972, | |
2791 991,1010,1029,1050,1066,1074,1079,1082,1091,1101,1105,1118,1127,1141, | |
2792 1149,1176,1204,1246,1281,1319,1354,1357,1395,1418,1461,1504,1531,1568, | |
2793 1624,1653,1679,1689,1708,1737,1753,1788,1834,1860,1884,1902,1916,1932, | |
2794 1938,1959,1992,2028,2034,2059,2087,2092,2107,2128,2142,2148,2155,2174, | |
2795 2182,2187,2197,2205,2208,2215,2222,2229,2237,2247,2260,2270,2278,2286, | |
2796 2294,2302,2310,2321,2333,2344,2352,2356,2362,2368,2370,2373,2413,2446, | |
2797 2452,2455,2460,2465,2468,2471,2476,2519,2536,2544,2550,2554,2559,2577, | |
2798 2587,2616,2621,2646,2676,2684,2689,2706,2735,2762,2784,2806,2825,2854, | |
2799 2875,2893,2912,2939,2942,2946,2953,2970,2979,2986,2993,3000,3023,3050, | |
2800 3054,3072,3090,3103,3112,3121,3136,3170,3187,3226,3234,3236,3270,3293, | |
2801 3303,3322,3344,3366,3389,3409,3431,3441,3445,3491,3522,3552,3566,3586, | |
2802 3602,3604,3612,3637,3652,3660,3667,3674,3696,3721,3725,3730,3735,3739, | |
2803 3743,3749,3758,3768,3785,3813,3832,3856,3878,3946,3956,3963,3969,3976,3977 | |
2804 }; | |
2805 | |
2806 | |
2807 static const unsigned char ag_fl[] = { | |
2808 1,1,2,0,1,2,0,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,1,0,1,5,2,2,2,2,2,2,2, | |
2809 1,1,1,2,3,1,2,3,2,1,1,1,1,2,1,3,1,3,4,1,2,2,1,2,1,1,2,1,1,2,2,2,3,4,0, | |
2810 0,2,4,1,2,0,1,3,1,0,4,0,5,1,1,2,4,2,4,1,3,2,1,2,1,2,1,2,3,3,2,3,2,1,1, | |
2811 1,2,1,2,1,0,1,2,3,1,2,3,3,2,2,2,1,2,0,1,2,1,3,3,3,0,1,1,1,1,2,1,1,2,1, | |
2812 2,0,2,1,2,1,1,1,1,1,1,1,3,3,1,4,1,2,1,1,1,1,1,1,1,1,1,3,5,4,3,3,3,1,3, | |
2813 3,4,3,4,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,1,1,2,1,1,2,2,2,1,2, | |
2814 1,2,0,3,1,2,2,3,0,2,3,1,3,1,2,3,3,4,3,1,2,2,2,2,2,2,2,2,2,2,3,2,4,7,1, | |
2815 2,0,1,1,2,6,3,4,1,3,1,3,3,4,3,4,3,3,2,4,4,2,4,3,2,1,2,0,1,2,0,2,1,1,3, | |
2816 2,2,0,2,1,3,1,3,2,2,0,2,1,2,2,1,1,2,2,2,1,2,2,1,1,2,1,2,0,1,2,1,1,2,1, | |
2817 2,0,1,2,1 | |
2818 }; | |
2819 | |
2820 static const unsigned char ag_ptt[] = { | |
2821 0, 4, 4, 5, 5, 1, 9, 9, 6, 10, 12, 14, 16, 18, 20, 22, 24, 26, | |
2822 28, 30, 32, 34, 36, 40, 40, 43, 43, 38, 41, 41, 41, 41, 41, 49, 49, 42, | |
2823 42, 45, 45, 45, 54, 54, 45, 52, 50, 50, 50, 51, 51, 56, 56, 58, 58, 57, | |
2824 62, 62, 64, 65, 65, 67, 67, 63, 55, 55, 55, 53, 69, 68, 68, 70, 66, 66, | |
2825 66, 61, 61, 77, 77, 61, 75, 80, 75, 81, 75, 78, 78, 78, 76, 84, 84, 87, | |
2826 83, 88, 90, 90, 82, 82, 91, 91, 91, 94, 94, 94, 59, 3, 3, 8, 8, 8, | |
2827 98, 98,102,102,100,100,104,104,104, 39, 39, 39, 39,108,108,109,109, 99, | |
2828 110,110,114,111,118,118,116,116,117,117,124,124,117,119,119,121,121,125, | |
2829 125,129,129, 71, 71,131,131,133,133,133,135,135,136,136,115,115,115,115, | |
2830 115,138,138,138,138,138,144,144, 46, 46, 46,146,146,146,147,147,148,150, | |
2831 150,150,149,155,155,155,140,140,140,140,140,140,140,140,140,140,140,168, | |
2832 170,142,141,141,143,152,152,152,152,152,153,153,154,154, 72, 72,176,176, | |
2833 175, 48,179,179,177,178,178,180,180,180,180,180,180,180,180,182,181,181, | |
2834 181,181,181,181,181,181,181,181,181,181,199,199,200,200,200,192,191,191, | |
2835 185,201,201,134,134,134,134,134,134,134,134,134,134,134,132,132, 47,210, | |
2836 211,211,212,212,208,209,209,213,213,213,213,213,214,214,218,218,218,218, | |
2837 218,218,220, 73,221,221,221,222,222,222,222, 97,225,225, 97,231,231,231, | |
2838 232,232,233,233,217,234,234,234,235,235,236,236,216,230 | |
2839 }; | |
2840 | |
2841 static const unsigned char *ag_valid(int ag_k) { | |
2842 const unsigned char *ag_tp = &ag_tstt[ag_sbt[(PCB).sn+1]]; | |
2843 while (*--ag_tp != (unsigned char) ag_k) if (*ag_tp == 0) return NULL; | |
2844 return ag_tp; | |
2845 } | |
2846 | |
2847 int pgg_change_reduction(pgg_token_type ag_k) { | |
2848 if (!ag_valid(ag_k)) return 0; | |
2849 (PCB).reduction_token = ag_k; | |
2850 return 1; | |
2851 } | |
2852 | |
2853 static void ag_default(const int *ag_tp) { | |
2854 (PCB).ag_dsn = (PCB).sn; | |
2855 (PCB).ag_dtl = ag_tp; | |
2856 while (!ag_valid((pgg_token_type) *ag_tp)) ag_tp++; | |
2857 (PCB).reduction_token = (pgg_token_type) *ag_tp; | |
2858 } | |
2859 | |
2860 | |
2861 | |
2862 static void ag_ra(void) | |
2863 { | |
2864 switch(ag_rpx[(PCB).ag_ap]) { | |
2865 case 1: ag_rp_1(V(0,(int *))); break; | |
2866 case 2: ag_rp_2(); break; | |
2867 case 3: ag_rp_4(V(0,(int *))); break; | |
2868 case 4: V(0,(int *)) = ag_rp_5(V(0,(int *))); break; | |
2869 case 5: V(0,(int *)) = ag_rp_6(V(0,(int *))); break; | |
2870 case 6: V(0,(int *)) = ag_rp_7(); break; | |
2871 case 7: V(0,(int *)) = ag_rp_8(V(0,(int *))); break; | |
2872 case 8: ag_rp_9(V(0,(int *))); break; | |
2873 case 9: ag_rp_10(V(2,(int *))); break; | |
2874 case 10: V(0,(int *)) = ag_rp_11(); break; | |
2875 case 11: V(0,(int *)) = ag_rp_12(); break; | |
2876 case 12: V(0,(int *)) = ag_rp_13(); break; | |
2877 case 13: ag_rp_14(V(0,(int *))); break; | |
2878 case 14: ag_rp_15(V(1,(int *))); break; | |
2879 case 15: ag_rp_16(V(0,(int *))); break; | |
2880 case 16: V(0,(int *)) = ag_rp_17(V(1,(int *))); break; | |
2881 case 17: ag_rp_18(V(0,(int *))); break; | |
2882 case 18: ag_rp_19(V(0,(int *))); break; | |
2883 case 19: ag_rp_20(V(1,(int *))); break; | |
2884 case 20: V(0,(int *)) = ag_rp_21(V(1,(int *))); break; | |
2885 case 21: ag_rp_22(V(1,(int *)), V(2,(int *))); break; | |
2886 case 22: ag_rp_23(V(2,(int *)), V(3,(int *))); break; | |
2887 case 23: ag_rp_24(); break; | |
2888 case 24: V(0,(int *)) = ag_rp_25(); break; | |
2889 case 25: V(0,(int *)) = ag_rp_26(); break; | |
2890 case 26: V(0,(int *)) = ag_rp_27(); break; | |
2891 case 27: ag_rp_28(); break; | |
2892 case 28: ag_rp_29(); break; | |
2893 case 29: ag_rp_30(); break; | |
2894 case 30: ag_rp_31(); break; | |
2895 case 31: ag_rp_32(); break; | |
2896 case 32: ag_rp_33(); break; | |
2897 case 33: ag_rp_34(); break; | |
2898 case 34: ag_rp_35(); break; | |
2899 case 35: ag_rp_36(); break; | |
2900 case 36: ag_rp_37(); break; | |
2901 case 37: ag_rp_38(); break; | |
2902 case 38: ag_rp_39(); break; | |
2903 case 39: ag_rp_40(); break; | |
2904 case 40: ag_rp_41(); break; | |
2905 case 41: ag_rp_42(V(0,(int *))); break; | |
2906 case 42: ag_rp_43(V(1,(int *))); break; | |
2907 case 43: ag_rp_44(V(2,(int *))); break; | |
2908 case 44: ag_rp_45(V(2,(int *))); break; | |
2909 case 45: ag_rp_46(V(1,(int *))); break; | |
2910 case 46: ag_rp_47(V(2,(int *))); break; | |
2911 case 47: V(0,(int *)) = ag_rp_48(V(1,(int *))); break; | |
2912 case 48: V(0,(int *)) = ag_rp_49(V(1,(int *))); break; | |
2913 case 49: V(0,(int *)) = ag_rp_50(V(0,(int *)), V(1,(int *))); break; | |
2914 case 50: V(0,(int *)) = ag_rp_51(); break; | |
2915 case 51: V(0,(int *)) = ag_rp_52(); break; | |
2916 case 52: V(0,(int *)) = ag_rp_53(V(1,(int *))); break; | |
2917 case 53: V(0,(int *)) = ag_rp_54(V(1,(int *))); break; | |
2918 case 54: V(0,(int *)) = ag_rp_55(V(0,(int *))); break; | |
2919 case 55: V(0,(int *)) = ag_rp_56(V(0,(int *)), V(1,(int *))); break; | |
2920 case 56: V(0,(int *)) = ag_rp_57(); break; | |
2921 case 57: V(0,(int *)) = ag_rp_58(V(0,(int *)), V(1,(int *))); break; | |
2922 case 58: V(0,(int *)) = ag_rp_59(V(0,(int *))); break; | |
2923 case 59: V(0,(int *)) = ag_rp_60(V(0,(int *)), V(1,(int *))); break; | |
2924 case 60: V(0,(int *)) = ag_rp_61(V(0,(int *))); break; | |
2925 case 61: V(0,(int *)) = ag_rp_62(V(0,(int *))); break; | |
2926 case 62: V(0,(int *)) = ag_rp_63(V(0,(int *))); break; | |
2927 case 63: V(0,(int *)) = VDO(AG_WRAP_4 *, ag_rp_64(VW(0, AG_WRAP_4 *))); break; | |
2928 case 64: VRO(AG_WRAP_4 *, ag_rp_65(VW(0, AG_WRAP_4 *), VW(2, AG_WRAP_4 *))); | |
2929 VWD(2, AG_WRAP_4 *); break; | |
2930 case 65: VRO(AG_WRAP_4 *, ag_rp_66(VW(0, AG_WRAP_4 *), VW(2, AG_WRAP_4 *))); | |
2931 VWD(2, AG_WRAP_4 *); break; | |
2932 case 66: VRO(AG_WRAP_4 *, ag_rp_67(VW(0, AG_WRAP_4 *), VW(3, AG_WRAP_4 *))); | |
2933 VWD(3, AG_WRAP_4 *); break; | |
2934 case 67: VNO AG_WRAP_4(ag_rp_68(VW(1, AG_WRAP_4 *))); | |
2935 VWD(1, AG_WRAP_4 *); break; | |
2936 case 68: VNO AG_WRAP_4(ag_rp_69(V(0,(int *)))); break; | |
2937 case 69: VNO AG_WRAP_4(ag_rp_70(V(0,(int *)))); break; | |
2938 case 70: VNO AG_WRAP_4(ag_rp_71()); break; | |
2939 case 71: VNO AG_WRAP_4(ag_rp_72(VW(1, AG_WRAP_4 *))); | |
2940 VWD(1, AG_WRAP_4 *); break; | |
2941 case 72: VNO AG_WRAP_4(ag_rp_73(V(1,(int *)), V(3,(int *)))); break; | |
2942 case 73: VNO AG_WRAP_4(ag_rp_74(V(0,(int *)), V(3,(int *)))); break; | |
2943 case 74: ag_rp_75(VW(2, AG_WRAP_4 *)); | |
2944 VWD(2, AG_WRAP_4 *); break; | |
2945 case 75: ag_rp_76(V(2,(int *))); break; | |
2946 case 76: ag_rp_77(V(2,(int *))); break; | |
2947 case 77: ag_rp_78(); break; | |
2948 case 78: ag_rp_79(V(2,(int *))); break; | |
2949 case 79: ag_rp_80(V(2,(int *))); break; | |
2950 case 80: ag_rp_81(); break; | |
2951 case 81: V(0,(int *)) = ag_rp_82(V(0,(int *))); break; | |
2952 case 82: V(0,(int *)) = ag_rp_83(); break; | |
2953 case 83: V(0,(int *)) = ag_rp_84(); break; | |
2954 case 84: V(0,(int *)) = ag_rp_85(); break; | |
2955 case 85: V(0,(int *)) = ag_rp_86(); break; | |
2956 case 86: V(0,(int *)) = ag_rp_87(); break; | |
2957 case 87: V(0,(int *)) = ag_rp_88(); break; | |
2958 case 88: V(0,(int *)) = ag_rp_89(); break; | |
2959 case 89: V(0,(int *)) = ag_rp_90(); break; | |
2960 case 90: V(0,(int *)) = ag_rp_91(); break; | |
2961 case 91: V(0,(int *)) = ag_rp_92(); break; | |
2962 case 92: V(0,(int *)) = ag_rp_93(); break; | |
2963 case 93: V(0,(int *)) = ag_rp_94(V(1,(int *))); break; | |
2964 case 94: V(0,(int *)) = ag_rp_95(V(0,(int *)), V(1,(int *))); break; | |
2965 case 95: V(0,(int *)) = ag_rp_96(V(0,(int *)), V(1,(int *))); break; | |
2966 case 96: V(0,(int *)) = ag_rp_97(V(1,(int *))); break; | |
2967 case 97: ag_rp_98(V(0,(int *))); break; | |
2968 case 98: ag_rp_99(V(0,(int *))); break; | |
2969 case 99: ag_rp_100(V(1,(int *))); break; | |
2970 case 100: ag_rp_101(V(1,(int *))); break; | |
2971 case 101: ag_rp_102(V(1,(int *))); break; | |
2972 case 102: ag_rp_103(V(0,(int *))); break; | |
2973 case 103: ag_rp_104(V(1,(int *))); break; | |
2974 case 104: ag_rp_105(V(0,(int *))); break; | |
2975 case 105: ag_rp_106(V(1,(int *))); break; | |
2976 case 106: V(0,(int *)) = ag_rp_107(); break; | |
2977 case 107: V(0,(int *)) = ag_rp_108(); break; | |
2978 case 108: ag_rp_109(V(0,(int *))); break; | |
2979 case 109: ag_rp_110(V(1,(int *))); break; | |
2980 case 110: ag_rp_111(); break; | |
2981 case 111: ag_rp_112(); break; | |
2982 case 112: ag_rp_113(); break; | |
2983 case 113: ag_rp_114(); break; | |
2984 case 114: ag_rp_115(); break; | |
2985 case 115: ag_rp_116(V(2,(int *))); break; | |
2986 case 116: ag_rp_117(); break; | |
2987 case 117: ag_rp_118(); break; | |
2988 case 118: ag_rp_119(); break; | |
2989 case 119: ag_rp_120(); break; | |
2990 case 120: ag_rp_121(); break; | |
2991 case 121: ag_rp_122(); break; | |
2992 case 122: ag_rp_123(); break; | |
2993 case 123: ag_rp_124(); break; | |
2994 case 124: ag_rp_125(V(2,(int *))); break; | |
2995 case 125: ag_rp_126(); break; | |
2996 case 126: ag_rp_127(); break; | |
2997 case 127: ag_rp_128(V(4,(int *)), V(6,(int *))); break; | |
2998 case 128: V(0,(int *)) = ag_rp_129(); break; | |
2999 case 129: ag_rp_130(VW(5, AG_WRAP_4 *)); | |
3000 VWD(5, AG_WRAP_4 *); break; | |
3001 case 130: ag_rp_131(VW(2, AG_WRAP_4 *)); | |
3002 VWD(2, AG_WRAP_4 *); break; | |
3003 case 131: ag_rp_132(V(0,(int *))); break; | |
3004 case 132: ag_rp_133(V(2,(int *))); break; | |
3005 case 133: V(0,(int *)) = ag_rp_134(); break; | |
3006 case 134: V(0,(int *)) = ag_rp_135(); break; | |
3007 case 135: V(0,(int *)) = ag_rp_136(); break; | |
3008 case 136: V(0,(int *)) = ag_rp_137(); break; | |
3009 case 137: V(0,(int *)) = ag_rp_138(); break; | |
3010 case 138: V(0,(int *)) = ag_rp_139(); break; | |
3011 case 139: V(0,(int *)) = VDO(AG_WRAP_4 *, ag_rp_140(VW(0, AG_WRAP_4 *))); break; | |
3012 case 140: V(0,(int *)) = VDO(AG_WRAP_4 *, ag_rp_141(VW(0, AG_WRAP_4 *))); break; | |
3013 case 141: V(0,(int *)) = VDO(AG_WRAP_4 *, ag_rp_142(VW(0, AG_WRAP_4 *))); break; | |
3014 case 142: V(0,(int *)) = ag_rp_143(); break; | |
3015 case 143: V(0,(int *)) = ag_rp_144(); break; | |
3016 case 144: V(0,(int *)) = ag_rp_145(); break; | |
3017 case 145: V(0,(int *)) = ag_rp_146(); break; | |
3018 case 146: ag_rp_147(V(1,(unsigned char * *))); break; | |
3019 case 147: ag_rp_148(); break; | |
3020 case 148: V(0,(unsigned char * *)) = ag_rp_149(); break; | |
3021 case 149: V(0,(unsigned char * *)) = ag_rp_150(); break; | |
3022 case 150: ag_rp_151(); break; | |
3023 case 151: ag_rp_152(); break; | |
3024 case 152: ag_default(&ag_rtt[0]); ag_rp_153(); break; | |
3025 } | |
3026 (PCB).la_ptr = (PCB).pointer; | |
3027 } | |
3028 | |
3029 | |
3030 static const unsigned char ag_ctn[] = { | |
3031 0,0, 97,1, 0,0, 0,0, 99,1, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, | |
3032 0,0, 0,0, 57,1,208,1, 59,1, 51,1, 56,1, 48,1, 47,1, 0,0, 45,1, 41,1, | |
3033 41,1, 41,1, 41,1, 41,1, 0,0, 0,0, 98,1, 0,0, 75,1, 0,0, 57,2, 0,0, | |
3034 0,0, 0,0, 0,0, 56,1, 0,0, 56,2,177,1, 48,2,217,1,216,1,213,1,213,1, | |
3035 213,1, 0,0, 47,2, 0,0, 46,2, 0,0, 52,1, 52,1, 0,0, 0,0, 0,0, 0,0, | |
3036 0,0, 0,0, 0,0, 0,0, 75,2, 75,2, 0,0, 84,1, 0,0, 0,0, 57,3,177,2, | |
3037 0,0, 0,0, 0,0, 0,0, 0,0,213,2, 0,0, 0,0,132,1,132,1,134,1, 0,0, | |
3038 148,1,134,1,134,1,134,1, 0,0, 0,0,111,1,110,1, 0,0, 0,0, 0,0,144,1, | |
3039 0,0, 0,0,134,1, 68,1, 0,0, 66,1, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, | |
3040 0,0, 75,3, 75,3, 0,0, 0,0, 0,0, 0,0, 0,0,180,1,181,1,181,1,181,1, | |
3041 181,1,181,1,181,1,181,1,181,1,181,1,181,1,181,1,181,1,180,1,180,1,180,1, | |
3042 180,1,180,1, 0,0, 0,0, 0,0, 0,0, 0,0, 73,1,132,2,141,1,143,1, 0,0, | |
3043 141,1,150,1,150,1,150,1, 63,1, 0,0, 67,1, 67,1,134,2,134,2, 0,0, 0,0, | |
3044 119,1,111,2,110,2, 0,0, 0,0,144,2, 0,0, 0,0,134,2,134,2, 0,0, 0,0, | |
3045 134,1, 68,2, 68,2, 66,2, 75,4, 0,0, 84,3, 0,0, 0,0, 0,0, 0,0,185,1, | |
3046 0,0, 0,0,147,2,181,2,147,2, 0,0,180,2, 0,0,180,2, 0,0, 0,0, 0,0, | |
3047 0,0, 0,0, 0,0,132,3,125,1,148,3,134,3,134,3, 0,0,134,3,134,3,125,1, | |
3048 121,1,144,3, 0,0, 0,0,144,3, 0,0, 0,0, 0,0, 72,1, 68,3, 66,3,181,3, | |
3049 181,3,181,3,185,2,146,1, 0,0,147,3,180,3,144,4, 72,2, 0,0, 0,0,201,1, | |
3050 146,2, 0,0,181,5,199,1,201,2,114,1, 0,0, 0,0,114,2,199,1 | |
3051 }; | |
3052 | |
3053 #ifndef MISSING_FORMAT | |
3054 #define MISSING_FORMAT "Missing %s" | |
3055 #endif | |
3056 #ifndef UNEXPECTED_FORMAT | |
3057 #define UNEXPECTED_FORMAT "Unexpected %s" | |
3058 #endif | |
3059 #ifndef UNNAMED_TOKEN | |
3060 #define UNNAMED_TOKEN "input" | |
3061 #endif | |
3062 | |
3063 | |
3064 static void ag_diagnose(void) { | |
3065 int ag_snd = (PCB).sn; | |
3066 int ag_k = ag_sbt[ag_snd]; | |
3067 | |
3068 if (*TOKEN_NAMES[ag_tstt[ag_k]] && ag_astt[ag_k + 1] == ag_action_8) { | |
3069 sprintf((PCB).ag_msg, MISSING_FORMAT, TOKEN_NAMES[ag_tstt[ag_k]]); | |
3070 } | |
3071 else if (ag_astt[ag_sbe[(PCB).sn]] == ag_action_8 | |
3072 && (ag_k = (int) ag_sbe[(PCB).sn] + 1) == (int) ag_sbt[(PCB).sn+1] - 1 | |
3073 && *TOKEN_NAMES[ag_tstt[ag_k]]) { | |
3074 sprintf((PCB).ag_msg, MISSING_FORMAT, TOKEN_NAMES[ag_tstt[ag_k]]); | |
3075 } | |
3076 else if ((PCB).token_number && *TOKEN_NAMES[(PCB).token_number]) { | |
3077 sprintf((PCB).ag_msg, UNEXPECTED_FORMAT, TOKEN_NAMES[(PCB).token_number]); | |
3078 } | |
3079 else if (isprint(INPUT_CODE((*(PCB).pointer))) && INPUT_CODE((*(PCB).pointer)) != '\\') { | |
3080 char buf[20]; | |
3081 sprintf(buf, "\'%c\'", (char) INPUT_CODE((*(PCB).pointer))); | |
3082 sprintf((PCB).ag_msg, UNEXPECTED_FORMAT, buf); | |
3083 } | |
3084 else sprintf((PCB).ag_msg, UNEXPECTED_FORMAT, UNNAMED_TOKEN); | |
3085 (PCB).error_message = (PCB).ag_msg; | |
3086 | |
3087 | |
3088 { | |
3089 int ag_sx, ag_t; | |
3090 | |
3091 ag_sx = (PCB).ssx; | |
3092 (PCB).ss[ag_sx] = (PCB).sn; | |
3093 do { | |
3094 while (ag_sx && ag_ctn[2*(ag_snd = (PCB).ss[ag_sx])] == 0) ag_sx--; | |
3095 if (ag_sx) { | |
3096 ag_t = ag_ctn[2*ag_snd]; | |
3097 ag_sx -= ag_ctn[2*ag_snd +1]; | |
3098 ag_snd = (PCB).ss[ag_sx]; | |
3099 } | |
3100 else { | |
3101 ag_snd = 0; | |
3102 ag_t = ag_ptt[0]; | |
3103 } | |
3104 } while (ag_sx && *TOKEN_NAMES[ag_t]==0); | |
3105 if (*TOKEN_NAMES[ag_t] == 0) ag_t = 0; | |
3106 (PCB).error_frame_ssx = ag_sx; | |
3107 (PCB).error_frame_token = (pgg_token_type) ag_t; | |
3108 } | |
3109 | |
3110 | |
3111 } | |
3112 static int ag_action_1_r_proc(void); | |
3113 static int ag_action_2_r_proc(void); | |
3114 static int ag_action_3_r_proc(void); | |
3115 static int ag_action_4_r_proc(void); | |
3116 static int ag_action_1_s_proc(void); | |
3117 static int ag_action_3_s_proc(void); | |
3118 static int ag_action_1_proc(void); | |
3119 static int ag_action_2_proc(void); | |
3120 static int ag_action_3_proc(void); | |
3121 static int ag_action_4_proc(void); | |
3122 static int ag_action_5_proc(void); | |
3123 static int ag_action_6_proc(void); | |
3124 static int ag_action_7_proc(void); | |
3125 static int ag_action_8_proc(void); | |
3126 static int ag_action_9_proc(void); | |
3127 static int ag_action_10_proc(void); | |
3128 static int ag_action_11_proc(void); | |
3129 static int ag_action_8_proc(void); | |
3130 | |
3131 | |
3132 static int (*const ag_r_procs_scan[])(void) = { | |
3133 ag_action_1_r_proc, | |
3134 ag_action_2_r_proc, | |
3135 ag_action_3_r_proc, | |
3136 ag_action_4_r_proc | |
3137 }; | |
3138 | |
3139 static int (*const ag_s_procs_scan[])(void) = { | |
3140 ag_action_1_s_proc, | |
3141 ag_action_2_r_proc, | |
3142 ag_action_3_s_proc, | |
3143 ag_action_4_r_proc | |
3144 }; | |
3145 | |
3146 static int (*const ag_gt_procs_scan[])(void) = { | |
3147 ag_action_1_proc, | |
3148 ag_action_2_proc, | |
3149 ag_action_3_proc, | |
3150 ag_action_4_proc, | |
3151 ag_action_5_proc, | |
3152 ag_action_6_proc, | |
3153 ag_action_7_proc, | |
3154 ag_action_8_proc, | |
3155 ag_action_9_proc, | |
3156 ag_action_10_proc, | |
3157 ag_action_11_proc, | |
3158 ag_action_8_proc | |
3159 }; | |
3160 | |
3161 | |
3162 static int ag_rns(int ag_t, int *ag_sx, int ag_snd) { | |
3163 while (1) { | |
3164 int ag_act, ag_k = ag_sbt[ag_snd], ag_lim = ag_sbt[ag_snd+1]; | |
3165 int ag_p; | |
3166 | |
3167 while (ag_k < ag_lim && ag_tstt[ag_k] != ag_t) ag_k++; | |
3168 if (ag_k == ag_lim) break; | |
3169 ag_act = ag_astt[ag_k]; | |
3170 ag_p = ag_pstt[ag_k]; | |
3171 if (ag_act == ag_action_2) return ag_p; | |
3172 if (ag_act == ag_action_10 || ag_act == ag_action_11) { | |
3173 (*ag_sx)--; | |
3174 return ag_snd; | |
3175 } | |
3176 if (ag_act != ag_action_3 && | |
3177 ag_act != ag_action_4) break; | |
3178 *ag_sx -= (ag_fl[ag_p] - 1); | |
3179 ag_snd = (PCB).ss[*ag_sx]; | |
3180 ag_t = ag_ptt[ag_p]; | |
3181 } | |
3182 return 0; | |
3183 } | |
3184 | |
3185 static int ag_jns(int ag_t) { | |
3186 int ag_k; | |
3187 | |
3188 ag_k = ag_sbt[(PCB).sn]; | |
3189 while (ag_tstt[ag_k] != ag_t && ag_tstt[ag_k]) ag_k++; | |
3190 while (1) { | |
3191 int ag_p = ag_pstt[ag_k]; | |
3192 int ag_sd; | |
3193 | |
3194 switch (ag_astt[ag_k]) { | |
3195 case ag_action_2: | |
3196 GET_CONTEXT; | |
3197 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3198 return ag_p; | |
3199 case ag_action_10: | |
3200 case ag_action_11: | |
3201 return (PCB).ss[(PCB).ssx--]; | |
3202 case ag_action_9: | |
3203 GET_CONTEXT; | |
3204 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3205 (PCB).ssx++; | |
3206 (PCB).sn = ag_p; | |
3207 ag_k = ag_sbt[(PCB).sn]; | |
3208 while (ag_tstt[ag_k] != ag_t && ag_tstt[ag_k]) ag_k++; | |
3209 continue; | |
3210 case ag_action_3: | |
3211 case ag_action_4: | |
3212 ag_sd = ag_fl[ag_p] - 1; | |
3213 if (ag_sd) (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3214 else GET_CONTEXT; | |
3215 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3216 ag_t = ag_ptt[ag_p]; | |
3217 ag_k = ag_sbt[(PCB).sn+1]; | |
3218 while (ag_tstt[--ag_k] != ag_t); | |
3219 continue; | |
3220 case ag_action_5: | |
3221 case ag_action_6: | |
3222 if (ag_fl[ag_p]) break; | |
3223 (PCB).sn = ag_rns(ag_ptt[ag_p],&(PCB).ssx, (PCB).sn); | |
3224 (PCB).ss[++(PCB).ssx] = (PCB).sn; | |
3225 ag_k = ag_sbt[(PCB).sn]; | |
3226 while (ag_tstt[ag_k] != ag_t && ag_tstt[ag_k]) ag_k++; | |
3227 continue; | |
3228 } | |
3229 break; | |
3230 } | |
3231 return 0; | |
3232 } | |
3233 | |
3234 | |
3235 static int ag_atx(int ag_t, int *ag_sx, int ag_snd) { | |
3236 int ag_k, ag_f; | |
3237 int ag_save_btsx = (PCB).btsx; | |
3238 int ag_flag = 1; | |
3239 | |
3240 while (1) { | |
3241 int ag_a; | |
3242 | |
3243 (PCB).bts[128 - ++(PCB).btsx] = *ag_sx; | |
3244 (PCB).ss[128 - (PCB).btsx] = (PCB).ss[*ag_sx]; | |
3245 (PCB).ss[*ag_sx] = ag_snd; | |
3246 ag_k = ag_sbt[ag_snd]; | |
3247 while (ag_tstt[ag_k] != ag_t && ag_tstt[ag_k]) ag_k++; | |
3248 ag_a = ag_astt[ag_k]; | |
3249 if (ag_a == ag_action_2 || | |
3250 ag_a == ag_action_3 || | |
3251 ag_a == ag_action_10 || | |
3252 ag_a == ag_action_11 || | |
3253 ag_a == ag_action_1 || | |
3254 ag_a == ag_action_4) break; | |
3255 if ((ag_a == ag_action_5 || | |
3256 ag_a == ag_action_6) && | |
3257 (ag_k = ag_fl[ag_f = ag_pstt[ag_k]]) == 0) { | |
3258 ag_snd = ag_rns(ag_ptt[ag_f],ag_sx, (PCB).ss[*ag_sx]); | |
3259 (*ag_sx)++; | |
3260 continue; | |
3261 } | |
3262 if (ag_a == ag_action_9) { | |
3263 ag_snd = ag_pstt[ag_k]; | |
3264 (*ag_sx)++; | |
3265 continue; | |
3266 } | |
3267 ag_flag = 0; | |
3268 break; | |
3269 } | |
3270 while ((PCB).btsx > ag_save_btsx) { | |
3271 *ag_sx = (PCB).bts[128 - (PCB).btsx]; | |
3272 (PCB).ss[*ag_sx] = (PCB).ss[128 - (PCB).btsx--]; | |
3273 } | |
3274 return ag_flag; | |
3275 } | |
3276 | |
3277 | |
3278 static int ag_tst_tkn(void) { | |
3279 int ag_rk, ag_sx, ag_snd = (PCB).sn; | |
3280 | |
3281 (PCB).token_number = (pgg_token_type) AG_TCV(INPUT_CODE(*(PCB).la_ptr)); | |
3282 (PCB).la_ptr++; | |
3283 if (ag_key_index[(PCB).sn]) { | |
3284 unsigned ag_k = ag_key_index[(PCB).sn]; | |
3285 int ag_ch = CONVERT_CASE(INPUT_CODE(*(PCB).pointer)); | |
3286 if (ag_ch <= 255) { | |
3287 while (ag_key_ch[ag_k] < ag_ch) ag_k++; | |
3288 if (ag_key_ch[ag_k] == ag_ch) ag_get_key_word(ag_k); | |
3289 } | |
3290 } | |
3291 for (ag_rk = 0; ag_rk < (PCB).ag_lrss; ag_rk += 2) { | |
3292 ag_sx = (PCB).ag_rss[ag_rk]; | |
3293 if (ag_sx > (PCB).ssx || ag_sx > (PCB).ag_min_depth) continue; | |
3294 (PCB).sn = (PCB).ag_rss[ag_rk + 1]; | |
3295 if (ag_atx((PCB).token_number, &ag_sx, (PCB).sn)) break; | |
3296 } | |
3297 (PCB).sn = ag_snd; | |
3298 return ag_rk; | |
3299 } | |
3300 | |
3301 static void ag_set_error_procs(void); | |
3302 | |
3303 static void ag_auto_resynch(void) { | |
3304 int ag_sx, ag_rk; | |
3305 int ag_rk1, ag_rk2, ag_tk1; | |
3306 DELETE_WRAPPERS; | |
3307 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3308 if ((PCB).ag_error_depth && (PCB).ag_min_depth >= (PCB).ag_error_depth) { | |
3309 (PCB).ssx = (PCB).ag_error_depth; | |
3310 (PCB).sn = (PCB).ss[(PCB).ssx]; | |
3311 } | |
3312 else { | |
3313 ag_diagnose(); | |
3314 SYNTAX_ERROR; | |
3315 if ((PCB).exit_flag != AG_RUNNING_CODE) return; | |
3316 (PCB).ag_error_depth = (PCB).ag_min_depth = 0; | |
3317 (PCB).ag_lrss = 0; | |
3318 (PCB).ss[ag_sx = (PCB).ssx] = (PCB).sn; | |
3319 (PCB).ag_min_depth = (PCB).ag_rss[(PCB).ag_lrss++] = ag_sx; | |
3320 (PCB).ag_rss[(PCB).ag_lrss++] = (PCB).sn; | |
3321 while (ag_sx && (PCB).ag_lrss < 2*128) { | |
3322 int ag_t = 0, ag_x, ag_s, ag_sxs = ag_sx; | |
3323 | |
3324 while (ag_sx && (ag_t = ag_ctn[2*(PCB).sn]) == 0) (PCB).sn = (PCB).ss[--ag_sx]; | |
3325 if (ag_t) (PCB).sn = (PCB).ss[ag_sx -= ag_ctn[2*(PCB).sn +1]]; | |
3326 else { | |
3327 if (ag_sx == 0) (PCB).sn = 0; | |
3328 ag_t = ag_ptt[0]; | |
3329 } | |
3330 if ((ag_s = ag_rns(ag_t, &ag_sx, (PCB).sn)) == 0) break; | |
3331 for (ag_x = 0; ag_x < (PCB).ag_lrss; ag_x += 2) | |
3332 if ((PCB).ag_rss[ag_x] == ag_sx + 1 && (PCB).ag_rss[ag_x+1] == ag_s) break; | |
3333 if (ag_x == (PCB).ag_lrss) { | |
3334 (PCB).ag_rss[(PCB).ag_lrss++] = ++ag_sx; | |
3335 (PCB).ag_rss[(PCB).ag_lrss++] = (PCB).sn = ag_s; | |
3336 } | |
3337 else if (ag_sx >= ag_sxs) ag_sx--; | |
3338 } | |
3339 ag_set_error_procs(); | |
3340 } | |
3341 (PCB).la_ptr = (PCB).pointer; | |
3342 if ((PCB).ssx > (PCB).ag_min_depth) (PCB).ag_min_depth = (PCB).ssx; | |
3343 while (1) { | |
3344 ag_rk1 = ag_tst_tkn(); | |
3345 if ((PCB).token_number == 44) | |
3346 {(PCB).exit_flag = AG_SYNTAX_ERROR_CODE; return;} | |
3347 if (ag_rk1 < (PCB).ag_lrss) break; | |
3348 {(PCB).la_ptr = (PCB).pointer + 1; ag_track();} | |
3349 } | |
3350 ag_tk1 = (PCB).token_number; | |
3351 ag_track(); | |
3352 ag_rk2 = ag_tst_tkn(); | |
3353 if (ag_rk2 < ag_rk1) {ag_rk = ag_rk2; ag_track();} | |
3354 else {ag_rk = ag_rk1; (PCB).token_number = (pgg_token_type) ag_tk1; (PCB).la_ptr = (PCB).pointer;} | |
3355 (PCB).ag_min_depth = (PCB).ssx = (PCB).ag_rss[ag_rk++]; | |
3356 (PCB).sn = (PCB).ss[(PCB).ssx] = (PCB).ag_rss[ag_rk]; | |
3357 (PCB).sn = ag_jns((PCB).token_number); | |
3358 if ((PCB).ag_error_depth == 0 || (PCB).ag_error_depth > (PCB).ssx) | |
3359 (PCB).ag_error_depth = (PCB).ssx; | |
3360 if (++(PCB).ssx >= 128) { | |
3361 (PCB).exit_flag = AG_STACK_ERROR_CODE; | |
3362 PARSER_STACK_OVERFLOW; | |
3363 return; | |
3364 } | |
3365 GET_CONTEXT; | |
3366 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3367 (PCB).ag_tmp_depth = (PCB).ag_min_depth; | |
3368 (PCB).la_ptr = (PCB).pointer; | |
3369 return; | |
3370 } | |
3371 | |
3372 | |
3373 static int ag_action_10_proc(void) { | |
3374 int ag_t = (PCB).token_number; | |
3375 (PCB).btsx = 0, (PCB).drt = -1; | |
3376 do { | |
3377 ag_track(); | |
3378 (PCB).token_number = (pgg_token_type) AG_TCV(INPUT_CODE(*(PCB).la_ptr)); | |
3379 (PCB).la_ptr++; | |
3380 if (ag_key_index[(PCB).sn]) { | |
3381 unsigned ag_k = ag_key_index[(PCB).sn]; | |
3382 int ag_ch = CONVERT_CASE(INPUT_CODE(*(PCB).pointer)); | |
3383 if (ag_ch <= 255) { | |
3384 while (ag_key_ch[ag_k] < ag_ch) ag_k++; | |
3385 if (ag_key_ch[ag_k] == ag_ch) ag_get_key_word(ag_k); | |
3386 } | |
3387 } | |
3388 } while ((PCB).token_number == (pgg_token_type) ag_t); | |
3389 (PCB).la_ptr = (PCB).pointer; | |
3390 return 1; | |
3391 } | |
3392 | |
3393 static int ag_action_11_proc(void) { | |
3394 int ag_t = (PCB).token_number; | |
3395 | |
3396 (PCB).btsx = 0, (PCB).drt = -1; | |
3397 do { | |
3398 (*(int *) &(PCB).vs[(PCB).ssx]) = *(PCB).pointer; | |
3399 (PCB).ssx--; | |
3400 ag_track(); | |
3401 ag_ra(); | |
3402 if ((PCB).exit_flag != AG_RUNNING_CODE) return 0; | |
3403 (PCB).ssx++; | |
3404 (PCB).token_number = (pgg_token_type) AG_TCV(INPUT_CODE(*(PCB).la_ptr)); | |
3405 (PCB).la_ptr++; | |
3406 if (ag_key_index[(PCB).sn]) { | |
3407 unsigned ag_k = ag_key_index[(PCB).sn]; | |
3408 int ag_ch = CONVERT_CASE(INPUT_CODE(*(PCB).pointer)); | |
3409 if (ag_ch <= 255) { | |
3410 while (ag_key_ch[ag_k] < ag_ch) ag_k++; | |
3411 if (ag_key_ch[ag_k] == ag_ch) ag_get_key_word(ag_k); | |
3412 } | |
3413 } | |
3414 } | |
3415 while ((PCB).token_number == (pgg_token_type) ag_t); | |
3416 (PCB).la_ptr = (PCB).pointer; | |
3417 return 1; | |
3418 } | |
3419 | |
3420 static int ag_action_3_r_proc(void) { | |
3421 int ag_sd = ag_fl[(PCB).ag_ap] - 1; | |
3422 if (ag_sd) (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3423 (PCB).btsx = 0, (PCB).drt = -1; | |
3424 (PCB).reduction_token = (pgg_token_type) ag_ptt[(PCB).ag_ap]; | |
3425 ag_ra(); | |
3426 return (PCB).exit_flag == AG_RUNNING_CODE; | |
3427 } | |
3428 | |
3429 static int ag_action_3_s_proc(void) { | |
3430 int ag_sd = ag_fl[(PCB).ag_ap] - 1; | |
3431 if (ag_sd) (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3432 (PCB).btsx = 0, (PCB).drt = -1; | |
3433 (PCB).reduction_token = (pgg_token_type) ag_ptt[(PCB).ag_ap]; | |
3434 ag_ra(); | |
3435 return (PCB).exit_flag == AG_RUNNING_CODE; | |
3436 } | |
3437 | |
3438 static int ag_action_4_r_proc(void) { | |
3439 int ag_sd = ag_fl[(PCB).ag_ap] - 1; | |
3440 if (ag_sd) (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3441 (PCB).reduction_token = (pgg_token_type) ag_ptt[(PCB).ag_ap]; | |
3442 return 1; | |
3443 } | |
3444 | |
3445 static int ag_action_2_proc(void) { | |
3446 (PCB).btsx = 0, (PCB).drt = -1; | |
3447 if ((PCB).ssx >= 128) { | |
3448 (PCB).exit_flag = AG_STACK_ERROR_CODE; | |
3449 PARSER_STACK_OVERFLOW; | |
3450 } | |
3451 (*(int *) &(PCB).vs[(PCB).ssx]) = *(PCB).pointer; | |
3452 GET_CONTEXT; | |
3453 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3454 (PCB).ssx++; | |
3455 (PCB).sn = (PCB).ag_ap; | |
3456 ag_track(); | |
3457 return 0; | |
3458 } | |
3459 | |
3460 static int ag_action_9_proc(void) { | |
3461 if ((PCB).drt == -1) { | |
3462 (PCB).drt=(PCB).token_number; | |
3463 (PCB).dssx=(PCB).ssx; | |
3464 (PCB).dsn=(PCB).sn; | |
3465 } | |
3466 ag_prot(); | |
3467 (PCB).vs[(PCB).ssx] = ag_null_value; | |
3468 GET_CONTEXT; | |
3469 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3470 (PCB).ssx++; | |
3471 (PCB).sn = (PCB).ag_ap; | |
3472 (PCB).la_ptr = (PCB).pointer; | |
3473 return (PCB).exit_flag == AG_RUNNING_CODE; | |
3474 } | |
3475 | |
3476 static int ag_action_2_r_proc(void) { | |
3477 (PCB).ssx++; | |
3478 (PCB).sn = (PCB).ag_ap; | |
3479 return 0; | |
3480 } | |
3481 | |
3482 static int ag_action_7_proc(void) { | |
3483 --(PCB).ssx; | |
3484 (PCB).la_ptr = (PCB).pointer; | |
3485 (PCB).exit_flag = AG_SUCCESS_CODE; | |
3486 return 0; | |
3487 } | |
3488 | |
3489 static int ag_action_1_proc(void) { | |
3490 ag_track(); | |
3491 (PCB).exit_flag = AG_SUCCESS_CODE; | |
3492 return 0; | |
3493 } | |
3494 | |
3495 static int ag_action_1_r_proc(void) { | |
3496 (PCB).exit_flag = AG_SUCCESS_CODE; | |
3497 return 0; | |
3498 } | |
3499 | |
3500 static int ag_action_1_s_proc(void) { | |
3501 (PCB).exit_flag = AG_SUCCESS_CODE; | |
3502 return 0; | |
3503 } | |
3504 | |
3505 static int ag_action_4_proc(void) { | |
3506 int ag_sd = ag_fl[(PCB).ag_ap] - 1; | |
3507 (PCB).reduction_token = (pgg_token_type) ag_ptt[(PCB).ag_ap]; | |
3508 (PCB).btsx = 0, (PCB).drt = -1; | |
3509 (*(int *) &(PCB).vs[(PCB).ssx]) = *(PCB).pointer; | |
3510 if (ag_sd) (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3511 else GET_CONTEXT; | |
3512 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3513 ag_track(); | |
3514 while ((PCB).exit_flag == AG_RUNNING_CODE) { | |
3515 unsigned ag_t1 = ag_sbe[(PCB).sn] + 1; | |
3516 unsigned ag_t2 = ag_sbt[(PCB).sn+1] - 1; | |
3517 do { | |
3518 unsigned ag_tx = (ag_t1 + ag_t2)/2; | |
3519 if (ag_tstt[ag_tx] < (unsigned char)(PCB).reduction_token) ag_t1 = ag_tx + 1; | |
3520 else ag_t2 = ag_tx; | |
3521 } while (ag_t1 < ag_t2); | |
3522 if (ag_tstt[ag_t1] != (PCB).reduction_token) { | |
3523 (PCB).exit_flag = AG_REDUCTION_ERROR_CODE; | |
3524 REDUCTION_TOKEN_ERROR; break;} | |
3525 (PCB).ag_ap = ag_pstt[ag_t1]; | |
3526 if ((*(PCB).s_procs[ag_astt[ag_t1]])() == 0) break; | |
3527 } | |
3528 return 0; | |
3529 } | |
3530 | |
3531 static int ag_action_3_proc(void) { | |
3532 int ag_sd = ag_fl[(PCB).ag_ap] - 1; | |
3533 (PCB).btsx = 0, (PCB).drt = -1; | |
3534 (*(int *) &(PCB).vs[(PCB).ssx]) = *(PCB).pointer; | |
3535 if (ag_sd) (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3536 else GET_CONTEXT; | |
3537 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3538 ag_track(); | |
3539 (PCB).reduction_token = (pgg_token_type) ag_ptt[(PCB).ag_ap]; | |
3540 ag_ra(); | |
3541 while ((PCB).exit_flag == AG_RUNNING_CODE) { | |
3542 unsigned ag_t1 = ag_sbe[(PCB).sn] + 1; | |
3543 unsigned ag_t2 = ag_sbt[(PCB).sn+1] - 1; | |
3544 do { | |
3545 unsigned ag_tx = (ag_t1 + ag_t2)/2; | |
3546 if (ag_tstt[ag_tx] < (unsigned char)(PCB).reduction_token) ag_t1 = ag_tx + 1; | |
3547 else ag_t2 = ag_tx; | |
3548 } while (ag_t1 < ag_t2); | |
3549 if (ag_tstt[ag_t1] != (PCB).reduction_token) { | |
3550 (PCB).exit_flag = AG_REDUCTION_ERROR_CODE; | |
3551 REDUCTION_TOKEN_ERROR; break;} | |
3552 (PCB).ag_ap = ag_pstt[ag_t1]; | |
3553 if ((*(PCB).s_procs[ag_astt[ag_t1]])() == 0) break; | |
3554 } | |
3555 return 0; | |
3556 } | |
3557 | |
3558 static int ag_action_8_proc(void) { | |
3559 ag_undo(); | |
3560 (PCB).la_ptr = (PCB).pointer; | |
3561 ag_auto_resynch(); | |
3562 return (PCB).exit_flag == AG_RUNNING_CODE; | |
3563 } | |
3564 | |
3565 static int ag_action_5_proc(void) { | |
3566 int ag_sd = ag_fl[(PCB).ag_ap]; | |
3567 (PCB).btsx = 0, (PCB).drt = -1; | |
3568 if (ag_sd) (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3569 else { | |
3570 GET_CONTEXT; | |
3571 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3572 } | |
3573 (PCB).la_ptr = (PCB).pointer; | |
3574 (PCB).reduction_token = (pgg_token_type) ag_ptt[(PCB).ag_ap]; | |
3575 ag_ra(); | |
3576 while ((PCB).exit_flag == AG_RUNNING_CODE) { | |
3577 unsigned ag_t1 = ag_sbe[(PCB).sn] + 1; | |
3578 unsigned ag_t2 = ag_sbt[(PCB).sn+1] - 1; | |
3579 do { | |
3580 unsigned ag_tx = (ag_t1 + ag_t2)/2; | |
3581 if (ag_tstt[ag_tx] < (unsigned char)(PCB).reduction_token) ag_t1 = ag_tx + 1; | |
3582 else ag_t2 = ag_tx; | |
3583 } while (ag_t1 < ag_t2); | |
3584 if (ag_tstt[ag_t1] != (PCB).reduction_token) { | |
3585 (PCB).exit_flag = AG_REDUCTION_ERROR_CODE; | |
3586 REDUCTION_TOKEN_ERROR; break;} | |
3587 (PCB).ag_ap = ag_pstt[ag_t1]; | |
3588 if ((*(PCB).r_procs[ag_astt[ag_t1]])() == 0) break; | |
3589 } | |
3590 return (PCB).exit_flag == AG_RUNNING_CODE; | |
3591 } | |
3592 | |
3593 static int ag_action_6_proc(void) { | |
3594 int ag_sd = ag_fl[(PCB).ag_ap]; | |
3595 (PCB).reduction_token = (pgg_token_type) ag_ptt[(PCB).ag_ap]; | |
3596 if ((PCB).drt == -1) { | |
3597 (PCB).drt=(PCB).token_number; | |
3598 (PCB).dssx=(PCB).ssx; | |
3599 (PCB).dsn=(PCB).sn; | |
3600 } | |
3601 if (ag_sd) { | |
3602 (PCB).sn = (PCB).ss[(PCB).ssx -= ag_sd]; | |
3603 } | |
3604 else { | |
3605 ag_prot(); | |
3606 (PCB).vs[(PCB).ssx] = ag_null_value; | |
3607 GET_CONTEXT; | |
3608 (PCB).ss[(PCB).ssx] = (PCB).sn; | |
3609 } | |
3610 (PCB).la_ptr = (PCB).pointer; | |
3611 while ((PCB).exit_flag == AG_RUNNING_CODE) { | |
3612 unsigned ag_t1 = ag_sbe[(PCB).sn] + 1; | |
3613 unsigned ag_t2 = ag_sbt[(PCB).sn+1] - 1; | |
3614 do { | |
3615 unsigned ag_tx = (ag_t1 + ag_t2)/2; | |
3616 if (ag_tstt[ag_tx] < (unsigned char)(PCB).reduction_token) ag_t1 = ag_tx + 1; | |
3617 else ag_t2 = ag_tx; | |
3618 } while (ag_t1 < ag_t2); | |
3619 if (ag_tstt[ag_t1] != (PCB).reduction_token) { | |
3620 (PCB).exit_flag = AG_REDUCTION_ERROR_CODE; | |
3621 REDUCTION_TOKEN_ERROR; break;} | |
3622 (PCB).ag_ap = ag_pstt[ag_t1]; | |
3623 if ((*(PCB).r_procs[ag_astt[ag_t1]])() == 0) break; | |
3624 } | |
3625 return (PCB).exit_flag == AG_RUNNING_CODE; | |
3626 } | |
3627 | |
3628 | |
3629 static void ag_check_depth(int ag_fl) { | |
3630 int ag_sx = (PCB).ssx - ag_fl; | |
3631 if ((PCB).ag_error_depth && ag_sx < (PCB).ag_tmp_depth) (PCB).ag_tmp_depth = ag_sx; | |
3632 } | |
3633 | |
3634 static int ag_action_3_er_proc(void) { | |
3635 ag_check_depth(ag_fl[(PCB).ag_ap] - 1); | |
3636 return ag_action_4_r_proc(); | |
3637 } | |
3638 | |
3639 static int ag_action_2_e_proc(void) { | |
3640 ag_action_2_proc(); | |
3641 (PCB).ag_min_depth = (PCB).ag_tmp_depth; | |
3642 return 0; | |
3643 } | |
3644 | |
3645 static int ag_action_4_e_proc(void) { | |
3646 ag_check_depth(ag_fl[(PCB).ag_ap] - 1); | |
3647 (PCB).ag_min_depth = (PCB).ag_tmp_depth; | |
3648 return ag_action_4_proc(); | |
3649 } | |
3650 | |
3651 static int ag_action_6_e_proc(void) { | |
3652 ag_check_depth(ag_fl[(PCB).ag_ap]); | |
3653 return ag_action_6_proc(); | |
3654 } | |
3655 | |
3656 static int ag_action_11_e_proc(void) { | |
3657 return ag_action_10_proc(); | |
3658 } | |
3659 | |
3660 static int (*ag_r_procs_error[])(void) = { | |
3661 ag_action_1_r_proc, | |
3662 ag_action_2_r_proc, | |
3663 ag_action_3_er_proc, | |
3664 ag_action_3_er_proc | |
3665 }; | |
3666 | |
3667 static int (*ag_s_procs_error[])(void) = { | |
3668 ag_action_1_s_proc, | |
3669 ag_action_2_r_proc, | |
3670 ag_action_3_er_proc, | |
3671 ag_action_3_er_proc | |
3672 }; | |
3673 | |
3674 static int (*ag_gt_procs_error[])(void) = { | |
3675 ag_action_1_proc, | |
3676 ag_action_2_e_proc, | |
3677 ag_action_4_e_proc, | |
3678 ag_action_4_e_proc, | |
3679 ag_action_6_e_proc, | |
3680 ag_action_6_e_proc, | |
3681 ag_action_7_proc, | |
3682 ag_action_8_proc, | |
3683 ag_action_9_proc, | |
3684 ag_action_10_proc, | |
3685 ag_action_11_e_proc, | |
3686 ag_action_8_proc | |
3687 }; | |
3688 | |
3689 static void ag_set_error_procs(void) { | |
3690 (PCB).gt_procs = ag_gt_procs_error; | |
3691 (PCB).r_procs = ag_r_procs_error; | |
3692 (PCB).s_procs = ag_s_procs_error; | |
3693 } | |
3694 | |
3695 | |
3696 void init_pgg(void) { | |
3697 (PCB).la_ptr = (PCB).pointer; | |
3698 (PCB).gt_procs = ag_gt_procs_scan; | |
3699 (PCB).r_procs = ag_r_procs_scan; | |
3700 (PCB).s_procs = ag_s_procs_scan; | |
3701 (PCB).ag_error_depth = (PCB).ag_min_depth = (PCB).ag_tmp_depth = 0; | |
3702 (PCB).ag_resynch_active = 0; | |
3703 (PCB).ss[0] = (PCB).sn = (PCB).ssx = 0; | |
3704 (PCB).exit_flag = AG_RUNNING_CODE; | |
3705 (PCB).line = FIRST_LINE; | |
3706 (PCB).column = FIRST_COLUMN; | |
3707 (PCB).btsx = 0, (PCB).drt = -1; | |
3708 } | |
3709 | |
3710 void pgg(void) { | |
3711 init_pgg(); | |
3712 (PCB).exit_flag = AG_RUNNING_CODE; | |
3713 while ((PCB).exit_flag == AG_RUNNING_CODE) { | |
3714 unsigned ag_t1 = ag_sbt[(PCB).sn]; | |
3715 if (ag_tstt[ag_t1]) { | |
3716 unsigned ag_t2 = ag_sbe[(PCB).sn] - 1; | |
3717 (PCB).token_number = (pgg_token_type) AG_TCV(INPUT_CODE(*(PCB).la_ptr)); | |
3718 (PCB).la_ptr++; | |
3719 if (ag_key_index[(PCB).sn]) { | |
3720 unsigned ag_k = ag_key_index[(PCB).sn]; | |
3721 int ag_ch = CONVERT_CASE(INPUT_CODE(*(PCB).pointer)); | |
3722 if (ag_ch <= 255) { | |
3723 while (ag_key_ch[ag_k] < ag_ch) ag_k++; | |
3724 if (ag_key_ch[ag_k] == ag_ch) ag_get_key_word(ag_k); | |
3725 } | |
3726 } | |
3727 do { | |
3728 unsigned ag_tx = (ag_t1 + ag_t2)/2; | |
3729 if (ag_tstt[ag_tx] > (unsigned char)(PCB).token_number) | |
3730 ag_t1 = ag_tx + 1; | |
3731 else ag_t2 = ag_tx; | |
3732 } while (ag_t1 < ag_t2); | |
3733 if (ag_tstt[ag_t1] != (unsigned char)(PCB).token_number) | |
3734 ag_t1 = ag_sbe[(PCB).sn]; | |
3735 } | |
3736 (PCB).ag_ap = ag_pstt[ag_t1]; | |
3737 (*(PCB).gt_procs[ag_astt[ag_t1]])(); | |
3738 } | |
3739 } | |
3740 | |
3741 |