1 /* A lexical scanner generated by flex */
3 /* Scanner skeleton version:
4 * $Header: /home/daffy/u0/vern/flex/RCS/flex.skl,v 2.91 96/09/10 16:58:48 vern Exp $
8 #define YY_FLEX_MAJOR_VERSION 2
9 #define YY_FLEX_MINOR_VERSION 5
14 /* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
27 /* Use prototypes in function declarations. */
30 /* The "const" storage-class-modifier is valid. */
33 #else /* ! __cplusplus */
41 #endif /* ! __cplusplus */
60 #define YY_PROTO(proto) proto
62 #define YY_PROTO(proto) ()
65 /* Returned upon end-of-file. */
68 /* Promotes a possibly negative, possibly signed char to an unsigned
69 * integer for use as an array index. If the signed char is negative,
70 * we want to instead treat it as an 8-bit unsigned char, hence the
73 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
75 /* Enter a start condition. This macro really ought to take a parameter,
76 * but we do it the disgusting crufty way forced on us by the ()-less
77 * definition of BEGIN.
79 #define BEGIN yy_start = 1 + 2 *
81 /* Translate the current start state into a value that can be later handed
82 * to BEGIN to return to the state. The YYSTATE alias is for lex
85 #define YY_START ((yy_start - 1) / 2)
86 #define YYSTATE YY_START
88 /* Action number for EOF rule of a given start state. */
89 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
91 /* Special action meaning "start processing a new file". */
92 #define YY_NEW_FILE yyrestart( yyin )
94 #define YY_END_OF_BUFFER_CHAR 0
96 /* Size of default input buffer. */
97 #define YY_BUF_SIZE 16384
99 typedef struct yy_buffer_state *YY_BUFFER_STATE;
102 extern FILE *yyin, *yyout;
104 #define EOB_ACT_CONTINUE_SCAN 0
105 #define EOB_ACT_END_OF_FILE 1
106 #define EOB_ACT_LAST_MATCH 2
108 /* The funky do-while in the following #define is used to turn the definition
109 * int a single C statement (which needs a semi-colon terminator). This
110 * avoids problems with code like:
112 * if ( condition_holds )
115 * do_something_else();
117 * Prior to using the do-while the compiler would get upset at the
118 * "else" because it interpreted the "if" statement as being all
119 * done when it reached the ';' after the yyless() call.
122 /* Return all but the first 'n' matched characters back to the input stream. */
127 /* Undo effects of setting up yytext. */ \
128 *yy_cp = yy_hold_char; \
129 YY_RESTORE_YY_MORE_OFFSET \
130 yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
131 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
135 #define unput(c) yyunput( c, yytext_ptr )
137 /* The following is because we cannot portably get our hands on size_t
138 * (without autoconf's help, which isn't available because we want
139 * flex-generated scanners to compile on their own).
141 typedef unsigned int yy_size_t;
144 struct yy_buffer_state
148 char *yy_ch_buf; /* input buffer */
149 char *yy_buf_pos; /* current position in input buffer */
151 /* Size of input buffer in bytes, not including room for EOB
154 yy_size_t yy_buf_size;
156 /* Number of characters read into yy_ch_buf, not including EOB
161 /* Whether we "own" the buffer - i.e., we know we created it,
162 * and can realloc() it to grow it, and should free() it to
165 int yy_is_our_buffer;
167 /* Whether this is an "interactive" input source; if so, and
168 * if we're using stdio for input, then we want to use getc()
169 * instead of fread(), to make sure we stop fetching input after
172 int yy_is_interactive;
174 /* Whether we're considered to be at the beginning of a line.
175 * If so, '^' rules will be active on the next match, otherwise
180 /* Whether to try to fill the input buffer when we reach the
185 int yy_buffer_status;
186 #define YY_BUFFER_NEW 0
187 #define YY_BUFFER_NORMAL 1
188 /* When an EOF's been seen but there's still some text to process
189 * then we mark the buffer as YY_EOF_PENDING, to indicate that we
190 * shouldn't try reading from the input source any more. We might
191 * still have a bunch of tokens to match, though, because of
192 * possible backing-up.
194 * When we actually see the EOF, we change the status to "new"
195 * (via yyrestart()), so that the user can continue scanning by
196 * just pointing yyin at a new input file.
198 #define YY_BUFFER_EOF_PENDING 2
201 static YY_BUFFER_STATE yy_current_buffer = 0;
203 /* We provide macros for accessing buffer states in case in the
204 * future we want to put the buffer states in a more general
207 #define YY_CURRENT_BUFFER yy_current_buffer
210 /* yy_hold_char holds the character lost when yytext is formed. */
211 static char yy_hold_char;
213 static int yy_n_chars; /* number of characters read into yy_ch_buf */
218 /* Points to current character in buffer. */
219 static char *yy_c_buf_p = (char *) 0;
220 static int yy_init = 1; /* whether we need to initialize */
221 static int yy_start = 0; /* start state number */
223 /* Flag which is used to allow yywrap()'s to do buffer switches
224 * instead of setting up a fresh yyin. A bit of a hack ...
226 static int yy_did_buffer_switch_on_eof;
228 void yyrestart YY_PROTO(( FILE *input_file ));
230 void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
231 void yy_load_buffer_state YY_PROTO(( void ));
232 YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
233 void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
234 void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
235 void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
236 #define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
238 YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
239 YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str ));
240 YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
242 static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
243 static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
244 static void yy_flex_free YY_PROTO(( void * ));
246 #define yy_new_buffer yy_create_buffer
248 #define yy_set_interactive(is_interactive) \
250 if ( ! yy_current_buffer ) \
251 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
252 yy_current_buffer->yy_is_interactive = is_interactive; \
255 #define yy_set_bol(at_bol) \
257 if ( ! yy_current_buffer ) \
258 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
259 yy_current_buffer->yy_at_bol = at_bol; \
262 #define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
264 typedef unsigned char YY_CHAR;
265 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
266 typedef int yy_state_type;
267 extern char yytext[];
270 static yy_state_type yy_get_previous_state YY_PROTO(( void ));
271 static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
272 static int yy_get_next_buffer YY_PROTO(( void ));
273 static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
275 /* Done after the current pattern has been matched and before the
276 * corresponding action - sets up yytext.
278 #define YY_DO_BEFORE_ACTION \
279 yytext_ptr = yy_bp; \
280 yyleng = (int) (yy_cp - yy_bp); \
281 yy_hold_char = *yy_cp; \
283 if ( yyleng + yy_more_offset >= YYLMAX ) \
284 YY_FATAL_ERROR( "token too large, exceeds YYLMAX" ); \
285 yy_flex_strncpy( &yytext[yy_more_offset], yytext_ptr, yyleng + 1 ); \
286 yyleng += yy_more_offset; \
287 yy_prev_more_offset = yy_more_offset; \
288 yy_more_offset = 0; \
291 #define YY_NUM_RULES 311
292 #define YY_END_OF_BUFFER 312
293 static yyconst short int yy_accept[1176] =
295 0, 0, 0, 0, 0, 0, 312, 310, 309, 45,
296 43, 308, 54, 55, 99, 100, 306, 52, 53, 279,
297 58, 47, 57, 91, 145, 40, 40, 40, 46, 42,
298 259, 41, 258, 90, 304, 48, 310, 49, 86, 310,
299 310, 98, 98, 98, 98, 98, 98, 98, 103, 103,
300 103, 103, 103, 94, 101, 103, 103, 103, 95, 96,
301 103, 97, 103, 103, 102, 50, 51, 87, 298, 296,
302 296, 285, 285, 285, 293, 293, 285, 298, 285, 295,
303 298, 298, 298, 285, 311, 56, 44, 106, 306, 280,
304 265, 40, 0, 0, 260, 261, 304, 0, 307, 0,
306 264, 105, 0, 0, 0, 0, 0, 0, 0, 0,
307 0, 0, 0, 81, 0, 0, 0, 0, 0, 0,
308 0, 0, 210, 0, 0, 0, 0, 0, 0, 0,
309 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
310 0, 0, 0, 0, 0, 63, 64, 281, 0, 0,
311 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
312 0, 266, 267, 0, 144, 0, 0, 0, 0, 0,
313 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
314 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
315 0, 0, 0, 133, 0, 0, 76, 0, 0, 0,
317 0, 0, 0, 0, 0, 291, 283, 293, 0, 286,
318 288, 290, 289, 287, 295, 0, 0, 0, 284, 0,
319 56, 92, 93, 0, 0, 0, 305, 0, 0, 75,
320 80, 0, 16, 0, 111, 0, 0, 0, 0, 0,
321 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
322 0, 0, 0, 0, 59, 0, 146, 0, 0, 0,
323 0, 14, 0, 0, 0, 0, 0, 273, 83, 0,
324 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
325 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
326 0, 228, 0, 0, 0, 0, 78, 122, 0, 0,
328 22, 0, 0, 0, 0, 20, 0, 0, 0, 0,
329 0, 0, 121, 0, 0, 0, 0, 0, 85, 0,
330 0, 0, 0, 0, 18, 0, 0, 0, 0, 0,
331 0, 119, 0, 0, 0, 0, 0, 1, 104, 0,
332 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
333 0, 180, 0, 65, 275, 0, 0, 32, 0, 0,
334 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
335 0, 0, 0, 292, 0, 0, 0, 0, 0, 0,
336 253, 0, 0, 0, 0, 0, 0, 256, 0, 0,
337 0, 0, 2, 0, 0, 0, 0, 0, 0, 0,
339 0, 0, 0, 245, 0, 0, 0, 0, 0, 0,
340 0, 0, 62, 0, 162, 0, 0, 77, 257, 0,
341 302, 0, 0, 0, 82, 0, 0, 205, 238, 0,
342 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
343 0, 0, 4, 0, 0, 0, 136, 0, 0, 132,
344 0, 0, 0, 0, 0, 278, 0, 123, 0, 0,
345 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
346 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
347 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
348 0, 277, 0, 0, 0, 157, 0, 0, 68, 0,
350 0, 0, 0, 0, 0, 0, 229, 0, 34, 0,
351 0, 0, 0, 0, 0, 0, 0, 0, 0, 174,
352 129, 0, 127, 71, 0, 0, 0, 282, 0, 72,
353 0, 0, 0, 0, 0, 0, 0, 0, 73, 0,
354 36, 0, 0, 0, 0, 214, 221, 0, 135, 0,
355 0, 270, 0, 0, 0, 0, 134, 0, 0, 0,
356 0, 0, 0, 0, 0, 0, 0, 303, 0, 0,
357 0, 0, 0, 0, 60, 0, 37, 0, 0, 0,
358 0, 0, 0, 0, 0, 0, 0, 0, 235, 0,
359 0, 204, 0, 0, 23, 0, 0, 0, 21, 0,
361 38, 0, 0, 0, 0, 0, 0, 0, 0, 0,
362 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
363 268, 0, 0, 0, 216, 0, 0, 139, 0, 0,
364 0, 0, 0, 0, 0, 0, 137, 193, 25, 0,
365 79, 84, 0, 26, 0, 0, 0, 0, 0, 254,
366 5, 0, 24, 0, 0, 0, 0, 209, 246, 0,
367 0, 27, 0, 0, 61, 0, 297, 0, 0, 0,
368 0, 0, 0, 0, 219, 0, 0, 0, 0, 0,
369 0, 0, 0, 33, 0, 0, 138, 0, 0, 147,
370 0, 0, 131, 112, 0, 154, 0, 0, 130, 0,
372 117, 0, 124, 0, 0, 0, 0, 29, 0, 0,
373 0, 0, 0, 0, 0, 28, 0, 0, 0, 0,
374 211, 0, 0, 0, 236, 0, 0, 203, 107, 0,
375 128, 0, 0, 269, 0, 0, 0, 0, 0, 0,
376 276, 0, 0, 0, 0, 0, 0, 0, 0, 0,
377 0, 0, 0, 0, 0, 274, 0, 0, 0, 141,
378 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
379 0, 0, 0, 0, 148, 0, 0, 0, 0, 0,
380 0, 0, 0, 248, 0, 0, 0, 0, 0, 0,
381 247, 0, 0, 0, 0, 0, 0, 0, 0, 0,
383 0, 74, 0, 9, 0, 35, 0, 222, 0, 0,
384 215, 7, 0, 0, 263, 0, 0, 89, 0, 0,
385 0, 0, 262, 0, 0, 88, 163, 0, 0, 272,
386 0, 0, 0, 31, 0, 0, 0, 0, 0, 220,
387 0, 30, 0, 0, 0, 301, 0, 0, 0, 0,
388 0, 0, 0, 0, 233, 0, 0, 0, 109, 0,
389 0, 0, 0, 0, 0, 153, 190, 0, 0, 0,
390 0, 0, 0, 0, 218, 0, 19, 0, 0, 0,
391 0, 0, 166, 0, 0, 0, 118, 0, 0, 0,
392 0, 0, 0, 251, 0, 0, 0, 0, 194, 0,
394 0, 0, 0, 0, 0, 0, 249, 300, 0, 231,
395 149, 0, 0, 0, 0, 271, 0, 0, 255, 223,
396 0, 0, 0, 0, 3, 0, 0, 0, 0, 0,
397 0, 0, 299, 0, 165, 0, 0, 0, 0, 0,
398 0, 0, 0, 168, 0, 0, 0, 0, 0, 0,
399 0, 301, 0, 116, 0, 0, 0, 0, 0, 0,
400 0, 0, 0, 0, 0, 108, 0, 0, 0, 0,
401 0, 189, 0, 202, 0, 11, 0, 0, 217, 207,
402 0, 0, 0, 213, 0, 0, 0, 0, 0, 0,
403 159, 171, 152, 0, 160, 0, 158, 0, 0, 0,
405 0, 182, 0, 0, 300, 150, 0, 0, 0, 294,
406 0, 0, 17, 0, 196, 230, 0, 0, 185, 0,
407 234, 161, 164, 0, 67, 299, 299, 0, 0, 66,
408 125, 0, 170, 0, 0, 0, 0, 192, 0, 0,
409 0, 8, 0, 0, 142, 208, 0, 0, 0, 0,
410 0, 0, 0, 110, 0, 151, 237, 0, 173, 227,
411 0, 201, 0, 143, 0, 0, 120, 0, 114, 0,
412 0, 0, 0, 0, 0, 0, 183, 0, 0, 184,
413 197, 232, 0, 294, 294, 294, 224, 0, 6, 225,
414 0, 0, 70, 15, 69, 0, 239, 0, 0, 179,
416 0, 206, 39, 0, 0, 187, 0, 240, 155, 0,
417 0, 0, 10, 175, 200, 0, 140, 0, 115, 0,
418 0, 0, 0, 172, 191, 0, 0, 0, 0, 0,
419 0, 212, 0, 0, 0, 126, 12, 199, 0, 243,
420 242, 0, 0, 0, 113, 169, 177, 188, 195, 156,
421 181, 198, 226, 186, 13, 250, 0, 0, 0, 252,
422 0, 176, 0, 0, 0, 167, 178, 0, 0, 0,
426 static yyconst int yy_ec[256] =
428 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
429 1, 1, 4, 1, 1, 1, 1, 1, 1, 1,
430 1, 1, 1, 1, 1, 5, 1, 1, 1, 1,
431 1, 2, 6, 7, 8, 1, 9, 10, 11, 12,
432 13, 14, 15, 16, 17, 18, 19, 20, 21, 22,
433 23, 24, 23, 23, 23, 25, 23, 26, 27, 28,
434 29, 30, 31, 1, 32, 32, 32, 32, 32, 32,
435 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
436 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
437 34, 35, 36, 37, 38, 39, 40, 41, 42, 43,
439 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
440 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
441 64, 65, 66, 67, 68, 69, 1, 1, 1, 1,
442 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
443 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
444 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
445 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
446 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
447 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
448 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
450 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
451 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
452 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
453 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
454 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
458 static yyconst int yy_meta[70] =
460 1, 2, 3, 4, 1, 1, 4, 1, 1, 1,
461 1, 1, 5, 1, 1, 1, 1, 1, 1, 6,
462 6, 6, 6, 6, 6, 1, 1, 1, 1, 1,
463 1, 6, 7, 1, 1, 1, 1, 7, 8, 9,
464 9, 9, 9, 9, 9, 10, 10, 10, 10, 10,
465 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
466 10, 10, 10, 10, 10, 1, 1, 1, 1
469 static yyconst short int yy_base[1184] =
471 0, 0, 69, 0, 1446, 1445, 1451, 1454, 1454, 1454,
472 1447, 1454, 1454, 1454, 1454, 1439, 1437, 1454, 1454, 1454,
473 1454, 1454, 1454, 1454, 120, 120, 127, 133, 1454, 1454,
474 1419, 1454, 1416, 1454, 139, 1454, 163, 1454, 1454, 0,
475 166, 133, 151, 166, 181, 129, 176, 1388, 188, 130,
476 1384, 1399, 199, 200, 215, 148, 211, 1454, 230, 229,
477 242, 126, 247, 209, 1389, 1454, 1454, 1454, 1454, 1454,
478 1454, 1412, 1454, 1430, 286, 292, 168, 1410, 243, 298,
479 1394, 1384, 1389, 1368, 1427, 1454, 1454, 1454, 1422, 1454,
480 1454, 304, 230, 1375, 1454, 1454, 318, 300, 1454, 1428,
482 1454, 0, 265, 176, 1376, 1386, 153, 1388, 1381, 1386,
483 275, 241, 1371, 1454, 294, 1384, 1372, 1369, 1368, 1366,
484 1362, 1374, 1454, 227, 1373, 302, 1358, 1364, 1369, 312,
485 126, 1353, 1359, 1359, 1352, 1366, 1367, 298, 1349, 281,
486 1362, 314, 1354, 307, 1361, 1454, 1454, 188, 158, 1363,
487 1344, 1337, 319, 321, 1347, 1342, 1349, 335, 326, 1337,
488 325, 1454, 1454, 1334, 1454, 323, 1343, 1335, 1334, 1345,
489 1347, 342, 344, 1333, 1349, 332, 1340, 1341, 347, 1340,
490 340, 1326, 356, 1344, 1318, 357, 1327, 363, 1333, 1329,
491 1338, 1325, 362, 1322, 364, 372, 1454, 1322, 1317, 1326,
493 1331, 355, 1328, 322, 1317, 1454, 1454, 402, 0, 1454,
494 1454, 1454, 1454, 1454, 411, 1325, 1326, 1324, 1454, 1360,
495 1454, 1454, 1454, 1322, 407, 416, 1454, 1304, 1305, 1454,
496 1309, 1311, 1309, 1307, 371, 1301, 1306, 1303, 1294, 1313,
497 1311, 1303, 386, 1308, 1309, 1304, 1307, 1289, 1290, 1304,
498 1300, 1292, 1286, 1284, 1454, 1280, 1454, 1293, 1298, 393,
499 1286, 1289, 1277, 1287, 1275, 1280, 1280, 1288, 1454, 1286,
500 409, 1277, 1287, 1269, 1286, 1266, 1265, 1270, 1280, 1278,
501 1260, 1274, 1275, 1256, 1272, 1271, 1271, 401, 1265, 1261,
502 1252, 1454, 1266, 1266, 1249, 1267, 1454, 1247, 1261, 1256,
504 1249, 1244, 1253, 1235, 1251, 1244, 1245, 1237, 403, 412,
505 1234, 1250, 1252, 1252, 1244, 1246, 1232, 1238, 1454, 1243,
506 1246, 1241, 1244, 400, 1238, 1242, 1233, 1221, 1220, 1225,
507 1231, 398, 1232, 1231, 1215, 1226, 1221, 1454, 1454, 1220,
508 1213, 1212, 1224, 1209, 1211, 1208, 1207, 1218, 1210, 1208,
509 1205, 1197, 1204, 1454, 1454, 1213, 1205, 242, 1202, 1213,
510 1209, 1193, 1207, 1198, 1201, 1206, 1200, 1193, 1181, 1187,
511 1199, 1195, 1182, 0, 1192, 1191, 1185, 1196, 1192, 1178,
512 1454, 1170, 1189, 1173, 1172, 1186, 1170, 1454, 1170, 1165,
513 1182, 1175, 1176, 1171, 1182, 1167, 1177, 415, 1175, 1174,
515 1173, 1173, 1164, 1454, 1160, 1165, 1170, 1167, 1166, 1169,
516 1155, 1165, 1454, 1153, 1454, 1147, 1160, 1454, 1454, 1155,
517 1454, 1162, 1148, 318, 1454, 1160, 1140, 1454, 1153, 1153,
518 1154, 1151, 415, 1139, 1142, 418, 1148, 1149, 1145, 1145,
519 1128, 1129, 1454, 1138, 1134, 1126, 1131, 1131, 1137, 1454,
520 1138, 1122, 1125, 1117, 1122, 1454, 1118, 1454, 1126, 1131,
521 1108, 1127, 1130, 1127, 1124, 1120, 1122, 1104, 1120, 1106,
522 1111, 419, 419, 1102, 1109, 1113, 1107, 1098, 1112, 1097,
523 1101, 1096, 1094, 1092, 1106, 1109, 1089, 1107, 1106, 429,
524 1086, 1454, 1100, 1099, 1098, 1454, 1094, 1096, 1454, 1099,
526 1093, 417, 1091, 1082, 1088, 1077, 379, 1089, 1454, 1092,
527 1073, 1079, 1084, 1070, 1068, 1085, 1084, 1080, 1079, 1454,
528 1454, 1078, 1454, 1454, 1077, 1067, 1074, 1454, 1067, 1063,
529 1076, 1057, 1061, 1067, 1058, 1068, 1046, 421, 1055, 1064,
530 1454, 1048, 1066, 1048, 1052, 1454, 1454, 1059, 1454, 1051,
531 1044, 1057, 1055, 1045, 1053, 1053, 1454, 1052, 1037, 1049,
532 1033, 1043, 1042, 1046, 1030, 1030, 1043, 1454, 1039, 1026,
533 1028, 434, 1025, 1034, 1454, 1023, 443, 1035, 1034, 1020,
534 1029, 1016, 1027, 1071, 1014, 1028, 1029, 1024, 1046, 1025,
535 1026, 1454, 1008, 1006, 1454, 1003, 1010, 1003, 1454, 1003,
537 1454, 1007, 1005, 1011, 1002, 998, 1010, 996, 1008, 1000,
538 991, 1009, 985, 1007, 1002, 997, 996, 995, 984, 984,
539 1454, 197, 998, 995, 1454, 998, 995, 984, 992, 977,
540 969, 974, 972, 973, 975, 964, 975, 1454, 431, 972,
541 1454, 1454, 972, 433, 980, 976, 962, 963, 972, 1454,
542 1454, 966, 1454, 961, 962, 972, 1013, 1454, 1454, 966,
543 962, 1454, 960, 951, 1454, 966, 1454, 965, 951, 954,
544 958, 946, 964, 950, 1454, 951, 947, 936, 942, 945,
545 957, 943, 949, 456, 935, 943, 1454, 944, 948, 1454,
546 933, 941, 488, 1454, 986, 1454, 929, 932, 490, 926,
548 1454, 936, 925, 924, 941, 928, 928, 956, 916, 932,
549 916, 934, 926, 929, 912, 948, 929, 920, 927, 477,
550 1454, 922, 919, 910, 1454, 909, 891, 1454, 453, 890,
551 1454, 884, 893, 1454, 873, 887, 873, 865, 129, 285,
552 1454, 338, 450, 440, 441, 455, 451, 435, 458, 449,
553 448, 464, 449, 456, 453, 1454, 465, 457, 455, 1454,
554 459, 468, 476, 480, 463, 471, 473, 486, 487, 484,
555 476, 476, 483, 492, 491, 481, 482, 484, 491, 481,
556 493, 496, 489, 519, 543, 497, 507, 508, 495, 511,
557 1454, 512, 498, 500, 516, 504, 518, 519, 509, 514,
559 523, 513, 517, 1454, 521, 1454, 530, 1454, 527, 514,
560 1454, 1454, 515, 572, 1454, 526, 530, 1454, 577, 533,
561 528, 580, 1454, 532, 536, 1454, 1454, 532, 527, 1454,
562 541, 540, 545, 1454, 542, 532, 548, 542, 550, 1454,
563 536, 1454, 541, 555, 545, 581, 597, 550, 567, 557,
564 569, 565, 563, 570, 575, 566, 564, 563, 1454, 580,
565 585, 583, 570, 575, 566, 1454, 1454, 573, 588, 591,
566 577, 583, 596, 587, 1454, 599, 1454, 585, 597, 595,
567 607, 604, 1454, 596, 598, 593, 1454, 612, 602, 598,
568 613, 602, 614, 1454, 606, 617, 621, 607, 1454, 606,
570 616, 606, 622, 608, 620, 611, 1454, 650, 632, 1454,
571 1454, 633, 677, 634, 626, 1454, 641, 642, 1454, 1454,
572 642, 643, 646, 634, 1454, 639, 636, 630, 636, 637,
573 637, 654, 691, 655, 1454, 640, 657, 656, 640, 661,
574 655, 705, 654, 1454, 664, 674, 662, 676, 677, 682,
575 679, 710, 734, 1454, 683, 683, 680, 689, 685, 674,
576 686, 696, 688, 687, 690, 1454, 694, 692, 696, 708,
577 694, 1454, 707, 1454, 708, 1454, 699, 710, 1454, 1454,
578 703, 700, 709, 1454, 702, 719, 723, 716, 705, 720,
579 1454, 1454, 1454, 723, 1454, 717, 1454, 710, 711, 723,
581 731, 1454, 720, 730, 755, 1454, 738, 780, 782, 787,
582 729, 737, 1454, 750, 1454, 1454, 738, 753, 1454, 751,
583 1454, 1454, 1454, 741, 1454, 1454, 796, 756, 744, 1454,
584 1454, 751, 1454, 739, 802, 754, 763, 1454, 763, 753,
585 753, 1454, 778, 0, 1454, 1454, 770, 778, 766, 782,
586 774, 765, 791, 1454, 768, 1454, 1454, 774, 1454, 1454,
587 776, 1454, 781, 1454, 778, 785, 1454, 792, 1454, 783,
588 788, 791, 795, 786, 801, 802, 1454, 793, 794, 1454,
589 1454, 1454, 847, 849, 1454, 851, 1454, 797, 1454, 1454,
590 812, 809, 1454, 1454, 1454, 814, 1454, 0, 811, 1454,
592 800, 1454, 1454, 803, 856, 1454, 812, 821, 1454, 808,
593 824, 816, 1454, 1454, 1454, 830, 1454, 811, 1454, 813,
594 829, 815, 822, 1454, 1454, 823, 824, 815, 837, 825,
595 830, 1454, 877, 832, 828, 1454, 1454, 1454, 847, 843,
596 1454, 835, 844, 839, 1454, 1454, 1454, 1454, 1454, 1454,
597 1454, 1454, 1454, 1454, 1454, 1454, 848, 841, 854, 1454,
598 851, 1454, 853, 849, 846, 1454, 1454, 848, 852, 837,
599 851, 1454, 839, 1454, 1454, 903, 908, 918, 927, 930,
603 static yyconst short int yy_def[1184] =
605 1175, 1, 1175, 3, 1176, 1176, 1175, 1175, 1175, 1175,
606 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
607 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
608 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1177,
609 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
610 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
611 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
612 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
613 1175, 1175, 1175, 1175, 1178, 1175, 1175, 1175, 1175, 1175,
614 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
616 1175, 1177, 1175, 1179, 1175, 1175, 1175, 1175, 1175, 1175,
617 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
618 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
619 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
620 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
621 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
622 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
623 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
624 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
625 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
627 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1180, 1175,
628 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1178,
629 1175, 1175, 1175, 1175, 1175, 1179, 1175, 1175, 1175, 1175,
630 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
631 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
632 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
633 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
634 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
635 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
636 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
638 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
639 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
640 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
641 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
642 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
643 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
644 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
645 1175, 1175, 1175, 1180, 1175, 1175, 1175, 1175, 1175, 1175,
646 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
647 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
649 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
650 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
651 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
652 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
653 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
654 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
655 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
656 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
657 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
658 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
660 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
661 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
662 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
663 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
664 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
665 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
666 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
667 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
668 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
669 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
671 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
672 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
673 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
674 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
675 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
676 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
677 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
678 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
679 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
680 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
682 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
683 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
684 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
685 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
686 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
687 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
688 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
689 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
690 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
691 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
693 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
694 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
695 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
696 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
697 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
698 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
699 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
700 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
701 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
702 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
704 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
705 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
706 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
707 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
708 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
709 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
710 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
711 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
712 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
713 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
715 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1181,
716 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
717 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
718 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
719 1175, 1175, 1175, 1182, 1175, 1175, 1175, 1175, 1175, 1175,
720 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
721 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
722 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
723 1175, 1175, 1175, 1175, 1175, 1181, 1175, 1175, 1175, 1175,
724 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1183, 1175, 1175,
726 1175, 1175, 1175, 1175, 1182, 1175, 1175, 1175, 1175, 1175,
727 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
728 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
729 1175, 1175, 1183, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
730 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
731 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
732 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
733 1175, 1175, 1175, 1175, 0, 1175, 1175, 1175, 1175, 1175,
737 static yyconst short int yy_nxt[1524] =
739 8, 9, 10, 11, 12, 13, 14, 15, 8, 16,
740 17, 18, 19, 20, 21, 22, 23, 24, 25, 26,
741 27, 26, 26, 26, 28, 29, 30, 31, 32, 33,
742 34, 35, 35, 36, 37, 38, 39, 40, 41, 42,
743 43, 44, 45, 46, 47, 48, 49, 50, 51, 52,
744 53, 54, 55, 56, 57, 58, 59, 60, 61, 62,
745 63, 64, 65, 58, 58, 66, 8, 67, 68, 69,
746 70, 71, 69, 69, 72, 69, 69, 73, 74, 69,
747 73, 73, 73, 73, 73, 73, 73, 73, 75, 76,
748 76, 76, 76, 76, 73, 69, 77, 78, 79, 73,
750 80, 80, 69, 69, 69, 73, 69, 69, 69, 69,
751 69, 81, 82, 69, 69, 69, 69, 69, 69, 69,
752 69, 69, 69, 69, 69, 69, 69, 83, 69, 69,
753 69, 69, 69, 69, 69, 84, 69, 73, 90, 92,
754 92, 92, 92, 92, 92, 93, 92, 92, 92, 92,
755 92, 92, 92, 92, 92, 92, 92, 92, 97, 97,
756 97, 97, 97, 97, 98, 99, 100, 103, 862, 134,
757 97, 97, 91, 105, 148, 106, 97, 225, 196, 135,
758 197, 136, 149, 107, 265, 108, 137, 266, 150, 168,
759 111, 94, 109, 110, 112, 210, 211, 104, 104, 288,
761 169, 113, 114, 230, 115, 118, 170, 116, 171, 119,
762 117, 231, 120, 121, 227, 101, 122, 123, 289, 124,
763 127, 128, 125, 138, 129, 126, 139, 143, 130, 140,
764 286, 144, 141, 162, 131, 145, 753, 132, 153, 157,
765 287, 146, 154, 158, 133, 147, 155, 159, 202, 163,
766 172, 222, 160, 223, 173, 203, 204, 174, 164, 161,
767 754, 175, 156, 509, 176, 165, 103, 177, 166, 178,
768 183, 213, 214, 179, 167, 184, 185, 180, 252, 186,
769 237, 191, 187, 181, 182, 192, 253, 188, 198, 193,
770 189, 238, 190, 510, 199, 194, 104, 104, 195, 239,
772 200, 98, 99, 100, 201, 208, 208, 208, 208, 208,
773 208, 208, 208, 208, 208, 208, 208, 215, 215, 215,
774 215, 215, 215, 92, 92, 92, 92, 92, 92, 215,
775 215, 235, 236, 276, 277, 215, 863, 97, 97, 97,
776 97, 97, 97, 273, 241, 255, 283, 242, 209, 97,
777 97, 261, 243, 279, 274, 97, 244, 284, 256, 293,
778 257, 280, 568, 262, 371, 295, 296, 281, 305, 263,
779 569, 294, 264, 297, 302, 308, 311, 303, 306, 298,
780 372, 312, 309, 318, 319, 864, 324, 320, 328, 329,
781 337, 338, 321, 332, 322, 340, 344, 333, 323, 304,
783 325, 334, 348, 359, 335, 354, 349, 360, 225, 341,
784 345, 368, 355, 356, 361, 369, 346, 225, 385, 362,
785 357, 208, 208, 208, 208, 208, 208, 386, 387, 363,
786 215, 215, 215, 215, 215, 215, 651, 395, 652, 477,
787 411, 486, 215, 215, 396, 227, 412, 440, 215, 422,
788 460, 441, 423, 462, 227, 487, 424, 478, 547, 576,
789 461, 580, 613, 614, 548, 615, 463, 645, 634, 464,
790 635, 677, 577, 706, 646, 581, 616, 806, 720, 678,
791 617, 707, 711, 773, 712, 769, 636, 774, 770, 814,
792 775, 822, 852, 865, 866, 867, 868, 853, 869, 870,
794 871, 872, 873, 874, 713, 875, 876, 807, 846, 846,
795 854, 877, 878, 879, 880, 815, 881, 823, 882, 883,
796 884, 887, 888, 885, 889, 890, 891, 892, 893, 894,
797 895, 896, 897, 899, 898, 900, 901, 886, 902, 903,
798 904, 905, 906, 907, 785, 816, 817, 824, 825, 909,
799 910, 911, 912, 913, 914, 915, 818, 916, 826, 917,
800 918, 919, 920, 921, 922, 923, 924, 925, 926, 927,
801 928, 929, 930, 814, 908, 908, 931, 932, 819, 934,
802 935, 822, 936, 937, 938, 939, 940, 941, 942, 943,
803 944, 945, 946, 947, 948, 949, 950, 951, 953, 815,
805 952, 952, 952, 952, 952, 952, 954, 823, 933, 933,
806 955, 956, 952, 952, 957, 958, 959, 960, 952, 961,
807 963, 964, 965, 966, 967, 968, 969, 970, 971, 816,
808 817, 972, 962, 973, 974, 975, 976, 824, 825, 977,
809 818, 978, 979, 980, 981, 982, 983, 984, 826, 985,
810 986, 987, 988, 989, 990, 991, 992, 993, 994, 995,
811 996, 997, 998, 999, 1000, 1001, 1002, 1003, 1004, 1005,
812 1005, 1005, 1005, 1005, 1005, 1006, 1007, 1011, 1008, 1008,
813 1012, 1005, 1005, 1013, 1014, 1015, 1016, 1005, 1009, 1017,
814 1018, 1019, 1020, 1021, 1022, 1023, 1024, 1025, 1028, 1029,
816 1030, 1031, 1026, 1032, 1033, 1034, 1035, 1036, 1010, 1010,
817 1027, 1027, 1027, 1027, 1027, 1027, 1037, 1038, 1039, 1040,
818 1041, 1042, 1027, 1027, 1043, 1045, 1046, 1047, 1027, 952,
819 952, 952, 952, 952, 952, 953, 1048, 1049, 1050, 1051,
820 1044, 952, 952, 1052, 1053, 1054, 1055, 952, 1056, 1057,
821 1058, 1059, 1060, 1061, 1062, 1063, 1064, 1065, 1066, 1067,
822 1068, 1069, 1070, 1071, 1072, 1073, 1074, 1075, 1076, 1077,
823 1078, 1079, 1080, 1081, 1005, 1005, 1005, 1005, 1005, 1005,
824 1082, 1008, 1008, 1083, 1083, 1087, 1005, 1005, 1084, 1084,
825 1088, 1009, 1005, 1089, 1090, 1091, 1092, 1093, 1094, 1085,
827 1095, 1096, 1097, 1035, 1099, 1100, 1101, 1026, 1098, 1102,
828 1103, 1010, 1010, 1010, 1010, 1027, 1027, 1027, 1027, 1027,
829 1027, 1104, 1106, 1107, 1108, 1109, 1110, 1027, 1027, 1111,
830 1112, 1113, 1114, 1027, 1115, 1116, 1117, 1118, 1119, 1120,
831 1121, 1122, 1123, 1124, 1125, 1126, 1127, 1128, 1083, 1083,
832 1084, 1084, 1084, 1084, 1129, 1130, 1131, 1132, 1134, 1135,
833 1136, 1085, 1137, 1085, 1138, 1139, 1140, 1141, 1142, 1143,
834 1144, 1145, 1146, 1147, 1148, 1149, 1150, 1151, 1010, 1010,
835 1152, 1153, 1154, 1155, 1156, 1157, 1158, 1159, 1160, 1161,
836 1162, 1163, 1164, 1165, 1166, 1167, 1168, 1169, 1170, 1171,
838 1172, 1173, 1174, 85, 85, 85, 85, 85, 85, 85,
839 85, 85, 85, 102, 102, 861, 102, 102, 220, 220,
840 220, 220, 220, 220, 220, 220, 220, 220, 226, 860,
841 859, 858, 226, 226, 226, 374, 857, 856, 374, 1086,
842 1086, 855, 1086, 1086, 1086, 1105, 1105, 851, 850, 1105,
843 1105, 1105, 1105, 1105, 1105, 1133, 1133, 849, 848, 1133,
844 1133, 1133, 1133, 1133, 1133, 847, 845, 844, 843, 842,
845 841, 840, 839, 838, 837, 836, 835, 834, 833, 832,
846 831, 830, 829, 828, 827, 821, 820, 819, 813, 812,
847 811, 810, 809, 808, 805, 804, 803, 802, 801, 800,
849 799, 798, 797, 796, 795, 794, 793, 792, 791, 790,
850 789, 788, 787, 786, 785, 784, 783, 782, 781, 780,
851 779, 778, 777, 776, 772, 771, 768, 767, 766, 765,
852 764, 763, 762, 761, 760, 759, 758, 757, 756, 755,
853 752, 751, 750, 749, 748, 747, 746, 745, 744, 743,
854 742, 741, 740, 739, 738, 737, 736, 735, 734, 733,
855 732, 731, 730, 729, 728, 727, 726, 725, 724, 723,
856 722, 721, 720, 719, 718, 717, 716, 715, 714, 710,
857 709, 708, 705, 704, 703, 702, 701, 700, 699, 698,
858 697, 696, 695, 694, 693, 692, 691, 690, 689, 688,
860 687, 686, 685, 684, 683, 682, 681, 680, 679, 676,
861 675, 674, 673, 672, 671, 670, 669, 668, 667, 666,
862 665, 664, 663, 662, 661, 660, 659, 658, 657, 656,
863 655, 654, 653, 650, 649, 648, 647, 644, 643, 642,
864 641, 640, 639, 638, 637, 633, 632, 631, 630, 629,
865 628, 627, 626, 625, 624, 623, 622, 621, 620, 619,
866 618, 612, 611, 610, 609, 608, 607, 606, 605, 604,
867 603, 602, 601, 600, 599, 598, 597, 596, 595, 594,
868 593, 592, 591, 590, 589, 588, 587, 586, 585, 584,
869 583, 582, 579, 578, 575, 574, 573, 572, 571, 570,
871 567, 566, 565, 564, 563, 562, 561, 560, 559, 558,
872 557, 556, 555, 554, 553, 552, 551, 550, 549, 546,
873 545, 544, 543, 542, 541, 540, 539, 538, 537, 536,
874 535, 534, 533, 532, 531, 530, 529, 528, 527, 526,
875 525, 524, 523, 522, 521, 520, 519, 518, 517, 516,
876 515, 514, 513, 512, 511, 508, 507, 506, 505, 504,
877 503, 502, 501, 500, 499, 498, 497, 496, 495, 494,
878 493, 492, 491, 490, 489, 488, 485, 484, 483, 482,
879 481, 480, 479, 476, 475, 474, 473, 472, 471, 470,
880 469, 468, 467, 466, 465, 459, 458, 457, 456, 455,
882 454, 453, 452, 451, 450, 449, 448, 447, 446, 445,
883 444, 443, 442, 286, 439, 438, 437, 436, 435, 434,
884 433, 432, 431, 430, 429, 428, 427, 426, 425, 421,
885 420, 419, 418, 417, 416, 415, 414, 413, 410, 409,
886 408, 407, 406, 405, 404, 403, 402, 401, 400, 399,
887 398, 397, 394, 393, 392, 391, 390, 389, 388, 384,
888 383, 382, 381, 380, 379, 378, 221, 377, 376, 375,
889 373, 370, 367, 366, 365, 364, 358, 353, 352, 351,
890 350, 347, 343, 342, 339, 336, 331, 330, 327, 326,
891 317, 316, 315, 314, 313, 310, 307, 301, 300, 299,
893 292, 291, 290, 285, 282, 278, 275, 272, 271, 270,
894 269, 268, 267, 260, 259, 258, 254, 251, 250, 249,
895 248, 247, 246, 245, 240, 234, 233, 232, 229, 228,
896 99, 224, 89, 221, 219, 218, 217, 216, 212, 207,
897 206, 205, 152, 151, 142, 96, 95, 89, 88, 87,
898 1175, 86, 86, 7, 1175, 1175, 1175, 1175, 1175, 1175,
899 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
900 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
901 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
902 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
904 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
905 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
909 static yyconst short int yy_chk[1524] =
911 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
912 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
913 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
914 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
915 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
916 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
917 1, 1, 1, 1, 1, 1, 1, 1, 1, 3,
918 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
919 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
920 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
922 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
923 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
924 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
925 3, 3, 3, 3, 3, 3, 3, 3, 25, 26,
926 26, 26, 26, 26, 26, 27, 27, 27, 27, 27,
927 27, 27, 28, 28, 28, 28, 28, 28, 35, 35,
928 35, 35, 35, 35, 37, 37, 37, 41, 739, 46,
929 35, 35, 25, 42, 50, 42, 35, 104, 62, 46,
930 62, 46, 50, 42, 131, 42, 46, 131, 50, 56,
931 43, 28, 42, 42, 43, 77, 77, 41, 41, 149,
933 56, 43, 43, 107, 43, 44, 56, 43, 56, 44,
934 43, 107, 44, 44, 104, 37, 44, 44, 149, 44,
935 45, 45, 44, 47, 45, 44, 47, 49, 45, 47,
936 148, 49, 47, 55, 45, 49, 622, 45, 53, 54,
937 148, 49, 53, 54, 45, 49, 53, 54, 64, 55,
938 57, 93, 54, 93, 57, 64, 64, 57, 55, 54,
939 622, 57, 53, 358, 57, 55, 103, 57, 55, 59,
940 60, 79, 79, 59, 55, 60, 60, 59, 124, 60,
941 112, 61, 60, 59, 59, 61, 124, 60, 63, 61,
942 60, 112, 60, 358, 63, 61, 103, 103, 61, 112,
944 63, 98, 98, 98, 63, 75, 75, 75, 75, 75,
945 75, 76, 76, 76, 76, 76, 76, 80, 80, 80,
946 80, 80, 80, 92, 92, 92, 92, 92, 92, 80,
947 80, 111, 111, 140, 140, 80, 740, 97, 97, 97,
948 97, 97, 97, 138, 115, 126, 144, 115, 75, 97,
949 97, 130, 115, 142, 138, 97, 115, 144, 126, 153,
950 126, 142, 424, 130, 204, 154, 154, 142, 159, 130,
951 424, 153, 130, 154, 158, 161, 166, 158, 159, 154,
952 204, 166, 161, 172, 172, 742, 173, 172, 176, 176,
953 181, 181, 172, 179, 172, 183, 186, 179, 172, 158,
955 173, 179, 188, 195, 179, 193, 188, 195, 225, 183,
956 186, 202, 193, 193, 196, 202, 186, 226, 235, 196,
957 193, 208, 208, 208, 208, 208, 208, 235, 235, 196,
958 215, 215, 215, 215, 215, 215, 507, 243, 507, 324,
959 260, 332, 215, 215, 243, 225, 260, 288, 215, 271,
960 309, 288, 271, 310, 226, 332, 271, 324, 398, 433,
961 309, 436, 472, 472, 398, 473, 310, 502, 490, 310,
962 490, 538, 433, 572, 502, 436, 473, 684, 720, 538,
963 473, 572, 577, 644, 577, 639, 490, 644, 639, 693,
964 644, 699, 729, 743, 744, 745, 746, 729, 747, 748,
966 749, 750, 751, 752, 577, 753, 754, 684, 720, 720,
967 729, 755, 757, 758, 759, 693, 761, 699, 762, 763,
968 764, 765, 766, 764, 767, 768, 769, 770, 771, 772,
969 773, 774, 775, 776, 775, 777, 778, 764, 779, 780,
970 781, 782, 783, 784, 785, 693, 693, 699, 699, 786,
971 787, 788, 789, 790, 792, 793, 693, 794, 699, 795,
972 796, 797, 798, 799, 800, 801, 802, 803, 805, 807,
973 809, 810, 813, 814, 785, 785, 816, 817, 819, 820,
974 821, 822, 824, 825, 828, 829, 831, 832, 833, 835,
975 836, 837, 838, 839, 841, 843, 844, 845, 847, 814,
977 846, 846, 846, 846, 846, 846, 848, 822, 819, 819,
978 849, 850, 846, 846, 851, 852, 853, 854, 846, 855,
979 856, 857, 858, 860, 861, 862, 863, 864, 865, 814,
980 814, 868, 855, 869, 870, 871, 872, 822, 822, 873,
981 814, 874, 876, 878, 879, 880, 881, 882, 822, 884,
982 885, 886, 888, 889, 890, 891, 892, 893, 895, 896,
983 897, 898, 900, 901, 902, 903, 904, 905, 906, 908,
984 908, 908, 908, 908, 908, 909, 912, 914, 913, 913,
985 915, 908, 908, 917, 918, 921, 922, 908, 913, 923,
986 924, 926, 927, 928, 929, 930, 931, 932, 934, 936,
988 937, 938, 933, 939, 940, 941, 942, 943, 913, 913,
989 933, 933, 933, 933, 933, 933, 945, 946, 947, 948,
990 949, 950, 933, 933, 951, 955, 956, 957, 933, 952,
991 952, 952, 952, 952, 952, 953, 958, 959, 960, 961,
992 953, 952, 952, 962, 963, 964, 965, 952, 967, 968,
993 969, 970, 971, 973, 975, 977, 978, 981, 982, 983,
994 985, 986, 987, 988, 989, 990, 994, 996, 998, 999,
995 1000, 1001, 1003, 1004, 1005, 1005, 1005, 1005, 1005, 1005,
996 1007, 1008, 1008, 1009, 1009, 1011, 1005, 1005, 1010, 1010,
997 1012, 1008, 1005, 1014, 1017, 1018, 1020, 1024, 1028, 1010,
999 1029, 1032, 1034, 1035, 1036, 1037, 1039, 1027, 1035, 1040,
1000 1041, 1008, 1008, 1009, 1009, 1027, 1027, 1027, 1027, 1027,
1001 1027, 1043, 1047, 1048, 1049, 1050, 1051, 1027, 1027, 1052,
1002 1053, 1055, 1058, 1027, 1061, 1063, 1065, 1066, 1068, 1070,
1003 1071, 1072, 1073, 1074, 1075, 1076, 1078, 1079, 1083, 1083,
1004 1084, 1084, 1086, 1086, 1088, 1091, 1092, 1096, 1099, 1101,
1005 1104, 1084, 1105, 1086, 1107, 1108, 1110, 1111, 1112, 1116,
1006 1118, 1120, 1121, 1122, 1123, 1126, 1127, 1128, 1083, 1083,
1007 1129, 1130, 1131, 1133, 1134, 1135, 1139, 1140, 1142, 1143,
1008 1144, 1157, 1158, 1159, 1161, 1163, 1164, 1165, 1168, 1169,
1010 1170, 1171, 1173, 1176, 1176, 1176, 1176, 1176, 1176, 1176,
1011 1176, 1176, 1176, 1177, 1177, 738, 1177, 1177, 1178, 1178,
1012 1178, 1178, 1178, 1178, 1178, 1178, 1178, 1178, 1179, 737,
1013 736, 735, 1179, 1179, 1179, 1180, 733, 732, 1180, 1181,
1014 1181, 730, 1181, 1181, 1181, 1182, 1182, 727, 726, 1182,
1015 1182, 1182, 1182, 1182, 1182, 1183, 1183, 724, 723, 1183,
1016 1183, 1183, 1183, 1183, 1183, 722, 719, 718, 717, 716,
1017 715, 714, 713, 712, 711, 710, 709, 708, 707, 706,
1018 705, 704, 703, 702, 700, 698, 697, 695, 692, 691,
1019 689, 688, 686, 685, 683, 682, 681, 680, 679, 678,
1021 677, 676, 674, 673, 672, 671, 670, 669, 668, 666,
1022 664, 663, 661, 660, 657, 656, 655, 654, 652, 649,
1023 648, 647, 646, 645, 643, 640, 637, 636, 635, 634,
1024 633, 632, 631, 630, 629, 628, 627, 626, 624, 623,
1025 620, 619, 618, 617, 616, 615, 614, 613, 612, 611,
1026 610, 609, 608, 607, 606, 605, 604, 603, 602, 600,
1027 598, 597, 596, 594, 593, 591, 590, 589, 588, 587,
1028 586, 585, 584, 583, 582, 581, 580, 579, 578, 576,
1029 574, 573, 571, 570, 569, 567, 566, 565, 564, 563,
1030 562, 561, 560, 559, 558, 556, 555, 554, 553, 552,
1032 551, 550, 548, 545, 544, 543, 542, 540, 539, 537,
1033 536, 535, 534, 533, 532, 531, 530, 529, 527, 526,
1034 525, 522, 519, 518, 517, 516, 515, 514, 513, 512,
1035 511, 510, 508, 506, 505, 504, 503, 501, 500, 498,
1036 497, 495, 494, 493, 491, 489, 488, 487, 486, 485,
1037 484, 483, 482, 481, 480, 479, 478, 477, 476, 475,
1038 474, 471, 470, 469, 468, 467, 466, 465, 464, 463,
1039 462, 461, 460, 459, 457, 455, 454, 453, 452, 451,
1040 449, 448, 447, 446, 445, 444, 442, 441, 440, 439,
1041 438, 437, 435, 434, 432, 431, 430, 429, 427, 426,
1043 423, 422, 420, 417, 416, 414, 412, 411, 410, 409,
1044 408, 407, 406, 405, 403, 402, 401, 400, 399, 397,
1045 396, 395, 394, 393, 392, 391, 390, 389, 387, 386,
1046 385, 384, 383, 382, 380, 379, 378, 377, 376, 375,
1047 373, 372, 371, 370, 369, 368, 367, 366, 365, 364,
1048 363, 362, 361, 360, 359, 357, 356, 353, 352, 351,
1049 350, 349, 348, 347, 346, 345, 344, 343, 342, 341,
1050 340, 337, 336, 335, 334, 333, 331, 330, 329, 328,
1051 327, 326, 325, 323, 322, 321, 320, 318, 317, 316,
1052 315, 314, 313, 312, 311, 308, 307, 306, 305, 304,
1054 303, 302, 301, 300, 299, 298, 296, 295, 294, 293,
1055 291, 290, 289, 287, 286, 285, 284, 283, 282, 281,
1056 280, 279, 278, 277, 276, 275, 274, 273, 272, 270,
1057 268, 267, 266, 265, 264, 263, 262, 261, 259, 258,
1058 256, 254, 253, 252, 251, 250, 249, 248, 247, 246,
1059 245, 244, 242, 241, 240, 239, 238, 237, 236, 234,
1060 233, 232, 231, 229, 228, 224, 220, 218, 217, 216,
1061 205, 203, 201, 200, 199, 198, 194, 192, 191, 190,
1062 189, 187, 185, 184, 182, 180, 178, 177, 175, 174,
1063 171, 170, 169, 168, 167, 164, 160, 157, 156, 155,
1065 152, 151, 150, 145, 143, 141, 139, 137, 136, 135,
1066 134, 133, 132, 129, 128, 127, 125, 122, 121, 120,
1067 119, 118, 117, 116, 113, 110, 109, 108, 106, 105,
1068 100, 94, 89, 85, 84, 83, 82, 81, 78, 74,
1069 72, 65, 52, 51, 48, 33, 31, 17, 16, 11,
1070 7, 6, 5, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
1071 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
1072 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
1073 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
1074 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
1076 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
1077 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175,
1081 static yy_state_type yy_last_accepting_state;
1082 static char *yy_last_accepting_cpos;
1084 /* The intent behind this definition is that it'll catch
1085 * any uses of REJECT which flex missed.
1087 #define REJECT reject_used_but_not_detected
1088 static int yy_more_offset = 0;
1089 static int yy_prev_more_offset = 0;
1090 #define yymore() (yy_more_offset = yy_flex_strlen( yytext ))
1091 #define YY_NEED_STRLEN
1092 #define YY_MORE_ADJ 0
1093 #define YY_RESTORE_YY_MORE_OFFSET \
1095 yy_more_offset = yy_prev_more_offset; \
1096 yyleng -= yy_more_offset; \
1102 char yytext[YYLMAX];
1108 /* Copyright (c) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
1109 * 2005, 2006 by Arkkra Enterprises */
1110 /* All rights reserved */
1112 /* lexer for music publication program. Recognizes and returns all the
1113 * tokens needed by yacc. */
1116 #include "rational.h"
1118 #include "defines.h"
1119 #include "structs.h"
1120 #include "globals.h"
1123 /* In order to reduce the number of terminal symbols so yacc wouldn't blow
1124 * up, we mapped several similar tokens to the same return code. The
1125 * yylval variable is then used to say which specific one of the set
1126 * was actually in the input. Bison doesn't have the number of tokens
1127 * restriction, but grouping related tokens is still useful. */
1128 extern YYSTYPE yylval;
1131 #define YY_INPUT(buf,result,max_size) \
1133 int c = getc(yyin); \
1135 Last_was_newline = YES; \
1136 yylineno += not_in_mac(1); \
1139 Last_was_newline = NO; \
1141 if (c == EOF || c == 0) { \
1149 /* list of Flex buffers for includes/macros */
1151 YY_BUFFER_STATE buff;
1152 struct Lexbuffer *next;
1154 static struct Lexbuffer *Lexlist;
1156 /* We add a newline at end of input, to avoid cryptic error message
1157 * if user didn't end the file with a newline. */
1158 static YY_BUFFER_STATE Eof_newline = 0;
1160 /* The compressed form of an "if" clause is stored here,
1161 * then passed to a mini-parser. */
1162 unsigned char Ifclause_buff[1024];
1163 int If_length; /* how much of Ifclause_buffer is used */
1164 static void add_ifclause P((int token));
1165 static void addnum_ifclause P((int value));
1166 static void addnumstr_ifclause P((char *numtoken));
1167 extern void set_ifclause_buffer P((unsigned char * buffer, int length));
1168 extern int ifparse P((void));
1169 static void bad_input P((char *where));
1174 static int If_count = 0; /* how many if, ifdef, and ifndef constructs in progress */
1175 static int If_errs; /* to try to deduce missing 'then' */
1176 static int Escapedquotes = 0;
1177 static int Raw_string = NO; /* YES if doing raw string (not expanding
1178 * any non-ASCII into Mup escapes) */
1180 static int get_a_param P((char *macname));
1181 static void skipwhite P((void));
1182 static void to_eol P((void));
1183 static int skip2else P((void));
1184 static int oddbs P((void));
1185 static void embedquotes P((void));
1186 static void xpand_non_ascii P((void));
1187 static void ignore P((void));
1192 /* Macros after this point can all be overridden by user definitions in
1196 #ifndef YY_SKIP_YYWRAP
1198 extern "C" int yywrap YY_PROTO(( void ));
1200 extern int yywrap YY_PROTO(( void ));
1205 static void yyunput YY_PROTO(( int c, char *buf_ptr ));
1209 static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
1212 #ifdef YY_NEED_STRLEN
1213 static int yy_flex_strlen YY_PROTO(( yyconst char * ));
1218 static int yyinput YY_PROTO(( void ));
1220 static int input YY_PROTO(( void ));
1225 static int yy_start_stack_ptr = 0;
1226 static int yy_start_stack_depth = 0;
1227 static int *yy_start_stack = 0;
1228 #ifndef YY_NO_PUSH_STATE
1229 static void yy_push_state YY_PROTO(( int new_state ));
1231 #ifndef YY_NO_POP_STATE
1232 static void yy_pop_state YY_PROTO(( void ));
1234 #ifndef YY_NO_TOP_STATE
1235 static int yy_top_state YY_PROTO(( void ));
1239 #define YY_NO_PUSH_STATE 1
1240 #define YY_NO_POP_STATE 1
1241 #define YY_NO_TOP_STATE 1
1244 #ifdef YY_MALLOC_DECL
1252 /* Just try to get by without declaring the routines. This will fail
1253 * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
1254 * or sizeof(void*) != sizeof(int).
1259 /* Amount of stuff to slurp up with each read. */
1260 #ifndef YY_READ_BUF_SIZE
1261 #define YY_READ_BUF_SIZE 8192
1264 /* Copy whatever the last rule matched to the standard output. */
1267 /* This used to be an fputs(), but since the string might contain NUL's,
1268 * we now use fwrite().
1270 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
1273 /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
1274 * is returned in "result".
1277 #define YY_INPUT(buf,result,max_size) \
1278 if ( yy_current_buffer->yy_is_interactive ) \
1281 for ( n = 0; n < max_size && \
1282 (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
1283 buf[n] = (char) c; \
1285 buf[n++] = (char) c; \
1286 if ( c == EOF && ferror( yyin ) ) \
1287 YY_FATAL_ERROR( "input in flex scanner failed" ); \
1290 else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
1291 && ferror( yyin ) ) \
1292 YY_FATAL_ERROR( "input in flex scanner failed" );
1295 /* No semi-colon after return; correct usage is to write "yyterminate();" -
1296 * we don't want an extra ';' after the "return" because that will cause
1297 * some compilers to complain about unreachable statements.
1300 #define yyterminate() return YY_NULL
1303 /* Number of entries by which start-condition stack grows. */
1304 #ifndef YY_START_STACK_INCR
1305 #define YY_START_STACK_INCR 25
1308 /* Report a fatal error. */
1309 #ifndef YY_FATAL_ERROR
1310 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
1313 /* Default declaration of generated scanner - a define so the user can
1314 * easily add parameters.
1317 #define YY_DECL int yylex YY_PROTO(( void ))
1320 /* Code executed at the beginning of each rule, after yytext and yyleng
1323 #ifndef YY_USER_ACTION
1324 #define YY_USER_ACTION
1327 /* Code executed at the end of each rule. */
1329 #define YY_BREAK break;
1332 #define YY_RULE_SETUP \
1337 register yy_state_type yy_current_state;
1338 register char *yy_cp, *yy_bp;
1339 register int yy_act;
1354 yy_start = 1; /* first start state */
1362 if ( ! yy_current_buffer )
1364 yy_create_buffer( yyin, YY_BUF_SIZE );
1366 yy_load_buffer_state();
1369 while ( 1 ) /* loops until end-of-file is reached */
1373 /* Support of yytext. */
1374 *yy_cp = yy_hold_char;
1376 /* yy_bp points to the position in yy_ch_buf of the start of
1381 yy_current_state = yy_start;
1385 register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
1386 if ( yy_accept[yy_current_state] )
1388 yy_last_accepting_state = yy_current_state;
1389 yy_last_accepting_cpos = yy_cp;
1391 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1393 yy_current_state = (int) yy_def[yy_current_state];
1394 if ( yy_current_state >= 1176 )
1395 yy_c = yy_meta[(unsigned int) yy_c];
1397 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1400 while ( yy_base[yy_current_state] != 1454 );
1403 yy_act = yy_accept[yy_current_state];
1405 { /* have to back up */
1406 yy_cp = yy_last_accepting_cpos;
1407 yy_current_state = yy_last_accepting_state;
1408 yy_act = yy_accept[yy_current_state];
1411 YY_DO_BEFORE_ACTION;
1414 do_action: /* This label is used only to access EOF actions. */
1418 { /* beginning of action switch */
1419 case 0: /* must back up */
1420 /* undo the effects of YY_DO_BEFORE_ACTION */
1421 *yy_cp = yy_hold_char;
1422 yy_cp = yy_last_accepting_cpos;
1423 yy_current_state = yy_last_accepting_state;
1424 goto yy_find_action;
1429 { yylval.intval = FONT_TR; return(T_FONT); }
1434 { yylval.intval = FONT_TB; return(T_FONT); }
1439 { yylval.intval = FONT_TX; return(T_FONT); }
1444 { yylval.intval = FONT_TI; return(T_FONT); }
1449 { yylval.intval = BASE_TIMES; return(T_FFAMILY); }
1454 { yylval.intval = BASE_AVANTGARDE; return(T_FFAMILY); }
1459 { yylval.intval = BASE_COURIER; return(T_FFAMILY); }
1464 { yylval.intval = BASE_HELVETICA; return(T_FFAMILY); }
1469 { yylval.intval = BASE_BOOKMAN; return(T_FFAMILY); }
1474 { yylval.intval = BASE_NEWCENTURY; return(T_FFAMILY); }
1479 { yylval.intval = BASE_PALATINO; return(T_FFAMILY); }
1485 /* set up include using filename with quotes stripped */
1486 yytext[yyleng - 1] = '\0';
1487 includefile(strchr(yytext, '"') + 1);
1494 yytext[yyleng - 1] = '\0';
1495 parse_font_file(strchr(yytext, '"') + 1);
1503 { yylval.intval = DIMINISHED; return(T_XPOS_INT); }
1510 { yylval.intval = AUGMENTED; return(T_XPOS_INT); }
1517 { yylval.intval = PERFECT; return(T_XPOS_INT); }
1524 { yylval.intval = MINOR; return(T_XPOS_INT); }
1531 { yylval.intval = MAJOR; return(T_XPOS_INT); }
1556 { yylval.intval = C_HEADER; return(T_BLOCKHEAD); }
1561 { yylval.intval = C_FOOTER; return(T_BLOCKHEAD); }
1566 { yylval.intval = C_HEAD2; return(T_BLOCKHEAD); }
1571 { yylval.intval = C_FOOT2; return(T_BLOCKHEAD); }
1576 { yylval.intval = C_TOP; return(T_BLOCKHEAD); }
1581 { yylval.intval = C_BOT; return(T_BLOCKHEAD); }
1586 { yylval.intval = C_TOP2; return(T_BLOCKHEAD); }
1591 { yylval.intval = C_BOT2; return(T_BLOCKHEAD); }
1596 { yylval.intval = C_BLOCK; return(T_BLOCKHEAD); }
1611 return(T_HEADSHAPES);
1626 return(T_SEMICOLON);
1685 { BEGIN STRING; yymore(); }
1691 /* string: handle embedded backslashed quotes */
1692 if (yytext[yyleng-2] == '\\' && oddbs() == YES) {
1700 if (yyleng > YYLMAX) {
1701 l_ufatal(Curr_filename, yylineno,
1702 "text string too long");
1751 { yylval.intval = L_NORMAL; return(T_TIE); }
1756 { yylval.intval = L_DOTTED; return(T_TIE); }
1761 { yylval.intval = L_DASHED; return(T_TIE); }
1766 { yylval.intval = L_NORMAL; return(T_SLUR); }
1771 { yylval.intval = L_DOTTED; return(T_SLUR); }
1776 { yylval.intval = L_DASHED; return(T_SLUR); }
1786 { yylval.intval = PL_ABOVE; return(T_PLACE); }
1791 { yylval.intval = PL_BELOW; return(T_PLACE); }
1796 { yylval.intval = PL_BETWEEN; return(T_PLACE); }
1821 return(T_SLASHMARK);
1851 { yylval.intval = PAD; return(T_PAD); }
1861 { yylval.intval = L_NORMAL; return(T_TILDE); }
1866 { yylval.intval = L_DOTTED; return(T_TILDE); }
1871 { yylval.intval = L_DASHED; return(T_TILDE); }
1886 { yylval.intval = 2; return(T_MULTIWHOLE); }
1891 { yylval.intval = 4; return(T_MULTIWHOLE); }
1926 return(T_AMPERSAND);
1941 return(T_LETTER); /* all letters not used for something special */
1951 return(T_LVAR); /* multi-character location variable names */
1966 { yylval.intval = NO; return(T_SCOREFEED); }
1971 { yylval.intval = YES; return(T_SCOREFEED); }
1976 return(T_MULTIREST);
1981 { yylval.intval = SINGLEBAR; return(T_BARTYPE); }
1986 { yylval.intval = DOUBLEBAR; return(T_BARTYPE); }
1991 { yylval.intval = REPEATSTART; return(T_BARTYPE); }
1996 { yylval.intval = REPEATEND; return(T_BARTYPE); }
2001 { yylval.intval = REPEATBOTH; return(T_BARTYPE); }
2006 { yylval.intval = INVISBAR; return(T_BARTYPE); }
2011 { yylval.intval = ENDBAR; return(T_BARTYPE); }
2016 { yylval.intval = RESTART; return(T_BARTYPE); }
2023 return(T_REHEARSAL);
2048 return(T_ENDENDING);
2053 return(T_HIDECHANGES);
2058 { yylval.intval = L_WIDE; return(T_LINETYPE); }
2063 { yylval.intval = L_MEDIUM; return(T_LINETYPE); }
2068 { yylval.intval = L_WAVY; return(T_LINETYPE); }
2073 { yylval.intval = L_DOTTED; return(T_LINETYPE); }
2078 { yylval.intval = L_DASHED; return(T_LINETYPE); }
2103 { yylval.intval = J_LEFT; return(T_PRINTTYPE); }
2108 { yylval.intval = J_RIGHT; return(T_PRINTTYPE); }
2113 { yylval.intval = J_CENTER; return(T_PRINTTYPE); }
2118 { yylval.intval = J_NONE; return(T_PRINTTYPE); }
2123 { return(T_POSTSCRIPT); }
2128 { yylval.intval = J_RAGPARA; return(T_PARATYPE); }
2133 { yylval.intval = J_JUSTPARA; return(T_PARATYPE); }
2138 return(T_PARAGRAPH);
2163 { yylval.intval = NUMSTAFF; return(T_NUMVAR); }
2168 { yylval.intval = VSCHEME; return(T_VVAR); }
2173 { yylval.intval = VCOMBINE; return(T_VCOMBINE); }
2178 { yylval.intval = VC_NOOVERLAP; return(T_VCOMBVAL); }
2183 { yylval.intval = VC_SHAREONE; return(T_VCOMBVAL); }
2188 { yylval.intval = VC_OVERLAP; return(T_VCOMBVAL); }
2193 { yylval.intval = DEFOCT; return(T_NUMVAR); }
2198 { yylval.intval = LYRICSSIZE; return(T_NUMVAR); }
2203 { yylval.intval = SYLPOSITION; return(T_NUMVAR); }
2208 { yylval.intval = SIZE; return(T_NUMVAR); }
2213 { yylval.intval = MINSTSEP; return(T_NUMVAR); }
2218 { yylval.intval = MINSCPAD; return(T_SCOREPAD); }
2223 { yylval.intval = STAFFPAD; return(T_NUMVAR); }
2228 { yylval.intval = CHORDDIST; return(T_NUMVAR); }
2233 { yylval.intval = DIST; return(T_NUMVAR); }
2238 { yylval.intval = DYNDIST; return(T_NUMVAR); }
2244 l_yyerror(Curr_filename, yylineno,
2245 "'crescdist' has been renamed 'dyndist'");
2246 yylval.intval = DYNDIST;
2253 { yylval.intval = DIVISION; return(T_NUMVAR); }
2258 { yylval.intval = RELEASE; return(T_NUMVAR); }
2263 { yylval.intval = PANELSPERPAGE; return(T_NUMVAR); }
2268 { yylval.intval = GRIDFRET; return(T_NUMVAR); }
2273 { yylval.intval = RESTCOMBINE; return(T_NUMVAR); }
2278 { yylval.intval = FIRSTPAGE; return(T_NUMVAR); }
2283 { yylval.intval = MINSCSEP; return(T_SCORESEP); }
2288 { yylval.intval = STAFFLINES; return(T_STAFFLINES); }
2293 { yylval.intval = ONTHELINE; return(T_YESNOVAR); }
2298 { yylval.intval = WARN; return(T_YESNOVAR); }
2303 { yylval.intval = NUMBERMRPT; return(T_YESNOVAR); }
2308 { yylval.intval = PRINTMULTNUM; return(T_YESNOVAR); }
2313 { yylval.intval = RESTSYMMULT; return(T_YESNOVAR); }
2318 { yylval.intval = GRIDSWHEREUSED; return(T_YESNOVAR); }
2323 { yylval.intval = GRIDSATEND; return(T_YESNOVAR); }
2333 { yylval.intval = TABWHITEBOX; return(T_YESNOVAR); }
2338 { yylval.intval = TIMEUNIT; return(T_TIMEUNIT); }
2343 { yylval.intval = SWINGUNIT; return(T_SWINGUNIT); }
2348 { yylval.intval = TOPMARGIN; return(T_FNUMVAR); }
2353 { yylval.intval = BOTMARGIN; return(T_FNUMVAR); }
2358 { yylval.intval = BOTMARGIN; return(T_FNUMVAR); }
2363 { yylval.intval = LEFTMARGIN; return(T_FNUMVAR); }
2368 { yylval.intval = RIGHTMARGIN; return(T_FNUMVAR); }
2373 { yylval.intval = PACKFACT; return(T_FNUMVAR); }
2378 { yylval.intval = PACKEXP; return(T_FNUMVAR); }
2383 { yylval.intval = STAFFSCALE; return(T_FNUMVAR); }
2388 { yylval.intval = GRIDSCALE; return(T_FNUMVAR); }
2393 { yylval.intval = SCALE_FACTOR; return(T_FNUMVAR); }
2398 { yylval.intval = STEMLEN; return(T_FNUMVAR); }
2403 { yylval.intval = STEMSHORTEN; return(T_FNUMVAR); }
2408 { yylval.intval = BEAMSLOPE; return(T_2FNUMVAR); }
2413 { yylval.intval = TRANSPOSITION; return(T_TRANSPOSE); }
2418 { yylval.intval = ADDTRANSPOSITION; return(T_TRANSPOSE); }
2423 { yylval.intval = LYRICSALIGN; return(T_FNUMVAR); }
2428 { yylval.intval = PAGEHEIGHT; return(T_FNUMVAR); }
2433 { yylval.intval = PAGEWIDTH; return(T_FNUMVAR); }
2438 { return(T_PSVAR); }
2443 { yylval.intval = PS_LETTER; return(T_PAGESIZE); }
2448 { yylval.intval = PS_LEGAL; return(T_PAGESIZE); }
2453 { yylval.intval = PS_FLSA; return(T_PAGESIZE); }
2458 { yylval.intval = PS_HALFLETTER; return(T_PAGESIZE); }
2463 { yylval.intval = O_PORTRAIT; return(T_ORIENTATION); }
2468 { yylval.intval = O_LANDSCAPE; return(T_ORIENTATION); }
2473 { yylval.intval = UNITS; return(T_UNITS); }
2478 { yylval.intval = CM; return(T_UNITTYPE); }
2483 { yylval.intval = INCHES; return(T_UNITTYPE); }
2488 { yylval.intval = ENDINGSTYLE; return(T_ENDSTYLE); }
2493 { yylval.intval = REHSTYLE; return(T_REH_STYLE); }
2498 { yylval.intval = RS_BOXED; return(T_REHTYPE); }
2503 { yylval.intval = RS_CIRCLED; return(T_REHTYPE); }
2508 { yylval.intval = RS_PLAIN; return(T_REHTYPE); }
2513 { yylval.intval = PEDSTYLE; return(T_PEDSTYLE); }
2523 { yylval.intval = ENDING_BARRED; return(T_ENDTYPE); }
2528 { yylval.intval = ENDING_GROUPED; return(T_ENDTYPE); }
2533 { yylval.intval = BRACELIST; return(T_RANGELISTVAR); }
2538 { yylval.intval = BRACKLIST; return(T_RANGELISTVAR); }
2543 { yylval.intval = BARSTLIST; return(T_BARSTLISTVAR); }
2548 { yylval.intval = PL_ABOVE; return(T_ORDER); }
2553 { yylval.intval = PL_BELOW; return(T_ORDER); }
2558 { yylval.intval = PL_BETWEEN; return(T_ORDER); }
2563 return(T_OTHERTEXT);
2568 { yylval.intval = SHARPS; return(T_KEY); }
2573 { yylval.intval = TIME; return(T_TIME); }
2578 { yylval.intval = BEAMSTLIST; return(T_RATNUMLISTVAR); }
2583 { yylval.intval = VISIBLE; return(T_VISVAR); }
2588 { return(T_WHEREUSED); }
2593 { yylval.intval = MEASNUM; return(T_YESNOVAR); }
2598 { yylval.intval = CANCELKEY; return(T_YESNOVAR); }
2603 { yylval.intval = LABEL; return(T_STRVAR); }
2608 { yylval.intval = LABEL2; return(T_STRVAR); }
2613 { yylval.intval = NOTEHEADS; return(T_STRVAR); }
2618 { yylval.intval = FONT; return(T_FONTVAR); }
2623 { yylval.intval = FONTFAMILY; return(T_FAMILY); }
2628 { yylval.intval = LYRICSFONT; return(T_FONTVAR); }
2633 { yylval.intval = LYRICSFAMILY; return(T_FAMILY); }
2638 { yylval.intval = MEASNUMSIZE; return(T_NUMVAR); }
2643 { yylval.intval = MEASNUMFONT; return(T_FONTVAR); }
2648 { yylval.intval = MEASNUMFAMILY; return(T_FAMILY); }
2653 { yylval.intval = CLEF; return(T_CLEFVAR); }
2658 { return(T_UNSET); }
2663 { yylval.intval = TREBLE_8A; return(T_CLEF); }
2668 { yylval.intval = TREBLE; return(T_CLEF); }
2673 { yylval.intval = TREBLE_8; return(T_CLEF); }
2678 { yylval.intval = FRENCHVIOLIN; return(T_CLEF); }
2683 { yylval.intval = SOPRANO; return(T_CLEF); }
2688 { yylval.intval = MEZZOSOPRANO; return(T_CLEF); }
2693 { yylval.intval = ALTO; return(T_CLEF); }
2698 { yylval.intval = TENOR; return(T_CLEF); }
2703 { yylval.intval = BARITONE; return(T_CLEF); }
2708 { yylval.intval = BASS; return(T_CLEF); }
2723 { yylval.intval = L_NORMAL; return(T_L_ANGLE); }
2728 { return(T_L_DBLANGLE); }
2733 { return(T_R_DBLANGLE); }
2738 { yylval.intval = L_DOTTED; return(T_L_ANGLE); }
2743 { yylval.intval = L_DASHED; return(T_L_ANGLE); }
2748 { yylval.intval = IN_DOWNWARD; return(T_NOWHERE_SLIDE); }
2753 { yylval.intval = IN_UPWARD; return(T_NOWHERE_SLIDE); }
2758 { yylval.intval = OUT_UPWARD; return(T_NOWHERE_SLIDE); }
2763 { yylval.intval = OUT_DOWNWARD; return(T_NOWHERE_SLIDE); }
2778 { yylval.intval = TM_CHORD; return(T_MODIFIER); }
2783 { yylval.intval = TM_ANALYSIS; return(T_MODIFIER); }
2788 { yylval.intval = TM_FIGBASS; return(T_MODIFIER); }
2793 { yylval.intval = TM_DYN; return(T_MODIFIER); }
2843 /* End of 'if' clause'. Set back to the
2844 * normal lexer. Call the mini-paser on
2845 * the compressed form of the clause we
2849 set_ifclause_buffer(Ifclause_buff, If_length);
2850 if (ifparse() == YES) {
2854 /* skip ifdef-ed part */
2855 if (skip2else() == YES) {
2859 /* if found an endif instead,
2860 * we just continue */
2867 { add_ifclause('a'); }
2872 { add_ifclause('o'); }
2877 { add_ifclause(yytext[0]); }
2882 { add_ifclause('l'); }
2887 { add_ifclause('r'); }
2892 { add_ifclause('L'); }
2897 { add_ifclause('G'); }
2902 { add_ifclause('E'); }
2907 { add_ifclause('N'); }
2914 { addnumstr_ifclause(yytext); }
2924 for (parens = m = 0; m < yyleng; m++) {
2925 if (yytext[m] == '(') {
2927 } else if (yytext[m] == ')') {
2932 yyerror("unmatched parentheses around target of 'defined'");
2934 macname = yytext + 7 + strspn(yytext + 7, "( \t\n");
2935 strtok(macname, " \t\n)");
2936 add_ifclause(is_defined(macname, YES) ? 'T' : 'F');
2943 if (is_defined(yytext, YES) != 0) {
2947 addnumstr_ifclause("0");
2960 yyerror("Missing 'then' for 'if' clause");
2968 bad_input("'if' clause");
2969 /* User forgetting or misspelling 'then' can
2970 * quickly cause hundreds of errors,
2971 * so bail out if we suspect that.
2972 * The actual number of errors to bail out on
2974 if (++If_errs > 20) {
2975 ufatal("Too many errors in 'if' clause. Maybe missing 'then'?");
2982 define_macro(yytext + 7);
2987 undef_macro(yytext + 6);
2995 /* do ifdef or ifndef as appropriate */
2996 if (yytext[2] == 'n') {
2997 result = ! is_defined(yytext + 7
2998 + strspn(yytext + 7, " \t"), NO);
3001 result = is_defined(yytext + 6
3002 + strspn(yytext + 6, " \t"), NO);
3006 /* do stuff till else or endif */
3010 /* skip ifdef-ed part */
3011 if (skip2else() == YES) {
3015 /* if found an endif instead,
3016 * we just continue */
3025 yyerror("else without ifdef");
3029 if (skip2else() == YES) {
3030 yyerror("else without ifdef");
3040 yyerror("endif without ifdef");
3056 if (isspace(yytext[1]) ||
3057 isspace(yytext[yyleng-2])) {
3058 yyerror("spaces not allowed inside ` ` marks");
3061 /* We only need the leading ` to tell
3062 * it is a quoted macro parm,
3063 * and it's easier to deal with later
3064 * if there is no trailing `
3065 * so strip off the trailing. */
3066 yytext[yyleng - 1] = '\0';
3074 { yylval.intval = strlen(yytext); return(T_TICKS); }
3080 /* ignore backslashed newlines;
3081 * allow white space after backslash */
3089 /* in case we get control-Z from DOS */
3097 /* ignore extra white space */
3108 case YY_STATE_EOF(INITIAL):
3109 case YY_STATE_EOF(IF_CLAUSE):
3110 case YY_STATE_EOF(STRING):
3113 /* In case user used an editor or other tool to
3114 * create the input file which may leave the final
3115 * line without a newline, add a newline to the
3116 * input. If there was already a newline, an extra
3117 * one should never hurt. Adding it can prevent
3118 * cryptic message about error at token '' */
3119 if (Eof_newline == 0) {
3120 Eof_newline = yy_scan_string("\n");
3123 yy_delete_buffer(Eof_newline);
3134 case YY_END_OF_BUFFER:
3136 /* Amount of text matched not including the EOB char. */
3137 int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
3139 /* Undo the effects of YY_DO_BEFORE_ACTION. */
3140 *yy_cp = yy_hold_char;
3141 YY_RESTORE_YY_MORE_OFFSET
3143 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
3145 /* We're scanning a new file or input source. It's
3146 * possible that this happened because the user
3147 * just pointed yyin at a new source and called
3148 * yylex(). If so, then we have to assure
3149 * consistency between yy_current_buffer and our
3150 * globals. Here is the right place to do so, because
3151 * this is the first action (other than possibly a
3152 * back-up) that will match for the new input source.
3154 yy_n_chars = yy_current_buffer->yy_n_chars;
3155 yy_current_buffer->yy_input_file = yyin;
3156 yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
3159 /* Note that here we test for yy_c_buf_p "<=" to the position
3160 * of the first EOB in the buffer, since yy_c_buf_p will
3161 * already have been incremented past the NUL character
3162 * (since all states make transitions on EOB to the
3163 * end-of-buffer state). Contrast this with the test
3166 if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
3167 { /* This was really a NUL. */
3168 yy_state_type yy_next_state;
3170 yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
3172 yy_current_state = yy_get_previous_state();
3174 /* Okay, we're now positioned to make the NUL
3175 * transition. We couldn't have
3176 * yy_get_previous_state() go ahead and do it
3177 * for us because it doesn't know how to deal
3178 * with the possibility of jamming (and we don't
3179 * want to build jamming into it because then it
3180 * will run more slowly).
3183 yy_next_state = yy_try_NUL_trans( yy_current_state );
3185 yy_bp = yytext_ptr + YY_MORE_ADJ;
3187 if ( yy_next_state )
3189 /* Consume the NUL. */
3190 yy_cp = ++yy_c_buf_p;
3191 yy_current_state = yy_next_state;
3198 goto yy_find_action;
3202 else switch ( yy_get_next_buffer() )
3204 case EOB_ACT_END_OF_FILE:
3206 yy_did_buffer_switch_on_eof = 0;
3210 /* Note: because we've taken care in
3211 * yy_get_next_buffer() to have set up
3212 * yytext, we can now set up
3213 * yy_c_buf_p so that if some total
3214 * hoser (like flex itself) wants to
3215 * call the scanner after we return the
3216 * YY_NULL, it'll still work - another
3217 * YY_NULL will get returned.
3219 yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
3221 yy_act = YY_STATE_EOF(YY_START);
3227 if ( ! yy_did_buffer_switch_on_eof )
3233 case EOB_ACT_CONTINUE_SCAN:
3235 yytext_ptr + yy_amount_of_matched_text;
3237 yy_current_state = yy_get_previous_state();
3240 yy_bp = yytext_ptr + YY_MORE_ADJ;
3243 case EOB_ACT_LAST_MATCH:
3245 &yy_current_buffer->yy_ch_buf[yy_n_chars];
3247 yy_current_state = yy_get_previous_state();
3250 yy_bp = yytext_ptr + YY_MORE_ADJ;
3251 goto yy_find_action;
3258 "fatal flex scanner internal error--no action found" );
3259 } /* end of action switch */
3260 } /* end of scanning one token */
3261 } /* end of yylex */
3264 /* yy_get_next_buffer - try to read in a new buffer
3266 * Returns a code representing an action:
3267 * EOB_ACT_LAST_MATCH -
3268 * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
3269 * EOB_ACT_END_OF_FILE - end of file
3272 static int yy_get_next_buffer()
3274 register char *dest = yy_current_buffer->yy_ch_buf;
3275 register char *source = yytext_ptr;
3276 register int number_to_move, i;
3279 if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
3281 "fatal flex scanner internal error--end of buffer missed" );
3283 if ( yy_current_buffer->yy_fill_buffer == 0 )
3284 { /* Don't try to fill the buffer, so this is an EOF. */
3285 if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
3287 /* We matched a single character, the EOB, so
3288 * treat this as a final EOF.
3290 return EOB_ACT_END_OF_FILE;
3295 /* We matched some text prior to the EOB, first
3298 return EOB_ACT_LAST_MATCH;
3302 /* Try to read more data. */
3304 /* First move last chars to start of buffer. */
3305 number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
3307 for ( i = 0; i < number_to_move; ++i )
3308 *(dest++) = *(source++);
3310 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
3311 /* don't do the read, it's not guaranteed to return an EOF,
3314 yy_current_buffer->yy_n_chars = yy_n_chars = 0;
3319 yy_current_buffer->yy_buf_size - number_to_move - 1;
3321 while ( num_to_read <= 0 )
3322 { /* Not enough room in the buffer - grow it. */
3323 #ifdef YY_USES_REJECT
3325 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
3328 /* just a shorter name for the current buffer */
3329 YY_BUFFER_STATE b = yy_current_buffer;
3331 int yy_c_buf_p_offset =
3332 (int) (yy_c_buf_p - b->yy_ch_buf);
3334 if ( b->yy_is_our_buffer )
3336 int new_size = b->yy_buf_size * 2;
3338 if ( new_size <= 0 )
3339 b->yy_buf_size += b->yy_buf_size / 8;
3341 b->yy_buf_size *= 2;
3343 b->yy_ch_buf = (char *)
3344 /* Include room in for 2 EOB chars. */
3345 yy_flex_realloc( (void *) b->yy_ch_buf,
3346 b->yy_buf_size + 2 );
3349 /* Can't grow it, we don't own it. */
3352 if ( ! b->yy_ch_buf )
3354 "fatal error - scanner input buffer overflow" );
3356 yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
3358 num_to_read = yy_current_buffer->yy_buf_size -
3363 if ( num_to_read > YY_READ_BUF_SIZE )
3364 num_to_read = YY_READ_BUF_SIZE;
3366 /* Read in more data. */
3367 YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
3368 yy_n_chars, num_to_read );
3370 yy_current_buffer->yy_n_chars = yy_n_chars;
3373 if ( yy_n_chars == 0 )
3375 if ( number_to_move == YY_MORE_ADJ )
3377 ret_val = EOB_ACT_END_OF_FILE;
3383 ret_val = EOB_ACT_LAST_MATCH;
3384 yy_current_buffer->yy_buffer_status =
3385 YY_BUFFER_EOF_PENDING;
3390 ret_val = EOB_ACT_CONTINUE_SCAN;
3392 yy_n_chars += number_to_move;
3393 yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
3394 yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
3396 yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
3402 /* yy_get_previous_state - get the state just before the EOB char was reached */
3404 static yy_state_type yy_get_previous_state()
3406 register yy_state_type yy_current_state;
3407 register char *yy_cp;
3409 yy_current_state = yy_start;
3411 for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
3413 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
3414 if ( yy_accept[yy_current_state] )
3416 yy_last_accepting_state = yy_current_state;
3417 yy_last_accepting_cpos = yy_cp;
3419 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3421 yy_current_state = (int) yy_def[yy_current_state];
3422 if ( yy_current_state >= 1176 )
3423 yy_c = yy_meta[(unsigned int) yy_c];
3425 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3428 return yy_current_state;
3432 /* yy_try_NUL_trans - try to make a transition on the NUL character
3435 * next_state = yy_try_NUL_trans( current_state );
3438 #ifdef YY_USE_PROTOS
3439 static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
3441 static yy_state_type yy_try_NUL_trans( yy_current_state )
3442 yy_state_type yy_current_state;
3445 register int yy_is_jam;
3446 register char *yy_cp = yy_c_buf_p;
3448 register YY_CHAR yy_c = 1;
3449 if ( yy_accept[yy_current_state] )
3451 yy_last_accepting_state = yy_current_state;
3452 yy_last_accepting_cpos = yy_cp;
3454 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3456 yy_current_state = (int) yy_def[yy_current_state];
3457 if ( yy_current_state >= 1176 )
3458 yy_c = yy_meta[(unsigned int) yy_c];
3460 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3461 yy_is_jam = (yy_current_state == 1175);
3463 return yy_is_jam ? 0 : yy_current_state;
3468 #ifdef YY_USE_PROTOS
3469 static void yyunput( int c, register char *yy_bp )
3471 static void yyunput( c, yy_bp )
3473 register char *yy_bp;
3476 register char *yy_cp = yy_c_buf_p;
3478 /* undo effects of setting up yytext */
3479 *yy_cp = yy_hold_char;
3481 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
3482 { /* need to shift things up to make room */
3483 /* +2 for EOB chars. */
3484 register int number_to_move = yy_n_chars + 2;
3485 register char *dest = &yy_current_buffer->yy_ch_buf[
3486 yy_current_buffer->yy_buf_size + 2];
3487 register char *source =
3488 &yy_current_buffer->yy_ch_buf[number_to_move];
3490 while ( source > yy_current_buffer->yy_ch_buf )
3491 *--dest = *--source;
3493 yy_cp += (int) (dest - source);
3494 yy_bp += (int) (dest - source);
3495 yy_current_buffer->yy_n_chars =
3496 yy_n_chars = yy_current_buffer->yy_buf_size;
3498 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
3499 YY_FATAL_ERROR( "flex scanner push-back overflow" );
3502 *--yy_cp = (char) c;
3506 yy_hold_char = *yy_cp;
3509 #endif /* ifndef YY_NO_UNPUT */
3513 static int yyinput()
3520 *yy_c_buf_p = yy_hold_char;
3522 if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
3524 /* yy_c_buf_p now points to the character we want to return.
3525 * If this occurs *before* the EOB characters, then it's a
3526 * valid NUL; if not, then we've hit the end of the buffer.
3528 if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
3529 /* This was really a NUL. */
3533 { /* need more input */
3534 int offset = yy_c_buf_p - yytext_ptr;
3537 switch ( yy_get_next_buffer() )
3539 case EOB_ACT_LAST_MATCH:
3540 /* This happens because yy_g_n_b()
3541 * sees that we've accumulated a
3542 * token and flags that we need to
3543 * try matching the token before
3544 * proceeding. But for input(),
3545 * there's no matching to consider.
3546 * So convert the EOB_ACT_LAST_MATCH
3547 * to EOB_ACT_END_OF_FILE.
3550 /* Reset buffer status. */
3555 case EOB_ACT_END_OF_FILE:
3560 if ( ! yy_did_buffer_switch_on_eof )
3569 case EOB_ACT_CONTINUE_SCAN:
3570 yy_c_buf_p = yytext_ptr + offset;
3576 c = *(unsigned char *) yy_c_buf_p; /* cast for 8-bit char's */
3577 *yy_c_buf_p = '\0'; /* preserve yytext */
3578 yy_hold_char = *++yy_c_buf_p;
3585 #ifdef YY_USE_PROTOS
3586 void yyrestart( FILE *input_file )
3588 void yyrestart( input_file )
3592 if ( ! yy_current_buffer )
3593 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
3595 yy_init_buffer( yy_current_buffer, input_file );
3596 yy_load_buffer_state();
3600 #ifdef YY_USE_PROTOS
3601 void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
3603 void yy_switch_to_buffer( new_buffer )
3604 YY_BUFFER_STATE new_buffer;
3607 if ( yy_current_buffer == new_buffer )
3610 if ( yy_current_buffer )
3612 /* Flush out information for old buffer. */
3613 *yy_c_buf_p = yy_hold_char;
3614 yy_current_buffer->yy_buf_pos = yy_c_buf_p;
3615 yy_current_buffer->yy_n_chars = yy_n_chars;
3618 yy_current_buffer = new_buffer;
3619 yy_load_buffer_state();
3621 /* We don't actually know whether we did this switch during
3622 * EOF (yywrap()) processing, but the only time this flag
3623 * is looked at is after yywrap() is called, so it's safe
3624 * to go ahead and always set it.
3626 yy_did_buffer_switch_on_eof = 1;
3630 #ifdef YY_USE_PROTOS
3631 void yy_load_buffer_state( void )
3633 void yy_load_buffer_state()
3636 yy_n_chars = yy_current_buffer->yy_n_chars;
3637 yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
3638 yyin = yy_current_buffer->yy_input_file;
3639 yy_hold_char = *yy_c_buf_p;
3643 #ifdef YY_USE_PROTOS
3644 YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
3646 YY_BUFFER_STATE yy_create_buffer( file, size )
3653 b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
3655 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
3657 b->yy_buf_size = size;
3659 /* yy_ch_buf has to be 2 characters longer than the size given because
3660 * we need to put in 2 end-of-buffer characters.
3662 b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
3663 if ( ! b->yy_ch_buf )
3664 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
3666 b->yy_is_our_buffer = 1;
3668 yy_init_buffer( b, file );
3674 #ifdef YY_USE_PROTOS
3675 void yy_delete_buffer( YY_BUFFER_STATE b )
3677 void yy_delete_buffer( b )
3684 if ( b == yy_current_buffer )
3685 yy_current_buffer = (YY_BUFFER_STATE) 0;
3687 if ( b->yy_is_our_buffer )
3688 yy_flex_free( (void *) b->yy_ch_buf );
3690 yy_flex_free( (void *) b );
3694 #ifndef YY_ALWAYS_INTERACTIVE
3695 #ifndef YY_NEVER_INTERACTIVE
3696 extern int isatty YY_PROTO(( int ));
3700 #ifdef YY_USE_PROTOS
3701 void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
3703 void yy_init_buffer( b, file )
3710 yy_flush_buffer( b );
3712 b->yy_input_file = file;
3713 b->yy_fill_buffer = 1;
3715 #if YY_ALWAYS_INTERACTIVE
3716 b->yy_is_interactive = 1;
3718 #if YY_NEVER_INTERACTIVE
3719 b->yy_is_interactive = 0;
3721 b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
3727 #ifdef YY_USE_PROTOS
3728 void yy_flush_buffer( YY_BUFFER_STATE b )
3730 void yy_flush_buffer( b )
3740 /* We always need two end-of-buffer characters. The first causes
3741 * a transition to the end-of-buffer state. The second causes
3742 * a jam in that state.
3744 b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
3745 b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
3747 b->yy_buf_pos = &b->yy_ch_buf[0];
3750 b->yy_buffer_status = YY_BUFFER_NEW;
3752 if ( b == yy_current_buffer )
3753 yy_load_buffer_state();
3757 #ifndef YY_NO_SCAN_BUFFER
3758 #ifdef YY_USE_PROTOS
3759 YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
3761 YY_BUFFER_STATE yy_scan_buffer( base, size )
3769 base[size-2] != YY_END_OF_BUFFER_CHAR ||
3770 base[size-1] != YY_END_OF_BUFFER_CHAR )
3771 /* They forgot to leave room for the EOB's. */
3774 b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
3776 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
3778 b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
3779 b->yy_buf_pos = b->yy_ch_buf = base;
3780 b->yy_is_our_buffer = 0;
3781 b->yy_input_file = 0;
3782 b->yy_n_chars = b->yy_buf_size;
3783 b->yy_is_interactive = 0;
3785 b->yy_fill_buffer = 0;
3786 b->yy_buffer_status = YY_BUFFER_NEW;
3788 yy_switch_to_buffer( b );
3795 #ifndef YY_NO_SCAN_STRING
3796 #ifdef YY_USE_PROTOS
3797 YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
3799 YY_BUFFER_STATE yy_scan_string( yy_str )
3800 yyconst char *yy_str;
3804 for ( len = 0; yy_str[len]; ++len )
3807 return yy_scan_bytes( yy_str, len );
3812 #ifndef YY_NO_SCAN_BYTES
3813 #ifdef YY_USE_PROTOS
3814 YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
3816 YY_BUFFER_STATE yy_scan_bytes( bytes, len )
3817 yyconst char *bytes;
3826 /* Get memory for full buffer, including space for trailing EOB's. */
3828 buf = (char *) yy_flex_alloc( n );
3830 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
3832 for ( i = 0; i < len; ++i )
3835 buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
3837 b = yy_scan_buffer( buf, n );
3839 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
3841 /* It's okay to grow etc. this buffer, and we should throw it
3842 * away when we're done.
3844 b->yy_is_our_buffer = 1;
3851 #ifndef YY_NO_PUSH_STATE
3852 #ifdef YY_USE_PROTOS
3853 static void yy_push_state( int new_state )
3855 static void yy_push_state( new_state )
3859 if ( yy_start_stack_ptr >= yy_start_stack_depth )
3863 yy_start_stack_depth += YY_START_STACK_INCR;
3864 new_size = yy_start_stack_depth * sizeof( int );
3866 if ( ! yy_start_stack )
3867 yy_start_stack = (int *) yy_flex_alloc( new_size );
3870 yy_start_stack = (int *) yy_flex_realloc(
3871 (void *) yy_start_stack, new_size );
3873 if ( ! yy_start_stack )
3875 "out of memory expanding start-condition stack" );
3878 yy_start_stack[yy_start_stack_ptr++] = YY_START;
3885 #ifndef YY_NO_POP_STATE
3886 static void yy_pop_state()
3888 if ( --yy_start_stack_ptr < 0 )
3889 YY_FATAL_ERROR( "start-condition stack underflow" );
3891 BEGIN(yy_start_stack[yy_start_stack_ptr]);
3896 #ifndef YY_NO_TOP_STATE
3897 static int yy_top_state()
3899 return yy_start_stack[yy_start_stack_ptr - 1];
3903 #ifndef YY_EXIT_FAILURE
3904 #define YY_EXIT_FAILURE 2
3907 #ifdef YY_USE_PROTOS
3908 static void yy_fatal_error( yyconst char msg[] )
3910 static void yy_fatal_error( msg )
3914 (void) fprintf( stderr, "%s\n", msg );
3915 exit( YY_EXIT_FAILURE );
3920 /* Redefine yyless() so it works in section 3 code. */
3926 /* Undo effects of setting up yytext. */ \
3927 yytext[yyleng] = yy_hold_char; \
3928 yy_c_buf_p = yytext + n; \
3929 yy_hold_char = *yy_c_buf_p; \
3930 *yy_c_buf_p = '\0'; \
3936 /* Internal utility routines. */
3939 #ifdef YY_USE_PROTOS
3940 static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
3942 static void yy_flex_strncpy( s1, s2, n )
3949 for ( i = 0; i < n; ++i )
3954 #ifdef YY_NEED_STRLEN
3955 #ifdef YY_USE_PROTOS
3956 static int yy_flex_strlen( yyconst char *s )
3958 static int yy_flex_strlen( s )
3963 for ( n = 0; s[n]; ++n )
3971 #ifdef YY_USE_PROTOS
3972 static void *yy_flex_alloc( yy_size_t size )
3974 static void *yy_flex_alloc( size )
3978 return (void *) malloc( size );
3981 #ifdef YY_USE_PROTOS
3982 static void *yy_flex_realloc( void *ptr, yy_size_t size )
3984 static void *yy_flex_realloc( ptr, size )
3989 /* The cast to (char *) in the following accommodates both
3990 * implementations that use char* generic pointers, and those
3991 * that use void* generic pointers. It works with the latter
3992 * because both ANSI C and C++ allow castless assignment from
3993 * any pointer type to void*, and deal with argument conversions
3994 * as though doing an assignment.
3996 return (void *) realloc( (char *) ptr, size );
3999 #ifdef YY_USE_PROTOS
4000 static void yy_flex_free( void *ptr )
4002 static void yy_flex_free( ptr )
4020 /* comments go to end of line. This can be done with a simple
4021 * lex pattern, but when taken with all the other patterns, lex blows
4022 * up because of too many right contexts. So we do this special case
4023 * with this function.
4030 while ((yytext[yyleng] = input()) != '\n' && yytext[yyleng] != 0 &&
4031 yytext[yyleng] != EOF) {
4032 if (++yyleng >= YYLMAX) {
4033 l_ufatal(Curr_filename, yylineno, "input line too long");
4035 if (yytext[yyleng-1] == '\r') {
4036 /* If the \r is by itself, treat like a newline */
4038 if ((c = input()) == '\n') {
4039 yytext[--yyleng] = '\n';
4048 if (yytext[yyleng] == 0 || yytext[yyleng] == EOF) {
4052 if (yyleng > 0 && yytext[yyleng - 1] == '\\') {
4053 /* if backslashed newline, replace with real newline
4055 yytext[--yyleng] = '\n';
4058 /* handle DOS style backslashed \r\n */
4059 else if (yyleng > 1 && yytext[yyleng - 1] == '\r'
4060 && yytext[yyleng - 2] == '\\') {
4061 yytext[yyleng - 2] = '\r';
4062 yytext[--yyleng] = '\n';
4066 /* put newline back onto input stream */
4070 yytext[yyleng] = '\0';
4072 if (Preproc == YES && Ppcomments == YES) {
4073 printf("%s", yytext);
4078 /* Save macro text in specified file.
4079 * @ is used to mark end of macro definition.
4080 * Returns YES if there appeared to be any references to
4081 * macro parameters to be quoted.
4082 * (See the comment above the QS_ #defines in macros.c for more details.) */
4087 FILE *file; /* put macro text into this file */
4090 int c; /* character read from macro */
4091 int num_backslashes = 0;
4092 int has_quoted_parameters = NO;
4095 while ((c = input()) != 0 && c != EOF) {
4097 /* if had a backslash before it, use real @ */
4098 if (num_backslashes == 1) {
4100 num_backslashes = 0;
4103 /* reached end of macro definition */
4104 return(has_quoted_parameters);
4110 if (num_backslashes == 2) {
4112 num_backslashes = 0;
4116 if (num_backslashes == 1) {
4120 num_backslashes = 0;
4122 has_quoted_parameters = YES;
4128 yyerror("unterminated macro");
4129 return(has_quoted_parameters);
4133 /* collect the parameter names on the definition of a macro with parameters */
4136 get_parameters(macname)
4138 char *macname; /* name of macro being defined */
4141 while (get_a_param(macname) == YES) {
4147 get_a_param(macname)
4152 int c; /* input character */
4153 int index; /* into name buffer */
4156 /* skip leading white space */
4159 /* collect macro-like parameter names (upper case, digits, or
4160 * underscore, starting with upper case), delimited by comma
4161 * and ended by close parenthesis. */
4162 while ((c = input()) != '\0' && c != EOF) {
4166 while ((c = input()) != '\0' && c != EOF) {
4167 if (isupper(c) || isdigit(c) || c == '_') {
4168 yytext[index++] = c;
4171 /* found end of parameter name */
4173 yytext[index] = '\0';
4174 add_parameter(macname, yytext);
4176 /* skip white space */
4179 /* next better be , or ) */
4180 if ((c = input()) != ',' && c != ')') {
4181 l_yyerror(Curr_filename, yylineno,
4182 "unexpected character '%c' in parameter list for macro %s",
4187 /* return to input so we can
4188 * read on next call to know
4189 * we are at end of list */
4196 else if (c == ')') {
4197 /* end of parameter list */
4201 l_yyerror(Curr_filename, yylineno,
4202 "illegal macro parameter name starting at character '%c'", c);
4206 yyerror("unexpected end-of-file in macro parameter list");
4211 /* Read input, skipping any white space. White space is space, tab, return,
4212 * backslashed return, newline, or backslashed newline.
4213 * Backslashed anything else will leave the backslash in the input
4214 * without the thing that followed it.
4224 while ((c = input()) != '\0' && c != EOF) {
4225 if (c == ' ' || c == '\t' || c == '\n' || c == '\r') {
4230 if ((c = input()) == '\n' || c == '\r' ) {
4231 /* backslashed newline/return is white space */
4239 /* non-space. Stuff back into input and return */
4247 /* collect arguments to a call to a macro with parameters */
4250 get_mac_arguments(macname, num_args)
4252 char *macname; /* name of the macro, to use in error messages */
4253 int num_args; /* number of arguments expected */
4256 int c; /* input character */
4257 char *argbuff; /* for storing argument */
4258 int n; /* number of arguments collected so far */
4261 /* first skip any white space before the opening parenthesis */
4264 /* next thing better be open parenthesis */
4265 if ((c = input()) != '(') {
4267 l_yyerror(Curr_filename, yylineno,
4268 "macro %s has parameters, but has no '(' on call",
4271 /* Trying to parse anything more in this file might be
4272 * almost hopeless. But we'll try just skipping to end of
4273 * the line and returning failure and hope for the best. */
4274 while (((c = input()) != '\0') && (c != EOF) &&
4275 (c != '\n') && (c != '\r')) {
4281 /* init to no argument collected. Space will be malloc-ed when needed */
4282 argbuff = (char *) 0;
4285 /* Now collect arguments. Read and process input
4286 * one character at a time */
4287 while ((c = input()) != '\0' && c != EOF) {
4290 /* something that has been escaped with a backslash.
4291 * Get the next character and do appropriate escape. */
4292 switch (c = input()) {
4294 /* some unexpected backslashed thing */
4295 l_warning(Curr_filename, yylineno,
4296 "dubious escape \\%c in argument %d of macro %s",
4298 /* fall through to use the literal, to be
4299 * sort of consistent with how C handles
4300 * such dubious escapes */
4303 case ',': /* would normally mean end of argument */
4304 case ')': /* would normally mean end of argument list */
4305 case '\\': /* user wants a real backslash */
4306 /* escaped to allow literal, so copy the
4307 * character without backslash to buffer */
4308 argbuff = add2argbuff(argbuff, c);
4312 /* user wanted to put a newline in the input
4313 * to make it look better, but doesn't really
4314 * want a newline here in the argument text,
4315 * so just skip over this character */
4319 /* If by itself, treat like newline.
4320 * If immediately followed by a newline,
4321 * treat the pair like newline.
4323 if ((c = input()) != '\n') {
4324 /* Followed by something other than
4325 * newline, so push back into input.
4333 l_yyerror(Curr_filename, yylineno,
4334 "unexpected end of file in macro %s argument %d",
4341 /* This marks the end of an argument.
4342 * Process this argument, then reset for next one */
4343 if (++n <= num_args) {
4344 set_parm_value(macname, argbuff, n);
4347 /* discard this one. It's extra. But wait
4348 * to print error until we find the ),
4349 * so if they have lots of extras we only
4350 * print one message */
4351 if (argbuff != (char *) 0) {
4356 /* reset for next argument */
4357 argbuff = (char *) 0;
4361 /* this marks end of arguments. Save the last one
4362 * collected and signal success */
4363 if (++n == num_args) {
4364 /* good. got exactly the right number of
4365 * arguments. Save the last one and
4366 * declare victory */
4367 set_parm_value(macname, argbuff, n);
4371 l_yyerror(Curr_filename, yylineno,
4372 "too %s arguments to macro %s (expected %d, got %d)",
4373 ((n < num_args) ? "few" : "many"),
4374 macname, num_args, n);
4379 /* ordinary character. Save it away */
4380 argbuff = add2argbuff(argbuff, c);
4385 l_yyerror(Curr_filename, yylineno, "unexpected end of file in call to %s macro",
4391 /* skip input until find an else or endif. If find else, return YES, if find
4392 * endif or end of file, return NO */
4393 /* It probably would be possible to get lex to do this pattern matching with
4394 * appropriate start conditions, but it seems like too much trouble to figure
4395 * that out. Just need to look for 2 simple patterns, so do simple state
4398 typedef enum { STATE_NONE, STATE_E, STATE_EL, STATE_ELS, STATE_EN,
4399 STATE_END, STATE_ENDI, STATE_I, STATE_IF, STATE_IFD,
4406 int c; /* char read from input */
4407 STATE state = STATE_NONE;
4408 int escaped; /* true if got odd number of backslashes */
4409 int saved_ppcomments; /* saved value of Ppcomments */
4412 /* When skipping stuff in if/else, we don't want anything to come
4413 * out when using -E -C. Since this function can call to_eol(),
4414 * we have to convince it -C isn't on even if it is. */
4415 saved_ppcomments = Ppcomments;
4418 /* read characters. Based on current character and state, go into
4419 * new state if appropriate. */
4420 while ((c = input()) != 0 && c != EOF) {
4425 if (state == STATE_ELS) {
4427 Ppcomments = saved_ppcomments;
4430 else if (state == STATE_IFD) {
4439 state = (state == STATE_E ? STATE_EL : STATE_NONE);
4443 state = (state == STATE_EL ? STATE_ELS : STATE_NONE);
4447 if (state == STATE_E) {
4450 else if (state == STATE_IF) {
4451 /* for ifndef. Treat this like ifdef. There is
4452 * a tiny bug here in that user could input
4453 * ifnnndef and we would interpret that as
4454 * ifndef. However, since if we're in this
4455 * function, we are skipping stuff that is
4456 * ifdef-ed out, who cares if we miss some
4457 * off-the-wall syntax error? */
4466 if (state == STATE_EN) {
4469 else if (state == STATE_IF) {
4478 state = (state == STATE_END ? STATE_ENDI : STATE_I);
4482 if (state == STATE_ENDI) {
4484 Ppcomments = saved_ppcomments;
4487 else if (state == STATE_I) {
4490 else if (state == STATE_IFDE) {
4491 if (skip2else() == YES) {
4492 if (skip2else() == YES) {
4493 yyerror("else without ifdef");
4503 if ((c = input()) == '/') {
4504 /* Skip past comments, in case they happen to
4505 * contain 'else' or 'endif'
4506 * that could confuse us. */
4509 else if (c != 0 && c != EOF) {
4516 /* Skip strings, in case they happen to contain
4517 * 'else' or 'endif' that could confuse us. */
4519 while ((c = input()) != 0 && c != EOF) {
4520 if (c == '"' && ! escaped) {
4533 if (state == STATE_IF) {
4534 /* skip to else or endif */
4535 if (skip2else() == YES) {
4536 /* if was an else, need to continue
4538 if (skip2else() == YES) {
4539 yyerror("else without ifdef");
4549 yyerror("unexpected end-of-file: missing endif");
4554 /* at the very end, verify all if, ifdef, and ifndef clauses are closed */
4560 if (If_count != 0) {
4561 yyerror("missing endif");
4566 /* check if there is an odd number of backslashes starting before the final
4567 * double quote. If so, return YES--the last backslash applies to the double
4568 * quote. Otherwise return NO, because the backslash was itself backslashed
4569 * which means user wants to end string with a backslash */
4576 int bscount = 0; /* count of backslashes */
4578 for (i = yyleng - 2; i >= 0; i--) {
4579 if (yytext[i] == '\\') {
4586 return ((bscount & 1) ? YES: NO);
4590 /* Flex has the (documented) limitation that you can't change the value
4591 * of yyleng in the same rule action as you use yymore. So when there is
4592 * an escaped double quote mark inside a string, we can't remove it and
4593 * also use yymore in the same rule. So we collect the whole string,
4594 * including their embedded quote marks and their backslashes,
4595 * then call this function which moves the characters back to get rid of
4596 * the backslashes, and adjusts yyleng appropriately.
4606 if (Escapedquotes < 1) {
4607 /* No escaped quote found, so nothing to do here */
4612 for (i = 1; i < yyleng; i++) {
4613 /* if there is a quote inside the string,
4614 * it must have been escaped */
4615 if (yytext[i] == '"' && yytext[i-1] == '\\' && i < yyleng - 1) {
4618 /* If we have come across one or more embedded quotes,
4619 * move bytes to the left one position for each quote,
4620 * which gets rid of the backslashes. */
4622 yytext[i-moveback] = yytext[i];
4625 yytext[i-moveback] = '\0';
4626 yyleng -= Escapedquotes;
4632 /* Mapping of Latin-1 non-ASCII characters to their Mup names. If Mup
4633 * doesn't support the value, or the value is undefined in Latin-1,
4634 * value in this table is 0. */
4635 static char *latin1_to_mup_name[] = {
4669 /* 161 */ "exclamdown",
4671 /* 163 */ "sterling",
4676 /* 168 */ "dieresis",
4677 /* 169 */ "copyright",
4678 /* 170 */ "ordfeminine",
4692 /* 184 */ "cedilla",
4699 /* 191 */ "questiondown",
4766 /* This function goes through the string currently in yytext, and if it finds
4767 * any non-ASCII characters that can be transformed into the non-ASCII
4768 * characters that Mup supports through the \(....) escape mechanism,
4769 * it replaces them with the appropriate escape strings.
4770 * This functionality probably logically belongs in fix_string(),
4771 * but for historical reasons, that function is not allowed
4772 * to increase the length of a string,
4773 * so it's easier to do this step separately.
4779 int index; /* walk through yytext */
4780 int start; /* index of first non-ascii */
4781 int value; /* value of a character */
4782 char *replacement; /* Mup's name for the non_ascii */
4783 static char *tmp_buff = 0; /* for expanded version */
4784 int tmp_index; /* index into tmp_buff */
4786 if (Raw_string == YES) {
4787 /* Collecting a string for something like raw PostScript,
4788 * that shouldn't be converted. */
4792 /* see if any non-ascii */
4793 for (index = 0; index < yyleng; index++) {
4794 if (yytext[index] & 0x80) {
4799 if (index == yyleng) {
4800 /* no non-ascii in current string, so leave it as is */
4804 /* If we don't have a buffer yet, allocate it. If an input file
4805 * has no non-ascii in it at all, we'll never get here, and no
4806 * memory will be wasted on a buffer we don't need. If we do get
4807 * here, chances are there will be lots more non-ascii, so we
4808 * keep the buffer around, rather than constantly doing malloc/free. */
4809 if (tmp_buff == 0) {
4810 MALLOCA(char, tmp_buff, YYLMAX);
4813 /* only need to rewrite the part of the string
4814 * beyond the first non-ascii, so remember where we are now */
4817 /* walk through, converting non-ascii to their Mup names */
4818 for (tmp_index = 0; index < yyleng; index++) {
4820 if (yytext[index] & 0x80) {
4821 /* Look up replacement. The replacement table
4822 * only contains entries for 128-255,
4823 * so adjust the value of the non-ascii character
4824 * to get the appropriate array offset. */
4825 value = ((int)(yytext[index])) & 0xff;
4826 replacement = latin1_to_mup_name[value - 128];
4828 if (replacement == (char *) 0) {
4829 /* Apparently user is able to input a
4830 * character that Mup doesn't support... */
4831 l_yyerror(Curr_filename, yylineno,
4832 "unsupported non-ASCII character (0x%x) in string",
4833 yytext[index] & 0xff);
4836 (void) sprintf(tmp_buff + tmp_index, "\\(%s)",
4838 tmp_index += strlen(replacement) + 3;
4842 /* normal ASCII character; copy as is */
4843 tmp_buff[tmp_index++] = yytext[index];
4847 /* Now we can copy the expanded string back into yytext and update
4848 * yyleng so that all later code will think the user typed in the
4849 * expanded version themselves. */
4850 (void) strncpy(yytext + start, tmp_buff, tmp_index);
4851 yyleng = start + tmp_index;
4852 yytext[yyleng] = '\0';
4856 /* push a character back into input. This allows another C file to
4857 * access the unput macro */
4869 /* this function will do nothing unless the "preprocessor only" flag is on,
4870 * in which case it will print the current token
4877 if (Preproc == YES) {
4878 printf("%s", yytext);
4883 /* When collecting raw PostScript, we don't want to convert non-ASCII to
4884 * Mup escapes. These functions turn the raw processing on and off. */
4899 /* Create a new flex buffer for the given input file and switch to it */
4907 struct Lexbuffer *newbuff;
4910 MALLOC(Lexbuffer, newbuff, 1);
4912 newbuff->buff = YY_CURRENT_BUFFER;
4916 MALLOC(Lexbuffer, newbuff, 1);
4917 newbuff->next = Lexlist;
4919 newbuff->buff = yy_create_buffer(file, YY_BUF_SIZE);
4920 yy_switch_to_buffer(newbuff->buff);
4923 /* Switch back to previous flex buffer on the stack */
4929 struct Lexbuffer *nextbuff;
4932 pfatal("attempt to pop from empty lex buffer stack");
4934 nextbuff = Lexlist->next;
4935 yy_delete_buffer(Lexlist->buff);
4938 yy_switch_to_buffer(nextbuff->buff);
4942 /* The contents of an "if clause" is stored in compressed form in
4943 * Ifclause_buff, and eventually passed to a mini-parser. This function
4944 * add tokens to the buffer. Compressed format:
4945 * input compressed token
4946 * -------------------------------------
4971 * defined(X) T or F depending on whether X is defined or not
4972 * literal number # followed by 4 bytes in MSB order
4973 * macro name # followed by macro's value as 4 bytes in MSB order
4982 if (If_length >= sizeof(Ifclause_buff)) {
4983 ufatal("Sorry, 'if' clause is too complex");
4985 Ifclause_buff[If_length++] = (unsigned char) (token & 0xff);
4988 /* We store numbers in the if-clause compressed form as '#' followed by
4989 * 4 bytes in MSB order.
4994 addnum_ifclause(value)
5002 for (shift = 24; shift >= 0; shift -= 8) {
5003 add_ifclause((value >> shift) & 0xff);
5008 /* Add number in ASCII. Convert to value and add */
5011 addnumstr_ifclause(numtoken)
5022 value = strtol(numtoken, &end_p, 0);
5023 if (*end_p != '\0') {
5024 /* Lexer shouldn't allow unparsable number,
5025 * so if strtol didn't get to end, must be too big */
5026 yyerror("bad number (probably out of range)");
5029 /* Additional range check assuming strtol sets this properly
5030 * on all systems. */
5031 else if (errno == ERANGE) {
5032 yyerror("number is out of range");
5036 addnum_ifclause(value);
5040 /* Give error message for invalid input character, as actual character
5041 * if printable, otherwise as hex value. */
5046 char *where; /* describes where the bad input was found */
5049 if (isgraph(yytext[0])) {
5050 l_yyerror(Curr_filename, yylineno,
5051 "invalid character in %s: '%c'",
5055 l_yyerror(Curr_filename, yylineno,
5056 "invalid character in %s: 0x%x",
5057 where, (int) yytext[0]);