Debian Codegraph @

texk/detex/detex-src/detex.c

raw
1 #line 5 "../../../texk/detex/detex-src/detex.l"
2 /*
3 * Copyright (c) 1986-2007 Purdue University
4 * All rights reserved.
5 *
6 * Developed by: Daniel Trinkle
7 * Department of Computer Science, Purdue University
8 * http://www.cs.purdue.edu/
9 *
10 * Permission is hereby granted, free of charge, to any person obtaining
11 * a copy of this software and associated documentation files (the
12 * "Software"), to deal with the Software without restriction, including
13 * without limitation the rights to use, copy, modify, merge, publish,
14 * distribute, sublicense, and/or sell copies of the Software, and to
15 * permit persons to whom the Software is furnished to do so, subject to
16 * the following conditions:
17 *
18 * o Redistributions of source code must retain the above copyright
19 * notice, this list of conditions and the following disclaimers.
20 *
21 * o Redistributions in binary form must reproduce the above copyright
22 * notice, this list of conditions and the following disclaimers in the
23 * documentation and/or other materials provided with the distribution.
24 *
25 * o Neither the names of Daniel Trinkle, Purdue University, nor the
26 * names of its contributors may be used to endorse or promote products
27 * derived from this Software without specific prior written
28 * permission.
29 *
30 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
31 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
32 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
33 * IN NO EVENT SHALL THE CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR
34 * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
35 * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
36 * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE SOFTWARE.
37 */
38
39
40 /*
41 * detex [-e environment-list] [-c] [-l] [-n] [-s] [-t] [-w] [-1] [file[.tex] ]
42 *
43 * This program is used to remove TeX or LaTeX constructs from a text
44 * file.
45 */
46
47 #include "detex.h"
48
49 #ifdef KPATHSEA
50
51 #include <c-auto.h>
52 #include <kpathsea/c-auto.h>
53 #include <kpathsea/config.h>
54 #include <kpathsea/c-memstr.h>
55 #include <kpathsea/c-pathmx.h>
56 #include <kpathsea/c-std.h>
57 #include <kpathsea/tex-file.h>
58
59 #ifdef HAVE_SYS_PARAM_H
60 #include <sys/param.h>
61 #endif
62
63 #else /* KPATHSEA */
64
65 #ifdef HAVE_STRING_H
66 #include <string.h>
67 #else
68 #include <strings.h>
69 #define strrchr rindex
70 #endif
71
72 #ifdef HAVE_LIMITS_H
73 #include <limits.h>
74 #else
75 #include <sys/param.h>
76 #ifndef PATH_MAX /* for old BSD */
77 #define PATH_MAX MAXPATHLEN
78 #endif
79 #endif /* HAVE_LIMITS_H */
80
81 #ifdef OS2
82 #include <stdlib.h>
83 #endif
84
85 #ifdef WIN32
86 #include <fcntl.h>
87 #include <io.h>
88 #endif
89
90 #endif /* KPATHSEA */
91
92
93
94 #line 95 "../../../texk/detex/detex-src/detex.c"
95
96 #define YY_INT_ALIGNED short int
97
98 /* A lexical scanner generated by flex */
99
100 #define FLEX_SCANNER
101 #define YY_FLEX_MAJOR_VERSION 2
102 #define YY_FLEX_MINOR_VERSION 6
103 #define YY_FLEX_SUBMINOR_VERSION 0
104 #if YY_FLEX_SUBMINOR_VERSION > 0
105 #define FLEX_BETA
106 #endif
107
108 /* First, we deal with platform-specific or compiler-specific issues. */
109
110 /* begin standard C headers. */
111 #include <stdio.h>
112 #include <string.h>
113 #include <errno.h>
114 #include <stdlib.h>
115
116 /* end standard C headers. */
117
118 /* flex integer type definitions */
119
120 #ifndef FLEXINT_H
121 #define FLEXINT_H
122
123 /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
124
125 #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
126
127 /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
128 * if you want the limit (max/min) macros for int types.
129 */
130 #ifndef __STDC_LIMIT_MACROS
131 #define __STDC_LIMIT_MACROS 1
132 #endif
133
134 #include <inttypes.h>
135 typedef int8_t flex_int8_t;
136 typedef uint8_t flex_uint8_t;
137 typedef int16_t flex_int16_t;
138 typedef uint16_t flex_uint16_t;
139 typedef int32_t flex_int32_t;
140 typedef uint32_t flex_uint32_t;
141 #else
142 typedef signed char flex_int8_t;
143 typedef short int flex_int16_t;
144 typedef int flex_int32_t;
145 typedef unsigned char flex_uint8_t;
146 typedef unsigned short int flex_uint16_t;
147 typedef unsigned int flex_uint32_t;
148
149 /* Limits of integral types. */
150 #ifndef INT8_MIN
151 #define INT8_MIN (-128)
152 #endif
153 #ifndef INT16_MIN
154 #define INT16_MIN (-32767-1)
155 #endif
156 #ifndef INT32_MIN
157 #define INT32_MIN (-2147483647-1)
158 #endif
159 #ifndef INT8_MAX
160 #define INT8_MAX (127)
161 #endif
162 #ifndef INT16_MAX
163 #define INT16_MAX (32767)
164 #endif
165 #ifndef INT32_MAX
166 #define INT32_MAX (2147483647)
167 #endif
168 #ifndef UINT8_MAX
169 #define UINT8_MAX (255U)
170 #endif
171 #ifndef UINT16_MAX
172 #define UINT16_MAX (65535U)
173 #endif
174 #ifndef UINT32_MAX
175 #define UINT32_MAX (4294967295U)
176 #endif
177
178 #endif /* ! C99 */
179
180 #endif /* ! FLEXINT_H */
181
182 #ifdef __cplusplus
183
184 /* The "const" storage-class-modifier is valid. */
185 #define YY_USE_CONST
186
187 #else /* ! __cplusplus */
188
189 /* C99 requires __STDC__ to be defined as 1. */
190 #if defined (__STDC__)
191
192 #define YY_USE_CONST
193
194 #endif /* defined (__STDC__) */
195 #endif /* ! __cplusplus */
196
197 #ifdef YY_USE_CONST
198 #define yyconst const
199 #else
200 #define yyconst
201 #endif
202
203 /* Returned upon end-of-file. */
204 #define YY_NULL 0
205
206 /* Promotes a possibly negative, possibly signed char to an unsigned
207 * integer for use as an array index. If the signed char is negative,
208 * we want to instead treat it as an 8-bit unsigned char, hence the
209 * double cast.
210 */
211 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
212
213 /* Enter a start condition. This macro really ought to take a parameter,
214 * but we do it the disgusting crufty way forced on us by the ()-less
215 * definition of BEGIN.
216 */
217 #define BEGIN (yy_start) = 1 + 2 *
218
219 /* Translate the current start state into a value that can be later handed
220 * to BEGIN to return to the state. The YYSTATE alias is for lex
221 * compatibility.
222 */
223 #define YY_START (((yy_start) - 1) / 2)
224 #define YYSTATE YY_START
225
226 /* Action number for EOF rule of a given start state. */
227 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
228
229 /* Special action meaning "start processing a new file". */
230 #define YY_NEW_FILE yyrestart(yyin )
231
232 #define YY_END_OF_BUFFER_CHAR 0
233
234 /* Size of default input buffer. */
235 #ifndef YY_BUF_SIZE
236 #ifdef __ia64__
237 /* On IA-64, the buffer size is 16k, not 8k.
238 * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
239 * Ditto for the __ia64__ case accordingly.
240 */
241 #define YY_BUF_SIZE 32768
242 #else
243 #define YY_BUF_SIZE 16384
244 #endif /* __ia64__ */
245 #endif
246
247 /* The state buf must be large enough to hold one state per character in the main buffer.
248 */
249 #define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
250
251 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
252 #define YY_TYPEDEF_YY_BUFFER_STATE
253 typedef struct yy_buffer_state *YY_BUFFER_STATE;
254 #endif
255
256 #ifndef YY_TYPEDEF_YY_SIZE_T
257 #define YY_TYPEDEF_YY_SIZE_T
258 typedef size_t yy_size_t;
259 #endif
260
261 extern yy_size_t yyleng;
262
263 extern FILE *yyin, *yyout;
264
265 #define EOB_ACT_CONTINUE_SCAN 0
266 #define EOB_ACT_END_OF_FILE 1
267 #define EOB_ACT_LAST_MATCH 2
268
269 #define YY_LESS_LINENO(n)
270 #define YY_LINENO_REWIND_TO(ptr)
271
272 /* Return all but the first "n" matched characters back to the input stream. */
273 #define yyless(n) \
274 do \
275 { \
276 /* Undo effects of setting up yytext. */ \
277 int yyless_macro_arg = (n); \
278 YY_LESS_LINENO(yyless_macro_arg);\
279 *yy_cp = (yy_hold_char); \
280 YY_RESTORE_YY_MORE_OFFSET \
281 (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
282 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
283 } \
284 while ( 0 )
285
286 #define unput(c) yyunput( c, (yytext_ptr) )
287
288 #ifndef YY_STRUCT_YY_BUFFER_STATE
289 #define YY_STRUCT_YY_BUFFER_STATE
290 struct yy_buffer_state
291 {
292 FILE *yy_input_file;
293
294 char *yy_ch_buf; /* input buffer */
295 char *yy_buf_pos; /* current position in input buffer */
296
297 /* Size of input buffer in bytes, not including room for EOB
298 * characters.
299 */
300 yy_size_t yy_buf_size;
301
302 /* Number of characters read into yy_ch_buf, not including EOB
303 * characters.
304 */
305 yy_size_t yy_n_chars;
306
307 /* Whether we "own" the buffer - i.e., we know we created it,
308 * and can realloc() it to grow it, and should free() it to
309 * delete it.
310 */
311 int yy_is_our_buffer;
312
313 /* Whether this is an "interactive" input source; if so, and
314 * if we're using stdio for input, then we want to use getc()
315 * instead of fread(), to make sure we stop fetching input after
316 * each newline.
317 */
318 int yy_is_interactive;
319
320 /* Whether we're considered to be at the beginning of a line.
321 * If so, '^' rules will be active on the next match, otherwise
322 * not.
323 */
324 int yy_at_bol;
325
326 int yy_bs_lineno; /**< The line count. */
327 int yy_bs_column; /**< The column count. */
328
329 /* Whether to try to fill the input buffer when we reach the
330 * end of it.
331 */
332 int yy_fill_buffer;
333
334 int yy_buffer_status;
335
336 #define YY_BUFFER_NEW 0
337 #define YY_BUFFER_NORMAL 1
338 /* When an EOF's been seen but there's still some text to process
339 * then we mark the buffer as YY_EOF_PENDING, to indicate that we
340 * shouldn't try reading from the input source any more. We might
341 * still have a bunch of tokens to match, though, because of
342 * possible backing-up.
343 *
344 * When we actually see the EOF, we change the status to "new"
345 * (via yyrestart()), so that the user can continue scanning by
346 * just pointing yyin at a new input file.
347 */
348 #define YY_BUFFER_EOF_PENDING 2
349
350 };
351 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
352
353 /* Stack of input buffers. */
354 static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */
355 static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */
356 static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */
357
358 /* We provide macros for accessing buffer states in case in the
359 * future we want to put the buffer states in a more general
360 * "scanner state".
361 *
362 * Returns the top of the stack, or NULL.
363 */
364 #define YY_CURRENT_BUFFER ( (yy_buffer_stack) \
365 ? (yy_buffer_stack)[(yy_buffer_stack_top)] \
366 : NULL)
367
368 /* Same as previous macro, but useful when we know that the buffer stack is not
369 * NULL or when we need an lvalue. For internal use only.
370 */
371 #define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)]
372
373 /* yy_hold_char holds the character lost when yytext is formed. */
374 static char yy_hold_char;
375 static yy_size_t yy_n_chars; /* number of characters read into yy_ch_buf */
376 yy_size_t yyleng;
377
378 /* Points to current character in buffer. */
379 static char *yy_c_buf_p = (char *) 0;
380 static int yy_init = 0; /* whether we need to initialize */
381 static int yy_start = 0; /* start state number */
382
383 /* Flag which is used to allow yywrap()'s to do buffer switches
384 * instead of setting up a fresh yyin. A bit of a hack ...
385 */
386 static int yy_did_buffer_switch_on_eof;
387
388 void yyrestart (FILE *input_file );
389 void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer );
390 YY_BUFFER_STATE yy_create_buffer (FILE *file,int size );
391 void yy_delete_buffer (YY_BUFFER_STATE b );
392 void yy_flush_buffer (YY_BUFFER_STATE b );
393 void yypush_buffer_state (YY_BUFFER_STATE new_buffer );
394 void yypop_buffer_state (void );
395
396 static void yyensure_buffer_stack (void );
397 static void yy_load_buffer_state (void );
398 static void yy_init_buffer (YY_BUFFER_STATE b,FILE *file );
399
400 #define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER )
401
402 YY_BUFFER_STATE yy_scan_buffer (char *base,yy_size_t size );
403 YY_BUFFER_STATE yy_scan_string (yyconst char *yy_str );
404 YY_BUFFER_STATE yy_scan_bytes (yyconst char *bytes,yy_size_t len );
405
406 void *yyalloc (yy_size_t );
407 void *yyrealloc (void *,yy_size_t );
408 void yyfree (void * );
409
410 #define yy_new_buffer yy_create_buffer
411
412 #define yy_set_interactive(is_interactive) \
413 { \
414 if ( ! YY_CURRENT_BUFFER ){ \
415 yyensure_buffer_stack (); \
416 YY_CURRENT_BUFFER_LVALUE = \
417 yy_create_buffer(yyin,YY_BUF_SIZE ); \
418 } \
419 YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
420 }
421
422 #define yy_set_bol(at_bol) \
423 { \
424 if ( ! YY_CURRENT_BUFFER ){\
425 yyensure_buffer_stack (); \
426 YY_CURRENT_BUFFER_LVALUE = \
427 yy_create_buffer(yyin,YY_BUF_SIZE ); \
428 } \
429 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
430 }
431
432 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
433
434 /* Begin user sect3 */
435
436 typedef unsigned char YY_CHAR;
437
438 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
439
440 typedef int yy_state_type;
441
442 extern int yylineno;
443
444 int yylineno = 1;
445
446 extern char *yytext;
447 #ifdef yytext_ptr
448 #undef yytext_ptr
449 #endif
450 #define yytext_ptr yytext
451
452 static yy_state_type yy_get_previous_state (void );
453 static yy_state_type yy_try_NUL_trans (yy_state_type current_state );
454 static int yy_get_next_buffer (void );
455 #if defined(__GNUC__) && __GNUC__ >= 3
456 __attribute__((__noreturn__))
457 #endif
458 static void yy_fatal_error (yyconst char msg[] );
459
460 /* Done after the current pattern has been matched and before the
461 * corresponding action - sets up yytext.
462 */
463 #define YY_DO_BEFORE_ACTION \
464 (yytext_ptr) = yy_bp; \
465 yyleng = (size_t) (yy_cp - yy_bp); \
466 (yy_hold_char) = *yy_cp; \
467 *yy_cp = '\0'; \
468 (yy_c_buf_p) = yy_cp;
469
470 #define YY_NUM_RULES 174
471 #define YY_END_OF_BUFFER 175
472 /* This struct is not used in this scanner,
473 but its presence is necessary. */
474 struct yy_trans_info
475 {
476 flex_int32_t yy_verify;
477 flex_int32_t yy_nxt;
478 };
479 static yyconst flex_int16_t yy_accept[1362] =
480 { 0,
481 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
482 0, 0, 0, 0, 145, 145, 0, 0, 0, 0,
483 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
484 0, 0, 167, 167, 0, 0, 0, 0, 0, 0,
485 140, 140, 0, 0, 175, 174, 92, 91, 90, 107,
486 105, 107, 106, 107, 107, 119, 122, 121, 120, 128,
487 130, 129, 113, 110, 109, 112, 113, 113, 159, 159,
488 160, 159, 159, 108, 1, 159, 159, 159, 158, 159,
489 147, 152, 155, 147, 156, 149, 146, 145, 143, 142,
490 146, 146, 144, 12, 12, 174, 11, 12, 102, 100,
491
492 101, 102, 102, 18, 16, 17, 15, 14, 15, 97,
493 95, 96, 97, 97, 115, 117, 116, 124, 126, 125,
494 165, 162, 163, 164, 167, 166, 171, 168, 169, 170,
495 173, 172, 6, 6, 7, 140, 44, 43, 46, 104,
496 0, 0, 0, 0, 0, 0, 0, 119, 121, 128,
497 129, 111, 0, 0, 0, 0, 0, 0, 0, 161,
498 0, 148, 103, 1, 153, 154, 150, 158, 0, 157,
499 139, 137, 132, 93, 136, 136, 136, 136, 98, 138,
500 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
501 136, 136, 136, 136, 136, 136, 136, 136, 151, 0,
502
503 0, 0, 145, 144, 142, 142, 0, 141, 0, 0,
504 11, 0, 0, 0, 0, 0, 99, 0, 0, 0,
505 0, 0, 0, 0, 16, 14, 0, 94, 0, 0,
506 0, 0, 0, 0, 0, 115, 116, 124, 125, 164,
507 167, 6, 0, 44, 0, 45, 0, 106, 0, 0,
508 0, 0, 0, 0, 0, 112, 0, 0, 0, 0,
509 0, 0, 0, 150, 157, 136, 136, 134, 134, 138,
510 0, 136, 136, 136, 136, 136, 136, 136, 136, 136,
511 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
512 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
513
514 136, 136, 136, 136, 136, 136, 0, 0, 0, 0,
515 0, 0, 0, 0, 101, 0, 0, 0, 0, 0,
516 0, 0, 0, 96, 0, 0, 0, 0, 0, 0,
517 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
518 133, 133, 0, 138, 136, 136, 136, 136, 136, 136,
519 89, 136, 71, 136, 136, 136, 136, 136, 136, 136,
520 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
521 136, 78, 136, 136, 136, 136, 136, 136, 136, 136,
522 136, 136, 136, 136, 136, 136, 136, 136, 136, 0,
523 0, 0, 0, 0, 0, 0, 0, 0, 0, 13,
524
525 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
526 0, 0, 0, 0, 136, 136, 136, 136, 136, 136,
527 136, 136, 136, 67, 136, 136, 136, 136, 136, 136,
528 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
529 136, 136, 136, 136, 136, 136, 136, 136, 57, 136,
530 136, 136, 136, 136, 136, 33, 136, 136, 136, 136,
531 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
532 85, 136, 136, 25, 0, 0, 0, 0, 0, 0,
533 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
534 0, 0, 0, 0, 0, 0, 67, 136, 136, 136,
535
536 136, 3, 136, 136, 136, 136, 48, 136, 136, 136,
537 136, 136, 136, 136, 136, 136, 136, 73, 127, 0,
538 0, 0, 0, 0, 74, 136, 136, 136, 136, 136,
539 136, 136, 136, 136, 136, 136, 57, 136, 136, 136,
540 136, 136, 136, 136, 136, 136, 136, 136, 131, 136,
541 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
542 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
543 0, 0, 0, 0, 106, 0, 112, 0, 136, 136,
544 136, 136, 136, 0, 0, 136, 136, 136, 136, 136,
545 136, 136, 136, 136, 136, 136, 0, 0, 0, 0,
546
547 0, 136, 136, 136, 0, 0, 0, 0, 0, 0,
548 0, 0, 0, 0, 0, 19, 136, 136, 136, 136,
549 136, 136, 136, 136, 136, 136, 136, 37, 136, 136,
550 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
551 136, 136, 136, 136, 136, 136, 136, 136, 35, 136,
552 0, 0, 0, 0, 0, 136, 0, 0, 0, 0,
553 0, 101, 0, 96, 0, 0, 0, 0, 136, 136,
554 136, 136, 136, 0, 0, 64, 136, 136, 58, 136,
555 136, 136, 136, 136, 136, 136, 0, 0, 0, 0,
556 0, 0, 0, 0, 0, 0, 0, 22, 0, 0,
557
558 0, 136, 114, 0, 19, 19, 136, 75, 136, 136,
559 136, 136, 136, 136, 76, 136, 136, 136, 136, 136,
560 136, 136, 34, 136, 59, 136, 136, 136, 136, 136,
561 136, 123, 136, 136, 136, 136, 136, 136, 0, 0,
562 0, 0, 0, 0, 0, 0, 0, 0, 0, 20,
563 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
564 0, 0, 136, 136, 136, 136, 136, 0, 136, 66,
565 58, 50, 136, 136, 136, 53, 83, 136, 0, 22,
566 22, 22, 22, 0, 0, 0, 0, 0, 136, 136,
567 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
568
569 36, 136, 136, 136, 136, 38, 59, 136, 136, 136,
570 136, 136, 136, 136, 136, 136, 136, 136, 136, 0,
571 20, 20, 20, 20, 0, 0, 0, 0, 0, 0,
572 0, 0, 0, 0, 0, 136, 136, 136, 136, 136,
573 0, 136, 136, 136, 136, 51, 0, 84, 0, 0,
574 22, 22, 0, 0, 0, 0, 0, 0, 0, 0,
575 0, 0, 0, 0, 136, 136, 136, 135, 136, 136,
576 136, 26, 136, 52, 77, 62, 136, 136, 39, 41,
577 136, 27, 136, 136, 136, 136, 136, 136, 136, 49,
578 136, 136, 0, 0, 20, 20, 0, 0, 0, 0,
579
580 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
581 8, 9, 0, 4, 0, 136, 136, 136, 136, 0,
582 0, 0, 136, 136, 136, 136, 0, 0, 0, 22,
583 22, 0, 0, 0, 0, 0, 23, 72, 136, 136,
584 0, 86, 81, 136, 32, 62, 40, 136, 39, 79,
585 31, 136, 29, 136, 136, 60, 136, 136, 70, 0,
586 0, 20, 20, 0, 0, 0, 0, 0, 21, 10,
587 0, 136, 136, 136, 28, 0, 0, 0, 0, 0,
588 0, 136, 47, 136, 136, 0, 0, 0, 22, 22,
589 0, 0, 0, 0, 136, 118, 0, 136, 136, 30,
590
591 82, 136, 60, 136, 136, 0, 0, 20, 20, 0,
592 0, 0, 0, 0, 136, 136, 80, 0, 0, 0,
593 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
594 65, 136, 136, 0, 0, 22, 22, 0, 0, 0,
595 0, 0, 0, 0, 0, 136, 135, 136, 87, 63,
596 136, 136, 0, 0, 20, 20, 0, 0, 0, 0,
597 0, 0, 0, 0, 0, 136, 136, 0, 0, 0,
598 0, 0, 24, 0, 69, 68, 0, 0, 22, 0,
599 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
600 0, 0, 0, 0, 22, 0, 0, 0, 0, 136,
601
602 136, 63, 61, 55, 0, 0, 20, 0, 0, 0,
603 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
604 0, 0, 20, 0, 0, 0, 0, 0, 5, 136,
605 54, 0, 0, 0, 0, 0, 0, 0, 0, 0,
606 0, 0, 0, 0, 0, 0, 0, 0, 22, 0,
607 22, 22, 22, 0, 0, 0, 0, 0, 0, 0,
608 0, 136, 88, 61, 0, 0, 0, 0, 0, 0,
609 0, 0, 0, 0, 0, 0, 20, 0, 20, 20,
610 20, 0, 0, 0, 0, 0, 0, 0, 0, 56,
611 0, 0, 0, 0, 0, 2, 0, 22, 22, 22,
612
613 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
614 0, 0, 0, 0, 0, 0, 0, 0, 0, 42,
615 0, 20, 20, 20, 0, 0, 0, 0, 0, 0,
616 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
617 0, 0, 0, 0, 0, 0, 0, 2, 22, 0,
618 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
619 0, 0, 0, 0, 0, 0, 42, 42, 20, 0,
620 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
621 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
622 0, 0, 0, 0, 22, 0, 0, 0, 0, 20,
623
624 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
625 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
626 0, 0, 0, 22, 0, 20, 0, 0, 0, 0,
627 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
628 0, 0, 0, 0, 22, 0, 20, 0, 0, 0,
629 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
630 0
631 } ;
632
633 static yyconst YY_CHAR yy_ec[256] =
634 { 0,
635 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
636 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
637 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
638 1, 4, 5, 1, 1, 6, 7, 1, 8, 9,
639 10, 11, 12, 13, 14, 15, 1, 16, 16, 16,
640 16, 16, 17, 17, 17, 17, 17, 1, 1, 18,
641 19, 20, 21, 22, 23, 24, 24, 24, 25, 24,
642 24, 24, 24, 24, 24, 26, 24, 24, 27, 24,
643 24, 24, 24, 24, 24, 24, 24, 24, 24, 24,
644 28, 29, 30, 1, 1, 31, 32, 33, 34, 35,
645
646 36, 37, 38, 39, 40, 26, 41, 42, 43, 44,
647 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
648 55, 56, 57, 58, 59, 60, 1, 1, 1, 1,
649 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
650 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
651 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
652 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
653 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
654 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
655 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
656
657 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
658 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
659 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
660 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
661 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
662 1, 1, 1, 1, 1
663 } ;
664
665 static yyconst YY_CHAR yy_meta[61] =
666 { 0,
667 1, 2, 3, 2, 4, 1, 1, 5, 1, 1,
668 1, 1, 6, 7, 1, 7, 7, 1, 7, 1,
669 1, 8, 9, 9, 9, 9, 9, 1, 10, 11,
670 7, 9, 9, 9, 9, 9, 9, 9, 9, 9,
671 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
672 9, 9, 9, 9, 9, 9, 12, 1, 13, 1
673 } ;
674
675 static yyconst flex_uint16_t yy_base[1416] =
676 { 0,
677 0, 0, 0, 1, 2, 6, 14, 26, 11, 30,
678 43, 47, 96, 0, 156, 0, 216, 0, 274, 277,
679 326, 0, 7, 8, 384, 387, 389, 392, 395, 406,
680 20, 386, 3340, 3339, 398, 409, 39, 44, 16, 35,
681 3352, 3351, 21, 25, 3366, 3371, 3371, 3371, 3371, 3371,
682 3371, 3359, 3371, 241, 3313, 0, 3371, 3360, 3371, 0,
683 3371, 3359, 3371, 3371, 3371, 3371, 272, 3310, 3371, 3358,
684 3371, 3330, 3327, 3351, 0, 3348, 3342, 3340, 24, 3345,
685 468, 3321, 403, 3371, 3371, 3371, 3371, 527, 3371, 0,
686 294, 0, 3294, 3371, 530, 533, 0, 536, 3371, 3371,
687
688 3371, 511, 3299, 3371, 0, 3371, 3371, 3346, 3312, 3371,
689 3371, 3371, 418, 3296, 0, 3371, 3343, 0, 3371, 3342,
690 3371, 3371, 3371, 3341, 0, 3371, 3371, 3371, 3371, 3371,
691 3371, 3371, 0, 0, 3307, 3371, 0, 3371, 91, 3371,
692 3306, 3297, 3304, 3307, 3302, 3, 3304, 0, 3333, 0,
693 3332, 3371, 3298, 3289, 3296, 3299, 3294, 35, 3296, 3326,
694 3293, 3371, 3371, 0, 3371, 3371, 3312, 43, 3317, 3316,
695 3371, 3371, 3371, 3371, 0, 65, 540, 543, 3371, 271,
696 269, 16, 279, 253, 3279, 266, 372, 554, 3286, 560,
697 255, 567, 3289, 393, 572, 281, 3271, 273, 3371, 407,
698
699 414, 425, 563, 3262, 0, 0, 558, 0, 572, 591,
700 0, 607, 3278, 3277, 3284, 3279, 3371, 3278, 3269, 3276,
701 3279, 3274, 360, 3276, 0, 3305, 3263, 3371, 3270, 3261,
702 3268, 3271, 3266, 399, 3268, 0, 3297, 0, 3296, 3371,
703 0, 0, 3254, 0, 578, 613, 3250, 3371, 3249, 3249,
704 3247, 3250, 401, 3243, 3244, 3371, 3243, 3243, 3241, 3244,
705 515, 3237, 3245, 3371, 3276, 0, 628, 633, 3371, 3255,
706 3252, 3246, 3242, 3246, 3246, 3227, 3234, 3238, 3240, 3238,
707 3227, 602, 418, 3225, 605, 3222, 3236, 3224, 3224, 3213,
708 43, 3225, 611, 3214, 3211, 3217, 3229, 551, 3228, 3223,
709
710 3225, 3203, 3216, 3219, 3206, 537, 608, 580, 3203, 3214,
711 3207, 3217, 3201, 3201, 3371, 3200, 3200, 3198, 3201, 612,
712 3194, 3207, 3194, 3371, 3193, 3193, 3191, 3194, 616, 3187,
713 3200, 3185, 3184, 3183, 3195, 3181, 3180, 3179, 3191, 3176,
714 661, 3371, 3195, 3371, 619, 3184, 510, 3177, 3186, 3176,
715 3180, 3168, 0, 3176, 3175, 3166, 3165, 3174, 3181, 3176,
716 3169, 3174, 3158, 3164, 3171, 3170, 3169, 632, 3168, 640,
717 3154, 3160, 3165, 3160, 3167, 3162, 3143, 3154, 3145, 633,
718 3145, 3147, 633, 3142, 3142, 643, 3157, 3149, 3156, 661,
719 3128, 3134, 3131, 3117, 3125, 3108, 3107, 3104, 3116, 3371,
720
721 3102, 3101, 3083, 3095, 682, 3080, 3078, 3066, 3033, 3032,
722 3036, 3035, 3014, 3025, 3007, 3006, 3003, 2998, 3002, 2984,
723 2983, 2972, 2965, 0, 2964, 2967, 2744, 2741, 2746, 2735,
724 2739, 2736, 2747, 2732, 2728, 2724, 2727, 694, 2734, 2742,
725 2726, 2728, 2727, 2734, 2737, 646, 2730, 2722, 2755, 2729,
726 2728, 2710, 2706, 2711, 2727, 0, 2723, 2717, 2711, 2719,
727 2709, 2714, 2718, 2711, 2718, 576, 2715, 2702, 2702, 2710,
728 0, 2694, 2705, 3371, 2690, 2691, 2700, 2703, 2684, 2693,
729 2692, 2677, 2676, 2689, 2688, 2673, 697, 700, 2677, 2671,
730 2670, 2683, 2673, 2667, 2666, 2679, 3371, 2669, 2668, 671,
731
732 2665, 712, 2674, 2664, 2653, 2671, 2673, 2669, 2668, 2655,
733 2666, 2655, 2654, 715, 2662, 2648, 2661, 0, 0, 731,
734 709, 705, 768, 0, 0, 2647, 2658, 685, 2641, 2648,
735 2639, 2645, 2653, 2634, 2634, 2627, 3371, 2647, 2645, 2644,
736 2641, 2640, 2626, 2637, 2624, 2617, 2623, 702, 0, 2621,
737 2623, 2616, 2629, 2629, 2616, 2628, 2605, 2624, 747, 2621,
738 2619, 2622, 754, 2603, 2607, 2601, 2600, 2613, 2603, 2597,
739 2596, 2609, 763, 2608, 2607, 2594, 2604, 2592, 2588, 2587,
740 2591, 2599, 2602, 771, 775, 2590, 2594, 2589, 2578, 2579,
741 2589, 2578, 2588, 2588, 2583, 2568, 778, 771, 780, 827,
742
743 0, 821, 2577, 2576, 783, 789, 802, 2565, 401, 2575,
744 2566, 2564, 2564, 557, 2560, 818, 2569, 2567, 2560, 2558,
745 2561, 2562, 2563, 2555, 2559, 2540, 2562, 0, 2548, 2542,
746 2546, 2557, 2556, 2534, 2542, 2542, 2541, 2545, 2546, 2545,
747 2540, 2528, 2542, 2545, 2526, 2526, 2532, 2535, 0, 2527,
748 835, 818, 810, 877, 0, 880, 855, 2528, 883, 893,
749 2525, 2528, 2516, 2526, 2514, 2512, 2508, 2506, 2516, 2514,
750 2499, 2505, 2514, 896, 2502, 0, 2498, 2509, 2532, 2487,
751 2495, 2489, 2492, 2501, 2501, 2498, 838, 824, 829, 2487,
752 618, 2497, 2488, 2482, 2481, 822, 2477, 886, 899, 902,
753
754 931, 2472, 771, 849, 905, 936, 2488, 0, 2487, 2468,
755 2465, 2461, 2477, 2463, 0, 2465, 2460, 2449, 2469, 2458,
756 2446, 2445, 0, 2435, 2470, 2430, 2428, 2431, 2431, 2435,
757 2424, 0, 2424, 2421, 2424, 2414, 2413, 2415, 934, 852,
758 858, 2396, 881, 2391, 2366, 2375, 2375, 891, 2369, 950,
759 959, 962, 965, 968, 971, 2372, 981, 0, 2364, 2353,
760 2350, 2363, 2343, 2350, 2340, 2345, 2345, 2346, 2346, 0,
761 3371, 0, 2335, 584, 2322, 0, 0, 820, 902, 985,
762 998, 1002, 1008, 0, 975, 911, 1053, 0, 2320, 2315,
763 2309, 2311, 2303, 2310, 2300, 2305, 2294, 2290, 2300, 2296,
764
765 0, 2288, 2287, 2275, 2274, 0, 3371, 2290, 2286, 2273,
766 2278, 2264, 2263, 238, 243, 273, 340, 383, 415, 941,
767 1018, 1030, 1034, 1063, 0, 998, 981, 1108, 0, 1021,
768 0, 1056, 500, 1079, 606, 638, 659, 643, 662, 1088,
769 687, 694, 697, 711, 718, 0, 0, 3371, 749, 749,
770 1115, 1124, 1105, 991, 1001, 766, 952, 801, 828, 872,
771 879, 996, 884, 1128, 890, 912, 913, 948, 943, 955,
772 982, 0, 975, 0, 0, 1024, 985, 1008, 1032, 0,
773 999, 0, 1013, 1014, 1023, 1027, 1039, 1028, 1025, 0,
774 1028, 1043, 1044, 1043, 1133, 1160, 1165, 1078, 1081, 1054,
775
776 1070, 1066, 1049, 1063, 1065, 1099, 1068, 1181, 1086, 1186,
777 3371, 3371, 1189, 3371, 1079, 1085, 1089, 1104, 1107, 1192,
778 1205, 1104, 1111, 1104, 1121, 1100, 1126, 1116, 1114, 1195,
779 1210, 1152, 1226, 1233, 1240, 1160, 3371, 0, 1120, 1117,
780 1157, 0, 0, 1135, 0, 3371, 0, 1142, 3371, 0,
781 0, 1151, 0, 1156, 1159, 1199, 1175, 1161, 0, 1174,
782 1172, 1258, 1248, 1209, 1262, 1271, 1285, 1191, 3371, 3371,
783 1192, 1197, 1196, 1206, 0, 0, 1295, 1241, 1343, 0,
784 1219, 1208, 0, 1218, 1226, 1213, 1220, 1228, 1320, 1391,
785 1238, 1239, 1256, 1242, 1245, 0, 1260, 1259, 1263, 0,
786
787 0, 1263, 3371, 1258, 1264, 1256, 1264, 1338, 1436, 1275,
788 1274, 1289, 1286, 1275, 1279, 1272, 0, 1319, 1322, 1332,
789 1281, 1309, 1297, 1296, 1307, 1310, 1320, 1309, 1369, 1312,
790 0, 1308, 1325, 1313, 1407, 1429, 1414, 1381, 1348, 1481,
791 0, 1323, 1317, 1334, 1342, 1335, 3371, 1336, 0, 1377,
792 1346, 1363, 1351, 1452, 1459, 1488, 1410, 1385, 1533, 0,
793 1360, 1362, 1419, 1437, 1497, 1370, 1393, 1477, 1500, 1537,
794 1549, 1407, 3371, 1380, 0, 0, 1595, 0, 1558, 1490,
795 1492, 1623, 0, 1495, 1502, 1506, 1389, 1444, 1407, 1429,
796 1436, 1446, 1479, 1449, 1611, 1469, 1476, 1493, 1671, 1492,
797
798 1478, 3371, 1521, 0, 1616, 0, 1619, 1548, 1528, 1710,
799 0, 1555, 1538, 1541, 1492, 1541, 1512, 1520, 1533, 1535,
800 1552, 1535, 1633, 1534, 1538, 1551, 1758, 1639, 3371, 1552,
801 0, 1550, 1551, 1604, 1554, 1647, 0, 1662, 1600, 1630,
802 1557, 1618, 1571, 1586, 1590, 1610, 1621, 1614, 1678, 1651,
803 1687, 1690, 1699, 1615, 1693, 1764, 1745, 1700, 1702, 1803,
804 0, 1621, 0, 3371, 0, 1719, 1704, 1707, 1638, 1694,
805 1664, 1650, 1685, 1688, 1704, 1686, 1761, 1724, 1780, 1792,
806 1807, 1702, 1812, 1851, 1799, 1815, 1741, 1879, 0, 0,
807 1708, 1704, 1746, 1750, 1857, 1766, 1796, 1867, 1870, 1874,
808
809 1927, 0, 1889, 1869, 1805, 1955, 0, 1872, 1817, 1840,
810 1725, 1774, 1742, 1742, 1745, 1749, 1814, 1754, 1895, 2004,
811 1884, 1900, 1903, 1906, 1949, 0, 2063, 1930, 1904, 2121,
812 0, 1952, 1907, 1910, 1779, 1939, 1805, 1790, 1807, 1819,
813 1926, 1829, 2067, 1828, 1841, 1934, 2169, 1908, 2070, 0,
814 1964, 1917, 1920, 1894, 1941, 1920, 1919, 1933, 1942, 1952,
815 1941, 2073, 1976, 2076, 2084, 2088, 0, 0, 2091, 0,
816 2066, 1980, 1983, 1948, 2055, 1968, 2007, 2024, 2041, 2051,
817 2050, 2100, 2083, 2137, 2146, 2172, 2048, 2204, 2220, 2197,
818 2099, 2091, 2255, 0, 2224, 2095, 2188, 2191, 2249, 2260,
819
820 2101, 2272, 2275, 2278, 2303, 0, 2281, 2129, 2113, 2339,
821 0, 2136, 2146, 2149, 2059, 2126, 2085, 2079, 2114, 2125,
822 2153, 2131, 2308, 2387, 2355, 2429, 2362, 0, 2229, 2162,
823 2194, 2136, 2154, 2167, 2150, 2169, 2171, 2191, 2171, 2358,
824 2213, 2366, 2391, 2408, 2471, 2420, 2513, 2433, 2222, 2425,
825 2436, 2450, 2555, 2613, 2453, 2671, 2462, 2495, 2729, 2346,
826 3371, 2788, 2801, 2814, 2827, 2840, 2853, 2866, 2879, 2892,
827 2905, 2918, 2931, 2944, 2957, 2970, 2983, 2996, 3009, 3020,
828 3031, 3040, 3049, 3058, 3060, 2233, 2239, 3069, 3080, 3091,
829 3104, 3117, 3124, 3126, 3135, 2245, 2246, 2251, 3145, 2252,
830
831 2256, 3151, 3160, 2257, 2259, 2260, 2277, 2278, 2285, 2287,
832 2288, 2290, 3173, 2291, 2293
833 } ;
834
835 static yyconst flex_int16_t yy_def[1416] =
836 { 0,
837 1362, 1362, 1363, 1363, 1364, 1364, 1365, 1365, 1366, 1366,
838 1367, 1367, 1361, 13, 1361, 15, 1361, 17, 1368, 1368,
839 1361, 21, 1369, 1369, 1370, 1370, 1371, 1371, 1372, 1372,
840 1373, 1373, 1374, 1374, 1375, 1375, 1376, 1376, 1377, 1377,
841 1362, 1362, 1378, 1378, 1361, 1361, 1361, 1361, 1361, 1361,
842 1361, 1361, 1361, 1361, 1361, 1379, 1361, 1361, 1361, 1380,
843 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
844 1361, 1361, 1361, 1361, 1381, 1361, 1361, 1361, 1361, 1382,
845 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1383,
846 1384, 1385, 1361, 1361, 1361, 1361, 1386, 1361, 1361, 1361,
847
848 1361, 1361, 1361, 1361, 1387, 1361, 1361, 1361, 1361, 1361,
849 1361, 1361, 1361, 1361, 1388, 1361, 1361, 1389, 1361, 1361,
850 1361, 1361, 1361, 1361, 1390, 1361, 1361, 1361, 1361, 1361,
851 1361, 1361, 1391, 1391, 1361, 1361, 1392, 1361, 1361, 1361,
852 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1379, 1361, 1380,
853 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
854 1361, 1361, 1361, 1381, 1361, 1361, 1361, 1361, 1393, 1382,
855 1361, 1361, 1361, 1361, 1394, 1394, 1394, 1394, 1361, 1361,
856 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
857 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1361, 1361,
858
859 1361, 1361, 1361, 1361, 1383, 1383, 1384, 1385, 1361, 1361,
860 1386, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
861 1361, 1361, 1361, 1361, 1387, 1361, 1361, 1361, 1361, 1361,
862 1361, 1361, 1361, 1361, 1361, 1388, 1361, 1389, 1361, 1361,
863 1390, 1391, 1361, 1392, 1361, 1361, 1361, 1361, 1361, 1361,
864 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
865 1361, 1361, 1361, 1361, 1393, 1394, 1394, 1361, 1361, 1361,
866 1395, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
867 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
868 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
869
870 1394, 1394, 1394, 1394, 1394, 1394, 1361, 1361, 1361, 1361,
871 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
872 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
873 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
874 1361, 1361, 1395, 1361, 1394, 1394, 1394, 1394, 1394, 1394,
875 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
876 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
877 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
878 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1361,
879 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
880
881 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
882 1361, 1361, 1361, 1361, 1394, 1394, 1394, 1394, 1394, 1394,
883 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
884 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
885 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
886 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
887 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
888 1394, 1394, 1394, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
889 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
890 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1394, 1394, 1394,
891
892 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
893 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1361,
894 1361, 1361, 1361, 1396, 1394, 1394, 1394, 1394, 1394, 1394,
895 1394, 1394, 1394, 1394, 1394, 1394, 1361, 1394, 1394, 1394,
896 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
897 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
898 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
899 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1394, 1394,
900 1394, 1394, 1394, 1361, 1361, 1394, 1394, 1394, 1394, 1394,
901 1394, 1394, 1394, 1394, 1394, 1394, 1361, 1361, 1361, 1361,
902
903 1397, 1394, 1394, 1394, 523, 605, 1361, 1361, 1361, 1361,
904 1361, 1361, 1361, 1361, 1361, 1396, 1394, 1394, 1394, 1394,
905 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
906 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
907 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
908 1361, 1361, 1361, 1361, 1398, 1394, 1361, 1361, 1361, 1361,
909 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1394, 1394,
910 1394, 1394, 1394, 1361, 1361, 1394, 1394, 1394, 1394, 1394,
911 1394, 1394, 1394, 1394, 1394, 1394, 600, 687, 1361, 1361,
912 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1397, 1361, 1361,
913
914 1361, 1394, 1394, 605, 1361, 1361, 1394, 1394, 1394, 1394,
915 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
916 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
917 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 654, 739,
918 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1398,
919 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1399, 1361, 1361,
920 1361, 1361, 1394, 1394, 1394, 1394, 1394, 1361, 1394, 1394,
921 1361, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 687, 1361,
922 1361, 1397, 1397, 701, 1361, 1361, 1361, 1400, 1394, 1394,
923 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
924
925 1394, 1394, 1394, 1394, 1394, 1394, 1361, 1394, 1394, 1394,
926 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 739,
927 1361, 1361, 1398, 1398, 753, 1361, 1361, 1361, 1401, 1361,
928 1402, 1361, 1399, 1361, 1361, 1394, 1394, 1394, 1394, 1394,
929 1361, 1394, 1394, 1394, 1394, 1394, 1403, 1361, 1361, 1361,
930 1397, 1397, 787, 853, 1361, 1361, 1361, 1361, 1361, 1361,
931 1361, 1361, 1361, 1400, 1394, 1394, 1394, 1394, 1394, 1394,
932 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
933 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394,
934 1394, 1394, 1361, 1361, 1398, 1398, 828, 897, 1361, 1361,
935
936 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1401, 1402, 1361,
937 1361, 1361, 1361, 1361, 1361, 1394, 1394, 1394, 1394, 1361,
938 1361, 1361, 1394, 1394, 1394, 1394, 1403, 1361, 1361, 1397,
939 1397, 853, 1361, 1361, 1400, 935, 1361, 1394, 1394, 1394,
940 1361, 1394, 1394, 1394, 1394, 1361, 1394, 1394, 1361, 1394,
941 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1394, 1361,
942 1361, 1398, 1398, 897, 1361, 1361, 1401, 967, 1361, 1361,
943 1361, 1394, 1394, 1394, 1394, 921, 1361, 1361, 1361, 1404,
944 1361, 1394, 1394, 1394, 1394, 1361, 1361, 1361, 1397, 1397,
945 1361, 1361, 935, 935, 1394, 1394, 1361, 1394, 1394, 1394,
946
947 1394, 1394, 1361, 1394, 1394, 1361, 1361, 1398, 1398, 1361,
948 1361, 967, 967, 1361, 1394, 1394, 1394, 979, 1018, 1361,
949 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1404, 1361,
950 1394, 1394, 1394, 1361, 1361, 990, 1035, 1361, 1361, 1361,
951 1405, 1361, 1361, 935, 935, 1394, 1361, 1394, 1394, 1394,
952 1394, 1394, 1361, 1361, 1009, 1054, 1361, 1361, 1361, 1406,
953 1361, 1361, 967, 967, 1361, 1394, 1394, 1018, 1361, 1361,
954 1404, 1071, 1361, 1361, 1394, 1394, 1361, 1035, 1077, 1361,
955 1361, 1361, 1407, 1040, 1084, 1361, 1361, 1361, 1361, 1361,
956 1361, 1361, 1361, 1361, 1405, 1361, 1361, 935, 935, 1394,
957
958 1394, 1361, 1394, 1394, 1361, 1054, 1105, 1361, 1361, 1361,
959 1408, 1059, 1112, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
960 1361, 1361, 1406, 1361, 1361, 967, 967, 1361, 1361, 1394,
961 1394, 1361, 1361, 1071, 1071, 1361, 1077, 1082, 1138, 1361,
962 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1407, 1084,
963 1361, 1361, 1405, 1361, 1361, 1099, 1155, 1361, 1361, 1361,
964 1409, 1394, 1394, 1361, 1105, 1110, 1166, 1361, 1361, 1361,
965 1361, 1361, 1361, 1361, 1361, 1361, 1408, 1112, 1361, 1361,
966 1406, 1361, 1361, 1127, 1183, 1361, 1361, 1361, 1410, 1394,
967 1361, 1361, 1071, 1071, 1361, 1361, 1138, 1361, 1361, 1405,
968
969 1361, 1155, 1201, 1361, 1361, 1361, 1411, 1160, 1208, 1361,
970 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1409, 1361,
971 1166, 1361, 1361, 1406, 1361, 1183, 1225, 1361, 1361, 1361,
972 1412, 1188, 1232, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
973 1361, 1361, 1410, 1361, 1361, 1071, 1071, 1361, 1405, 1201,
974 1206, 1251, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
975 1361, 1411, 1208, 1361, 1361, 1409, 1413, 1220, 1406, 1225,
976 1230, 1271, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
977 1361, 1412, 1232, 1361, 1361, 1410, 1361, 1361, 1247, 1288,
978 1361, 1361, 1361, 1414, 1405, 1251, 1361, 1361, 1409, 1406,
979
980 1271, 1361, 1361, 1410, 1361, 1288, 1305, 1361, 1361, 1361,
981 1415, 1293, 1312, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
982 1361, 1361, 1414, 1405, 1409, 1406, 1410, 1305, 1310, 1329,
983 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1415,
984 1312, 1361, 1361, 1414, 1361, 1409, 1361, 1410, 1329, 1361,
985 1361, 1414, 1409, 1410, 1414, 1361, 1225, 1414, 1414, 1307,
986 0, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
987 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
988 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
989 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
990
991 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
992 1361, 1361, 1361, 1361, 1361
993 } ;
994
995 static yyconst flex_uint16_t yy_nxt[3432] =
996 { 0,
997 1361, 1361, 48, 48, 51, 1361, 1361, 52, 51, 108,
998 108, 52, 61, 62, 61, 57, 58, 57, 134, 53,
999 53, 53, 46, 53, 53, 53, 57, 57, 58, 57,
1000 54, 61, 62, 61, 54, 109, 109, 134, 57, 168,
1001 168, 46, 252, 1361, 135, 64, 46, 122, 65, 64,
1002 55, 273, 65, 253, 55, 274, 49, 49, 168, 168,
1003 66, 66, 66, 135, 66, 66, 66, 61, 132, 61,
1004 57, 67, 59, 132, 260, 67, 123, 138, 124, 139,
1005 369, 138, 57, 139, 59, 261, 61, 267, 61, 267,
1006 370, 68, 245, 246, 245, 68, 69, 70, 71, 72,
1007
1008 73, 74, 75, 76, 69, 69, 69, 69, 77, 78,
1009 69, 79, 79, 69, 69, 69, 73, 69, 80, 80,
1010 80, 80, 80, 69, 81, 69, 82, 80, 80, 80,
1011 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
1012 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
1013 80, 80, 83, 84, 85, 86, 87, 88, 89, 88,
1014 87, 87, 87, 90, 87, 87, 87, 87, 87, 90,
1015 87, 91, 91, 87, 90, 87, 87, 91, 91, 91,
1016 91, 91, 91, 87, 92, 87, 90, 91, 91, 91,
1017 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
1018
1019 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
1020 91, 91, 93, 87, 87, 87, 94, 95, 96, 95,
1021 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
1022 94, 94, 94, 94, 94, 94, 94, 94, 97, 97,
1023 97, 97, 97, 94, 94, 94, 94, 97, 97, 97,
1024 97, 97, 97, 97, 97, 97, 97, 97, 97, 97,
1025 97, 97, 97, 97, 97, 97, 97, 97, 97, 97,
1026 97, 97, 98, 94, 94, 94, 100, 152, 141, 100,
1027 142, 270, 143, 144, 145, 887, 289, 888, 278, 146,
1028 290, 101, 101, 101, 101, 101, 101, 279, 271, 281,
1029
1030 267, 206, 102, 272, 267, 102, 889, 206, 305, 153,
1031 282, 154, 206, 155, 156, 157, 302, 275, 276, 303,
1032 158, 306, 103, 277, 206, 103, 104, 104, 46, 104,
1033 104, 104, 104, 104, 104, 104, 104, 104, 104, 104,
1034 104, 104, 104, 104, 104, 104, 104, 104, 105, 105,
1035 105, 105, 105, 104, 104, 104, 104, 105, 105, 105,
1036 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
1037 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
1038 105, 105, 104, 104, 106, 104, 111, 890, 46, 111,
1039 116, 117, 116, 116, 117, 116, 119, 120, 119, 319,
1040
1041 46, 112, 112, 112, 112, 112, 112, 119, 120, 119,
1042 320, 46, 113, 122, 200, 113, 200, 201, 202, 202,
1043 283, 201, 202, 202, 292, 128, 284, 228, 293, 307,
1044 307, 891, 114, 333, 705, 114, 128, 294, 328, 308,
1045 202, 202, 123, 705, 124, 116, 334, 116, 116, 329,
1046 116, 119, 892, 119, 129, 229, 130, 230, 358, 231,
1047 232, 233, 119, 359, 119, 129, 234, 130, 171, 171,
1048 309, 172, 171, 171, 173, 171, 174, 171, 171, 171,
1049 171, 171, 171, 171, 171, 171, 171, 171, 171, 175,
1050 176, 175, 175, 177, 178, 179, 180, 171, 171, 181,
1051
1052 182, 183, 184, 185, 186, 175, 187, 188, 189, 190,
1053 175, 191, 192, 193, 175, 194, 195, 196, 197, 198,
1054 175, 175, 175, 175, 171, 171, 171, 171, 203, 912,
1055 203, 209, 209, 209, 209, 209, 209, 212, 212, 212,
1056 217, 268, 269, 268, 268, 269, 268, 337, 218, 420,
1057 219, 421, 220, 221, 222, 268, 269, 268, 422, 223,
1058 338, 268, 269, 268, 203, 206, 203, 267, 268, 269,
1059 268, 206, 213, 209, 209, 209, 206, 388, 214, 245,
1060 246, 245, 389, 204, 379, 215, 210, 216, 206, 210,
1061 705, 287, 212, 212, 212, 390, 390, 285, 269, 288,
1062
1063 380, 269, 267, 295, 296, 297, 705, 298, 212, 212,
1064 212, 553, 269, 299, 245, 246, 245, 844, 269, 204,
1065 267, 300, 301, 307, 307, 269, 554, 213, 210, 341,
1066 342, 341, 845, 214, 268, 269, 268, 915, 361, 362,
1067 215, 355, 216, 213, 397, 356, 357, 372, 402, 214,
1068 363, 780, 415, 309, 373, 416, 215, 398, 216, 374,
1069 780, 403, 341, 342, 341, 442, 459, 443, 417, 464,
1070 418, 447, 448, 444, 460, 469, 390, 390, 465, 532,
1071 445, 466, 461, 487, 487, 487, 342, 916, 470, 449,
1072 917, 269, 918, 533, 534, 520, 520, 520, 487, 487,
1073
1074 487, 573, 573, 573, 581, 521, 309, 521, 522, 523,
1075 523, 919, 582, 584, 584, 584, 597, 597, 597, 342,
1076 605, 605, 524, 522, 523, 523, 598, 619, 598, 599,
1077 600, 600, 520, 520, 520, 620, 639, 922, 488, 923,
1078 640, 924, 521, 601, 521, 522, 523, 523, 651, 651,
1079 651, 574, 925, 488, 641, 659, 659, 659, 652, 524,
1080 652, 653, 654, 654, 573, 573, 573, 926, 585, 606,
1081 606, 606, 584, 584, 584, 655, 674, 674, 674, 597,
1082 597, 597, 607, 523, 523, 599, 600, 600, 928, 598,
1083 929, 598, 599, 600, 600, 687, 687, 1361, 605, 605,
1084
1085 608, 609, 610, 611, 1361, 1361, 601, 612, 790, 675,
1086 613, 933, 660, 614, 574, 791, 615, 704, 704, 706,
1087 706, 706, 699, 699, 699, 739, 739, 585, 688, 688,
1088 688, 700, 653, 654, 654, 933, 651, 651, 651, 1361,
1089 1361, 689, 600, 600, 779, 779, 652, 847, 652, 653,
1090 654, 654, 1361, 687, 687, 780, 754, 754, 754, 690,
1091 691, 692, 693, 655, 704, 704, 694, 1361, 1361, 695,
1092 933, 780, 696, 820, 820, 697, 848, 701, 740, 740,
1093 740, 751, 751, 751, 659, 659, 659, 781, 781, 781,
1094 752, 741, 654, 654, 757, 757, 757, 674, 674, 674,
1095
1096 699, 699, 699, 699, 699, 699, 706, 706, 706, 742,
1097 743, 744, 745, 755, 821, 933, 746, 779, 779, 747,
1098 758, 933, 748, 821, 821, 749, 853, 853, 782, 933,
1099 675, 783, 784, 784, 784, 938, 753, 706, 706, 706,
1100 821, 660, 785, 939, 785, 786, 787, 787, 1361, 739,
1101 739, 822, 822, 822, 940, 701, 820, 820, 701, 788,
1102 751, 751, 751, 751, 751, 751, 825, 825, 825, 754,
1103 754, 754, 830, 830, 830, 941, 826, 942, 826, 827,
1104 828, 828, 757, 757, 757, 933, 781, 781, 781, 786,
1105 787, 787, 823, 829, 933, 824, 897, 897, 831, 781,
1106
1107 781, 781, 943, 781, 781, 781, 1361, 1361, 758, 781,
1108 781, 781, 827, 828, 828, 753, 932, 932, 753, 822,
1109 822, 822, 830, 830, 830, 944, 755, 849, 945, 933,
1110 850, 822, 822, 822, 946, 822, 822, 822, 947, 948,
1111 849, 851, 949, 850, 782, 933, 950, 783, 831, 852,
1112 782, 951, 952, 783, 854, 854, 854, 910, 910, 910,
1113 893, 953, 954, 894, 822, 822, 822, 855, 787, 787,
1114 955, 956, 893, 895, 957, 894, 823, 958, 959, 824,
1115 913, 913, 913, 960, 961, 856, 857, 858, 859, 920,
1116 920, 920, 860, 1361, 1361, 861, 964, 964, 862, 965,
1117
1118 965, 863, 965, 965, 896, 823, 965, 965, 824, 898,
1119 898, 898, 965, 965, 911, 970, 781, 781, 781, 1361,
1120 853, 853, 899, 828, 828, 781, 781, 781, 971, 934,
1121 934, 934, 965, 972, 822, 822, 822, 914, 973, 974,
1122 900, 901, 902, 903, 921, 975, 981, 904, 965, 982,
1123 905, 983, 984, 906, 985, 986, 907, 782, 930, 987,
1124 783, 822, 822, 822, 988, 995, 782, 932, 932, 783,
1125 935, 996, 997, 936, 931, 823, 962, 998, 824, 1361,
1126 897, 897, 966, 966, 966, 999, 937, 910, 910, 910,
1127 913, 913, 913, 920, 920, 920, 781, 781, 781, 864,
1128
1129 1000, 994, 823, 1001, 1002, 824, 976, 976, 976, 1003,
1130 963, 781, 781, 781, 1004, 1005, 977, 1006, 977, 978,
1131 979, 979, 1007, 967, 964, 964, 968, 934, 934, 934,
1132 908, 1014, 1013, 980, 934, 934, 934, 782, 1015, 969,
1133 783, 934, 934, 934, 911, 989, 1016, 914, 921, 822,
1134 822, 822, 782, 1017, 1030, 783, 1018, 1018, 990, 822,
1135 822, 822, 1031, 966, 966, 966, 1032, 1033, 991, 848,
1136 1034, 992, 966, 966, 966, 991, 1035, 1042, 992, 993,
1137 1043, 864, 935, 1046, 937, 936, 966, 966, 966, 1047,
1138 823, 937, 1045, 824, 1048, 864, 1009, 1049, 937, 1044,
1139
1140 823, 1050, 1051, 824, 1010, 1052, 1053, 1011, 1008, 978,
1141 979, 979, 1054, 1010, 1061, 1062, 1011, 1065, 1066, 1067,
1142 969, 781, 781, 781, 1012, 908, 1069, 967, 908, 969,
1143 968, 1069, 1063, 1361, 1018, 1018, 1064, 1361, 1361, 822,
1144 822, 822, 1069, 969, 1019, 1019, 1019, 1068, 1068, 1069,
1145 1069, 1069, 1069, 1069, 1069, 1074, 1075, 1020, 979, 979,
1146 1076, 1077, 782, 1084, 1084, 783, 1096, 1097, 1036, 1069,
1147 1070, 1070, 1070, 864, 1100, 1021, 1022, 1023, 1024, 1101,
1148 823, 864, 1025, 824, 1098, 1026, 1055, 1102, 1027, 1103,
1149 1099, 1028, 1037, 1037, 1037, 1039, 1040, 1040, 1104, 1105,
1150
1151 1112, 1112, 1038, 1124, 1038, 1039, 1040, 1040, 1078, 1078,
1152 1078, 1071, 1125, 1130, 1072, 1037, 1037, 1037, 1038, 1041,
1153 1038, 1039, 1040, 1040, 1058, 1059, 1059, 1073, 1131, 1136,
1154 1079, 1079, 1079, 782, 1151, 1041, 783, 1056, 1056, 1056,
1155 1080, 1151, 1080, 1081, 1082, 1082, 1029, 1057, 1135, 1057,
1156 1058, 1059, 1059, 1106, 1106, 1106, 849, 1083, 908, 850,
1157 1107, 1107, 1107, 1057, 1060, 1057, 1058, 1059, 1059, 1126,
1158 1108, 1151, 1108, 1109, 1110, 1110, 908, 1151, 823, 1151,
1159 1060, 824, 1085, 1085, 1085, 1127, 1151, 1111, 1151, 1056,
1160 1056, 1056, 1068, 1068, 1151, 1086, 1040, 1040, 1128, 1128,
1161
1162 1128, 1070, 1070, 1070, 1081, 1082, 1082, 1138, 1138, 1361,
1163 1084, 1084, 1151, 1087, 1088, 1089, 1090, 1361, 1361, 1154,
1164 1091, 1150, 1150, 1092, 1155, 1162, 1093, 1163, 1151, 1094,
1165 893, 1164, 864, 894, 1113, 1113, 1113, 1179, 1070, 1070,
1166 1070, 1156, 1132, 1166, 1166, 1133, 1179, 1114, 1059, 1059,
1167 1070, 1070, 1070, 1361, 1361, 1129, 1178, 1178, 1073, 1079,
1168 1079, 1079, 1109, 1110, 1110, 1115, 1116, 1117, 1118, 1361,
1169 1112, 1112, 1119, 1179, 1179, 1120, 1179, 1179, 1121, 1132,
1170 1179, 1122, 1133, 1179, 1182, 1179, 1183, 1190, 1134, 1191,
1171 908, 1071, 1192, 1029, 1072, 1073, 1137, 1137, 1137, 1184,
1172
1173 849, 1179, 1198, 850, 1194, 1198, 1080, 1073, 1080, 1081,
1174 1082, 1082, 1152, 1152, 1152, 1361, 1361, 1165, 1165, 1165,
1175 1107, 1107, 1107, 1083, 1139, 1139, 1139, 1108, 1198, 1108,
1176 1109, 1110, 1110, 1198, 1180, 1180, 1180, 1140, 1082, 1082,
1177 1128, 1128, 1128, 1029, 1111, 1197, 1197, 1193, 1195, 1195,
1178 1195, 1198, 1198, 1153, 1198, 1141, 1142, 1143, 1144, 1198,
1179 1198, 893, 1145, 1201, 894, 1146, 1150, 1150, 1147, 1220,
1180 1198, 1148, 1157, 1157, 1157, 1181, 1361, 1138, 1138, 1199,
1181 1199, 1199, 1158, 1222, 1158, 1159, 1160, 1160, 1152, 1152,
1182 1152, 1152, 1152, 1152, 1202, 1202, 1202, 1129, 1222, 1161,
1183
1184 1152, 1152, 1152, 1222, 1158, 1196, 1158, 1159, 1160, 1160,
1185 864, 1167, 1167, 1167, 1159, 1160, 1160, 1208, 1208, 1361,
1186 1361, 1161, 1221, 1221, 1168, 1110, 1110, 1222, 1222, 849,
1187 1222, 1222, 849, 1361, 1166, 1166, 1222, 1222, 1200, 1178,
1188 1178, 1153, 1169, 1170, 1171, 1172, 1157, 1157, 1157, 1173,
1189 1225, 1244, 1174, 1222, 1245, 1175, 1232, 1232, 1176, 1185,
1190 1185, 1185, 1223, 1223, 1223, 1203, 1203, 1203, 1248, 1186,
1191 1264, 1186, 1187, 1188, 1188, 1204, 1264, 1204, 1205, 1206,
1192 1206, 1180, 1180, 1180, 1264, 1029, 1189, 991, 1264, 1029,
1193 992, 1264, 1207, 1180, 1180, 1180, 1246, 908, 1247, 1264,
1194
1195 1185, 1185, 1185, 937, 1209, 1209, 1209, 1264, 1180, 1180,
1196 1180, 1197, 1197, 1226, 1226, 1226, 1264, 1210, 1160, 1160,
1197 1251, 1251, 893, 1186, 1284, 1186, 1187, 1188, 1188, 1187,
1198 1188, 1188, 1361, 1361, 893, 1211, 1212, 1213, 1214, 1284,
1199 1189, 1010, 1215, 1284, 1011, 1216, 1224, 1264, 1217, 1181,
1200 1284, 1218, 1227, 1227, 1227, 1263, 1263, 969, 1195, 1195,
1201 1195, 1284, 1228, 1264, 1228, 1229, 1230, 1230, 1199, 1199,
1202 1199, 1199, 1199, 1199, 1284, 1152, 1152, 1152, 1287, 1231,
1203 1233, 1233, 1233, 1205, 1206, 1206, 1361, 1208, 1208, 1288,
1204 1203, 1203, 1203, 1234, 1188, 1188, 1265, 1265, 1265, 1221,
1205
1206 1221, 1223, 1223, 1223, 1223, 1223, 1223, 1180, 1180, 1180,
1207 1248, 1235, 1236, 1237, 1238, 1196, 1153, 1249, 1239, 1271,
1208 1271, 1240, 1361, 1361, 1241, 1283, 1283, 1242, 1250, 1250,
1209 1250, 991, 1361, 1361, 992, 1296, 1296, 1266, 1204, 1297,
1210 1204, 1205, 1206, 1206, 1229, 1230, 1230, 937, 1181, 1269,
1211 1270, 1270, 1270, 937, 1297, 1207, 1252, 1252, 1252, 1284,
1212 1228, 1297, 1228, 1229, 1230, 1230, 1361, 1232, 1232, 1253,
1213 1206, 1206, 1284, 1029, 1297, 1284, 1297, 1231, 1361, 1251,
1214 1251, 1284, 1289, 1297, 1297, 1297, 1297, 1254, 1255, 1256,
1215 1257, 1263, 1263, 1302, 1258, 1361, 1361, 1259, 1301, 1301,
1216
1217 1260, 1297, 1302, 1261, 1267, 1267, 1267, 1267, 1267, 1267,
1218 1267, 1267, 1267, 1267, 1267, 1267, 1267, 1267, 1267, 1267,
1219 1267, 1267, 1267, 1267, 1267, 1268, 1268, 1268, 1268, 1268,
1220 1268, 1267, 1267, 1267, 1267, 1268, 1268, 1268, 1268, 1268,
1221 1268, 1268, 1268, 1268, 1268, 1268, 1268, 1268, 1268, 1268,
1222 1268, 1268, 1268, 1268, 1268, 1268, 1268, 1268, 1268, 1268,
1223 1302, 1267, 1267, 1267, 1227, 1227, 1227, 1302, 1285, 1285,
1224 1285, 1152, 1152, 1152, 1298, 1298, 1298, 1265, 1265, 1265,
1225 1361, 1271, 1271, 1302, 1302, 1265, 1265, 1265, 1302, 1265,
1226 1265, 1265, 1180, 1180, 1180, 1302, 1305, 1302, 1283, 1283,
1227
1228 1302, 1303, 1303, 1303, 1342, 1010, 1312, 1312, 1011, 1286,
1229 1296, 1296, 1153, 1292, 1293, 1293, 1301, 1301, 991, 1342,
1230 1295, 969, 1272, 1272, 1272, 969, 991, 1299, 1329, 1329,
1231 1266, 937, 1342, 1181, 937, 1273, 1230, 1230, 1285, 1285,
1232 1285, 1300, 937, 1309, 1310, 1310, 937, 1285, 1285, 1285,
1233 1361, 1312, 1312, 1274, 1275, 1276, 1277, 1342, 969, 1342,
1234 1278, 1361, 1361, 1279, 1341, 1341, 1280, 1342, 1342, 1281,
1235 1290, 1290, 1290, 1285, 1285, 1285, 1342, 1361, 1361, 1010,
1236 1291, 1350, 1291, 1292, 1293, 1293, 1342, 1350, 1010, 1298,
1237 1298, 1298, 1298, 1298, 1298, 969, 1350, 1294, 1290, 1290,
1238
1239 1290, 1350, 1342, 1350, 969, 1306, 1306, 1306, 1029, 1349,
1240 1349, 1304, 1350, 1350, 1286, 1291, 1350, 1291, 1292, 1293,
1241 1293, 1307, 1307, 1307, 1350, 1152, 1152, 1152, 1341, 1341,
1242 969, 1308, 1294, 1308, 1309, 1310, 1310, 1349, 1349, 1132,
1243 1350, 211, 1133, 1361, 1329, 1329, 937, 225, 1311, 937,
1244 1265, 1265, 1265, 616, 698, 1073, 1313, 1313, 1313, 750,
1245 864, 1180, 1180, 1180, 908, 1029, 1153, 1095, 1123, 1314,
1246 1293, 1293, 1324, 1303, 1303, 1303, 1303, 1303, 1303, 1285,
1247 1285, 1285, 1307, 1307, 1307, 1149, 1177, 1315, 1316, 1317,
1248 1318, 1266, 1325, 1219, 1319, 1243, 1262, 1320, 1282, 1323,
1249
1250 1321, 1340, 1181, 1322, 1328, 1328, 1328, 937, 1326, 1343,
1251 1343, 1343, 886, 885, 1308, 884, 1308, 1309, 1310, 1310,
1252 1286, 1327, 883, 1132, 882, 881, 1133, 880, 879, 878,
1253 969, 1311, 877, 969, 876, 875, 969, 874, 873, 1073,
1254 1330, 1330, 1330, 872, 871, 870, 869, 1360, 1360, 1360,
1255 1344, 868, 867, 1331, 1310, 1310, 1265, 1265, 1265, 1351,
1256 1351, 1351, 866, 1285, 1285, 1285, 1073, 1343, 1343, 1343,
1257 865, 1332, 1333, 1334, 1335, 846, 843, 842, 1336, 841,
1258 840, 1337, 839, 838, 1338, 837, 836, 1339, 1345, 1345,
1259 1345, 1361, 1343, 1343, 1343, 835, 324, 1266, 1080, 315,
1260
1261 1080, 1081, 1082, 1082, 1286, 1346, 834, 832, 1132, 1343,
1262 1343, 1343, 1348, 937, 821, 1083, 1073, 821, 821, 821,
1263 969, 1265, 1265, 1265, 1073, 821, 1351, 1351, 1351, 1153,
1264 1347, 1347, 1347, 1132, 1285, 1285, 1285, 1351, 1351, 1351,
1265 1108, 821, 1108, 1109, 1110, 1110, 819, 1352, 818, 1073,
1266 1344, 1343, 1343, 1343, 1343, 1343, 1343, 1111, 817, 816,
1267 815, 814, 1266, 1357, 1357, 1357, 1073, 813, 1353, 812,
1268 811, 1181, 1345, 1345, 1345, 1286, 810, 809, 937, 808,
1269 807, 1354, 1080, 1073, 1080, 1081, 1082, 1082, 806, 805,
1270 804, 969, 1344, 1355, 1073, 1344, 1343, 1343, 1343, 1083,
1271
1272 803, 802, 801, 1358, 1010, 800, 799, 798, 1073, 797,
1273 796, 1073, 795, 849, 1347, 1347, 1347, 794, 793, 792,
1274 969, 789, 780, 780, 1108, 780, 1108, 1109, 1110, 1110,
1275 780, 780, 780, 778, 777, 776, 775, 1344, 774, 773,
1276 772, 1111, 771, 1359, 770, 769, 768, 767, 766, 765,
1277 764, 763, 256, 1073, 248, 893, 1356, 1356, 1356, 762,
1278 324, 761, 315, 760, 759, 756, 1204, 738, 1204, 1205,
1279 1206, 1206, 737, 736, 735, 734, 733, 732, 731, 730,
1280 729, 728, 727, 1207, 726, 725, 724, 723, 722, 721,
1281 720, 719, 718, 717, 716, 715, 714, 1266, 713, 712,
1282
1283 711, 710, 709, 708, 707, 705, 705, 705, 705, 705,
1284 705, 703, 702, 937, 1357, 1357, 1357, 686, 685, 684,
1285 683, 682, 681, 680, 1228, 679, 1228, 1229, 1230, 1230,
1286 678, 677, 676, 673, 672, 671, 670, 669, 256, 668,
1287 248, 1231, 667, 666, 665, 324, 664, 324, 663, 315,
1288 662, 315, 661, 658, 657, 1286, 656, 650, 649, 648,
1289 647, 646, 645, 644, 643, 642, 638, 637, 636, 635,
1290 634, 969, 1356, 1356, 1356, 633, 632, 631, 630, 629,
1291 628, 627, 1204, 626, 1204, 1205, 1206, 1206, 625, 624,
1292 623, 622, 621, 618, 617, 604, 603, 602, 596, 1207,
1293
1294 595, 594, 593, 592, 591, 590, 589, 588, 587, 586,
1295 583, 580, 579, 991, 578, 256, 577, 256, 576, 248,
1296 575, 248, 572, 571, 570, 569, 568, 567, 566, 937,
1297 1360, 1360, 1360, 565, 564, 563, 562, 561, 560, 559,
1298 1308, 558, 1308, 1309, 1310, 1310, 557, 556, 555, 552,
1299 551, 550, 549, 548, 547, 546, 545, 1311, 544, 543,
1300 542, 541, 540, 539, 538, 537, 536, 535, 531, 530,
1301 529, 1344, 528, 527, 526, 525, 519, 518, 517, 516,
1302 515, 514, 513, 512, 511, 510, 509, 1073, 46, 46,
1303 46, 46, 46, 46, 46, 46, 46, 46, 46, 46,
1304
1305 46, 47, 47, 47, 47, 47, 47, 47, 47, 47,
1306 47, 47, 47, 47, 50, 50, 50, 50, 50, 50,
1307 50, 50, 50, 50, 50, 50, 50, 56, 56, 56,
1308 56, 56, 56, 56, 56, 56, 56, 56, 56, 56,
1309 60, 60, 60, 60, 60, 60, 60, 60, 60, 60,
1310 60, 60, 60, 63, 63, 63, 63, 63, 63, 63,
1311 63, 63, 63, 63, 63, 63, 99, 99, 99, 99,
1312 99, 99, 99, 99, 99, 99, 99, 99, 99, 107,
1313 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
1314 107, 107, 110, 110, 110, 110, 110, 110, 110, 110,
1315
1316 110, 110, 110, 110, 110, 115, 115, 115, 115, 115,
1317 115, 115, 115, 115, 115, 115, 115, 115, 118, 118,
1318 118, 118, 118, 118, 118, 118, 118, 118, 118, 118,
1319 118, 121, 121, 121, 121, 121, 121, 121, 121, 121,
1320 121, 121, 121, 121, 125, 125, 125, 125, 125, 125,
1321 125, 125, 125, 125, 125, 125, 125, 127, 127, 127,
1322 127, 127, 127, 127, 127, 127, 127, 127, 127, 127,
1323 131, 131, 131, 131, 131, 131, 131, 131, 131, 131,
1324 131, 131, 131, 133, 133, 133, 133, 133, 133, 133,
1325 133, 133, 133, 133, 133, 133, 137, 137, 137, 137,
1326
1327 137, 137, 137, 137, 137, 137, 137, 137, 137, 148,
1328 508, 507, 148, 148, 506, 148, 148, 148, 148, 148,
1329 150, 505, 504, 150, 150, 150, 150, 150, 150, 150,
1330 150, 164, 164, 503, 164, 164, 164, 164, 164, 164,
1331 164, 164, 164, 164, 170, 502, 501, 500, 170, 205,
1332 499, 498, 205, 205, 205, 205, 205, 205, 205, 205,
1333 497, 205, 207, 496, 207, 207, 207, 208, 208, 236,
1334 495, 494, 236, 236, 236, 236, 236, 236, 236, 236,
1335 238, 493, 492, 238, 238, 238, 238, 238, 238, 238,
1336 238, 241, 241, 241, 241, 241, 241, 241, 241, 241,
1337
1338 241, 491, 241, 241, 242, 242, 242, 242, 242, 242,
1339 242, 242, 242, 490, 242, 242, 242, 244, 244, 244,
1340 244, 244, 244, 244, 244, 244, 244, 244, 265, 489,
1341 486, 485, 265, 266, 266, 343, 343, 343, 343, 343,
1342 343, 343, 343, 343, 343, 343, 343, 343, 833, 484,
1343 483, 482, 481, 833, 909, 480, 479, 478, 477, 909,
1344 927, 927, 927, 927, 927, 927, 927, 927, 927, 927,
1345 476, 927, 927, 1267, 1267, 1267, 1267, 1267, 1267, 1267,
1346 1267, 1267, 1267, 1267, 475, 1267, 474, 473, 472, 471,
1347 468, 467, 463, 462, 458, 457, 456, 455, 454, 453,
1348
1349 452, 451, 450, 446, 441, 440, 439, 438, 437, 436,
1350 435, 434, 433, 432, 431, 430, 429, 428, 427, 426,
1351 425, 424, 423, 419, 344, 414, 413, 412, 411, 410,
1352 409, 408, 407, 406, 405, 404, 324, 324, 401, 324,
1353 324, 400, 399, 315, 315, 396, 315, 315, 395, 394,
1354 393, 392, 391, 387, 386, 385, 384, 383, 382, 381,
1355 378, 377, 376, 375, 371, 368, 367, 366, 365, 364,
1356 360, 354, 353, 352, 351, 350, 349, 348, 347, 346,
1357 345, 344, 271, 1361, 340, 339, 256, 256, 336, 256,
1358 256, 335, 248, 248, 332, 248, 248, 331, 239, 237,
1359
1360 330, 327, 326, 325, 324, 323, 322, 226, 321, 318,
1361 317, 316, 315, 314, 313, 312, 311, 310, 204, 304,
1362 291, 286, 280, 169, 169, 264, 263, 160, 262, 259,
1363 258, 257, 256, 255, 151, 149, 254, 251, 250, 249,
1364 248, 247, 243, 240, 239, 237, 235, 227, 226, 224,
1365 204, 199, 169, 167, 166, 165, 163, 162, 161, 160,
1366 159, 151, 149, 147, 140, 1361, 136, 136, 126, 126,
1367 45, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1368 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1369 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1370
1371 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1372 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1373 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1374 1361
1375 } ;
1376
1377 static yyconst flex_int16_t yy_chk[3432] =
1378 { 0,
1379 0, 0, 3, 4, 5, 0, 0, 5, 6, 23,
1380 24, 6, 9, 9, 9, 7, 7, 7, 39, 5,
1381 5, 5, 31, 6, 6, 6, 7, 8, 8, 8,
1382 5, 10, 10, 10, 6, 23, 24, 40, 8, 79,
1383 79, 37, 146, 0, 39, 11, 38, 31, 11, 12,
1384 5, 182, 12, 146, 6, 182, 3, 4, 168, 168,
1385 11, 11, 11, 40, 12, 12, 12, 9, 37, 9,
1386 7, 11, 7, 38, 158, 12, 31, 43, 31, 43,
1387 291, 44, 8, 44, 8, 158, 10, 176, 10, 176,
1388 291, 11, 139, 139, 139, 12, 13, 13, 13, 13,
1389
1390 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
1391 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
1392 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
1393 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
1394 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
1395 13, 13, 13, 13, 13, 13, 15, 15, 15, 15,
1396 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
1397 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
1398 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
1399 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
1400
1401 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
1402 15, 15, 15, 15, 15, 15, 17, 17, 17, 17,
1403 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
1404 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
1405 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
1406 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
1407 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
1408 17, 17, 17, 17, 17, 17, 19, 67, 54, 20,
1409 54, 180, 54, 54, 54, 814, 191, 815, 184, 54,
1410 191, 19, 19, 19, 20, 20, 20, 184, 180, 186,
1411
1412 181, 91, 19, 181, 181, 20, 816, 91, 198, 67,
1413 186, 67, 91, 67, 67, 67, 196, 183, 183, 196,
1414 67, 198, 19, 183, 91, 20, 21, 21, 21, 21,
1415 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
1416 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
1417 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
1418 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
1419 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
1420 21, 21, 21, 21, 21, 21, 25, 817, 32, 26,
1421 27, 27, 27, 28, 28, 28, 29, 29, 29, 223,
1422
1423 35, 25, 25, 25, 26, 26, 26, 30, 30, 30,
1424 223, 36, 25, 32, 83, 26, 83, 83, 83, 83,
1425 187, 200, 200, 200, 194, 35, 187, 113, 194, 201,
1426 201, 818, 25, 253, 609, 26, 36, 194, 234, 202,
1427 202, 202, 32, 609, 32, 27, 253, 27, 28, 234,
1428 28, 29, 819, 29, 35, 113, 35, 113, 283, 113,
1429 113, 113, 30, 283, 30, 36, 113, 36, 81, 81,
1430 202, 81, 81, 81, 81, 81, 81, 81, 81, 81,
1431 81, 81, 81, 81, 81, 81, 81, 81, 81, 81,
1432 81, 81, 81, 81, 81, 81, 81, 81, 81, 81,
1433
1434 81, 81, 81, 81, 81, 81, 81, 81, 81, 81,
1435 81, 81, 81, 81, 81, 81, 81, 81, 81, 81,
1436 81, 81, 81, 81, 81, 81, 81, 81, 88, 833,
1437 88, 95, 95, 95, 96, 96, 96, 98, 98, 98,
1438 102, 177, 177, 177, 178, 178, 178, 261, 102, 347,
1439 102, 347, 102, 102, 102, 188, 188, 188, 347, 102,
1440 261, 190, 190, 190, 203, 207, 203, 178, 192, 192,
1441 192, 207, 98, 209, 209, 209, 207, 306, 98, 245,
1442 245, 245, 306, 88, 298, 98, 95, 98, 207, 96,
1443 614, 190, 210, 210, 210, 308, 308, 188, 177, 190,
1444
1445 298, 178, 192, 195, 195, 195, 614, 195, 212, 212,
1446 212, 466, 188, 195, 246, 246, 246, 774, 190, 203,
1447 195, 195, 195, 307, 307, 192, 466, 210, 209, 267,
1448 267, 267, 774, 210, 268, 268, 268, 835, 285, 285,
1449 210, 282, 210, 212, 320, 282, 282, 293, 329, 212,
1450 285, 691, 345, 307, 293, 345, 212, 320, 212, 293,
1451 691, 329, 341, 341, 341, 368, 380, 368, 345, 383,
1452 345, 370, 370, 368, 380, 386, 390, 390, 383, 446,
1453 368, 383, 380, 405, 405, 405, 267, 836, 386, 370,
1454 837, 268, 838, 446, 446, 438, 438, 438, 487, 487,
1455
1456 487, 488, 488, 488, 500, 438, 390, 438, 438, 438,
1457 438, 839, 500, 502, 502, 502, 514, 514, 514, 341,
1458 522, 522, 438, 521, 521, 521, 514, 528, 514, 514,
1459 514, 514, 520, 520, 520, 528, 548, 841, 405, 842,
1460 548, 843, 520, 514, 520, 520, 520, 520, 559, 559,
1461 559, 488, 844, 487, 548, 563, 563, 563, 559, 520,
1462 559, 559, 559, 559, 573, 573, 573, 845, 502, 523,
1463 523, 523, 584, 584, 584, 559, 585, 585, 585, 597,
1464 597, 597, 523, 523, 523, 598, 598, 598, 849, 597,
1465 850, 597, 597, 597, 597, 599, 599, 605, 605, 605,
1466
1467 523, 523, 523, 523, 606, 606, 597, 523, 703, 585,
1468 523, 856, 563, 523, 573, 703, 523, 607, 607, 616,
1469 616, 616, 602, 602, 602, 653, 653, 584, 600, 600,
1470 600, 602, 652, 652, 652, 858, 651, 651, 651, 688,
1471 688, 600, 600, 600, 689, 689, 651, 778, 651, 651,
1472 651, 651, 687, 687, 687, 696, 657, 657, 657, 600,
1473 600, 600, 600, 651, 704, 704, 600, 740, 740, 600,
1474 859, 696, 600, 741, 741, 600, 778, 602, 654, 654,
1475 654, 656, 656, 656, 659, 659, 659, 698, 698, 698,
1476 656, 654, 654, 654, 660, 660, 660, 674, 674, 674,
1477
1478 699, 699, 699, 700, 700, 700, 705, 705, 705, 654,
1479 654, 654, 654, 657, 743, 860, 654, 779, 779, 654,
1480 660, 861, 654, 743, 748, 654, 786, 786, 698, 863,
1481 674, 698, 701, 701, 701, 865, 656, 706, 706, 706,
1482 748, 659, 701, 866, 701, 701, 701, 701, 739, 739,
1483 739, 750, 750, 750, 867, 699, 820, 820, 700, 701,
1484 751, 751, 751, 752, 752, 752, 753, 753, 753, 754,
1485 754, 754, 755, 755, 755, 868, 753, 869, 753, 753,
1486 753, 753, 757, 757, 757, 857, 780, 780, 780, 785,
1487 785, 785, 750, 753, 857, 750, 827, 827, 755, 781,
1488
1489 781, 781, 870, 782, 782, 782, 854, 854, 757, 783,
1490 783, 783, 826, 826, 826, 751, 855, 855, 752, 821,
1491 821, 821, 830, 830, 830, 871, 754, 780, 873, 862,
1492 780, 822, 822, 822, 876, 823, 823, 823, 877, 878,
1493 781, 782, 879, 781, 782, 862, 881, 782, 830, 783,
1494 783, 883, 884, 783, 787, 787, 787, 832, 832, 832,
1495 821, 885, 886, 821, 824, 824, 824, 787, 787, 787,
1496 887, 888, 822, 823, 889, 822, 823, 891, 892, 823,
1497 834, 834, 834, 893, 894, 787, 787, 787, 787, 840,
1498 840, 840, 787, 898, 898, 787, 899, 899, 787, 900,
1499
1500 902, 787, 903, 901, 824, 824, 904, 905, 824, 828,
1501 828, 828, 901, 907, 832, 909, 851, 851, 851, 853,
1502 853, 853, 828, 828, 828, 852, 852, 852, 915, 864,
1503 864, 864, 906, 916, 895, 895, 895, 834, 917, 918,
1504 828, 828, 828, 828, 840, 919, 922, 828, 906, 923,
1505 828, 924, 925, 828, 926, 927, 828, 851, 851, 928,
1506 851, 896, 896, 896, 929, 939, 852, 932, 932, 852,
1507 864, 940, 941, 864, 852, 895, 895, 944, 895, 897,
1508 897, 897, 908, 908, 908, 948, 864, 910, 910, 910,
1509 913, 913, 913, 920, 920, 920, 930, 930, 930, 936,
1510
1511 952, 936, 896, 954, 955, 896, 921, 921, 921, 956,
1512 896, 931, 931, 931, 957, 958, 921, 960, 921, 921,
1513 921, 921, 961, 908, 964, 964, 908, 933, 933, 933,
1514 968, 971, 968, 921, 934, 934, 934, 930, 972, 908,
1515 930, 935, 935, 935, 910, 930, 973, 913, 920, 963,
1516 963, 963, 931, 974, 981, 931, 978, 978, 931, 962,
1517 962, 962, 982, 965, 965, 965, 984, 985, 933, 986,
1518 987, 933, 966, 966, 966, 934, 988, 991, 934, 935,
1519 992, 994, 935, 995, 933, 935, 967, 967, 967, 997,
1520 963, 934, 994, 963, 998, 993, 963, 999, 935, 993,
1521
1522 962, 1002, 1004, 962, 965, 1005, 1006, 965, 962, 977,
1523 977, 977, 1007, 966, 1010, 1011, 966, 1014, 1015, 1016,
1524 965, 989, 989, 989, 967, 1013, 1021, 967, 1012, 966,
1525 967, 1023, 1012, 1018, 1018, 1018, 1013, 1019, 1019, 1008,
1526 1008, 1008, 1022, 967, 979, 979, 979, 1020, 1020, 1024,
1527 1025, 1022, 1026, 1027, 1028, 1030, 1032, 979, 979, 979,
1528 1033, 1034, 989, 1039, 1039, 989, 1042, 1043, 989, 1027,
1529 1029, 1029, 1029, 1044, 1046, 979, 979, 979, 979, 1048,
1530 1008, 1045, 979, 1008, 1044, 979, 1008, 1050, 979, 1051,
1531 1045, 979, 990, 990, 990, 1038, 1038, 1038, 1052, 1053,
1532
1533 1058, 1058, 990, 1061, 990, 990, 990, 990, 1035, 1035,
1534 1035, 1029, 1062, 1066, 1029, 1037, 1037, 1037, 1035, 990,
1535 1035, 1035, 1035, 1035, 1057, 1057, 1057, 1029, 1067, 1074,
1536 1036, 1036, 1036, 990, 1087, 1035, 990, 1009, 1009, 1009,
1537 1036, 1089, 1036, 1036, 1036, 1036, 1072, 1009, 1072, 1009,
1538 1009, 1009, 1009, 1054, 1054, 1054, 1037, 1036, 1063, 1037,
1539 1055, 1055, 1055, 1054, 1009, 1054, 1054, 1054, 1054, 1063,
1540 1055, 1090, 1055, 1055, 1055, 1055, 1064, 1088, 1009, 1091,
1541 1054, 1009, 1040, 1040, 1040, 1064, 1088, 1055, 1092, 1056,
1542 1056, 1056, 1068, 1068, 1094, 1040, 1040, 1040, 1065, 1065,
1543
1544 1065, 1069, 1069, 1069, 1080, 1080, 1080, 1081, 1081, 1084,
1545 1084, 1084, 1093, 1040, 1040, 1040, 1040, 1085, 1085, 1096,
1546 1040, 1086, 1086, 1040, 1097, 1100, 1040, 1101, 1093, 1040,
1547 1056, 1103, 1098, 1056, 1059, 1059, 1059, 1115, 1070, 1070,
1548 1070, 1098, 1069, 1109, 1109, 1069, 1117, 1059, 1059, 1059,
1549 1071, 1071, 1071, 1113, 1113, 1065, 1114, 1114, 1069, 1079,
1550 1079, 1079, 1108, 1108, 1108, 1059, 1059, 1059, 1059, 1112,
1551 1112, 1112, 1059, 1118, 1116, 1059, 1119, 1120, 1059, 1070,
1552 1122, 1059, 1070, 1116, 1124, 1121, 1125, 1130, 1071, 1132,
1553 1126, 1071, 1133, 1135, 1071, 1070, 1077, 1077, 1077, 1126,
1554
1555 1079, 1121, 1141, 1079, 1135, 1143, 1077, 1071, 1077, 1077,
1556 1077, 1077, 1095, 1095, 1095, 1139, 1139, 1105, 1105, 1105,
1557 1107, 1107, 1107, 1077, 1082, 1082, 1082, 1105, 1144, 1105,
1558 1105, 1105, 1105, 1145, 1123, 1123, 1123, 1082, 1082, 1082,
1559 1128, 1128, 1128, 1134, 1105, 1140, 1140, 1134, 1136, 1136,
1560 1136, 1142, 1146, 1095, 1147, 1082, 1082, 1082, 1082, 1148,
1561 1142, 1107, 1082, 1154, 1107, 1082, 1150, 1150, 1082, 1162,
1562 1147, 1082, 1099, 1099, 1099, 1123, 1138, 1138, 1138, 1149,
1563 1149, 1149, 1099, 1169, 1099, 1099, 1099, 1099, 1151, 1151,
1564 1151, 1152, 1152, 1152, 1155, 1155, 1155, 1128, 1171, 1099,
1565
1566 1153, 1153, 1153, 1172, 1155, 1136, 1155, 1155, 1155, 1155,
1567 1099, 1110, 1110, 1110, 1158, 1158, 1158, 1159, 1159, 1167,
1568 1167, 1155, 1168, 1168, 1110, 1110, 1110, 1170, 1173, 1151,
1569 1174, 1176, 1152, 1166, 1166, 1166, 1170, 1175, 1153, 1178,
1570 1178, 1153, 1110, 1110, 1110, 1110, 1157, 1157, 1157, 1110,
1571 1182, 1191, 1110, 1175, 1192, 1110, 1187, 1187, 1110, 1127,
1572 1127, 1127, 1177, 1177, 1177, 1156, 1156, 1156, 1196, 1127,
1573 1211, 1127, 1127, 1127, 1127, 1156, 1213, 1156, 1156, 1156,
1574 1156, 1179, 1179, 1179, 1214, 1193, 1127, 1157, 1215, 1194,
1575 1157, 1216, 1156, 1180, 1180, 1180, 1193, 1127, 1194, 1218,
1576
1577 1185, 1185, 1185, 1157, 1160, 1160, 1160, 1212, 1181, 1181,
1578 1181, 1197, 1197, 1183, 1183, 1183, 1212, 1160, 1160, 1160,
1579 1205, 1205, 1179, 1183, 1235, 1183, 1183, 1183, 1183, 1186,
1580 1186, 1186, 1209, 1209, 1180, 1160, 1160, 1160, 1160, 1237,
1581 1183, 1185, 1160, 1238, 1185, 1160, 1181, 1217, 1160, 1181,
1582 1239, 1160, 1184, 1184, 1184, 1210, 1210, 1185, 1195, 1195,
1583 1195, 1240, 1184, 1217, 1184, 1184, 1184, 1184, 1198, 1198,
1584 1198, 1199, 1199, 1199, 1242, 1200, 1200, 1200, 1244, 1184,
1585 1188, 1188, 1188, 1204, 1204, 1204, 1208, 1208, 1208, 1245,
1586 1203, 1203, 1203, 1188, 1188, 1188, 1219, 1219, 1219, 1221,
1587
1588 1221, 1222, 1222, 1222, 1223, 1223, 1223, 1224, 1224, 1224,
1589 1248, 1188, 1188, 1188, 1188, 1195, 1200, 1200, 1188, 1229,
1590 1229, 1188, 1233, 1233, 1188, 1234, 1234, 1188, 1201, 1201,
1591 1201, 1203, 1252, 1252, 1203, 1253, 1253, 1219, 1201, 1254,
1592 1201, 1201, 1201, 1201, 1228, 1228, 1228, 1203, 1224, 1224,
1593 1225, 1225, 1225, 1219, 1256, 1201, 1206, 1206, 1206, 1241,
1594 1225, 1257, 1225, 1225, 1225, 1225, 1232, 1232, 1232, 1206,
1595 1206, 1206, 1236, 1246, 1255, 1241, 1258, 1225, 1251, 1251,
1596 1251, 1236, 1246, 1255, 1259, 1260, 1261, 1206, 1206, 1206,
1597 1206, 1263, 1263, 1274, 1206, 1272, 1272, 1206, 1273, 1273,
1598
1599 1206, 1260, 1276, 1206, 1220, 1220, 1220, 1220, 1220, 1220,
1600 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220,
1601 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220,
1602 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220,
1603 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220,
1604 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220, 1220,
1605 1277, 1220, 1220, 1220, 1227, 1227, 1227, 1278, 1243, 1243,
1606 1243, 1249, 1249, 1249, 1262, 1262, 1262, 1264, 1264, 1264,
1607 1271, 1271, 1271, 1279, 1280, 1265, 1265, 1265, 1275, 1266,
1608 1266, 1266, 1269, 1269, 1269, 1281, 1287, 1275, 1283, 1283,
1609
1610 1280, 1282, 1282, 1282, 1315, 1227, 1292, 1292, 1227, 1243,
1611 1296, 1296, 1249, 1291, 1291, 1291, 1301, 1301, 1264, 1317,
1612 1249, 1227, 1230, 1230, 1230, 1243, 1265, 1266, 1309, 1309,
1613 1266, 1262, 1318, 1269, 1264, 1230, 1230, 1230, 1284, 1284,
1614 1284, 1269, 1265, 1308, 1308, 1308, 1266, 1285, 1285, 1285,
1615 1312, 1312, 1312, 1230, 1230, 1230, 1230, 1319, 1282, 1316,
1616 1230, 1313, 1313, 1230, 1314, 1314, 1230, 1320, 1316, 1230,
1617 1247, 1247, 1247, 1286, 1286, 1286, 1322, 1330, 1330, 1284,
1618 1247, 1332, 1247, 1247, 1247, 1247, 1321, 1333, 1285, 1297,
1619 1297, 1297, 1298, 1298, 1298, 1284, 1333, 1247, 1290, 1290,
1620
1621 1290, 1334, 1321, 1335, 1285, 1288, 1288, 1288, 1247, 1331,
1622 1331, 1286, 1336, 1337, 1286, 1288, 1339, 1288, 1288, 1288,
1623 1288, 1289, 1289, 1289, 1338, 1295, 1295, 1295, 1341, 1341,
1624 1286, 1289, 1288, 1289, 1289, 1289, 1289, 1349, 1349, 1290,
1625 1338, 1386, 1290, 1329, 1329, 1329, 1297, 1387, 1289, 1298,
1626 1299, 1299, 1299, 1396, 1397, 1290, 1293, 1293, 1293, 1398,
1627 1400, 1300, 1300, 1300, 1401, 1404, 1295, 1405, 1406, 1293,
1628 1293, 1293, 1295, 1302, 1302, 1302, 1303, 1303, 1303, 1304,
1629 1304, 1304, 1307, 1307, 1307, 1407, 1408, 1293, 1293, 1293,
1630 1293, 1299, 1299, 1409, 1293, 1410, 1411, 1293, 1412, 1414,
1631
1632 1293, 1415, 1300, 1293, 1305, 1305, 1305, 1299, 1300, 1323,
1633 1323, 1323, 813, 812, 1305, 811, 1305, 1305, 1305, 1305,
1634 1304, 1304, 810, 1307, 809, 808, 1307, 805, 804, 803,
1635 1302, 1305, 802, 1303, 800, 799, 1304, 798, 797, 1307,
1636 1310, 1310, 1310, 796, 795, 794, 793, 1360, 1360, 1360,
1637 1323, 792, 791, 1310, 1310, 1310, 1325, 1325, 1325, 1340,
1638 1340, 1340, 790, 1327, 1327, 1327, 1323, 1342, 1342, 1342,
1639 789, 1310, 1310, 1310, 1310, 775, 773, 769, 1310, 768,
1640 767, 1310, 766, 765, 1310, 764, 763, 1310, 1324, 1324,
1641 1324, 1360, 1343, 1343, 1343, 762, 761, 1325, 1324, 760,
1642
1643 1324, 1324, 1324, 1324, 1327, 1325, 759, 756, 1342, 1344,
1644 1344, 1344, 1327, 1325, 749, 1324, 1340, 747, 746, 745,
1645 1327, 1346, 1346, 1346, 1342, 744, 1350, 1350, 1350, 1324,
1646 1326, 1326, 1326, 1343, 1348, 1348, 1348, 1351, 1351, 1351,
1647 1326, 742, 1326, 1326, 1326, 1326, 738, 1344, 737, 1343,
1648 1344, 1352, 1352, 1352, 1355, 1355, 1355, 1326, 736, 735,
1649 734, 733, 1346, 1357, 1357, 1357, 1344, 731, 1346, 730,
1650 729, 1326, 1345, 1345, 1345, 1348, 728, 727, 1346, 726,
1651 725, 1348, 1345, 1350, 1345, 1345, 1345, 1345, 724, 722,
1652 721, 1348, 1352, 1352, 1351, 1355, 1358, 1358, 1358, 1345,
1653
1654 720, 719, 718, 1355, 1357, 717, 716, 714, 1352, 713,
1655 712, 1355, 711, 1345, 1347, 1347, 1347, 710, 709, 707,
1656 1357, 702, 697, 695, 1347, 694, 1347, 1347, 1347, 1347,
1657 693, 692, 690, 686, 685, 684, 683, 1358, 682, 681,
1658 680, 1347, 679, 1358, 678, 677, 675, 673, 672, 671,
1659 670, 669, 668, 1358, 667, 1347, 1353, 1353, 1353, 666,
1660 665, 664, 663, 662, 661, 658, 1353, 650, 1353, 1353,
1661 1353, 1353, 648, 647, 646, 645, 644, 643, 642, 641,
1662 640, 639, 638, 1353, 637, 636, 635, 634, 633, 632,
1663 631, 630, 629, 627, 626, 625, 624, 1353, 623, 622,
1664
1665 621, 620, 619, 618, 617, 615, 613, 612, 611, 610,
1666 608, 604, 603, 1353, 1354, 1354, 1354, 596, 595, 594,
1667 593, 592, 591, 590, 1354, 589, 1354, 1354, 1354, 1354,
1668 588, 587, 586, 583, 582, 581, 580, 579, 578, 577,
1669 576, 1354, 575, 574, 572, 571, 570, 569, 568, 567,
1670 566, 565, 564, 562, 561, 1354, 560, 558, 557, 556,
1671 555, 554, 553, 552, 551, 550, 547, 546, 545, 544,
1672 543, 1354, 1356, 1356, 1356, 542, 541, 540, 539, 538,
1673 536, 535, 1356, 534, 1356, 1356, 1356, 1356, 533, 532,
1674 531, 530, 529, 527, 526, 517, 516, 515, 513, 1356,
1675
1676 512, 511, 510, 509, 508, 507, 506, 505, 504, 503,
1677 501, 499, 498, 1356, 496, 495, 494, 493, 492, 491,
1678 490, 489, 486, 485, 484, 483, 482, 481, 480, 1356,
1679 1359, 1359, 1359, 479, 478, 477, 476, 475, 473, 472,
1680 1359, 470, 1359, 1359, 1359, 1359, 469, 468, 467, 465,
1681 464, 463, 462, 461, 460, 459, 458, 1359, 457, 455,
1682 454, 453, 452, 451, 450, 449, 448, 447, 445, 444,
1683 443, 1359, 442, 441, 440, 439, 437, 436, 435, 434,
1684 433, 432, 431, 430, 429, 428, 427, 1359, 1362, 1362,
1685 1362, 1362, 1362, 1362, 1362, 1362, 1362, 1362, 1362, 1362,
1686
1687 1362, 1363, 1363, 1363, 1363, 1363, 1363, 1363, 1363, 1363,
1688 1363, 1363, 1363, 1363, 1364, 1364, 1364, 1364, 1364, 1364,
1689 1364, 1364, 1364, 1364, 1364, 1364, 1364, 1365, 1365, 1365,
1690 1365, 1365, 1365, 1365, 1365, 1365, 1365, 1365, 1365, 1365,
1691 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366,
1692 1366, 1366, 1366, 1367, 1367, 1367, 1367, 1367, 1367, 1367,
1693 1367, 1367, 1367, 1367, 1367, 1367, 1368, 1368, 1368, 1368,
1694 1368, 1368, 1368, 1368, 1368, 1368, 1368, 1368, 1368, 1369,
1695 1369, 1369, 1369, 1369, 1369, 1369, 1369, 1369, 1369, 1369,
1696 1369, 1369, 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
1697
1698 1370, 1370, 1370, 1370, 1370, 1371, 1371, 1371, 1371, 1371,
1699 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1372, 1372,
1700 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
1701 1372, 1373, 1373, 1373, 1373, 1373, 1373, 1373, 1373, 1373,
1702 1373, 1373, 1373, 1373, 1374, 1374, 1374, 1374, 1374, 1374,
1703 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1375, 1375, 1375,
1704 1375, 1375, 1375, 1375, 1375, 1375, 1375, 1375, 1375, 1375,
1705 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
1706 1376, 1376, 1376, 1377, 1377, 1377, 1377, 1377, 1377, 1377,
1707 1377, 1377, 1377, 1377, 1377, 1377, 1378, 1378, 1378, 1378,
1708
1709 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1379,
1710 426, 425, 1379, 1379, 423, 1379, 1379, 1379, 1379, 1379,
1711 1380, 422, 421, 1380, 1380, 1380, 1380, 1380, 1380, 1380,
1712 1380, 1381, 1381, 420, 1381, 1381, 1381, 1381, 1381, 1381,
1713 1381, 1381, 1381, 1381, 1382, 419, 418, 417, 1382, 1383,
1714 416, 415, 1383, 1383, 1383, 1383, 1383, 1383, 1383, 1383,
1715 414, 1383, 1384, 413, 1384, 1384, 1384, 1385, 1385, 1388,
1716 412, 411, 1388, 1388, 1388, 1388, 1388, 1388, 1388, 1388,
1717 1389, 410, 409, 1389, 1389, 1389, 1389, 1389, 1389, 1389,
1718 1389, 1390, 1390, 1390, 1390, 1390, 1390, 1390, 1390, 1390,
1719
1720 1390, 408, 1390, 1390, 1391, 1391, 1391, 1391, 1391, 1391,
1721 1391, 1391, 1391, 407, 1391, 1391, 1391, 1392, 1392, 1392,
1722 1392, 1392, 1392, 1392, 1392, 1392, 1392, 1392, 1393, 406,
1723 404, 403, 1393, 1394, 1394, 1395, 1395, 1395, 1395, 1395,
1724 1395, 1395, 1395, 1395, 1395, 1395, 1395, 1395, 1399, 402,
1725 401, 399, 398, 1399, 1402, 397, 396, 395, 394, 1402,
1726 1403, 1403, 1403, 1403, 1403, 1403, 1403, 1403, 1403, 1403,
1727 393, 1403, 1403, 1413, 1413, 1413, 1413, 1413, 1413, 1413,
1728 1413, 1413, 1413, 1413, 392, 1413, 391, 389, 388, 387,
1729 385, 384, 382, 381, 379, 378, 377, 376, 375, 374,
1730
1731 373, 372, 371, 369, 367, 366, 365, 364, 363, 362,
1732 361, 360, 359, 358, 357, 356, 355, 354, 352, 351,
1733 350, 349, 348, 346, 343, 340, 339, 338, 337, 336,
1734 335, 334, 333, 332, 331, 330, 328, 327, 326, 325,
1735 323, 322, 321, 319, 318, 317, 316, 314, 313, 312,
1736 311, 310, 309, 305, 304, 303, 302, 301, 300, 299,
1737 297, 296, 295, 294, 292, 290, 289, 288, 287, 286,
1738 284, 281, 280, 279, 278, 277, 276, 275, 274, 273,
1739 272, 271, 270, 265, 263, 262, 260, 259, 258, 257,
1740 255, 254, 252, 251, 250, 249, 247, 243, 239, 237,
1741
1742 235, 233, 232, 231, 230, 229, 227, 226, 224, 222,
1743 221, 220, 219, 218, 216, 215, 214, 213, 204, 197,
1744 193, 189, 185, 170, 169, 167, 161, 160, 159, 157,
1745 156, 155, 154, 153, 151, 149, 147, 145, 144, 143,
1746 142, 141, 135, 124, 120, 117, 114, 109, 108, 103,
1747 93, 82, 80, 78, 77, 76, 74, 73, 72, 70,
1748 68, 62, 58, 55, 52, 45, 42, 41, 34, 33,
1749 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1750 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1751 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1752
1753 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1754 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1755 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
1756 1361
1757 } ;
1758
1759 static yy_state_type yy_last_accepting_state;
1760 static char *yy_last_accepting_cpos;
1761
1762 extern int yy_flex_debug;
1763 int yy_flex_debug = 0;
1764
1765 /* The intent behind this definition is that it'll catch
1766 * any uses of REJECT which flex missed.
1767 */
1768 #define REJECT reject_used_but_not_detected
1769 #define yymore() yymore_used_but_not_detected
1770 #define YY_MORE_ADJ 0
1771 #define YY_RESTORE_YY_MORE_OFFSET
1772 char *yytext;
1773 #line 1 "../../../texk/detex/detex-src/detex.l"
1774
1775 #line 97 "../../../texk/detex/detex-src/detex.l"
1776 #undef IGNORE
1777 #undef ECHO
1778
1779 #define LaBEGIN if (fLatex) BEGIN
1780 #define IGNORE Ignore()
1781 #define INCRLINENO IncrLineNo()
1782 #define ECHO Echo()
1783 #define NOUN if (fSpace && !fWord && !fReplace) putchar(' '); else {if (fReplace) printf("noun");}
1784 #define VERBNOUN if (fReplace) printf(" verbs noun"); /* puts a verb and a noun to make grammar checking work */
1785 #define SPACE if (!fWord) putchar(' ')
1786 #define NEWLINE LineBreak()
1787 #define LATEX fLatex=!fForcetex
1788 #define KILLARGS(x) cArgs=x; LaBEGIN LaMacro
1789 #define STRIPARGS(x) cArgs=x; LaBEGIN LaMacro2
1790 #define CITE(x) if (fLatex && !fCite) KILLARGS(x)
1791
1792 /* avoid gratuitous gcc warning from passing -D for this on command line */
1793 #ifndef NO_MALLOC_DECL
1794 #define NO_MALLOC_DECL
1795 #endif
1796
1797 void LineBreak();
1798 void Ignore();
1799 void IncrLineNo();
1800 void Echo();
1801 void AddInclude(char *sbFile);
1802 void ErrorExit(const char *sb1);
1803 void UsageExit(void);
1804 void VersionExit(void);
1805 void IncludeFile(char *sbFile);
1806 void InputFile(char *sbFile);
1807 void SetEnvIgnore(const char *sbEnvList);
1808 #ifndef KPATHSEA
1809 void SetInputPaths(void);
1810 #endif
1811 void Warning(const char *sb1, const char *sb2);
1812 int BeginEnv(const char *sbEnv);
1813 int EndEnv(const char *sbEnv);
1814 int InList(char *sbFile);
1815 int SeparateList(char *sbList, char *rgsbList[] ,char chSep, int csbMax);
1816 FILE *TexOpen(char *sbFile);
1817 char *SafeMalloc(int cch, const char *sbMessage);
1818 #ifndef KPATHSEA
1819 char *getenv(const char *);
1820 #ifndef NO_MALLOC_DECL
1821 char *malloc();
1822 #endif
1823 #ifdef OS2
1824 void yyless(int);
1825 void OS2UsageExit(void);
1826 #endif
1827 #endif /* KPATHSEA */
1828
1829 char *rgsbEnvIgnore[MAXENVS]; /* list of environments ignored */
1830 char *rgsbIncList[MAXINCLIST]; /* list of includeonly files */
1831 char *rgsbInputPaths[MAXINPUTPATHS]; /* list of input paths in order */
1832 char sbCurrentIgnoredEnv[CCHMAXENV]; /* current environment being ignored */
1833 char *sbProgName; /* name we were invoked with */
1834 #ifndef NOFILE /* might be defined in <sys/param.h> */
1835 #define NOFILE 256
1836 #endif
1837 FILE *rgfp[NOFILE+1]; /* stack of input/include files */
1838 int cfp = 0; /* count of files in stack */
1839 int cOpenBrace = 0; /* count of `{' in <LaMacro> and <LaMacro2> */
1840 int cArgs = 0; /* argument connt in <LaArgs> */
1841 int csbEnvIgnore; /* count of environments ignored */
1842 int csbIncList = 0; /* count of includeonly files */
1843 int csbInputPaths; /* count of input paths */
1844 int fLatex = 0; /* flag to indicated delatex */
1845 int fWord = 0; /* flag for -w option */
1846 int fFollow = 1; /* flag to follow input/include */
1847 int fCite = 0; /* flag to echo \cite and \ref args */
1848 int fSpace = 0; /* flag to replace \cs with space */
1849 int fForcetex = 0; /* flag to inhibit latex mode */
1850 int fSrcLoc = 0; /* flag to display source location of original file */
1851 int fShowPictures = 0; /* flag to show picture names */
1852 int fReplace = 0; /* flag to replace envirnments with "noun" */
1853
1854 int currBracesLevel = 0;
1855 int footnoteLevel = -100;
1856
1857 #ifdef FLEX_SCANNER
1858 /* flex has contexts for buffers that need to be switched when file changes
1859 * otherwise output contains imported files in reverse order. Weird, but
1860 * true.
1861 */
1862 YY_BUFFER_STATE rgsb[NOFILE + 1]; /* flex context stack */
1863 char* fFileNames[NOFILE + 1]; /* names of the buffers in context stack */
1864 int fFileLines[NOFILE + 1]; /* line number in each of the context files */
1865 int fIsColumn0 = 1; /* Are we at the begining of a line? */
1866 int csb = 0; /* depth of flex context stack */
1867 #endif /* FLEX_SCANNER */
1868
1869
1870
1871
1872
1873 #line 1874 "../../../texk/detex/detex-src/detex.c"
1874
1875 #define INITIAL 0
1876 #define Define 1
1877 #define Display 2
1878 #define IncludeOnly 3
1879 #define Input 4
1880 #define Math 5
1881 #define Normal 6
1882 #define Control 7
1883 #define LaBegin 8
1884 #define LaDisplay 9
1885 #define LaEnd 10
1886 #define LaEnv 11
1887 #define LaFormula 12
1888 #define LaInclude 13
1889 #define LaSubfile 14
1890 #define LaMacro 15
1891 #define LaOptArg 16
1892 #define LaMacro2 17
1893 #define LaOptArg2 18
1894 #define LaVerbatim 19
1895 #define LaBreak 20
1896 #define LaPicture 21
1897
1898 #ifndef YY_NO_UNISTD_H
1899 /* Special case for "unistd.h", since it is non-ANSI. We include it way
1900 * down here because we want the user's section 1 to have been scanned first.
1901 * The user has a chance to override it with an option.
1902 */
1903 #include <unistd.h>
1904 #endif
1905
1906 #ifndef YY_EXTRA_TYPE
1907 #define YY_EXTRA_TYPE void *
1908 #endif
1909
1910 static int yy_init_globals (void );
1911
1912 /* Accessor methods to globals.
1913 These are made visible to non-reentrant scanners for convenience. */
1914
1915 int yylex_destroy (void );
1916
1917 int yyget_debug (void );
1918
1919 void yyset_debug (int debug_flag );
1920
1921 YY_EXTRA_TYPE yyget_extra (void );
1922
1923 void yyset_extra (YY_EXTRA_TYPE user_defined );
1924
1925 FILE *yyget_in (void );
1926
1927 void yyset_in (FILE * _in_str );
1928
1929 FILE *yyget_out (void );
1930
1931 void yyset_out (FILE * _out_str );
1932
1933 yy_size_t yyget_leng (void );
1934
1935 char *yyget_text (void );
1936
1937 int yyget_lineno (void );
1938
1939 void yyset_lineno (int _line_number );
1940
1941 /* Macros after this point can all be overridden by user definitions in
1942 * section 1.
1943 */
1944
1945 #ifndef YY_SKIP_YYWRAP
1946 #ifdef __cplusplus
1947 extern "C" int yywrap (void );
1948 #else
1949 extern int yywrap (void );
1950 #endif
1951 #endif
1952
1953 #ifndef YY_NO_UNPUT
1954
1955 #endif
1956
1957 #ifndef yytext_ptr
1958 static void yy_flex_strncpy (char *,yyconst char *,int );
1959 #endif
1960
1961 #ifdef YY_NEED_STRLEN
1962 static int yy_flex_strlen (yyconst char * );
1963 #endif
1964
1965 #ifndef YY_NO_INPUT
1966
1967 #ifdef __cplusplus
1968 static int yyinput (void );
1969 #else
1970 static int input (void );
1971 #endif
1972
1973 #endif
1974
1975 /* Amount of stuff to slurp up with each read. */
1976 #ifndef YY_READ_BUF_SIZE
1977 #ifdef __ia64__
1978 /* On IA-64, the buffer size is 16k, not 8k */
1979 #define YY_READ_BUF_SIZE 16384
1980 #else
1981 #define YY_READ_BUF_SIZE 8192
1982 #endif /* __ia64__ */
1983 #endif
1984
1985 /* Copy whatever the last rule matched to the standard output. */
1986 #ifndef ECHO
1987 /* This used to be an fputs(), but since the string might contain NUL's,
1988 * we now use fwrite().
1989 */
1990 #define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
1991 #endif
1992
1993 /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
1994 * is returned in "result".
1995 */
1996 #ifndef YY_INPUT
1997 #define YY_INPUT(buf,result,max_size) \
1998 if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
1999 { \
2000 int c = '*'; \
2001 size_t n; \
2002 for ( n = 0; n < max_size && \
2003 (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
2004 buf[n] = (char) c; \
2005 if ( c == '\n' ) \
2006 buf[n++] = (char) c; \
2007 if ( c == EOF && ferror( yyin ) ) \
2008 YY_FATAL_ERROR( "input in flex scanner failed" ); \
2009 result = n; \
2010 } \
2011 else \
2012 { \
2013 errno=0; \
2014 while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
2015 { \
2016 if( errno != EINTR) \
2017 { \
2018 YY_FATAL_ERROR( "input in flex scanner failed" ); \
2019 break; \
2020 } \
2021 errno=0; \
2022 clearerr(yyin); \
2023 } \
2024 }\
2025 \
2026
2027 #endif
2028
2029 /* No semi-colon after return; correct usage is to write "yyterminate();" -
2030 * we don't want an extra ';' after the "return" because that will cause
2031 * some compilers to complain about unreachable statements.
2032 */
2033 #ifndef yyterminate
2034 #define yyterminate() return YY_NULL
2035 #endif
2036
2037 /* Number of entries by which start-condition stack grows. */
2038 #ifndef YY_START_STACK_INCR
2039 #define YY_START_STACK_INCR 25
2040 #endif
2041
2042 /* Report a fatal error. */
2043 #ifndef YY_FATAL_ERROR
2044 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
2045 #endif
2046
2047 /* end tables serialization structures and prototypes */
2048
2049 /* Default declaration of generated scanner - a define so the user can
2050 * easily add parameters.
2051 */
2052 #ifndef YY_DECL
2053 #define YY_DECL_IS_OURS 1
2054
2055 extern int yylex (void);
2056
2057 #define YY_DECL int yylex (void)
2058 #endif /* !YY_DECL */
2059
2060 /* Code executed at the beginning of each rule, after yytext and yyleng
2061 * have been set up.
2062 */
2063 #ifndef YY_USER_ACTION
2064 #define YY_USER_ACTION
2065 #endif
2066
2067 /* Code executed at the end of each rule. */
2068 #ifndef YY_BREAK
2069 #define YY_BREAK /*LINTED*/break;
2070 #endif
2071
2072 #define YY_RULE_SETUP \
2073 YY_USER_ACTION
2074
2075 /** The main scanner function which does all the work.
2076 */
2077 YY_DECL
2078 {
2079 yy_state_type yy_current_state;
2080 char *yy_cp, *yy_bp;
2081 int yy_act;
2082
2083 if ( !(yy_init) )
2084 {
2085 (yy_init) = 1;
2086
2087 #ifdef YY_USER_INIT
2088 YY_USER_INIT;
2089 #endif
2090
2091 if ( ! (yy_start) )
2092 (yy_start) = 1; /* first start state */
2093
2094 if ( ! yyin )
2095 yyin = stdin;
2096
2097 if ( ! yyout )
2098 yyout = stdout;
2099
2100 if ( ! YY_CURRENT_BUFFER ) {
2101 yyensure_buffer_stack ();
2102 YY_CURRENT_BUFFER_LVALUE =
2103 yy_create_buffer(yyin,YY_BUF_SIZE );
2104 }
2105
2106 yy_load_buffer_state( );
2107 }
2108
2109 {
2110 #line 211 "../../../texk/detex/detex-src/detex.l"
2111
2112 #line 2113 "../../../texk/detex/detex-src/detex.c"
2113
2114 while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
2115 {
2116 yy_cp = (yy_c_buf_p);
2117
2118 /* Support of yytext. */
2119 *yy_cp = (yy_hold_char);
2120
2121 /* yy_bp points to the position in yy_ch_buf of the start of
2122 * the current run.
2123 */
2124 yy_bp = yy_cp;
2125
2126 yy_current_state = (yy_start);
2127 yy_match:
2128 do
2129 {
2130 YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
2131 if ( yy_accept[yy_current_state] )
2132 {
2133 (yy_last_accepting_state) = yy_current_state;
2134 (yy_last_accepting_cpos) = yy_cp;
2135 }
2136 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2137 {
2138 yy_current_state = (int) yy_def[yy_current_state];
2139 if ( yy_current_state >= 1362 )
2140 yy_c = yy_meta[(unsigned int) yy_c];
2141 }
2142 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2143 ++yy_cp;
2144 }
2145 while ( yy_current_state != 1361 );
2146 yy_cp = (yy_last_accepting_cpos);
2147 yy_current_state = (yy_last_accepting_state);
2148
2149 yy_find_action:
2150 yy_act = yy_accept[yy_current_state];
2151
2152 YY_DO_BEFORE_ACTION;
2153
2154 do_action: /* This label is used only to access EOF actions. */
2155
2156 switch ( yy_act )
2157 { /* beginning of action switch */
2158 case 0: /* must back up */
2159 /* undo the effects of YY_DO_BEFORE_ACTION */
2160 *yy_cp = (yy_hold_char);
2161 yy_cp = (yy_last_accepting_cpos);
2162 yy_current_state = (yy_last_accepting_state);
2163 goto yy_find_action;
2164
2165 case 1:
2166 YY_RULE_SETUP
2167 #line 212 "../../../texk/detex/detex-src/detex.l"
2168 /* ignore comments */ {INCRLINENO;}
2169 YY_BREAK
2170 case 2:
2171 /* rule 2 can match eol */
2172 YY_RULE_SETUP
2173 #line 214 "../../../texk/detex/detex-src/detex.l"
2174 {LATEX; IGNORE;}
2175 YY_BREAK
2176 case 3:
2177 YY_RULE_SETUP
2178 #line 216 "../../../texk/detex/detex-src/detex.l"
2179 /* environment start */ {LaBEGIN LaBegin; IGNORE;}
2180 YY_BREAK
2181 case 4:
2182 /* rule 4 can match eol */
2183 YY_RULE_SETUP
2184 #line 218 "../../../texk/detex/detex-src/detex.l"
2185 { if (BeginEnv("verbatim"))
2186 BEGIN LaEnv;
2187 else
2188 BEGIN LaVerbatim;
2189 IGNORE;
2190 }
2191 YY_BREAK
2192 case 5:
2193 /* rule 5 can match eol */
2194 YY_RULE_SETUP
2195 #line 225 "../../../texk/detex/detex-src/detex.l"
2196 /* verbatim mode */ {BEGIN Normal; IGNORE;}
2197 YY_BREAK
2198 case 6:
2199 /* rule 6 can match eol */
2200 YY_RULE_SETUP
2201 #line 226 "../../../texk/detex/detex-src/detex.l"
2202 ECHO;
2203 YY_BREAK
2204 case 7:
2205 YY_RULE_SETUP
2206 #line 227 "../../../texk/detex/detex-src/detex.l"
2207 ECHO;
2208 YY_BREAK
2209 case 8:
2210 /* rule 8 can match eol */
2211 YY_RULE_SETUP
2212 #line 229 "../../../texk/detex/detex-src/detex.l"
2213 { KILLARGS(1);
2214 if (BeginEnv("minipage"))
2215 BEGIN LaEnv;
2216 else
2217 BEGIN LaMacro; /* Normal; */
2218 IGNORE;
2219 }
2220 YY_BREAK
2221 case 9:
2222 /* rule 9 can match eol */
2223 YY_RULE_SETUP
2224 #line 237 "../../../texk/detex/detex-src/detex.l"
2225 {
2226 if (BeginEnv("table"))
2227 BEGIN LaEnv;
2228 else
2229 BEGIN Normal;
2230 IGNORE;
2231 }
2232 YY_BREAK
2233 case 10:
2234 /* rule 10 can match eol */
2235 YY_RULE_SETUP
2236 #line 245 "../../../texk/detex/detex-src/detex.l"
2237 {
2238 if (BeginEnv("figure"))
2239 BEGIN LaEnv;
2240 else
2241 BEGIN Normal;
2242 IGNORE;
2243 }
2244 YY_BREAK
2245 case 11:
2246 YY_RULE_SETUP
2247 #line 253 "../../../texk/detex/detex-src/detex.l"
2248 { if (BeginEnv(yytext))
2249 BEGIN LaEnv;
2250 else
2251 BEGIN Normal;
2252 IGNORE;
2253 }
2254 YY_BREAK
2255 /*<LaBegin>"\n" NEWLINE;*/
2256 case 12:
2257 YY_RULE_SETUP
2258 #line 260 "../../../texk/detex/detex-src/detex.l"
2259 {INCRLINENO;}
2260 YY_BREAK
2261 case 13:
2262 YY_RULE_SETUP
2263 #line 262 "../../../texk/detex/detex-src/detex.l"
2264 /* absorb some environments */ {LaBEGIN LaEnd; IGNORE;}
2265 YY_BREAK
2266 case 14:
2267 /* rule 14 can match eol */
2268 YY_RULE_SETUP
2269 #line 263 "../../../texk/detex/detex-src/detex.l"
2270 ;/*NEWLINE;*/
2271 YY_BREAK
2272 case 15:
2273 YY_RULE_SETUP
2274 #line 264 "../../../texk/detex/detex-src/detex.l"
2275 {INCRLINENO;}
2276 YY_BREAK
2277 case 16:
2278 YY_RULE_SETUP
2279 #line 266 "../../../texk/detex/detex-src/detex.l"
2280 /* end environment */ { if (EndEnv(yytext))
2281 BEGIN Normal;
2282 IGNORE;
2283 }
2284 YY_BREAK
2285 case 17:
2286 YY_RULE_SETUP
2287 #line 270 "../../../texk/detex/detex-src/detex.l"
2288 {BEGIN LaEnv; IGNORE;}
2289 YY_BREAK
2290 /*<LaEnd>"\n" NEWLINE;*/
2291 case 18:
2292 YY_RULE_SETUP
2293 #line 272 "../../../texk/detex/detex-src/detex.l"
2294 {INCRLINENO;}
2295 YY_BREAK
2296 case 19:
2297 /* rule 19 can match eol */
2298 YY_RULE_SETUP
2299 #line 274 "../../../texk/detex/detex-src/detex.l"
2300 ;
2301 YY_BREAK
2302 case 20:
2303 /* rule 20 can match eol */
2304 YY_RULE_SETUP
2305 #line 275 "../../../texk/detex/detex-src/detex.l"
2306 ;
2307 YY_BREAK
2308 case 21:
2309 /* rule 21 can match eol */
2310 YY_RULE_SETUP
2311 #line 276 "../../../texk/detex/detex-src/detex.l"
2312 ;
2313 YY_BREAK
2314 case 22:
2315 /* rule 22 can match eol */
2316 YY_RULE_SETUP
2317 #line 277 "../../../texk/detex/detex-src/detex.l"
2318 ;
2319 YY_BREAK
2320 case 23:
2321 /* rule 23 can match eol */
2322 YY_RULE_SETUP
2323 #line 278 "../../../texk/detex/detex-src/detex.l"
2324 ;
2325 YY_BREAK
2326 case 24:
2327 /* rule 24 can match eol */
2328 YY_RULE_SETUP
2329 #line 279 "../../../texk/detex/detex-src/detex.l"
2330 ;
2331 YY_BREAK
2332 case 25:
2333 YY_RULE_SETUP
2334 #line 280 "../../../texk/detex/detex-src/detex.l"
2335 ; /* hack to fix \begin{minipage}{300pt} */
2336 YY_BREAK
2337 case 26:
2338 YY_RULE_SETUP
2339 #line 282 "../../../texk/detex/detex-src/detex.l"
2340 { KILLARGS(1); }
2341 YY_BREAK
2342 case 27:
2343 YY_RULE_SETUP
2344 #line 283 "../../../texk/detex/detex-src/detex.l"
2345 { KILLARGS(2); }
2346 YY_BREAK
2347 case 28:
2348 YY_RULE_SETUP
2349 #line 284 "../../../texk/detex/detex-src/detex.l"
2350 { KILLARGS(2); }
2351 YY_BREAK
2352 case 29:
2353 YY_RULE_SETUP
2354 #line 285 "../../../texk/detex/detex-src/detex.l"
2355 { KILLARGS(2); }
2356 YY_BREAK
2357 case 30:
2358 YY_RULE_SETUP
2359 #line 286 "../../../texk/detex/detex-src/detex.l"
2360 { KILLARGS(2); }
2361 YY_BREAK
2362 case 31:
2363 YY_RULE_SETUP
2364 #line 287 "../../../texk/detex/detex-src/detex.l"
2365 { KILLARGS(2); }
2366 YY_BREAK
2367 case 32:
2368 YY_RULE_SETUP
2369 #line 288 "../../../texk/detex/detex-src/detex.l"
2370 { KILLARGS(1); }
2371 YY_BREAK
2372 case 33:
2373 YY_RULE_SETUP
2374 #line 289 "../../../texk/detex/detex-src/detex.l"
2375 { KILLARGS(1); }
2376 YY_BREAK
2377 case 34:
2378 YY_RULE_SETUP
2379 #line 290 "../../../texk/detex/detex-src/detex.l"
2380 { KILLARGS(2); }
2381 YY_BREAK
2382 case 35:
2383 YY_RULE_SETUP
2384 #line 291 "../../../texk/detex/detex-src/detex.l"
2385 { KILLARGS(1); }
2386 YY_BREAK
2387 case 36:
2388 YY_RULE_SETUP
2389 #line 292 "../../../texk/detex/detex-src/detex.l"
2390 { STRIPARGS(2); }
2391 YY_BREAK
2392 case 37:
2393 YY_RULE_SETUP
2394 #line 293 "../../../texk/detex/detex-src/detex.l"
2395 { KILLARGS(1); }
2396 YY_BREAK
2397 case 38:
2398 YY_RULE_SETUP
2399 #line 294 "../../../texk/detex/detex-src/detex.l"
2400 { STRIPARGS(2); }
2401 YY_BREAK
2402 case 39:
2403 YY_RULE_SETUP
2404 #line 295 "../../../texk/detex/detex-src/detex.l"
2405 { KILLARGS(2); }
2406 YY_BREAK
2407 case 40:
2408 YY_RULE_SETUP
2409 #line 296 "../../../texk/detex/detex-src/detex.l"
2410 ;
2411 YY_BREAK
2412 case 41:
2413 YY_RULE_SETUP
2414 #line 297 "../../../texk/detex/detex-src/detex.l"
2415 { KILLARGS(1); }
2416 YY_BREAK
2417 case 42:
2418 /* rule 42 can match eol */
2419 YY_RULE_SETUP
2420 #line 298 "../../../texk/detex/detex-src/detex.l"
2421 { LaBEGIN LaPicture; }
2422 YY_BREAK
2423 case 43:
2424 YY_RULE_SETUP
2425 #line 300 "../../../texk/detex/detex-src/detex.l"
2426 ;
2427 YY_BREAK
2428 case 44:
2429 /* rule 44 can match eol */
2430 YY_RULE_SETUP
2431 #line 301 "../../../texk/detex/detex-src/detex.l"
2432 { if(fShowPictures) { printf("<Picture %s>", yytext); } }
2433 YY_BREAK
2434 case 45:
2435 /* rule 45 can match eol */
2436 YY_RULE_SETUP
2437 #line 302 "../../../texk/detex/detex-src/detex.l"
2438 { BEGIN Normal; INCRLINENO; }
2439 YY_BREAK
2440 case 46:
2441 YY_RULE_SETUP
2442 #line 303 "../../../texk/detex/detex-src/detex.l"
2443 BEGIN Normal;
2444 YY_BREAK
2445 case 47:
2446 YY_RULE_SETUP
2447 #line 305 "../../../texk/detex/detex-src/detex.l"
2448 { KILLARGS(3); }
2449 YY_BREAK
2450 case 48:
2451 YY_RULE_SETUP
2452 #line 306 "../../../texk/detex/detex-src/detex.l"
2453 { KILLARGS(1); }
2454 YY_BREAK
2455 case 49:
2456 YY_RULE_SETUP
2457 #line 307 "../../../texk/detex/detex-src/detex.l"
2458 { KILLARGS(2); }
2459 YY_BREAK
2460 case 50:
2461 YY_RULE_SETUP
2462 #line 308 "../../../texk/detex/detex-src/detex.l"
2463 { KILLARGS(2); }
2464 YY_BREAK
2465 case 51:
2466 YY_RULE_SETUP
2467 #line 309 "../../../texk/detex/detex-src/detex.l"
2468 { KILLARGS(3); }
2469 YY_BREAK
2470 case 52:
2471 YY_RULE_SETUP
2472 #line 310 "../../../texk/detex/detex-src/detex.l"
2473 { KILLARGS(1); }
2474 YY_BREAK
2475 case 53:
2476 YY_RULE_SETUP
2477 #line 311 "../../../texk/detex/detex-src/detex.l"
2478 { STRIPARGS(1); }
2479 YY_BREAK
2480 case 54:
2481 YY_RULE_SETUP
2482 #line 312 "../../../texk/detex/detex-src/detex.l"
2483 { KILLARGS(1); }
2484 YY_BREAK
2485 case 55:
2486 YY_RULE_SETUP
2487 #line 313 "../../../texk/detex/detex-src/detex.l"
2488 { KILLARGS(1); }
2489 YY_BREAK
2490 case 56:
2491 YY_RULE_SETUP
2492 #line 314 "../../../texk/detex/detex-src/detex.l"
2493 { KILLARGS(3); }
2494 YY_BREAK
2495 case 57:
2496 YY_RULE_SETUP
2497 #line 316 "../../../texk/detex/detex-src/detex.l"
2498 ;/*NEWLINE;*/
2499 YY_BREAK
2500 case 58:
2501 YY_RULE_SETUP
2502 #line 317 "../../../texk/detex/detex-src/detex.l"
2503 ;/*NEWLINE;*/
2504 YY_BREAK
2505 case 59:
2506 YY_RULE_SETUP
2507 #line 318 "../../../texk/detex/detex-src/detex.l"
2508 ;/*NEWLINE;*/
2509 YY_BREAK
2510 case 60:
2511 YY_RULE_SETUP
2512 #line 319 "../../../texk/detex/detex-src/detex.l"
2513 ;/*NEWLINE;*/
2514 YY_BREAK
2515 case 61:
2516 YY_RULE_SETUP
2517 #line 320 "../../../texk/detex/detex-src/detex.l"
2518 ;/*NEWLINE;*/
2519 YY_BREAK
2520 case 62:
2521 YY_RULE_SETUP
2522 #line 321 "../../../texk/detex/detex-src/detex.l"
2523 ;/*NEWLINE;*/
2524 YY_BREAK
2525 case 63:
2526 YY_RULE_SETUP
2527 #line 322 "../../../texk/detex/detex-src/detex.l"
2528 ;/*NEWLINE;*/
2529 YY_BREAK
2530 case 64:
2531 YY_RULE_SETUP
2532 #line 324 "../../../texk/detex/detex-src/detex.l"
2533 /* ignore args */ {KILLARGS(1); IGNORE;}
2534 YY_BREAK
2535 case 65:
2536 YY_RULE_SETUP
2537 #line 325 "../../../texk/detex/detex-src/detex.l"
2538 /* of these \cs */ {KILLARGS(1); IGNORE;}
2539 YY_BREAK
2540 case 66:
2541 YY_RULE_SETUP
2542 #line 326 "../../../texk/detex/detex-src/detex.l"
2543 {KILLARGS(1); IGNORE;}
2544 YY_BREAK
2545 case 67:
2546 YY_RULE_SETUP
2547 #line 327 "../../../texk/detex/detex-src/detex.l"
2548 {KILLARGS(1);} /* kill space before */
2549 YY_BREAK
2550 case 68:
2551 YY_RULE_SETUP
2552 #line 328 "../../../texk/detex/detex-src/detex.l"
2553 {LATEX; KILLARGS(1); IGNORE;}
2554 YY_BREAK
2555 case 69:
2556 YY_RULE_SETUP
2557 #line 329 "../../../texk/detex/detex-src/detex.l"
2558 {LATEX; KILLARGS(1); IGNORE;}
2559 YY_BREAK
2560 case 70:
2561 YY_RULE_SETUP
2562 #line 330 "../../../texk/detex/detex-src/detex.l"
2563 {KILLARGS(1); IGNORE;}
2564 YY_BREAK
2565 case 71:
2566 YY_RULE_SETUP
2567 #line 331 "../../../texk/detex/detex-src/detex.l"
2568 {KILLARGS(1); IGNORE;}
2569 YY_BREAK
2570 case 72:
2571 YY_RULE_SETUP
2572 #line 332 "../../../texk/detex/detex-src/detex.l"
2573 {KILLARGS(1);}
2574 YY_BREAK
2575 case 73:
2576 YY_RULE_SETUP
2577 #line 333 "../../../texk/detex/detex-src/detex.l"
2578 {KILLARGS(1);}
2579 YY_BREAK
2580 /*<Normal>"\\footnote" {KILLARGS(1); SPACE;}*/
2581 case 74:
2582 YY_RULE_SETUP
2583 #line 335 "../../../texk/detex/detex-src/detex.l"
2584 {KILLARGS(1); IGNORE;}
2585 YY_BREAK
2586 case 75:
2587 YY_RULE_SETUP
2588 #line 336 "../../../texk/detex/detex-src/detex.l"
2589 {CITE(1); IGNORE;}
2590 YY_BREAK
2591 case 76:
2592 YY_RULE_SETUP
2593 #line 337 "../../../texk/detex/detex-src/detex.l"
2594 {CITE(1); IGNORE;}
2595 YY_BREAK
2596 case 77:
2597 YY_RULE_SETUP
2598 #line 338 "../../../texk/detex/detex-src/detex.l"
2599 {KILLARGS(1); IGNORE;}
2600 YY_BREAK
2601 case 78:
2602 YY_RULE_SETUP
2603 #line 339 "../../../texk/detex/detex-src/detex.l"
2604 {CITE(1); IGNORE;}
2605 YY_BREAK
2606 case 79:
2607 YY_RULE_SETUP
2608 #line 340 "../../../texk/detex/detex-src/detex.l"
2609 {KILLARGS(2); IGNORE;}
2610 YY_BREAK
2611 case 80:
2612 YY_RULE_SETUP
2613 #line 341 "../../../texk/detex/detex-src/detex.l"
2614 {KILLARGS(2); IGNORE;}
2615 YY_BREAK
2616 case 81:
2617 YY_RULE_SETUP
2618 #line 342 "../../../texk/detex/detex-src/detex.l"
2619 { KILLARGS(1); }
2620 YY_BREAK
2621 case 82:
2622 YY_RULE_SETUP
2623 #line 343 "../../../texk/detex/detex-src/detex.l"
2624 { KILLARGS(2); }
2625 YY_BREAK
2626 case 83:
2627 YY_RULE_SETUP
2628 #line 345 "../../../texk/detex/detex-src/detex.l"
2629 {KILLARGS(1);}
2630 YY_BREAK
2631 case 84:
2632 /* rule 84 can match eol */
2633 YY_RULE_SETUP
2634 #line 347 "../../../texk/detex/detex-src/detex.l"
2635 {
2636 putchar('(');
2637 footnoteLevel = currBracesLevel;
2638 ++currBracesLevel;
2639 }
2640 YY_BREAK
2641 case 85:
2642 YY_RULE_SETUP
2643 #line 352 "../../../texk/detex/detex-src/detex.l"
2644 /* ignore \verb<ch>...<ch> */ {
2645 if (fLatex) {
2646 int verbchar, c;
2647 verbchar = input();
2648 if (verbchar < ' ') {
2649 /* would be nice to include input filenames and line numbers */
2650 ErrorExit("\\verb not complete before eof");
2651 }
2652 while ((c = input()) != verbchar && c != '\n' && c != EOF && c != 0) {
2653 putchar(c);
2654 }
2655 if (c != verbchar) {
2656 ErrorExit("\\verb not complete before eof");
2657 }
2658 }
2659 }
2660 YY_BREAK
2661 case 86:
2662 YY_RULE_SETUP
2663 #line 369 "../../../texk/detex/detex-src/detex.l"
2664 { LATEX; KILLARGS(2); }
2665 YY_BREAK
2666 case 87:
2667 YY_RULE_SETUP
2668 #line 370 "../../../texk/detex/detex-src/detex.l"
2669 { LATEX; KILLARGS(2); }
2670 YY_BREAK
2671 case 88:
2672 YY_RULE_SETUP
2673 #line 371 "../../../texk/detex/detex-src/detex.l"
2674 { LATEX; KILLARGS(3); }
2675 YY_BREAK
2676 case 89:
2677 YY_RULE_SETUP
2678 #line 373 "../../../texk/detex/detex-src/detex.l"
2679 /* ignore def begin */ {BEGIN Define; IGNORE;}
2680 YY_BREAK
2681 case 90:
2682 YY_RULE_SETUP
2683 #line 374 "../../../texk/detex/detex-src/detex.l"
2684 BEGIN Normal;
2685 YY_BREAK
2686 case 91:
2687 /* rule 91 can match eol */
2688 YY_RULE_SETUP
2689 #line 375 "../../../texk/detex/detex-src/detex.l"
2690 NEWLINE;
2691 YY_BREAK
2692 case 92:
2693 YY_RULE_SETUP
2694 #line 376 "../../../texk/detex/detex-src/detex.l"
2695 ;
2696 YY_BREAK
2697 case 93:
2698 YY_RULE_SETUP
2699 #line 378 "../../../texk/detex/detex-src/detex.l"
2700 /* formula mode */ {LaBEGIN LaFormula; NOUN;}
2701 YY_BREAK
2702 case 94:
2703 YY_RULE_SETUP
2704 #line 379 "../../../texk/detex/detex-src/detex.l"
2705 BEGIN Normal;
2706 YY_BREAK
2707 case 95:
2708 /* rule 95 can match eol */
2709 YY_RULE_SETUP
2710 #line 380 "../../../texk/detex/detex-src/detex.l"
2711 NEWLINE;
2712 YY_BREAK
2713 case 96:
2714 YY_RULE_SETUP
2715 #line 381 "../../../texk/detex/detex-src/detex.l"
2716 VERBNOUN;
2717 YY_BREAK
2718 case 97:
2719 YY_RULE_SETUP
2720 #line 382 "../../../texk/detex/detex-src/detex.l"
2721 ;
2722 YY_BREAK
2723 case 98:
2724 YY_RULE_SETUP
2725 #line 384 "../../../texk/detex/detex-src/detex.l"
2726 /* display mode */ {LaBEGIN LaDisplay; NOUN;}
2727 YY_BREAK
2728 case 99:
2729 YY_RULE_SETUP
2730 #line 385 "../../../texk/detex/detex-src/detex.l"
2731 BEGIN Normal;
2732 YY_BREAK
2733 case 100:
2734 /* rule 100 can match eol */
2735 YY_RULE_SETUP
2736 #line 386 "../../../texk/detex/detex-src/detex.l"
2737 NEWLINE;
2738 YY_BREAK
2739 case 101:
2740 YY_RULE_SETUP
2741 #line 387 "../../../texk/detex/detex-src/detex.l"
2742 VERBNOUN;
2743 YY_BREAK
2744 case 102:
2745 YY_RULE_SETUP
2746 #line 388 "../../../texk/detex/detex-src/detex.l"
2747 ;
2748 YY_BREAK
2749 case 103:
2750 YY_RULE_SETUP
2751 #line 390 "../../../texk/detex/detex-src/detex.l"
2752 /* display mode */ {BEGIN Display; NOUN;}
2753 YY_BREAK
2754 case 104:
2755 YY_RULE_SETUP
2756 #line 391 "../../../texk/detex/detex-src/detex.l"
2757 BEGIN Normal;
2758 YY_BREAK
2759 case 105:
2760 /* rule 105 can match eol */
2761 YY_RULE_SETUP
2762 #line 392 "../../../texk/detex/detex-src/detex.l"
2763 NEWLINE;
2764 YY_BREAK
2765 case 106:
2766 YY_RULE_SETUP
2767 #line 393 "../../../texk/detex/detex-src/detex.l"
2768 VERBNOUN;
2769 YY_BREAK
2770 case 107:
2771 YY_RULE_SETUP
2772 #line 394 "../../../texk/detex/detex-src/detex.l"
2773 ;
2774 YY_BREAK
2775 case 108:
2776 YY_RULE_SETUP
2777 #line 396 "../../../texk/detex/detex-src/detex.l"
2778 /* math mode */ {BEGIN Math; NOUN;}
2779 YY_BREAK
2780 case 109:
2781 YY_RULE_SETUP
2782 #line 397 "../../../texk/detex/detex-src/detex.l"
2783 BEGIN Normal;
2784 YY_BREAK
2785 case 110:
2786 /* rule 110 can match eol */
2787 YY_RULE_SETUP
2788 #line 398 "../../../texk/detex/detex-src/detex.l"
2789 ;
2790 YY_BREAK
2791 case 111:
2792 YY_RULE_SETUP
2793 #line 399 "../../../texk/detex/detex-src/detex.l"
2794 ;
2795 YY_BREAK
2796 case 112:
2797 YY_RULE_SETUP
2798 #line 400 "../../../texk/detex/detex-src/detex.l"
2799 VERBNOUN;
2800 YY_BREAK
2801 case 113:
2802 YY_RULE_SETUP
2803 #line 401 "../../../texk/detex/detex-src/detex.l"
2804 ;
2805 YY_BREAK
2806 case 114:
2807 YY_RULE_SETUP
2808 #line 403 "../../../texk/detex/detex-src/detex.l"
2809 /* process files */ {LaBEGIN LaInclude; IGNORE;}
2810 YY_BREAK
2811 case 115:
2812 YY_RULE_SETUP
2813 #line 404 "../../../texk/detex/detex-src/detex.l"
2814 { IncludeFile(yytext);
2815 BEGIN Normal;
2816 }
2817 YY_BREAK
2818 case 116:
2819 /* rule 116 can match eol */
2820 YY_RULE_SETUP
2821 #line 407 "../../../texk/detex/detex-src/detex.l"
2822 NEWLINE;
2823 YY_BREAK
2824 case 117:
2825 YY_RULE_SETUP
2826 #line 408 "../../../texk/detex/detex-src/detex.l"
2827 ;
2828 YY_BREAK
2829 case 118:
2830 YY_RULE_SETUP
2831 #line 410 "../../../texk/detex/detex-src/detex.l"
2832 {BEGIN IncludeOnly; IGNORE;}
2833 YY_BREAK
2834 case 119:
2835 YY_RULE_SETUP
2836 #line 411 "../../../texk/detex/detex-src/detex.l"
2837 AddInclude(yytext);
2838 YY_BREAK
2839 case 120:
2840 YY_RULE_SETUP
2841 #line 412 "../../../texk/detex/detex-src/detex.l"
2842 { if (csbIncList == 0)
2843 *rgsbIncList[csbIncList++] = '\0';
2844 BEGIN Normal;
2845 }
2846 YY_BREAK
2847 case 121:
2848 /* rule 121 can match eol */
2849 YY_RULE_SETUP
2850 #line 416 "../../../texk/detex/detex-src/detex.l"
2851 NEWLINE;
2852 YY_BREAK
2853 case 122:
2854 YY_RULE_SETUP
2855 #line 417 "../../../texk/detex/detex-src/detex.l"
2856 ;
2857 YY_BREAK
2858 case 123:
2859 YY_RULE_SETUP
2860 #line 419 "../../../texk/detex/detex-src/detex.l"
2861 /* process files */ {LaBEGIN LaSubfile; IGNORE;}
2862 YY_BREAK
2863 case 124:
2864 YY_RULE_SETUP
2865 #line 420 "../../../texk/detex/detex-src/detex.l"
2866 { IncludeFile(yytext);
2867 BEGIN Normal;
2868 }
2869 YY_BREAK
2870 case 125:
2871 /* rule 125 can match eol */
2872 YY_RULE_SETUP
2873 #line 423 "../../../texk/detex/detex-src/detex.l"
2874 NEWLINE;
2875 YY_BREAK
2876 case 126:
2877 YY_RULE_SETUP
2878 #line 424 "../../../texk/detex/detex-src/detex.l"
2879 ;
2880 YY_BREAK
2881 case 127:
2882 YY_RULE_SETUP
2883 #line 426 "../../../texk/detex/detex-src/detex.l"
2884 {BEGIN Input; IGNORE;}
2885 YY_BREAK
2886 case 128:
2887 YY_RULE_SETUP
2888 #line 427 "../../../texk/detex/detex-src/detex.l"
2889 { InputFile(yytext);
2890 BEGIN Normal;
2891 }
2892 YY_BREAK
2893 case 129:
2894 /* rule 129 can match eol */
2895 YY_RULE_SETUP
2896 #line 430 "../../../texk/detex/detex-src/detex.l"
2897 NEWLINE;
2898 YY_BREAK
2899 case 130:
2900 YY_RULE_SETUP
2901 #line 431 "../../../texk/detex/detex-src/detex.l"
2902 ;
2903 YY_BREAK
2904 /* escaping commands */
2905 case 131:
2906 YY_RULE_SETUP
2907 #line 434 "../../../texk/detex/detex-src/detex.l"
2908 putchar('/');
2909 YY_BREAK
2910 case 132:
2911 YY_RULE_SETUP
2912 #line 435 "../../../texk/detex/detex-src/detex.l"
2913 putchar('%');
2914 YY_BREAK
2915 case 133:
2916 /* rule 133 can match eol */
2917 YY_RULE_SETUP
2918 #line 437 "../../../texk/detex/detex-src/detex.l"
2919 /* handle ligatures */ {(void)printf("%.2s", yytext+1);}
2920 YY_BREAK
2921 case 134:
2922 /* rule 134 can match eol */
2923 YY_RULE_SETUP
2924 #line 438 "../../../texk/detex/detex-src/detex.l"
2925 {(void)printf("%.1s", yytext+1);}
2926 YY_BREAK
2927 case 135:
2928 YY_RULE_SETUP
2929 #line 439 "../../../texk/detex/detex-src/detex.l"
2930 {NEWLINE;} /*BEGIN LaBreak;*/
2931 YY_BREAK
2932 case 136:
2933 YY_RULE_SETUP
2934 #line 441 "../../../texk/detex/detex-src/detex.l"
2935 /* ignore other \cs */ {BEGIN Control; IGNORE;}
2936 YY_BREAK
2937 case 137:
2938 YY_RULE_SETUP
2939 #line 442 "../../../texk/detex/detex-src/detex.l"
2940 SPACE;
2941 YY_BREAK
2942 case 138:
2943 /* rule 138 can match eol */
2944 YY_RULE_SETUP
2945 #line 443 "../../../texk/detex/detex-src/detex.l"
2946 NEWLINE;
2947 YY_BREAK
2948 case 139:
2949 YY_RULE_SETUP
2950 #line 444 "../../../texk/detex/detex-src/detex.l"
2951 IGNORE;
2952 YY_BREAK
2953 case 140:
2954 YY_RULE_SETUP
2955 #line 445 "../../../texk/detex/detex-src/detex.l"
2956 { if (yytext==NULL || strlen(yytext)==0
2957 || atoi(yytext)>=0)
2958 NEWLINE;
2959 BEGIN Normal;
2960 }
2961 YY_BREAK
2962 case 141:
2963 YY_RULE_SETUP
2964 #line 451 "../../../texk/detex/detex-src/detex.l"
2965 IGNORE;
2966 YY_BREAK
2967 case 142:
2968 YY_RULE_SETUP
2969 #line 452 "../../../texk/detex/detex-src/detex.l"
2970 IGNORE;
2971 YY_BREAK
2972 case 143:
2973 /* rule 143 can match eol */
2974 YY_RULE_SETUP
2975 #line 453 "../../../texk/detex/detex-src/detex.l"
2976 {BEGIN Normal; /*NEWLINE;*/}
2977 YY_BREAK
2978 case 144:
2979 YY_RULE_SETUP
2980 #line 454 "../../../texk/detex/detex-src/detex.l"
2981 {++currBracesLevel;BEGIN Normal; IGNORE;}
2982 YY_BREAK
2983 case 145:
2984 YY_RULE_SETUP
2985 #line 455 "../../../texk/detex/detex-src/detex.l"
2986 {BEGIN Normal; IGNORE;}
2987 YY_BREAK
2988 case 146:
2989 YY_RULE_SETUP
2990 #line 456 "../../../texk/detex/detex-src/detex.l"
2991 {yyless(0);BEGIN Normal;}
2992 YY_BREAK
2993 case 147:
2994 YY_RULE_SETUP
2995 #line 458 "../../../texk/detex/detex-src/detex.l"
2996 /* special characters */ IGNORE;
2997 YY_BREAK
2998 case 148:
2999 YY_RULE_SETUP
3000 #line 459 "../../../texk/detex/detex-src/detex.l"
3001 IGNORE;
3002 YY_BREAK
3003 case 149:
3004 YY_RULE_SETUP
3005 #line 460 "../../../texk/detex/detex-src/detex.l"
3006 SPACE;
3007 YY_BREAK
3008 case 150:
3009 YY_RULE_SETUP
3010 #line 461 "../../../texk/detex/detex-src/detex.l"
3011 putchar('-');
3012 YY_BREAK
3013 case 151:
3014 YY_RULE_SETUP
3015 #line 462 "../../../texk/detex/detex-src/detex.l"
3016 putchar('"');
3017 YY_BREAK
3018 case 152:
3019 YY_RULE_SETUP
3020 #line 463 "../../../texk/detex/detex-src/detex.l"
3021 putchar('\'');
3022 YY_BREAK
3023 case 153:
3024 YY_RULE_SETUP
3025 #line 464 "../../../texk/detex/detex-src/detex.l"
3026 putchar('"');
3027 YY_BREAK
3028 case 154:
3029 YY_RULE_SETUP
3030 #line 465 "../../../texk/detex/detex-src/detex.l"
3031 putchar('"');
3032 YY_BREAK
3033 /* braces */
3034 case 155:
3035 YY_RULE_SETUP
3036 #line 468 "../../../texk/detex/detex-src/detex.l"
3037 { ++currBracesLevel;
3038 }
3039 YY_BREAK
3040 case 156:
3041 YY_RULE_SETUP
3042 #line 470 "../../../texk/detex/detex-src/detex.l"
3043 {
3044 --currBracesLevel;
3045 if (currBracesLevel == footnoteLevel) {
3046 putchar(')');
3047 footnoteLevel = -100;
3048 }
3049 }
3050 YY_BREAK
3051 case 157:
3052 YY_RULE_SETUP
3053 #line 477 "../../../texk/detex/detex-src/detex.l"
3054 { if (fWord)
3055 (void)printf("%s\n", yytext);
3056 else
3057 ECHO;
3058 }
3059 YY_BREAK
3060 case 158:
3061 YY_RULE_SETUP
3062 #line 482 "../../../texk/detex/detex-src/detex.l"
3063 if (!fWord) ECHO;
3064 YY_BREAK
3065 case 159:
3066 YY_RULE_SETUP
3067 #line 483 "../../../texk/detex/detex-src/detex.l"
3068 { INCRLINENO; if (!fWord) ECHO; }
3069 YY_BREAK
3070 case 160:
3071 /* rule 160 can match eol */
3072 YY_RULE_SETUP
3073 #line 484 "../../../texk/detex/detex-src/detex.l"
3074 { if (!fWord) NEWLINE; }
3075 YY_BREAK
3076 case 161:
3077 YY_RULE_SETUP
3078 #line 485 "../../../texk/detex/detex-src/detex.l"
3079 if (!fWord) putchar('\t');
3080 YY_BREAK
3081 case 162:
3082 YY_RULE_SETUP
3083 #line 487 "../../../texk/detex/detex-src/detex.l"
3084 { BEGIN LaOptArg; }
3085 YY_BREAK
3086 case 163:
3087 YY_RULE_SETUP
3088 #line 488 "../../../texk/detex/detex-src/detex.l"
3089 { cOpenBrace++; }
3090 YY_BREAK
3091 case 164:
3092 /* rule 164 can match eol */
3093 YY_RULE_SETUP
3094 #line 489 "../../../texk/detex/detex-src/detex.l"
3095 { cOpenBrace--; INCRLINENO;
3096 if (cOpenBrace == 0)
3097 {
3098 if (--cArgs==0)
3099 BEGIN Normal;
3100 }
3101 }
3102 YY_BREAK
3103 case 165:
3104 YY_RULE_SETUP
3105 #line 496 "../../../texk/detex/detex-src/detex.l"
3106 ;
3107 YY_BREAK
3108 case 166:
3109 YY_RULE_SETUP
3110 #line 497 "../../../texk/detex/detex-src/detex.l"
3111 BEGIN LaMacro;
3112 YY_BREAK
3113 case 167:
3114 /* rule 167 can match eol */
3115 YY_RULE_SETUP
3116 #line 498 "../../../texk/detex/detex-src/detex.l"
3117 ;
3118 YY_BREAK
3119 case 168:
3120 YY_RULE_SETUP
3121 #line 500 "../../../texk/detex/detex-src/detex.l"
3122 { BEGIN LaOptArg2; }
3123 YY_BREAK
3124 case 169:
3125 YY_RULE_SETUP
3126 #line 501 "../../../texk/detex/detex-src/detex.l"
3127 { if (cOpenBrace == 0)
3128 {
3129 if (--cArgs==0)
3130 {
3131 BEGIN Normal;
3132 cOpenBrace--;
3133 }
3134 }
3135 cOpenBrace++;
3136 }
3137 YY_BREAK
3138 case 170:
3139 YY_RULE_SETUP
3140 #line 511 "../../../texk/detex/detex-src/detex.l"
3141 { cOpenBrace--; }
3142 YY_BREAK
3143 case 171:
3144 YY_RULE_SETUP
3145 #line 512 "../../../texk/detex/detex-src/detex.l"
3146 ;
3147 YY_BREAK
3148 case 172:
3149 YY_RULE_SETUP
3150 #line 513 "../../../texk/detex/detex-src/detex.l"
3151 BEGIN LaMacro2;
3152 YY_BREAK
3153 case 173:
3154 YY_RULE_SETUP
3155 #line 514 "../../../texk/detex/detex-src/detex.l"
3156 ;
3157 YY_BREAK
3158 case 174:
3159 YY_RULE_SETUP
3160 #line 515 "../../../texk/detex/detex-src/detex.l"
3161 ECHO;
3162 YY_BREAK
3163 #line 3164 "../../../texk/detex/detex-src/detex.c"
3164 case YY_STATE_EOF(INITIAL):
3165 case YY_STATE_EOF(Define):
3166 case YY_STATE_EOF(Display):
3167 case YY_STATE_EOF(IncludeOnly):
3168 case YY_STATE_EOF(Input):
3169 case YY_STATE_EOF(Math):
3170 case YY_STATE_EOF(Normal):
3171 case YY_STATE_EOF(Control):
3172 case YY_STATE_EOF(LaBegin):
3173 case YY_STATE_EOF(LaDisplay):
3174 case YY_STATE_EOF(LaEnd):
3175 case YY_STATE_EOF(LaEnv):
3176 case YY_STATE_EOF(LaFormula):
3177 case YY_STATE_EOF(LaInclude):
3178 case YY_STATE_EOF(LaSubfile):
3179 case YY_STATE_EOF(LaMacro):
3180 case YY_STATE_EOF(LaOptArg):
3181 case YY_STATE_EOF(LaMacro2):
3182 case YY_STATE_EOF(LaOptArg2):
3183 case YY_STATE_EOF(LaVerbatim):
3184 case YY_STATE_EOF(LaBreak):
3185 case YY_STATE_EOF(LaPicture):
3186 yyterminate();
3187
3188 case YY_END_OF_BUFFER:
3189 {
3190 /* Amount of text matched not including the EOB char. */
3191 int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;
3192
3193 /* Undo the effects of YY_DO_BEFORE_ACTION. */
3194 *yy_cp = (yy_hold_char);
3195 YY_RESTORE_YY_MORE_OFFSET
3196
3197 if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
3198 {
3199 /* We're scanning a new file or input source. It's
3200 * possible that this happened because the user
3201 * just pointed yyin at a new source and called
3202 * yylex(). If so, then we have to assure
3203 * consistency between YY_CURRENT_BUFFER and our
3204 * globals. Here is the right place to do so, because
3205 * this is the first action (other than possibly a
3206 * back-up) that will match for the new input source.
3207 */
3208 (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
3209 YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
3210 YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
3211 }
3212
3213 /* Note that here we test for yy_c_buf_p "<=" to the position
3214 * of the first EOB in the buffer, since yy_c_buf_p will
3215 * already have been incremented past the NUL character
3216 * (since all states make transitions on EOB to the
3217 * end-of-buffer state). Contrast this with the test
3218 * in input().
3219 */
3220 if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
3221 { /* This was really a NUL. */
3222 yy_state_type yy_next_state;
3223
3224 (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text;
3225
3226 yy_current_state = yy_get_previous_state( );
3227
3228 /* Okay, we're now positioned to make the NUL
3229 * transition. We couldn't have
3230 * yy_get_previous_state() go ahead and do it
3231 * for us because it doesn't know how to deal
3232 * with the possibility of jamming (and we don't
3233 * want to build jamming into it because then it
3234 * will run more slowly).
3235 */
3236
3237 yy_next_state = yy_try_NUL_trans( yy_current_state );
3238
3239 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
3240
3241 if ( yy_next_state )
3242 {
3243 /* Consume the NUL. */
3244 yy_cp = ++(yy_c_buf_p);
3245 yy_current_state = yy_next_state;
3246 goto yy_match;
3247 }
3248
3249 else
3250 {
3251 yy_cp = (yy_last_accepting_cpos);
3252 yy_current_state = (yy_last_accepting_state);
3253 goto yy_find_action;
3254 }
3255 }
3256
3257 else switch ( yy_get_next_buffer( ) )
3258 {
3259 case EOB_ACT_END_OF_FILE:
3260 {
3261 (yy_did_buffer_switch_on_eof) = 0;
3262
3263 if ( yywrap( ) )
3264 {
3265 /* Note: because we've taken care in
3266 * yy_get_next_buffer() to have set up
3267 * yytext, we can now set up
3268 * yy_c_buf_p so that if some total
3269 * hoser (like flex itself) wants to
3270 * call the scanner after we return the
3271 * YY_NULL, it'll still work - another
3272 * YY_NULL will get returned.
3273 */
3274 (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ;
3275
3276 yy_act = YY_STATE_EOF(YY_START);
3277 goto do_action;
3278 }
3279
3280 else
3281 {
3282 if ( ! (yy_did_buffer_switch_on_eof) )
3283 YY_NEW_FILE;
3284 }
3285 break;
3286 }
3287
3288 case EOB_ACT_CONTINUE_SCAN:
3289 (yy_c_buf_p) =
3290 (yytext_ptr) + yy_amount_of_matched_text;
3291
3292 yy_current_state = yy_get_previous_state( );
3293
3294 yy_cp = (yy_c_buf_p);
3295 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
3296 goto yy_match;
3297
3298 case EOB_ACT_LAST_MATCH:
3299 (yy_c_buf_p) =
3300 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)];
3301
3302 yy_current_state = yy_get_previous_state( );
3303
3304 yy_cp = (yy_c_buf_p);
3305 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
3306 goto yy_find_action;
3307 }
3308 break;
3309 }
3310
3311 default:
3312 YY_FATAL_ERROR(
3313 "fatal flex scanner internal error--no action found" );
3314 } /* end of action switch */
3315 } /* end of scanning one token */
3316 } /* end of user's declarations */
3317 } /* end of yylex */
3318
3319 /* yy_get_next_buffer - try to read in a new buffer
3320 *
3321 * Returns a code representing an action:
3322 * EOB_ACT_LAST_MATCH -
3323 * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
3324 * EOB_ACT_END_OF_FILE - end of file
3325 */
3326 static int yy_get_next_buffer (void)
3327 {
3328 char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
3329 char *source = (yytext_ptr);
3330 yy_size_t number_to_move, i;
3331 int ret_val;
3332
3333 if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )
3334 YY_FATAL_ERROR(
3335 "fatal flex scanner internal error--end of buffer missed" );
3336
3337 if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
3338 { /* Don't try to fill the buffer, so this is an EOF. */
3339 if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )
3340 {
3341 /* We matched a single character, the EOB, so
3342 * treat this as a final EOF.
3343 */
3344 return EOB_ACT_END_OF_FILE;
3345 }
3346
3347 else
3348 {
3349 /* We matched some text prior to the EOB, first
3350 * process it.
3351 */
3352 return EOB_ACT_LAST_MATCH;
3353 }
3354 }
3355
3356 /* Try to read more data. */
3357
3358 /* First move last chars to start of buffer. */
3359 number_to_move = (yy_size_t) ((yy_c_buf_p) - (yytext_ptr)) - 1;
3360
3361 for ( i = 0; i < number_to_move; ++i )
3362 *(dest++) = *(source++);
3363
3364 if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
3365 /* don't do the read, it's not guaranteed to return an EOF,
3366 * just force an EOF
3367 */
3368 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;
3369
3370 else
3371 {
3372 yy_size_t num_to_read =
3373 YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
3374
3375 while ( num_to_read <= 0 )
3376 { /* Not enough room in the buffer - grow it. */
3377
3378 /* just a shorter name for the current buffer */
3379 YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
3380
3381 int yy_c_buf_p_offset =
3382 (int) ((yy_c_buf_p) - b->yy_ch_buf);
3383
3384 if ( b->yy_is_our_buffer )
3385 {
3386 yy_size_t new_size = b->yy_buf_size * 2;
3387
3388 if ( new_size <= 0 )
3389 b->yy_buf_size += b->yy_buf_size / 8;
3390 else
3391 b->yy_buf_size *= 2;
3392
3393 b->yy_ch_buf = (char *)
3394 /* Include room in for 2 EOB chars. */
3395 yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 );
3396 }
3397 else
3398 /* Can't grow it, we don't own it. */
3399 b->yy_ch_buf = 0;
3400
3401 if ( ! b->yy_ch_buf )
3402 YY_FATAL_ERROR(
3403 "fatal error - scanner input buffer overflow" );
3404
3405 (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset];
3406
3407 num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
3408 number_to_move - 1;
3409
3410 }
3411
3412 if ( num_to_read > YY_READ_BUF_SIZE )
3413 num_to_read = YY_READ_BUF_SIZE;
3414
3415 /* Read in more data. */
3416 YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
3417 (yy_n_chars), num_to_read );
3418
3419 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3420 }
3421
3422 if ( (yy_n_chars) == 0 )
3423 {
3424 if ( number_to_move == YY_MORE_ADJ )
3425 {
3426 ret_val = EOB_ACT_END_OF_FILE;
3427 yyrestart(yyin );
3428 }
3429
3430 else
3431 {
3432 ret_val = EOB_ACT_LAST_MATCH;
3433 YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
3434 YY_BUFFER_EOF_PENDING;
3435 }
3436 }
3437
3438 else
3439 ret_val = EOB_ACT_CONTINUE_SCAN;
3440
3441 if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
3442 /* Extend the array by 50%, plus the number we really need. */
3443 yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);
3444 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size );
3445 if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
3446 YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
3447 }
3448
3449 (yy_n_chars) += number_to_move;
3450 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR;
3451 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR;
3452
3453 (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
3454
3455 return ret_val;
3456 }
3457
3458 /* yy_get_previous_state - get the state just before the EOB char was reached */
3459
3460 static yy_state_type yy_get_previous_state (void)
3461 {
3462 yy_state_type yy_current_state;
3463 char *yy_cp;
3464
3465 yy_current_state = (yy_start);
3466
3467 for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
3468 {
3469 YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
3470 if ( yy_accept[yy_current_state] )
3471 {
3472 (yy_last_accepting_state) = yy_current_state;
3473 (yy_last_accepting_cpos) = yy_cp;
3474 }
3475 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3476 {
3477 yy_current_state = (int) yy_def[yy_current_state];
3478 if ( yy_current_state >= 1362 )
3479 yy_c = yy_meta[(unsigned int) yy_c];
3480 }
3481 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3482 }
3483
3484 return yy_current_state;
3485 }
3486
3487 /* yy_try_NUL_trans - try to make a transition on the NUL character
3488 *
3489 * synopsis
3490 * next_state = yy_try_NUL_trans( current_state );
3491 */
3492 static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state )
3493 {
3494 int yy_is_jam;
3495 char *yy_cp = (yy_c_buf_p);
3496
3497 YY_CHAR yy_c = 1;
3498 if ( yy_accept[yy_current_state] )
3499 {
3500 (yy_last_accepting_state) = yy_current_state;
3501 (yy_last_accepting_cpos) = yy_cp;
3502 }
3503 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3504 {
3505 yy_current_state = (int) yy_def[yy_current_state];
3506 if ( yy_current_state >= 1362 )
3507 yy_c = yy_meta[(unsigned int) yy_c];
3508 }
3509 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3510 yy_is_jam = (yy_current_state == 1361);
3511
3512 return yy_is_jam ? 0 : yy_current_state;
3513 }
3514
3515 #ifndef YY_NO_UNPUT
3516
3517 #endif
3518
3519 #ifndef YY_NO_INPUT
3520 #ifdef __cplusplus
3521 static int yyinput (void)
3522 #else
3523 static int input (void)
3524 #endif
3525
3526 {
3527 int c;
3528
3529 *(yy_c_buf_p) = (yy_hold_char);
3530
3531 if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR )
3532 {
3533 /* yy_c_buf_p now points to the character we want to return.
3534 * If this occurs *before* the EOB characters, then it's a
3535 * valid NUL; if not, then we've hit the end of the buffer.
3536 */
3537 if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
3538 /* This was really a NUL. */
3539 *(yy_c_buf_p) = '\0';
3540
3541 else
3542 { /* need more input */
3543 yy_size_t offset = (yy_c_buf_p) - (yytext_ptr);
3544 ++(yy_c_buf_p);
3545
3546 switch ( yy_get_next_buffer( ) )
3547 {
3548 case EOB_ACT_LAST_MATCH:
3549 /* This happens because yy_g_n_b()
3550 * sees that we've accumulated a
3551 * token and flags that we need to
3552 * try matching the token before
3553 * proceeding. But for input(),
3554 * there's no matching to consider.
3555 * So convert the EOB_ACT_LAST_MATCH
3556 * to EOB_ACT_END_OF_FILE.
3557 */
3558
3559 /* Reset buffer status. */
3560 yyrestart(yyin );
3561
3562 /*FALLTHROUGH*/
3563
3564 case EOB_ACT_END_OF_FILE:
3565 {
3566 if ( yywrap( ) )
3567 return EOF;
3568
3569 if ( ! (yy_did_buffer_switch_on_eof) )
3570 YY_NEW_FILE;
3571 #ifdef __cplusplus
3572 return yyinput();
3573 #else
3574 return input();
3575 #endif
3576 }
3577
3578 case EOB_ACT_CONTINUE_SCAN:
3579 (yy_c_buf_p) = (yytext_ptr) + offset;
3580 break;
3581 }
3582 }
3583 }
3584
3585 c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */
3586 *(yy_c_buf_p) = '\0'; /* preserve yytext */
3587 (yy_hold_char) = *++(yy_c_buf_p);
3588
3589 return c;
3590 }
3591 #endif /* ifndef YY_NO_INPUT */
3592
3593 /** Immediately switch to a different input stream.
3594 * @param input_file A readable stream.
3595 *
3596 * @note This function does not reset the start condition to @c INITIAL .
3597 */
3598 void yyrestart (FILE * input_file )
3599 {
3600
3601 if ( ! YY_CURRENT_BUFFER ){
3602 yyensure_buffer_stack ();
3603 YY_CURRENT_BUFFER_LVALUE =
3604 yy_create_buffer(yyin,YY_BUF_SIZE );
3605 }
3606
3607 yy_init_buffer(YY_CURRENT_BUFFER,input_file );
3608 yy_load_buffer_state( );
3609 }
3610
3611 /** Switch to a different input buffer.
3612 * @param new_buffer The new input buffer.
3613 *
3614 */
3615 void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer )
3616 {
3617
3618 /* TODO. We should be able to replace this entire function body
3619 * with
3620 * yypop_buffer_state();
3621 * yypush_buffer_state(new_buffer);
3622 */
3623 yyensure_buffer_stack ();
3624 if ( YY_CURRENT_BUFFER == new_buffer )
3625 return;
3626
3627 if ( YY_CURRENT_BUFFER )
3628 {
3629 /* Flush out information for old buffer. */
3630 *(yy_c_buf_p) = (yy_hold_char);
3631 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
3632 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3633 }
3634
3635 YY_CURRENT_BUFFER_LVALUE = new_buffer;
3636 yy_load_buffer_state( );
3637
3638 /* We don't actually know whether we did this switch during
3639 * EOF (yywrap()) processing, but the only time this flag
3640 * is looked at is after yywrap() is called, so it's safe
3641 * to go ahead and always set it.
3642 */
3643 (yy_did_buffer_switch_on_eof) = 1;
3644 }
3645
3646 static void yy_load_buffer_state (void)
3647 {
3648 (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
3649 (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
3650 yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
3651 (yy_hold_char) = *(yy_c_buf_p);
3652 }
3653
3654 /** Allocate and initialize an input buffer state.
3655 * @param file A readable stream.
3656 * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
3657 *
3658 * @return the allocated buffer state.
3659 */
3660 YY_BUFFER_STATE yy_create_buffer (FILE * file, int size )
3661 {
3662 YY_BUFFER_STATE b;
3663
3664 b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) );
3665 if ( ! b )
3666 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
3667
3668 b->yy_buf_size = (yy_size_t)size;
3669
3670 /* yy_ch_buf has to be 2 characters longer than the size given because
3671 * we need to put in 2 end-of-buffer characters.
3672 */
3673 b->yy_ch_buf = (char *) yyalloc(b->yy_buf_size + 2 );
3674 if ( ! b->yy_ch_buf )
3675 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
3676
3677 b->yy_is_our_buffer = 1;
3678
3679 yy_init_buffer(b,file );
3680
3681 return b;
3682 }
3683
3684 /** Destroy the buffer.
3685 * @param b a buffer created with yy_create_buffer()
3686 *
3687 */
3688 void yy_delete_buffer (YY_BUFFER_STATE b )
3689 {
3690
3691 if ( ! b )
3692 return;
3693
3694 if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
3695 YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
3696
3697 if ( b->yy_is_our_buffer )
3698 yyfree((void *) b->yy_ch_buf );
3699
3700 yyfree((void *) b );
3701 }
3702
3703 /* Initializes or reinitializes a buffer.
3704 * This function is sometimes called more than once on the same buffer,
3705 * such as during a yyrestart() or at EOF.
3706 */
3707 static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file )
3708
3709 {
3710 int oerrno = errno;
3711
3712 yy_flush_buffer(b );
3713
3714 b->yy_input_file = file;
3715 b->yy_fill_buffer = 1;
3716
3717 /* If b is the current buffer, then yy_init_buffer was _probably_
3718 * called from yyrestart() or through yy_get_next_buffer.
3719 * In that case, we don't want to reset the lineno or column.
3720 */
3721 if (b != YY_CURRENT_BUFFER){
3722 b->yy_bs_lineno = 1;
3723 b->yy_bs_column = 0;
3724 }
3725
3726 b->yy_is_interactive = 0;
3727
3728 errno = oerrno;
3729 }
3730
3731 /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
3732 * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
3733 *
3734 */
3735 void yy_flush_buffer (YY_BUFFER_STATE b )
3736 {
3737 if ( ! b )
3738 return;
3739
3740 b->yy_n_chars = 0;
3741
3742 /* We always need two end-of-buffer characters. The first causes
3743 * a transition to the end-of-buffer state. The second causes
3744 * a jam in that state.
3745 */
3746 b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
3747 b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
3748
3749 b->yy_buf_pos = &b->yy_ch_buf[0];
3750
3751 b->yy_at_bol = 1;
3752 b->yy_buffer_status = YY_BUFFER_NEW;
3753
3754 if ( b == YY_CURRENT_BUFFER )
3755 yy_load_buffer_state( );
3756 }
3757
3758 /** Pushes the new state onto the stack. The new state becomes
3759 * the current state. This function will allocate the stack
3760 * if necessary.
3761 * @param new_buffer The new state.
3762 *
3763 */
3764 void yypush_buffer_state (YY_BUFFER_STATE new_buffer )
3765 {
3766 if (new_buffer == NULL)
3767 return;
3768
3769 yyensure_buffer_stack();
3770
3771 /* This block is copied from yy_switch_to_buffer. */
3772 if ( YY_CURRENT_BUFFER )
3773 {
3774 /* Flush out information for old buffer. */
3775 *(yy_c_buf_p) = (yy_hold_char);
3776 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
3777 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3778 }
3779
3780 /* Only push if top exists. Otherwise, replace top. */
3781 if (YY_CURRENT_BUFFER)
3782 (yy_buffer_stack_top)++;
3783 YY_CURRENT_BUFFER_LVALUE = new_buffer;
3784
3785 /* copied from yy_switch_to_buffer. */
3786 yy_load_buffer_state( );
3787 (yy_did_buffer_switch_on_eof) = 1;
3788 }
3789
3790 /** Removes and deletes the top of the stack, if present.
3791 * The next element becomes the new top.
3792 *
3793 */
3794 void yypop_buffer_state (void)
3795 {
3796 if (!YY_CURRENT_BUFFER)
3797 return;
3798
3799 yy_delete_buffer(YY_CURRENT_BUFFER );
3800 YY_CURRENT_BUFFER_LVALUE = NULL;
3801 if ((yy_buffer_stack_top) > 0)
3802 --(yy_buffer_stack_top);
3803
3804 if (YY_CURRENT_BUFFER) {
3805 yy_load_buffer_state( );
3806 (yy_did_buffer_switch_on_eof) = 1;
3807 }
3808 }
3809
3810 /* Allocates the stack if it does not exist.
3811 * Guarantees space for at least one push.
3812 */
3813 static void yyensure_buffer_stack (void)
3814 {
3815 yy_size_t num_to_alloc;
3816
3817 if (!(yy_buffer_stack)) {
3818
3819 /* First allocation is just for 2 elements, since we don't know if this
3820 * scanner will even need a stack. We use 2 instead of 1 to avoid an
3821 * immediate realloc on the next call.
3822 */
3823 num_to_alloc = 1; // After all that talk, this was set to 1 anyways...
3824 (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc
3825 (num_to_alloc * sizeof(struct yy_buffer_state*)
3826 );
3827 if ( ! (yy_buffer_stack) )
3828 YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
3829
3830 memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
3831
3832 (yy_buffer_stack_max) = num_to_alloc;
3833 (yy_buffer_stack_top) = 0;
3834 return;
3835 }
3836
3837 if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){
3838
3839 /* Increase the buffer to prepare for a possible push. */
3840 yy_size_t grow_size = 8 /* arbitrary grow size */;
3841
3842 num_to_alloc = (yy_buffer_stack_max) + grow_size;
3843 (yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc
3844 ((yy_buffer_stack),
3845 num_to_alloc * sizeof(struct yy_buffer_state*)
3846 );
3847 if ( ! (yy_buffer_stack) )
3848 YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
3849
3850 /* zero only the new slots.*/
3851 memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));
3852 (yy_buffer_stack_max) = num_to_alloc;
3853 }
3854 }
3855
3856 /** Setup the input buffer state to scan directly from a user-specified character buffer.
3857 * @param base the character buffer
3858 * @param size the size in bytes of the character buffer
3859 *
3860 * @return the newly allocated buffer state object.
3861 */
3862 YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size )
3863 {
3864 YY_BUFFER_STATE b;
3865
3866 if ( size < 2 ||
3867 base[size-2] != YY_END_OF_BUFFER_CHAR ||
3868 base[size-1] != YY_END_OF_BUFFER_CHAR )
3869 /* They forgot to leave room for the EOB's. */
3870 return 0;
3871
3872 b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) );
3873 if ( ! b )
3874 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
3875
3876 b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
3877 b->yy_buf_pos = b->yy_ch_buf = base;
3878 b->yy_is_our_buffer = 0;
3879 b->yy_input_file = 0;
3880 b->yy_n_chars = b->yy_buf_size;
3881 b->yy_is_interactive = 0;
3882 b->yy_at_bol = 1;
3883 b->yy_fill_buffer = 0;
3884 b->yy_buffer_status = YY_BUFFER_NEW;
3885
3886 yy_switch_to_buffer(b );
3887
3888 return b;
3889 }
3890
3891 /** Setup the input buffer state to scan a string. The next call to yylex() will
3892 * scan from a @e copy of @a str.
3893 * @param yystr a NUL-terminated string to scan
3894 *
3895 * @return the newly allocated buffer state object.
3896 * @note If you want to scan bytes that may contain NUL values, then use
3897 * yy_scan_bytes() instead.
3898 */
3899 YY_BUFFER_STATE yy_scan_string (yyconst char * yystr )
3900 {
3901
3902 return yy_scan_bytes(yystr,strlen(yystr) );
3903 }
3904
3905 /** Setup the input buffer state to scan the given bytes. The next call to yylex() will
3906 * scan from a @e copy of @a bytes.
3907 * @param yybytes the byte buffer to scan
3908 * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
3909 *
3910 * @return the newly allocated buffer state object.
3911 */
3912 YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len )
3913 {
3914 YY_BUFFER_STATE b;
3915 char *buf;
3916 yy_size_t n;
3917 yy_size_t i;
3918
3919 /* Get memory for full buffer, including space for trailing EOB's. */
3920 n = _yybytes_len + 2;
3921 buf = (char *) yyalloc(n );
3922 if ( ! buf )
3923 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
3924
3925 for ( i = 0; i < _yybytes_len; ++i )
3926 buf[i] = yybytes[i];
3927
3928 buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
3929
3930 b = yy_scan_buffer(buf,n );
3931 if ( ! b )
3932 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
3933
3934 /* It's okay to grow etc. this buffer, and we should throw it
3935 * away when we're done.
3936 */
3937 b->yy_is_our_buffer = 1;
3938
3939 return b;
3940 }
3941
3942 #ifndef YY_EXIT_FAILURE
3943 #define YY_EXIT_FAILURE 2
3944 #endif
3945
3946 static void yy_fatal_error (yyconst char* msg )
3947 {
3948 (void) fprintf( stderr, "%s\n", msg );
3949 exit( YY_EXIT_FAILURE );
3950 }
3951
3952 /* Redefine yyless() so it works in section 3 code. */
3953
3954 #undef yyless
3955 #define yyless(n) \
3956 do \
3957 { \
3958 /* Undo effects of setting up yytext. */ \
3959 int yyless_macro_arg = (n); \
3960 YY_LESS_LINENO(yyless_macro_arg);\
3961 yytext[yyleng] = (yy_hold_char); \
3962 (yy_c_buf_p) = yytext + yyless_macro_arg; \
3963 (yy_hold_char) = *(yy_c_buf_p); \
3964 *(yy_c_buf_p) = '\0'; \
3965 yyleng = yyless_macro_arg; \
3966 } \
3967 while ( 0 )
3968
3969 /* Accessor methods (get/set functions) to struct members. */
3970
3971 /** Get the current line number.
3972 *
3973 */
3974 int yyget_lineno (void)
3975 {
3976
3977 return yylineno;
3978 }
3979
3980 /** Get the input stream.
3981 *
3982 */
3983 FILE *yyget_in (void)
3984 {
3985 return yyin;
3986 }
3987
3988 /** Get the output stream.
3989 *
3990 */
3991 FILE *yyget_out (void)
3992 {
3993 return yyout;
3994 }
3995
3996 /** Get the length of the current token.
3997 *
3998 */
3999 yy_size_t yyget_leng (void)
4000 {
4001 return yyleng;
4002 }
4003
4004 /** Get the current token.
4005 *
4006 */
4007
4008 char *yyget_text (void)
4009 {
4010 return yytext;
4011 }
4012
4013 /** Set the current line number.
4014 * @param _line_number line number
4015 *
4016 */
4017 void yyset_lineno (int _line_number )
4018 {
4019
4020 yylineno = _line_number;
4021 }
4022
4023 /** Set the input stream. This does not discard the current
4024 * input buffer.
4025 * @param _in_str A readable stream.
4026 *
4027 * @see yy_switch_to_buffer
4028 */
4029 void yyset_in (FILE * _in_str )
4030 {
4031 yyin = _in_str ;
4032 }
4033
4034 void yyset_out (FILE * _out_str )
4035 {
4036 yyout = _out_str ;
4037 }
4038
4039 int yyget_debug (void)
4040 {
4041 return yy_flex_debug;
4042 }
4043
4044 void yyset_debug (int _bdebug )
4045 {
4046 yy_flex_debug = _bdebug ;
4047 }
4048
4049 static int yy_init_globals (void)
4050 {
4051 /* Initialization is the same as for the non-reentrant scanner.
4052 * This function is called from yylex_destroy(), so don't allocate here.
4053 */
4054
4055 (yy_buffer_stack) = 0;
4056 (yy_buffer_stack_top) = 0;
4057 (yy_buffer_stack_max) = 0;
4058 (yy_c_buf_p) = (char *) 0;
4059 (yy_init) = 0;
4060 (yy_start) = 0;
4061
4062 /* Defined in main.c */
4063 #ifdef YY_STDINIT
4064 yyin = stdin;
4065 yyout = stdout;
4066 #else
4067 yyin = (FILE *) 0;
4068 yyout = (FILE *) 0;
4069 #endif
4070
4071 /* For future reference: Set errno on error, since we are called by
4072 * yylex_init()
4073 */
4074 return 0;
4075 }
4076
4077 /* yylex_destroy is for both reentrant and non-reentrant scanners. */
4078 int yylex_destroy (void)
4079 {
4080
4081 /* Pop the buffer stack, destroying each element. */
4082 while(YY_CURRENT_BUFFER){
4083 yy_delete_buffer(YY_CURRENT_BUFFER );
4084 YY_CURRENT_BUFFER_LVALUE = NULL;
4085 yypop_buffer_state();
4086 }
4087
4088 /* Destroy the stack itself. */
4089 yyfree((yy_buffer_stack) );
4090 (yy_buffer_stack) = NULL;
4091
4092 /* Reset the globals. This is important in a non-reentrant scanner so the next time
4093 * yylex() is called, initialization will occur. */
4094 yy_init_globals( );
4095
4096 return 0;
4097 }
4098
4099 /*
4100 * Internal utility routines.
4101 */
4102
4103 #ifndef yytext_ptr
4104 static void yy_flex_strncpy (char* s1, yyconst char * s2, int n )
4105 {
4106
4107 int i;
4108 for ( i = 0; i < n; ++i )
4109 s1[i] = s2[i];
4110 }
4111 #endif
4112
4113 #ifdef YY_NEED_STRLEN
4114 static int yy_flex_strlen (yyconst char * s )
4115 {
4116 int n;
4117 for ( n = 0; s[n]; ++n )
4118 ;
4119
4120 return n;
4121 }
4122 #endif
4123
4124 void *yyalloc (yy_size_t size )
4125 {
4126 return (void *) malloc( size );
4127 }
4128
4129 void *yyrealloc (void * ptr, yy_size_t size )
4130 {
4131
4132 /* The cast to (char *) in the following accommodates both
4133 * implementations that use char* generic pointers, and those
4134 * that use void* generic pointers. It works with the latter
4135 * because both ANSI C and C++ allow castless assignment from
4136 * any pointer type to void*, and deal with argument conversions
4137 * as though doing an assignment.
4138 */
4139 return (void *) realloc( (char *) ptr, size );
4140 }
4141
4142 void yyfree (void * ptr )
4143 {
4144 free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
4145 }
4146
4147 #define YYTABLES_NAME "yytables"
4148
4149 #line 515 "../../../texk/detex/detex-src/detex.l"
4150
4151
4152
4153 /******
4154 ** main --
4155 ** Set sbProgName to the base of arg 0.
4156 ** Set the input paths.
4157 ** Check for options
4158 ** -c echo LaTeX \cite, \ref, and \pageref values
4159 ** -e <env-list> list of LaTeX environments to ignore
4160 ** -l force latex mode
4161 ** -n do not follow \input and \include
4162 ** -s replace control sequences with space
4163 ** -t force tex mode
4164 ** -w word only output
4165 ** -1 output some location information
4166 ** Set the list of LaTeX environments to ignore.
4167 ** Process each input file.
4168 ** If no input files are specified on the command line, process stdin.
4169 ******/
4170
4171 int
4172 main(int cArgs, char *rgsbArgs[])
4173 {
4174 char *pch, sbBadOpt[2];
4175 const char *sbEnvList = DEFAULTENV;
4176 int fSawFile = 0, iArgs = 1;
4177
4178 /* get base name and decide what we are doing, detex or delatex */
4179 #ifdef OS2
4180 char drive[_MAX_DRIVE], dir[_MAX_DIR];
4181 char fname[_MAX_FNAME], ext[_MAX_EXT];
4182 #ifdef __EMX__
4183 _wildcard(&cArgs, &rgsbArgs);
4184 _response(&cArgs, &rgsbArgs);
4185 #endif
4186 _splitpath (rgsbArgs[0], drive, dir, fname, ext);
4187 sbProgName = strlwr(fname);
4188 #elif defined(KPATHSEA)
4189 kpse_set_program_name (rgsbArgs[0], NULL);
4190 sbProgName = kpse_program_name;
4191 #else
4192 if ((sbProgName = strrchr(rgsbArgs[0], '/')) != NULL)
4193 sbProgName++;
4194 else
4195 sbProgName = rgsbArgs[0];
4196 #endif
4197 if (strcmp("delatex",sbProgName) == 0)
4198 fLatex = 1;
4199
4200 #ifndef KPATHSEA
4201 /* set rgsbInputPaths for use with TexOpen() */
4202 SetInputPaths();
4203 #endif
4204
4205 /* process command line options */
4206 while (iArgs < cArgs && *(pch = rgsbArgs[iArgs]) == CHOPT) {
4207 while (*++pch)
4208 switch (*pch) {
4209 case CHCITEOPT:
4210 fCite = 1;
4211 break;
4212 case CHENVOPT:
4213 if (++iArgs >= cArgs) {
4214 ErrorExit("-e option requires an argument");
4215 }
4216 sbEnvList = rgsbArgs[iArgs];
4217 break;
4218 case CHLATEXOPT:
4219 fLatex = 1;
4220 break;
4221 case CHNOFOLLOWOPT:
4222 fFollow = 0;
4223 break;
4224 case CHSPACEOPT:
4225 fSpace = 1;
4226 break;
4227 case CHTEXOPT:
4228 fForcetex = 1;
4229 break;
4230 case CHWORDOPT:
4231 fWord = 1;
4232 break;
4233 case CHREPLACE:
4234 fReplace = 1;
4235 break;
4236 case CHVERSIONOPT:
4237 VersionExit();
4238 break;
4239 case CHSRCLOC:
4240 fSrcLoc = 1;
4241 break;
4242 default:
4243 sbBadOpt[0] = *pch;
4244 sbBadOpt[1] = '\0';
4245 Warning("unknown option ignored -", sbBadOpt);
4246 UsageExit();
4247 }
4248 iArgs++;
4249 }
4250 SetEnvIgnore(sbEnvList);
4251
4252 #ifdef WIN32
4253 _setmode(fileno(stdout), _O_BINARY);
4254 #endif
4255
4256 /* process input files */
4257 for (; iArgs < cArgs; iArgs++) {
4258 fSawFile++;
4259 if ((yyin = TexOpen(rgsbArgs[iArgs])) == NULL) {
4260 Warning("can't open file", rgsbArgs[iArgs]);
4261 continue;;
4262 }
4263 fFileNames[csb] = rgsbArgs[iArgs];
4264 fFileLines[csb] = 1;
4265 BEGIN Normal;
4266 (void)yylex();
4267 }
4268
4269 /* if there were no input files, assume stdin */
4270 if (!fSawFile) {
4271 yyin = stdin;
4272 #ifdef OS2
4273 if (isatty(fileno(stdin)))
4274 OS2UsageExit();
4275 #endif
4276 BEGIN Normal;
4277 (void)yylex();
4278 }
4279 #ifndef FLEX_SCANNER
4280 if (YYSTATE != Normal)
4281 ErrorExit("input contains an unterminated mode or environment");
4282 #endif
4283 return(0);
4284 }
4285
4286 #ifdef FLEX_SCANNER
4287 #undef yywrap
4288 #endif
4289
4290 /******
4291 ** yywrap -- handles EOF for lex. Check to see if the stack of open files
4292 ** has anything on it. If it does, set yyin to the to value. If not
4293 ** return the termination signal for lex.
4294 ******/
4295
4296 int
4297 yywrap(void)
4298 {
4299 (void)fclose(yyin);
4300 #ifdef FLEX_SCANNER
4301 /* Pop context state */
4302 if (csb > 0) {
4303 free(fFileNames[csb]);
4304 yy_delete_buffer(YY_CURRENT_BUFFER );
4305 yy_switch_to_buffer(rgsb[--csb] );
4306 }
4307 #endif /* FLEX_SCANNER */
4308 if (cfp > 0) {
4309 yyin = rgfp[--cfp];
4310 return(0);
4311 }
4312 return(1);
4313 }
4314
4315 #ifdef OS2
4316
4317 /******
4318 ** yyless -- return characters to the input stream. Some systems don't have
4319 ** a yyless routine
4320 ******/
4321
4322 void
4323 yyless(int n)
4324 {
4325 int i = strlen(yytext);
4326
4327 while (i > n) unput(yytext[--i]);
4328 yytext[yyleng = n] = '\0';
4329 }
4330 #endif
4331
4332 /******
4333 ** PrintPrefix -- In case fSrcLoc is 1 and we are about to
4334 ** print the first column of a line, we want to output the location of
4335 ** that line in the original LaTeX document it came from.
4336 ******/
4337
4338 void
4339 PrintPrefix()
4340 {
4341 if (fSrcLoc && fIsColumn0) {
4342 printf("%s:%d: ", fFileNames[csb], fFileLines[csb]);
4343 fIsColumn0 = 0;
4344 }
4345 }
4346
4347 /******
4348 ** LineBreak -- choses the proper way to break a line. If '-1' option is
4349 ** enabled we also want to output some source location information.
4350 ******/
4351
4352 void
4353 LineBreak()
4354 {
4355 if (fWord) return;
4356 PrintPrefix();
4357 putchar('\n');
4358 fFileLines[csb]++; fIsColumn0=1;
4359 }
4360
4361 /******
4362 ** Echo -- If we are at column 0 and have specified '-1'; output
4363 ** the source location information.
4364 ******/
4365
4366 void
4367 Echo()
4368 {
4369 PrintPrefix();
4370 fprintf(yyout, "%s", yytext);
4371 }
4372
4373 /******
4374 ** IncrLineNo -- Increase the correct linenumber counter and
4375 ** reset the the 'fIsColumn0' to true.
4376 ******/
4377
4378 void
4379 IncrLineNo()
4380 {
4381 char *c;
4382 for (c=yytext; *c != '\0'; c++) {
4383 if (*c == '\n') {
4384 fFileLines[csb]++; fIsColumn0=1;
4385 }
4386 }
4387 }
4388
4389 /******
4390 ** Ignore -- Since we might need to track source location information we
4391 ** cannot just ignore text. We must at least increase the linenumber counter.
4392 ******/
4393
4394 void
4395 Ignore()
4396 {
4397 IncrLineNo();
4398 if (fSpace && !fWord) putchar(' ');
4399 }
4400
4401 /******
4402 ** SetEnvIgnore -- sets rgsbEnvIgnore to the values indicated by the
4403 ** sbEnvList.
4404 ******/
4405
4406 void
4407 SetEnvIgnore(const char *sbEnvList)
4408 {
4409 char *sb;
4410 sb = SafeMalloc(strlen(sbEnvList) + 1, "malloc for SetEnvIgnore failed");
4411 (void) strcpy(sb, sbEnvList);
4412
4413
4414 csbEnvIgnore = SeparateList(sb, rgsbEnvIgnore, CHENVSEP, MAXENVS);
4415 if (csbEnvIgnore == my_ERROR)
4416 ErrorExit("The environment list contains too many environments");
4417 }
4418
4419 /******
4420 ** BeginEnv -- checks to see if sbEnv is in the list rgsbEnvIgnore. If it
4421 ** is, sbCurrentIgnoredEnv is set to sbEnv.
4422 ******/
4423
4424 int
4425 BeginEnv(const char *sbEnv)
4426 {
4427 int i;
4428
4429 if (!fLatex) return(0);
4430 for (i = 0; i < csbEnvIgnore; ++i)
4431 if (strcmp(sbEnv, rgsbEnvIgnore[i]) == 0) {
4432 (void)strcpy(sbCurrentIgnoredEnv, sbEnv);
4433 return(1);
4434 }
4435 return(0);
4436 }
4437
4438 /******
4439 ** EndEnv -- checks to see if sbEnv is the current environment being ignored.
4440 ******/
4441
4442 int
4443 EndEnv(const char *sbEnv)
4444 {
4445 if (!fLatex) return(0);
4446 if (strcmp(sbEnv, sbCurrentIgnoredEnv) == 0)
4447 return(1);
4448 return(0);
4449 }
4450
4451 /******
4452 ** InputFile -- push the current yyin and open sbFile. If the open fails,
4453 ** the sbFile is ignored.
4454 ******/
4455
4456
4457 void
4458 InputFile(char *sbFile)
4459 {
4460 if (!fFollow)
4461 return;
4462 rgfp[cfp++] = yyin;
4463 if ((yyin = TexOpen(sbFile)) == NULL) {
4464 Warning("can't open \\input file", sbFile);
4465 yyin = rgfp[--cfp];
4466 return;
4467 }
4468 #ifdef FLEX_SCANNER
4469 rgsb[csb++] = YY_CURRENT_BUFFER;
4470 fFileLines[csb] = 1;
4471 fFileNames[csb] = strdup(sbFile);
4472 yy_switch_to_buffer(yy_create_buffer(yyin,YY_BUF_SIZE ) );
4473 #endif /* FLEX_SCANNER */
4474 }
4475
4476 /******
4477 ** IncludeFile -- if sbFile is not in the rgsbIncList, push current yyin
4478 ** and open sbFile. If the open fails, the sbFile is ignored.
4479 ******/
4480
4481 void
4482 IncludeFile(char *sbFile)
4483 {
4484 if (!fFollow)
4485 return;
4486 if (!InList(sbFile))
4487 return;
4488 rgfp[cfp++] = yyin;
4489 if ((yyin = TexOpen(sbFile)) == NULL) {
4490 Warning("can't open \\include file", sbFile);
4491 yyin = rgfp[--cfp];
4492 return;
4493 }
4494 #ifdef FLEX_SCANNER
4495 rgsb[csb++] = YY_CURRENT_BUFFER;
4496 fFileLines[csb] = 1;
4497 fFileNames[csb] = strdup(sbFile);
4498 yy_switch_to_buffer(yy_create_buffer(yyin,YY_BUF_SIZE ) );
4499 #endif /* FLEX_SCANNER */
4500 }
4501
4502 /******
4503 ** AddInclude -- adds sbFile to the rgsbIncList and increments csbIncList.
4504 ** If the include list is too long, sbFile is ignored.
4505 ******/
4506
4507 void
4508 AddInclude(char *sbFile)
4509 {
4510 if (!fFollow)
4511 return;
4512 if (csbIncList >= MAXINCLIST)
4513 Warning("\\includeonly list is too long, ignoring", sbFile);
4514 rgsbIncList[csbIncList] = SafeMalloc(strlen(sbFile) + 1, "malloc for AddInclude failed");
4515 (void)strcpy(rgsbIncList[csbIncList++], sbFile);
4516 }
4517
4518 /******
4519 ** InList -- checks to see if sbFile is in the rgsbIncList. If there is
4520 ** no list, all files are assumed to be "in the list".
4521 ******/
4522
4523 int
4524 InList(char *sbFile)
4525 {
4526 char *pch, sbBase[PATH_MAX];
4527 int i;
4528
4529 if (csbIncList == 0) /* no list */
4530 return(1);
4531 (void)strcpy(sbBase, sbFile);
4532 if ((pch = strrchr(sbBase, '.')) != NULL)
4533 *pch = '\0';
4534 i = 0;
4535 while ((i < csbIncList) && rgsbIncList[i])
4536 if (strcmp(rgsbIncList[i++], sbBase) == 0)
4537 return(1);
4538 return(0);
4539 }
4540
4541 #ifndef KPATHSEA
4542 /******
4543 ** SetInputPaths -- sets rgsbInputPaths to the values indicated by the
4544 ** TEXINPUTS environment variable if set or else DEFAULTINPUTS. If
4545 ** the user's TEXINPUTS has a leading ':' prepend the DEFAULTINPUTS
4546 ** to the path, if there is a trailing ':' append the DEFAULTINPUTS.
4547 ** This is consistent with the most recent TeX. However, this
4548 ** routine does not honor the '//' construct (expand subdirs).
4549 ******/
4550
4551 void
4552 SetInputPaths(void)
4553 {
4554 const char *sb;
4555 char *sbPaths;
4556 int cchDefaults, cchPaths;
4557
4558 cchDefaults = strlen(DEFAULTINPUTS);
4559 #ifdef OS2
4560 if ((sb = getenv("TEXINPUT")) == NULL)
4561 #endif
4562 if ((sb = getenv("TEXINPUTS")) == NULL)
4563 sb = DEFAULTINPUTS;
4564 cchPaths = strlen(sb);
4565 if (sb[0] == CHPATHSEP)
4566 cchPaths += cchDefaults;
4567 if (sb[strlen(sb) - 1] == CHPATHSEP)
4568 cchPaths += cchDefaults;
4569 sbPaths = SafeMalloc(cchPaths + 1, "malloc for SetInputPaths failed");
4570 sbPaths[0] = '\0';
4571 if (sb[0] == CHPATHSEP)
4572 (void)strcat(sbPaths, DEFAULTINPUTS);
4573 (void)strcat(sbPaths, sb);
4574 if (sb[strlen(sb) - 1] == CHPATHSEP)
4575 (void)strcat(sbPaths, DEFAULTINPUTS);
4576
4577 csbInputPaths = SeparateList(sbPaths, rgsbInputPaths, CHPATHSEP, MAXINPUTPATHS);
4578 if (csbInputPaths == my_ERROR)
4579 #ifdef OS2
4580 ErrorExit("TEXINPUT(S) environment variable has too many paths");
4581 #else
4582 ErrorExit("TEXINPUTS environment variable has too many paths");
4583 #endif
4584 }
4585 #endif
4586
4587 /******
4588 ** SeparateList -- takes a chSep separated list sbList, replaces the
4589 ** chSep's with NULLs and sets rgsbList[i] to the beginning of
4590 ** the ith word in sbList. The number of words is returned. A
4591 ** my_ERROR is returned if there are more than csbMax words.
4592 ******/
4593
4594 int
4595 SeparateList(char *sbList, char *rgsbList[], char chSep, int csbMax)
4596 {
4597 int csbList = 0;
4598
4599 while (sbList && *sbList && csbList < csbMax) {
4600 rgsbList[csbList++] = sbList;
4601 if ((sbList = strchr(sbList, chSep))) {
4602 *sbList++ = '\0';
4603 }
4604 }
4605 return(sbList && *sbList ? my_ERROR : csbList);
4606 }
4607
4608 /******
4609 ** TexOpen -- tries to open sbFile in each of the rgsbInputPaths in turn.
4610 ** For each input path the following order is used:
4611 ** file.tex - must be as named, if not there go to the next path
4612 ** file.ext - random extension, try it
4613 ** file - base name, add .tex and try it
4614 ** file - try it as is
4615 ** Notice that if file exists in the first path and file.tex exists in
4616 ** one of the other paths, file in the first path is what is opened.
4617 ** If the sbFile begins with a '/', no paths are searched.
4618 ******/
4619
4620 FILE *
4621 TexOpen(char *sbFile)
4622 {
4623 char *sbNew;
4624 #ifndef KPATHSEA
4625 char *pch;
4626 FILE *fp;
4627 int iPath;
4628 static char sbFullPath[PATH_MAX];
4629
4630 for (iPath = 0; iPath < csbInputPaths; iPath++) {
4631 #ifdef OS2
4632 if (*sbFile == '/' || *sbFile == '\\' || strchr(sbFile, ':')) { /* absolute path */
4633 #else
4634 if (*sbFile == '/') { /* absolute path */
4635 #endif
4636 (void)snprintf(sbFullPath, PATH_MAX-1, "%s", sbFile);
4637 iPath = csbInputPaths; /* only check once */
4638 } else {
4639 (void)snprintf(sbFullPath, PATH_MAX-1, "%s/%s", rgsbInputPaths[iPath], sbFile);
4640 }
4641 #ifdef OS2
4642 pch = sbFullPath;
4643 while (pch = strchr(pch, '\\')) {
4644 *pch = '/';
4645 }
4646 #endif
4647
4648 /* If sbFile ends in .tex then it must be there */
4649 if ((pch = strrchr(sbFullPath, '.')) != NULL
4650 && (strcmp(pch, ".tex") == 0)) {
4651 if ((fp = fopen(sbFullPath, "r")) != NULL)
4652 return(fp);
4653 else
4654 continue;
4655 }
4656
4657 /* if .<ext> then try to open it. the '.' represents */
4658 /* the beginning of an extension if it is not the first */
4659 /* character and it does not follow a '.' or a '/' */
4660 if (pch != NULL && pch > &(sbFullPath[0])
4661 && *(pch - 1) != '.' && *(pch - 1) != '/'
4662 && (fp = fopen(sbFullPath, "r")) != NULL) {
4663 return(fp);
4664 }
4665
4666 /* just base name, add .tex to the name */
4667 sbNew = SafeMalloc(strlen(sbFullPath) + 5, "malloc for TexOpen failed");
4668 (void)strcpy(sbNew, sbFullPath);
4669 (void)strcat(sbNew, ".tex");
4670 if ((fp = fopen(sbNew, "r")) != NULL) {
4671 free(sbNew);
4672 return(fp);
4673 }
4674 free(sbNew);
4675
4676 /* try sbFile regardless */
4677 if ((fp = fopen(sbFullPath, "r")) != NULL)
4678 return(fp);
4679 }
4680 return NULL;
4681 #else
4682 sbNew = kpse_find_file (sbFile, kpse_tex_format, false);
4683
4684 if (sbNew == NULL)
4685 return NULL;
4686
4687 return fopen (sbNew, "r");
4688 #endif
4689 }
4690
4691 /******
4692 ** SafeMalloc -- wrapper around malloc() to check for failure.
4693 ******/
4694
4695 char *
4696 SafeMalloc(int cch, const char *sbMessage)
4697 {
4698 char *sb;
4699
4700 if ((sb = (char *)malloc((unsigned)cch)) == NULL)
4701 ErrorExit(sbMessage);
4702 return(sb);
4703 }
4704
4705 /******
4706 ** Warning -- print a warning message preceded by the program name.
4707 ******/
4708
4709 void
4710 Warning(const char *sb1, const char *sb2)
4711 {
4712 (void)fprintf(stderr, "%s: warning: %s %s\n", sbProgName, sb1, sb2);
4713 }
4714
4715 /******
4716 ** ErrorExit -- print an error message preceded by the program name.
4717 ** Stdout is flushed and detex exits.
4718 ******/
4719
4720 void
4721 ErrorExit(const char *sb1)
4722 {
4723 (void)fflush(stdout);
4724 (void)fprintf(stderr, "%s: error: %s\n", sbProgName, sb1);
4725 exit(1);
4726 }
4727
4728 /******
4729 ** UsageExit -- print usage message and exit.
4730 ******/
4731
4732 void
4733 UsageExit(void)
4734 {
4735 (void)printf("\n%s [ -clnrstw1 ] [ -e environment-list ] [ filename[.tex] ... ]\n",
4736 sbProgName);
4737 puts("Strip (La)TeX commands from the input.\n\n \
4738 -c echo LaTeX \\cite, \\ref, and \\pageref values\n \
4739 -e <env-list> list of LaTeX environments to ignore\n \
4740 -l force latex mode\n \
4741 -n do not follow \\input, \\include and \\subfile\n \
4742 -r replace math with \"noun\" and \"noun verbs noun\" to preserve grammar\n \
4743 -s replace control sequences with space\n \
4744 -t force tex mode\n \
4745 -w word only output\n \
4746 -1 outputs the original file name and line number in the beginning of each line\n \
4747 -v show program version and exit\n\
4748 \n\
4749 opendetex home page: https://github.com/pkubowicz/opendetex");
4750 exit(0);
4751 }
4752
4753 /******
4754 ** VersionExit -- print version and exit.
4755 ******/
4756
4757 void
4758 VersionExit(void)
4759 {
4760 (void)printf("\nOpenDetex version %s\nhttps://github.com/pkubowicz/opendetex\n",
4761 VERSION);
4762 exit(0);
4763 }
4764