4
#define YY_INT_ALIGNED short int
6
/* A lexical scanner generated by flex */
9
#define YY_FLEX_MAJOR_VERSION 2
10
#define YY_FLEX_MINOR_VERSION 5
11
#define YY_FLEX_SUBMINOR_VERSION 33
12
#if YY_FLEX_SUBMINOR_VERSION > 0
16
/* First, we deal with platform-specific or compiler-specific issues. */
18
/* begin standard C headers. */
24
/* end standard C headers. */
26
/* flex integer type definitions */
31
/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
33
#if __STDC_VERSION__ >= 199901L
35
/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
36
* if you want the limit (max/min) macros for int types.
38
#ifndef __STDC_LIMIT_MACROS
39
#define __STDC_LIMIT_MACROS 1
43
typedef int8_t flex_int8_t;
44
typedef uint8_t flex_uint8_t;
45
typedef int16_t flex_int16_t;
46
typedef uint16_t flex_uint16_t;
47
typedef int32_t flex_int32_t;
48
typedef uint32_t flex_uint32_t;
50
typedef signed char flex_int8_t;
51
typedef short int flex_int16_t;
52
typedef int flex_int32_t;
53
typedef unsigned char flex_uint8_t;
54
typedef unsigned short int flex_uint16_t;
55
typedef unsigned int flex_uint32_t;
58
/* Limits of integral types. */
60
#define INT8_MIN (-128)
63
#define INT16_MIN (-32767-1)
66
#define INT32_MIN (-2147483647-1)
69
#define INT8_MAX (127)
72
#define INT16_MAX (32767)
75
#define INT32_MAX (2147483647)
78
#define UINT8_MAX (255U)
81
#define UINT16_MAX (65535U)
84
#define UINT32_MAX (4294967295U)
87
#endif /* ! FLEXINT_H */
91
/* The "const" storage-class-modifier is valid. */
94
#else /* ! __cplusplus */
100
#endif /* __STDC__ */
101
#endif /* ! __cplusplus */
104
#define yyconst const
109
/* Returned upon end-of-file. */
112
/* Promotes a possibly negative, possibly signed char to an unsigned
113
* integer for use as an array index. If the signed char is negative,
114
* we want to instead treat it as an 8-bit unsigned char, hence the
117
#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
119
/* Enter a start condition. This macro really ought to take a parameter,
120
* but we do it the disgusting crufty way forced on us by the ()-less
121
* definition of BEGIN.
123
#define BEGIN (yy_start) = 1 + 2 *
125
/* Translate the current start state into a value that can be later handed
126
* to BEGIN to return to the state. The YYSTATE alias is for lex
129
#define YY_START (((yy_start) - 1) / 2)
130
#define YYSTATE YY_START
132
/* Action number for EOF rule of a given start state. */
133
#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
135
/* Special action meaning "start processing a new file". */
136
#define YY_NEW_FILE yyrestart(yyin )
138
#define YY_END_OF_BUFFER_CHAR 0
140
/* Size of default input buffer. */
142
#define YY_BUF_SIZE 16384
145
/* The state buf must be large enough to hold one state per character in the main buffer.
147
#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
149
#ifndef YY_TYPEDEF_YY_BUFFER_STATE
150
#define YY_TYPEDEF_YY_BUFFER_STATE
151
typedef struct yy_buffer_state *YY_BUFFER_STATE;
156
extern FILE *yyin, *yyout;
158
#define EOB_ACT_CONTINUE_SCAN 0
159
#define EOB_ACT_END_OF_FILE 1
160
#define EOB_ACT_LAST_MATCH 2
162
#define YY_LESS_LINENO(n)
164
/* Return all but the first "n" matched characters back to the input stream. */
168
/* Undo effects of setting up yytext. */ \
169
int yyless_macro_arg = (n); \
170
YY_LESS_LINENO(yyless_macro_arg);\
171
*yy_cp = (yy_hold_char); \
172
YY_RESTORE_YY_MORE_OFFSET \
173
(yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
174
YY_DO_BEFORE_ACTION; /* set up yytext again */ \
178
#define unput(c) yyunput( c, (yytext_ptr) )
180
/* The following is because we cannot portably get our hands on size_t
181
* (without autoconf's help, which isn't available because we want
182
* flex-generated scanners to compile on their own).
185
#ifndef YY_TYPEDEF_YY_SIZE_T
186
#define YY_TYPEDEF_YY_SIZE_T
187
typedef unsigned int yy_size_t;
190
#ifndef YY_STRUCT_YY_BUFFER_STATE
191
#define YY_STRUCT_YY_BUFFER_STATE
192
struct yy_buffer_state
196
char *yy_ch_buf; /* input buffer */
197
char *yy_buf_pos; /* current position in input buffer */
199
/* Size of input buffer in bytes, not including room for EOB
202
yy_size_t yy_buf_size;
204
/* Number of characters read into yy_ch_buf, not including EOB
209
/* Whether we "own" the buffer - i.e., we know we created it,
210
* and can realloc() it to grow it, and should free() it to
213
int yy_is_our_buffer;
215
/* Whether this is an "interactive" input source; if so, and
216
* if we're using stdio for input, then we want to use getc()
217
* instead of fread(), to make sure we stop fetching input after
220
int yy_is_interactive;
222
/* Whether we're considered to be at the beginning of a line.
223
* If so, '^' rules will be active on the next match, otherwise
228
int yy_bs_lineno; /**< The line count. */
229
int yy_bs_column; /**< The column count. */
231
/* Whether to try to fill the input buffer when we reach the
236
int yy_buffer_status;
238
#define YY_BUFFER_NEW 0
239
#define YY_BUFFER_NORMAL 1
240
/* When an EOF's been seen but there's still some text to process
241
* then we mark the buffer as YY_EOF_PENDING, to indicate that we
242
* shouldn't try reading from the input source any more. We might
243
* still have a bunch of tokens to match, though, because of
244
* possible backing-up.
246
* When we actually see the EOF, we change the status to "new"
247
* (via yyrestart()), so that the user can continue scanning by
248
* just pointing yyin at a new input file.
250
#define YY_BUFFER_EOF_PENDING 2
253
#endif /* !YY_STRUCT_YY_BUFFER_STATE */
255
/* Stack of input buffers. */
256
static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */
257
static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */
258
static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */
260
/* We provide macros for accessing buffer states in case in the
261
* future we want to put the buffer states in a more general
264
* Returns the top of the stack, or NULL.
266
#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \
267
? (yy_buffer_stack)[(yy_buffer_stack_top)] \
270
/* Same as previous macro, but useful when we know that the buffer stack is not
271
* NULL or when we need an lvalue. For internal use only.
273
#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)]
275
/* yy_hold_char holds the character lost when yytext is formed. */
276
static char yy_hold_char;
277
static int yy_n_chars; /* number of characters read into yy_ch_buf */
280
/* Points to current character in buffer. */
281
static char *yy_c_buf_p = (char *) 0;
282
static int yy_init = 0; /* whether we need to initialize */
283
static int yy_start = 0; /* start state number */
285
/* Flag which is used to allow yywrap()'s to do buffer switches
286
* instead of setting up a fresh yyin. A bit of a hack ...
288
static int yy_did_buffer_switch_on_eof;
290
void yyrestart (FILE *input_file );
291
void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer );
292
YY_BUFFER_STATE yy_create_buffer (FILE *file,int size );
293
void yy_delete_buffer (YY_BUFFER_STATE b );
294
void yy_flush_buffer (YY_BUFFER_STATE b );
295
void yypush_buffer_state (YY_BUFFER_STATE new_buffer );
296
void yypop_buffer_state (void );
298
static void yyensure_buffer_stack (void );
299
static void yy_load_buffer_state (void );
300
static void yy_init_buffer (YY_BUFFER_STATE b,FILE *file );
302
#define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER )
304
YY_BUFFER_STATE yy_scan_buffer (char *base,yy_size_t size );
305
YY_BUFFER_STATE yy_scan_string (yyconst char *yy_str );
306
YY_BUFFER_STATE yy_scan_bytes (yyconst char *bytes,int len );
308
void *yyalloc (yy_size_t );
309
void *yyrealloc (void *,yy_size_t );
310
void yyfree (void * );
312
#define yy_new_buffer yy_create_buffer
314
#define yy_set_interactive(is_interactive) \
316
if ( ! YY_CURRENT_BUFFER ){ \
317
yyensure_buffer_stack (); \
318
YY_CURRENT_BUFFER_LVALUE = \
319
yy_create_buffer(yyin,YY_BUF_SIZE ); \
321
YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
324
#define yy_set_bol(at_bol) \
326
if ( ! YY_CURRENT_BUFFER ){\
327
yyensure_buffer_stack (); \
328
YY_CURRENT_BUFFER_LVALUE = \
329
yy_create_buffer(yyin,YY_BUF_SIZE ); \
331
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
334
#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
336
/* Begin user sect3 */
338
typedef unsigned char YY_CHAR;
340
FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
342
typedef int yy_state_type;
349
#define yytext_ptr yytext
351
static yy_state_type yy_get_previous_state (void );
352
static yy_state_type yy_try_NUL_trans (yy_state_type current_state );
353
static int yy_get_next_buffer (void );
354
static void yy_fatal_error (yyconst char msg[] );
356
/* Done after the current pattern has been matched and before the
357
* corresponding action - sets up yytext.
359
#define YY_DO_BEFORE_ACTION \
360
(yytext_ptr) = yy_bp; \
361
yyleng = (size_t) (yy_cp - yy_bp); \
362
(yy_hold_char) = *yy_cp; \
364
(yy_c_buf_p) = yy_cp;
366
#define YY_NUM_RULES 25
367
#define YY_END_OF_BUFFER 26
368
/* This struct is not used in this scanner,
369
but its presence is necessary. */
372
flex_int32_t yy_verify;
375
static yyconst flex_int16_t yy_accept[477] =
377
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
378
0, 0, 26, 25, 25, 25, 2, 25, 25, 6,
379
25, 25, 24, 25, 25, 25, 25, 25, 25, 25,
380
25, 9, 25, 25, 16, 25, 0, 0, 2, 0,
381
0, 6, 0, 0, 24, 0, 0, 0, 0, 0,
382
0, 0, 0, 0, 0, 9, 0, 0, 16, 0,
383
0, 1, 0, 1, 0, 0, 0, 0, 0, 0,
384
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
385
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
386
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
388
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
389
0, 0, 0, 0, 0, 0, 0, 23, 0, 0,
390
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
391
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
392
0, 0, 0, 0, 0, 0, 0, 0, 5, 0,
393
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
394
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
395
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
396
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
397
0, 0, 0, 0, 0, 0, 0, 0, 0, 13,
399
0, 0, 6, 0, 0, 0, 0, 0, 0, 0,
400
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
401
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
402
0, 0, 0, 0, 0, 0, 12, 0, 0, 0,
403
0, 0, 0, 0, 0, 10, 0, 0, 12, 0,
404
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
405
0, 0, 0, 0, 0, 15, 0, 0, 0, 0,
406
0, 0, 0, 0, 0, 0, 24, 0, 22, 0,
407
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
408
0, 0, 0, 0, 0, 0, 0, 11, 0, 17,
410
0, 0, 0, 0, 8, 0, 0, 0, 3, 0,
411
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
412
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
413
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
414
0, 0, 0, 14, 0, 0, 0, 0, 0, 14,
415
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
416
0, 0, 0, 0, 0, 0, 0, 0, 20, 0,
417
0, 0, 0, 0, 0, 4, 0, 0, 0, 0,
418
0, 0, 0, 0, 0, 0, 0, 0, 19, 0,
419
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
421
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
422
0, 0, 0, 0, 0, 0, 0, 0, 0, 21,
423
0, 0, 0, 0, 0, 7, 0, 0, 0, 0,
424
0, 24, 0, 0, 0, 0, 0, 0, 0, 0,
425
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
426
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
427
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
431
static yyconst flex_int32_t yy_ec[256] =
433
1, 1, 1, 1, 1, 1, 1, 1, 1, 2,
434
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
435
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
436
1, 3, 4, 1, 1, 1, 5, 1, 1, 1,
437
1, 1, 1, 1, 1, 1, 6, 1, 7, 1,
438
1, 1, 8, 1, 9, 1, 10, 11, 1, 1,
439
1, 1, 1, 12, 13, 14, 15, 16, 17, 18,
440
19, 1, 1, 1, 1, 1, 1, 20, 21, 22,
441
1, 23, 24, 25, 1, 26, 27, 1, 1, 1,
442
1, 1, 1, 1, 28, 1, 29, 30, 31, 32,
444
33, 34, 35, 1, 36, 1, 1, 37, 38, 39,
445
40, 41, 1, 42, 43, 44, 45, 46, 1, 47,
446
1, 48, 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,
449
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,
455
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
456
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
457
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
458
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
459
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
463
static yyconst flex_int32_t yy_meta[49] =
465
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
466
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
467
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
468
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
469
1, 1, 1, 1, 1, 1, 1, 1
472
static yyconst flex_int16_t yy_base[516] =
474
0, 0, 809, 0, 1, 2, 6, 27, 8, 11,
475
12, 13, 813, 815, 808, 809, 815, 18, 808, 815,
476
29, 807, 815, 33, 35, 7, 14, 21, 23, 48,
477
806, 815, 19, 805, 815, 54, 804, 803, 815, 802,
478
801, 815, 49, 800, 815, 53, 40, 25, 34, 41,
479
59, 60, 62, 66, 799, 815, 67, 798, 815, 71,
480
797, 815, 796, 815, 73, 74, 75, 76, 81, 77,
481
82, 78, 84, 85, 91, 87, 88, 89, 92, 93,
482
94, 98, 102, 103, 104, 105, 106, 108, 114, 116,
483
121, 125, 134, 117, 122, 126, 128, 132, 137, 141,
485
795, 142, 143, 146, 151, 152, 149, 158, 153, 154,
486
159, 167, 160, 161, 164, 162, 794, 815, 166, 174,
487
179, 171, 180, 169, 186, 184, 190, 189, 197, 200,
488
201, 793, 204, 206, 205, 207, 209, 202, 212, 217,
489
214, 215, 216, 218, 219, 220, 221, 792, 815, 228,
490
229, 232, 237, 233, 238, 240, 242, 244, 245, 246,
491
249, 251, 255, 257, 258, 259, 262, 265, 260, 266,
492
268, 281, 282, 269, 270, 284, 272, 280, 288, 291,
493
292, 791, 293, 790, 301, 295, 294, 300, 302, 304,
494
306, 310, 312, 315, 317, 319, 320, 321, 789, 815,
496
323, 788, 769, 325, 322, 324, 326, 327, 334, 335,
497
339, 344, 340, 342, 343, 345, 347, 351, 763, 366,
498
785, 355, 368, 371, 373, 369, 375, 376, 784, 384,
499
783, 381, 386, 762, 385, 781, 815, 389, 388, 392,
500
393, 387, 397, 403, 780, 815, 391, 779, 815, 400,
501
778, 755, 420, 404, 396, 406, 405, 407, 408, 409,
502
776, 775, 410, 411, 774, 815, 754, 413, 430, 412,
503
440, 444, 445, 447, 414, 772, 751, 770, 766, 449,
504
450, 739, 453, 454, 452, 767, 766, 457, 738, 761,
505
763, 460, 720, 462, 463, 467, 761, 815, 760, 815,
507
464, 726, 735, 757, 815, 465, 748, 468, 815, 469,
508
470, 471, 473, 724, 714, 474, 747, 479, 476, 483,
509
484, 730, 724, 485, 749, 487, 490, 493, 491, 725,
510
714, 494, 501, 503, 747, 505, 506, 745, 710, 744,
511
712, 514, 742, 815, 515, 520, 701, 709, 739, 815,
512
705, 526, 524, 531, 706, 696, 701, 530, 535, 533,
513
693, 733, 695, 542, 545, 517, 689, 730, 815, 729,
514
544, 548, 549, 690, 727, 815, 558, 562, 686, 534,
515
546, 694, 553, 563, 724, 568, 565, 723, 719, 569,
516
570, 718, 571, 573, 697, 574, 575, 679, 577, 581,
518
691, 578, 579, 683, 582, 584, 681, 585, 589, 684,
519
591, 586, 674, 592, 593, 713, 580, 595, 712, 815,
520
596, 598, 711, 600, 710, 815, 601, 603, 609, 709,
521
708, 691, 668, 668, 662, 681, 678, 700, 660, 668,
522
657, 655, 658, 655, 663, 693, 692, 671, 663, 656,
523
657, 665, 662, 684, 644, 652, 641, 639, 642, 639,
524
647, 677, 676, 672, 671, 650, 632, 644, 636, 634,
525
637, 627, 666, 665, 815, 815, 665, 664, 663, 662,
526
661, 660, 659, 658, 657, 656, 655, 654, 653, 652,
527
651, 650, 649, 648, 646, 645, 644, 643, 642, 641,
529
640, 637, 636, 633, 631, 630, 629, 628, 627, 624,
530
619, 617, 611, 603, 0
533
static yyconst flex_int16_t yy_def[516] =
535
477, 477, 477, 478, 479, 479, 480, 480, 481, 481,
536
482, 482, 476, 476, 476, 483, 476, 483, 484, 476,
537
484, 485, 476, 485, 485, 485, 485, 485, 485, 485,
538
486, 476, 486, 487, 476, 487, 488, 483, 476, 489,
539
484, 476, 484, 485, 476, 485, 485, 485, 485, 485,
540
485, 485, 485, 485, 486, 476, 486, 487, 476, 487,
541
488, 476, 489, 476, 484, 484, 484, 485, 485, 485,
542
485, 485, 485, 485, 485, 485, 485, 486, 487, 487,
543
484, 484, 484, 485, 485, 485, 485, 485, 485, 485,
544
485, 485, 485, 486, 487, 487, 484, 484, 484, 485,
546
490, 485, 485, 485, 485, 485, 485, 485, 485, 486,
547
487, 487, 484, 484, 484, 485, 490, 476, 485, 485,
548
485, 485, 485, 485, 485, 485, 486, 487, 487, 487,
549
484, 491, 484, 485, 485, 485, 485, 485, 485, 485,
550
485, 485, 486, 487, 487, 487, 484, 491, 476, 492,
551
485, 485, 485, 485, 485, 485, 485, 485, 485, 485,
552
486, 487, 487, 487, 487, 484, 492, 492, 485, 485,
553
485, 485, 485, 485, 485, 485, 485, 485, 486, 487,
554
487, 493, 487, 494, 492, 485, 485, 485, 485, 485,
555
485, 485, 485, 485, 485, 486, 487, 487, 493, 476,
557
487, 494, 476, 492, 485, 485, 485, 485, 485, 485,
558
485, 485, 485, 485, 486, 487, 487, 487, 476, 492,
559
495, 485, 485, 485, 485, 485, 485, 485, 496, 486,
560
497, 487, 487, 476, 492, 495, 476, 485, 485, 485,
561
485, 485, 485, 485, 496, 476, 486, 497, 476, 487,
562
498, 476, 492, 485, 485, 485, 485, 485, 485, 485,
563
499, 500, 486, 487, 498, 476, 476, 492, 485, 485,
564
485, 485, 485, 485, 485, 499, 476, 500, 476, 486,
565
487, 476, 492, 485, 485, 501, 502, 485, 476, 476,
566
503, 487, 476, 504, 485, 485, 501, 476, 502, 476,
568
485, 476, 476, 503, 476, 487, 476, 504, 476, 504,
569
485, 485, 485, 476, 476, 487, 476, 504, 485, 485,
570
485, 476, 476, 487, 476, 504, 485, 485, 485, 476,
571
476, 487, 476, 504, 505, 485, 485, 476, 476, 506,
572
476, 504, 505, 476, 485, 485, 476, 476, 506, 476,
573
476, 504, 485, 485, 476, 476, 476, 504, 485, 485,
574
476, 507, 476, 504, 485, 485, 476, 507, 476, 508,
575
504, 485, 485, 476, 508, 476, 485, 485, 476, 485,
576
485, 476, 485, 485, 509, 485, 485, 509, 476, 485,
577
485, 476, 485, 485, 476, 485, 485, 476, 485, 485,
579
476, 485, 485, 476, 485, 485, 476, 485, 485, 476,
580
485, 485, 476, 485, 485, 510, 485, 485, 510, 476,
581
485, 485, 511, 485, 511, 476, 485, 485, 485, 512,
582
512, 476, 476, 476, 476, 476, 476, 476, 476, 476,
583
476, 476, 476, 476, 476, 513, 513, 476, 476, 476,
584
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
585
476, 514, 514, 476, 476, 476, 476, 476, 476, 476,
586
476, 476, 515, 515, 476, 0, 476, 476, 476, 476,
587
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
588
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
590
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
591
476, 476, 476, 476, 476
594
static yyconst flex_int16_t yy_nxt[864] =
596
474, 17, 20, 20, 18, 21, 21, 23, 45, 32,
597
24, 25, 32, 35, 35, 45, 36, 36, 26, 39,
598
56, 40, 45, 27, 45, 28, 45, 29, 23, 30,
599
42, 24, 25, 43, 45, 45, 45, 46, 50, 26,
600
33, 45, 45, 33, 27, 52, 28, 47, 29, 45,
601
42, 53, 48, 51, 45, 59, 49, 57, 60, 54,
602
45, 45, 72, 45, 71, 65, 68, 45, 56, 69,
603
66, 70, 59, 67, 42, 42, 42, 45, 45, 45,
604
73, 75, 45, 45, 79, 45, 45, 80, 45, 45,
605
56, 94, 45, 59, 59, 42, 76, 74, 78, 42,
607
77, 85, 82, 42, 45, 45, 45, 45, 84, 45,
608
83, 81, 88, 89, 91, 45, 86, 45, 56, 92,
609
87, 101, 45, 59, 95, 97, 45, 59, 90, 42,
610
93, 96, 98, 42, 102, 45, 109, 100, 42, 106,
611
104, 107, 45, 45, 45, 99, 105, 45, 108, 103,
612
45, 113, 45, 45, 45, 56, 111, 112, 110, 45,
613
59, 42, 42, 45, 114, 42, 120, 45, 59, 121,
614
45, 132, 45, 115, 119, 45, 116, 123, 122, 124,
615
45, 45, 139, 125, 129, 45, 127, 45, 141, 130,
616
59, 56, 131, 135, 128, 126, 133, 138, 59, 136,
618
134, 59, 42, 45, 137, 42, 45, 45, 45, 154,
619
45, 155, 140, 45, 150, 45, 45, 56, 45, 59,
620
59, 59, 42, 151, 142, 143, 158, 144, 152, 42,
621
45, 153, 146, 45, 45, 162, 145, 156, 45, 45,
622
163, 45, 168, 45, 147, 45, 45, 45, 178, 160,
623
56, 176, 59, 157, 161, 159, 59, 164, 59, 59,
624
42, 45, 165, 42, 170, 166, 42, 45, 169, 45,
625
45, 45, 171, 45, 175, 172, 168, 177, 174, 168,
626
173, 45, 45, 45, 179, 45, 193, 181, 191, 56,
627
180, 195, 59, 59, 59, 45, 45, 183, 186, 184,
629
182, 45, 42, 45, 185, 45, 188, 45, 187, 189,
630
190, 45, 192, 45, 194, 168, 45, 212, 45, 207,
631
56, 59, 59, 45, 59, 45, 42, 45, 45, 197,
632
210, 196, 221, 206, 198, 45, 45, 201, 205, 168,
633
45, 45, 204, 45, 56, 45, 59, 208, 59, 209,
634
223, 214, 59, 211, 215, 231, 45, 220, 213, 224,
635
217, 48, 226, 216, 218, 49, 225, 42, 222, 45,
636
45, 230, 45, 240, 45, 241, 45, 45, 227, 228,
637
168, 233, 59, 229, 242, 56, 42, 59, 45, 45,
638
45, 232, 56, 45, 45, 239, 238, 45, 45, 168,
640
253, 59, 235, 255, 45, 45, 45, 45, 45, 45,
641
45, 56, 59, 45, 42, 45, 243, 244, 251, 254,
642
247, 42, 250, 256, 258, 283, 263, 168, 260, 261,
643
264, 45, 257, 259, 168, 262, 269, 270, 271, 273,
644
284, 45, 268, 281, 275, 45, 45, 285, 45, 272,
645
56, 59, 274, 45, 42, 45, 295, 280, 45, 288,
646
292, 59, 306, 309, 45, 45, 59, 168, 45, 309,
647
309, 45, 45, 286, 45, 59, 310, 45, 287, 294,
648
309, 291, 310, 310, 45, 45, 59, 286, 309, 301,
649
287, 45, 45, 310, 45, 59, 311, 296, 316, 312,
651
321, 310, 329, 333, 309, 313, 45, 45, 318, 319,
652
328, 336, 320, 324, 327, 309, 45, 310, 45, 334,
653
326, 45, 354, 332, 337, 45, 359, 309, 310, 352,
654
341, 309, 45, 335, 45, 45, 45, 340, 345, 342,
655
310, 365, 364, 309, 310, 309, 45, 45, 358, 45,
656
45, 378, 346, 372, 45, 377, 310, 373, 310, 45,
657
380, 353, 360, 45, 45, 383, 45, 381, 371, 45,
658
45, 45, 45, 396, 45, 45, 45, 366, 45, 45,
659
45, 45, 45, 45, 408, 45, 45, 45, 386, 384,
660
45, 412, 45, 45, 45, 387, 45, 45, 390, 45,
662
424, 45, 45, 463, 45, 399, 391, 394, 397, 403,
663
45, 447, 393, 400, 411, 421, 409, 431, 405, 425,
664
415, 402, 406, 414, 419, 418, 417, 388, 375, 368,
665
349, 343, 427, 308, 423, 429, 304, 299, 422, 430,
666
297, 278, 276, 265, 248, 245, 236, 428, 202, 199,
667
167, 148, 117, 63, 61, 58, 55, 44, 41, 38,
668
34, 31, 22, 19, 16, 14, 475, 475, 473, 472,
669
471, 470, 469, 468, 467, 466, 465, 464, 464, 462,
670
461, 460, 459, 458, 457, 456, 455, 454, 453, 452,
671
451, 450, 449, 448, 448, 446, 445, 444, 443, 442,
673
441, 440, 439, 438, 437, 436, 435, 434, 433, 432,
674
432, 426, 426, 420, 420, 416, 413, 410, 407, 404,
675
401, 398, 395, 392, 389, 389, 385, 382, 376, 379,
676
376, 369, 374, 370, 369, 367, 363, 362, 361, 357,
677
350, 356, 355, 344, 351, 350, 348, 347, 344, 339,
678
338, 333, 331, 330, 325, 323, 322, 317, 305, 315,
679
314, 300, 298, 307, 305, 303, 302, 300, 298, 293,
680
290, 279, 289, 277, 282, 266, 279, 277, 267, 266,
681
249, 246, 237, 252, 249, 246, 237, 234, 219, 203,
682
200, 203, 200, 149, 149, 118, 118, 64, 62, 59,
684
56, 45, 42, 64, 39, 62, 59, 56, 45, 42,
685
39, 37, 476, 15, 13, 476, 476, 476, 476, 476,
686
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
687
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
688
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
689
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
693
static yyconst flex_int16_t yy_chk[864] =
695
515, 4, 5, 6, 4, 5, 6, 7, 26, 9,
696
7, 7, 10, 11, 12, 27, 11, 12, 7, 18,
697
33, 18, 28, 7, 29, 7, 48, 7, 8, 8,
698
21, 8, 8, 21, 24, 49, 25, 24, 26, 8,
699
9, 47, 50, 10, 8, 28, 8, 25, 8, 30,
700
43, 29, 25, 27, 46, 36, 25, 33, 36, 30,
701
51, 52, 49, 53, 48, 43, 46, 54, 57, 46,
702
43, 47, 60, 43, 65, 66, 67, 68, 70, 72,
703
50, 52, 69, 71, 60, 73, 74, 60, 76, 77,
704
78, 78, 75, 79, 80, 81, 53, 51, 57, 82,
706
54, 69, 66, 83, 84, 85, 86, 87, 68, 88,
707
67, 65, 72, 73, 75, 89, 70, 90, 94, 76,
708
71, 85, 91, 95, 79, 81, 92, 96, 74, 97,
709
77, 80, 82, 98, 86, 93, 93, 84, 99, 90,
710
88, 91, 100, 102, 103, 83, 89, 104, 92, 87,
711
107, 97, 105, 106, 109, 110, 95, 96, 94, 108,
712
111, 113, 114, 116, 98, 115, 103, 119, 112, 104,
713
124, 114, 122, 99, 102, 120, 100, 106, 105, 107,
714
121, 123, 123, 108, 112, 126, 110, 125, 125, 112,
715
128, 127, 113, 119, 111, 109, 115, 122, 129, 120,
717
116, 130, 131, 138, 121, 133, 135, 134, 136, 136,
718
137, 137, 124, 139, 133, 141, 142, 143, 140, 144,
719
145, 146, 147, 134, 126, 127, 140, 128, 134, 150,
720
151, 135, 130, 152, 154, 144, 129, 138, 153, 155,
721
144, 156, 150, 157, 131, 158, 159, 160, 160, 142,
722
161, 158, 162, 139, 143, 141, 163, 145, 164, 165,
723
166, 169, 146, 167, 152, 147, 168, 170, 151, 171,
724
174, 175, 153, 177, 157, 154, 167, 159, 156, 168,
725
155, 178, 172, 173, 161, 176, 176, 163, 174, 179,
726
162, 178, 180, 181, 183, 187, 186, 165, 169, 166,
728
164, 188, 185, 189, 168, 190, 171, 191, 170, 172,
729
173, 192, 175, 193, 177, 185, 194, 193, 195, 188,
730
196, 197, 198, 205, 201, 206, 204, 207, 208, 180,
731
191, 179, 205, 187, 181, 209, 210, 183, 186, 204,
732
211, 213, 185, 214, 215, 212, 216, 189, 217, 190,
733
207, 195, 218, 192, 196, 216, 222, 204, 194, 208,
734
198, 212, 210, 197, 201, 212, 209, 220, 206, 223,
735
226, 215, 224, 224, 225, 225, 227, 228, 211, 213,
736
220, 218, 232, 214, 226, 230, 235, 233, 242, 239,
737
238, 217, 247, 240, 241, 223, 222, 255, 243, 235,
739
235, 250, 220, 239, 244, 254, 257, 256, 258, 259,
740
260, 263, 264, 270, 268, 275, 227, 228, 233, 238,
741
230, 253, 232, 240, 241, 268, 247, 268, 242, 243,
742
250, 269, 240, 241, 253, 244, 254, 255, 256, 258,
743
269, 271, 253, 264, 260, 272, 273, 270, 274, 257,
744
280, 281, 259, 285, 283, 284, 284, 263, 288, 275,
745
281, 292, 292, 294, 295, 301, 306, 283, 296, 308,
746
310, 311, 312, 271, 313, 316, 294, 319, 273, 283,
747
318, 280, 308, 310, 320, 321, 324, 272, 326, 288,
748
274, 327, 329, 318, 328, 332, 295, 285, 306, 296,
750
313, 326, 321, 333, 334, 301, 336, 337, 310, 311,
751
320, 328, 312, 316, 319, 342, 345, 334, 366, 326,
752
318, 346, 346, 324, 329, 353, 353, 352, 342, 342,
753
333, 358, 354, 327, 360, 380, 359, 332, 336, 334,
754
352, 359, 358, 364, 358, 371, 365, 381, 352, 372,
755
373, 373, 337, 365, 383, 372, 364, 366, 371, 377,
756
377, 345, 354, 378, 384, 380, 387, 378, 364, 386,
757
390, 391, 393, 393, 394, 396, 397, 360, 399, 402,
758
403, 417, 400, 405, 405, 406, 408, 412, 383, 381,
759
409, 409, 411, 414, 415, 384, 418, 421, 386, 422,
761
422, 424, 427, 514, 428, 396, 387, 391, 394, 400,
762
429, 513, 390, 397, 408, 417, 406, 512, 402, 511,
763
412, 399, 403, 411, 510, 415, 414, 509, 508, 507,
764
506, 505, 424, 504, 421, 428, 503, 502, 418, 429,
765
501, 500, 499, 498, 497, 496, 495, 427, 494, 493,
766
492, 491, 490, 489, 488, 487, 486, 485, 484, 483,
767
482, 481, 480, 479, 478, 477, 474, 473, 472, 471,
768
470, 469, 468, 467, 466, 465, 464, 463, 462, 461,
769
460, 459, 458, 457, 456, 455, 454, 453, 452, 451,
770
450, 449, 448, 447, 446, 445, 444, 443, 442, 441,
772
440, 439, 438, 437, 436, 435, 434, 433, 432, 431,
773
430, 425, 423, 419, 416, 413, 410, 407, 404, 401,
774
398, 395, 392, 389, 388, 385, 382, 379, 375, 374,
775
370, 368, 367, 363, 362, 361, 357, 356, 355, 351,
776
349, 348, 347, 343, 341, 340, 339, 338, 335, 331,
777
330, 325, 323, 322, 317, 315, 314, 307, 304, 303,
778
302, 299, 297, 293, 291, 290, 289, 287, 286, 282,
779
279, 278, 277, 276, 267, 265, 262, 261, 252, 251,
780
248, 245, 236, 234, 231, 229, 221, 219, 203, 202,
781
199, 184, 182, 148, 132, 117, 101, 63, 61, 58,
783
55, 44, 41, 40, 38, 37, 34, 31, 22, 19,
784
16, 15, 13, 3, 476, 476, 476, 476, 476, 476,
785
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
786
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
787
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
788
476, 476, 476, 476, 476, 476, 476, 476, 476, 476,
792
static yy_state_type yy_last_accepting_state;
793
static char *yy_last_accepting_cpos;
795
extern int yy_flex_debug;
796
int yy_flex_debug = 0;
798
/* The intent behind this definition is that it'll catch
799
* any uses of REJECT which flex missed.
801
#define REJECT reject_used_but_not_detected
802
#define yymore() yymore_used_but_not_detected
803
#define YY_MORE_ADJ 0
804
#define YY_RESTORE_YY_MORE_OFFSET
808
/* Time-stamp: "99/06/29 14:48:25 bauer" */
810
/* Filter for Windows NT 4.0 postscript printer driver. Enables
811
* the use of psnup from Angus Duggan's psutils package
812
* ( http://www.dcs.ed.ac.uk/home/ajcd/psutils/ )
813
* Copyright: GNU General Public License (GPL)
815
* Holger Bauer 1998, 1999 bauer@itsm.uni-stuttgart.de
816
* Michael Rath 1998, 1999 rath@itsm.uni-stuttgart.de
817
* Akim Demaille 1999 demaille@inf.enst.fr
819
* Release Date: 1999/02/04
824
* cc -O -o fixnt lex.yy.c
827
* csh-prompt> cat BAD_NT_Postscript_FILE.ps | fixnt | psnup -4 | gs -
829
* csh-prompt> cat BAD_NT_Postscript_FILE.ps | fixnt | psnup -4 >GOOD.ps
831
* Windows NT 3.5 users may be happy with:
832
* csh-prompt> cat BAD_NT_Postscript_FILE.ps | \
833
* sed 's/NTPSOct94/NTPSOct95/g' | fixnt | psnup -4 >GOOD.ps
836
* - check for NTPSOct94 (in the meantime use the sed command above)
839
* BUG-Reports: to Authors (above) (please, no 20MB postscript files !!!!!!)
840
* Patches (welcome) to code maintainer: bauer@itsm.uni-stuttgart.de
848
# if defined STDC_HEADERS || defined _LIBC || defined HAVE_STDLIB_H
851
# if HAVE_SYS_TYPES_H
852
# include <sys/types.h>
857
#else /* !HAVE_CONFIG_H */
861
# include <process.h>
863
# include <winbase.h>
867
# include <sys/types.h>
869
#endif /* !HAVE_CONFIG_H */
871
/* Support of prototyping when possible */
874
# define PARAMS(protos) protos
875
# else /* no PROTOTYPES */
876
# define PARAMS(protos) ()
877
# endif /* no PROTOTYPES */
880
/* Do not allow redefinition of malloc and realloc. */
889
void reassemble PARAMS ((FILE*,FILE*,FILE*,char*,char*,char*));
890
static int first_time = 1;
899
char adobefname[255];
902
char tmpdir[_MAX_PATH];
916
#ifndef YY_NO_UNISTD_H
917
/* Special case for "unistd.h", since it is non-ANSI. We include it way
918
* down here because we want the user's section 1 to have been scanned first.
919
* The user has a chance to override it with an option.
924
#ifndef YY_EXTRA_TYPE
925
#define YY_EXTRA_TYPE void *
928
static int yy_init_globals (void );
930
/* Macros after this point can all be overridden by user definitions in
934
#ifndef YY_SKIP_YYWRAP
936
extern "C" int yywrap (void );
938
extern int yywrap (void );
942
static void yyunput (int c,char *buf_ptr );
945
static void yy_flex_strncpy (char *,yyconst char *,int );
948
#ifdef YY_NEED_STRLEN
949
static int yy_flex_strlen (yyconst char * );
955
static int yyinput (void );
957
static int input (void );
962
/* Amount of stuff to slurp up with each read. */
963
#ifndef YY_READ_BUF_SIZE
964
#define YY_READ_BUF_SIZE 8192
967
/* Copy whatever the last rule matched to the standard output. */
969
/* This used to be an fputs(), but since the string might contain NUL's,
970
* we now use fwrite().
972
#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
975
/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
976
* is returned in "result".
979
#define YY_INPUT(buf,result,max_size) \
980
if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
984
for ( n = 0; n < max_size && \
985
(c = getc( yyin )) != EOF && c != '\n'; ++n ) \
988
buf[n++] = (char) c; \
989
if ( c == EOF && ferror( yyin ) ) \
990
YY_FATAL_ERROR( "input in flex scanner failed" ); \
996
while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
998
if( errno != EINTR) \
1000
YY_FATAL_ERROR( "input in flex scanner failed" ); \
1011
/* No semi-colon after return; correct usage is to write "yyterminate();" -
1012
* we don't want an extra ';' after the "return" because that will cause
1013
* some compilers to complain about unreachable statements.
1016
#define yyterminate() return YY_NULL
1019
/* Number of entries by which start-condition stack grows. */
1020
#ifndef YY_START_STACK_INCR
1021
#define YY_START_STACK_INCR 25
1024
/* Report a fatal error. */
1025
#ifndef YY_FATAL_ERROR
1026
#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
1029
/* end tables serialization structures and prototypes */
1031
/* Default declaration of generated scanner - a define so the user can
1032
* easily add parameters.
1035
#define YY_DECL_IS_OURS 1
1037
extern int yylex (void);
1039
#define YY_DECL int yylex (void)
1040
#endif /* !YY_DECL */
1042
/* Code executed at the beginning of each rule, after yytext and yyleng
1045
#ifndef YY_USER_ACTION
1046
#define YY_USER_ACTION
1049
/* Code executed at the end of each rule. */
1051
#define YY_BREAK break;
1054
#define YY_RULE_SETUP \
1056
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = \
1057
(yytext[yyleng - 1] == '\n'); \
1060
/** The main scanner function which does all the work.
1064
register yy_state_type yy_current_state;
1065
register char *yy_cp, *yy_bp;
1066
register int yy_act;
1078
#line 1079 "fixnt.c"
1089
(yy_start) = 1; /* first start state */
1097
if ( ! YY_CURRENT_BUFFER ) {
1098
yyensure_buffer_stack ();
1099
YY_CURRENT_BUFFER_LVALUE =
1100
yy_create_buffer(yyin,YY_BUF_SIZE );
1103
yy_load_buffer_state( );
1106
while ( 1 ) /* loops until end-of-file is reached */
1108
yy_cp = (yy_c_buf_p);
1110
/* Support of yytext. */
1111
*yy_cp = (yy_hold_char);
1113
/* yy_bp points to the position in yy_ch_buf of the start of
1118
yy_current_state = (yy_start);
1119
yy_current_state += YY_AT_BOL();
1123
register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
1124
if ( yy_accept[yy_current_state] )
1126
(yy_last_accepting_state) = yy_current_state;
1127
(yy_last_accepting_cpos) = yy_cp;
1129
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1131
yy_current_state = (int) yy_def[yy_current_state];
1132
if ( yy_current_state >= 477 )
1133
yy_c = yy_meta[(unsigned int) yy_c];
1135
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1138
while ( yy_base[yy_current_state] != 815 );
1141
yy_act = yy_accept[yy_current_state];
1143
{ /* have to back up */
1144
yy_cp = (yy_last_accepting_cpos);
1145
yy_current_state = (yy_last_accepting_state);
1146
yy_act = yy_accept[yy_current_state];
1149
YY_DO_BEFORE_ACTION;
1151
do_action: /* This label is used only to access EOF actions. */
1154
{ /* beginning of action switch */
1155
case 0: /* must back up */
1156
/* undo the effects of YY_DO_BEFORE_ACTION */
1157
*yy_cp = (yy_hold_char);
1158
yy_cp = (yy_last_accepting_cpos);
1159
yy_current_state = (yy_last_accepting_state);
1160
goto yy_find_action;
1163
/* rule 1 can match eol */
1166
{ /* regular Postscript starts here ... */
1172
/* rule 2 can match eol */
1175
{ /* nothing to do */
1179
/* rule 3 can match eol */
1182
{ /* Corel Draw modus recognized */
1188
/* rule 4 can match eol */
1191
{ /* suppress EndSetup */
1192
fprintf(yyout,"NTPSOct95 begin\n");
1197
/* rule 5 can match eol */
1200
{ /* read up to first page and just output everyting */
1201
sprintf(bodyfname, "%s/fixnt_Body_%d", tmpdir, pid);
1202
body = fopen(bodyfname,"w+");
1203
fprintf(body,"%s",yytext);
1208
/* rule 6 can match eol */
1212
fprintf(yyout,"%s",yytext);
1216
/* rule 7 can match eol */
1220
sprintf(adobefname, "%s/fixnt_Adobe_%d", tmpdir, pid);
1221
adobe = fopen(adobefname,"w+");
1222
fprintf(adobe,"%s",yytext);
1227
/* rule 8 can match eol */
1230
{ /* End of Adobe definition stuff */
1231
fprintf(adobe,"%s",yytext);
1236
/* rule 9 can match eol */
1239
{ /* print just everything ... */
1240
fprintf(adobe,"%s",yytext);
1244
/* rule 10 can match eol */
1248
/* remove showpage definition of CorelDraw defintions */
1250
fprintf(body," @gs @gr\n"); /* Corel draw defines spg as showpage */
1252
fprintf(body,"%s",yytext); /* Somebody else defined spg, leave it in */
1257
/* rule 11 can match eol */
1261
/* font definitions from here on */
1262
sprintf(fontfname, "%s/fixnt_Font_%d", tmpdir, pid);
1263
font = fopen(fontfname,"w+");
1264
fprintf(font,"%s",yytext);
1269
/* rule 12 can match eol */
1272
{ /* Font definitions go to FILE* font */
1273
fprintf(font,"%s",yytext);
1278
/* rule 13 can match eol */
1281
{ /* End of Font Definition */
1282
fprintf(font,"%s",yytext);
1287
/* rule 14 can match eol */
1291
/* NT 3.5 Postscript Files have different FontDefinitions */
1292
fprintf(font,"%s",yytext);
1297
/* rule 15 can match eol */
1301
/* NT 3.5 Postscript Files have different FontDefinitions */
1302
fprintf(font,"%s",yytext);
1307
/* rule 16 can match eol */
1310
{ /* goes all to FILE *font ... */
1311
fprintf(font,"%s",yytext);
1315
/* rule 17 can match eol */
1323
/* rule 18 can match eol */
1327
fprintf(body,"%%%%Trailer\nAdobe_WinNT_Driver_Gfx dup /terminate get exec\nPageSV restore\nFontSV restore\n");
1331
/* rule 19 can match eol */
1335
/* switch FontSV/PageSV */
1336
fprintf(body,"PageSV restore\nFontSV restore\n");
1340
/* rule 20 can match eol */
1344
/* put PageSV after Trailer */
1345
fprintf(body,"%%%%Trailer\nPageSV restore\n");
1349
/* rule 21 can match eol */
1353
/* put PageSV/FontSV after Trailer */
1354
fprintf(body,"%%%%Trailer\nPageSV restore\nFontSV restore\n");
1358
/* rule 22 can match eol */
1362
/* do not allow any PageSV's to appear within the actual body */
1366
/* rule 23 can match eol */
1370
/* What to do at the end of the file (either recognized by %%EOF or
1372
fprintf(body,"%s",yytext);
1376
case YY_STATE_EOF(BODY):
1379
/* This section is obsolete, could be removed ..., assume there is no
1380
string <<EOF>> in a Postscript file ... */
1382
/* Only flex knows about the <<EOF>> symbol therefore put the
1383
reassembling process into the main program. Plain lex does return 0
1384
for regular end of file marks. */
1389
/* rule 24 can match eol */
1392
{ /* put pages in FILE *body */
1393
fprintf(body,"%s",yytext);
1401
#line 1402 "fixnt.c"
1402
case YY_STATE_EOF(INITIAL):
1403
case YY_STATE_EOF(DUMMY):
1404
case YY_STATE_EOF(NORMAL):
1405
case YY_STATE_EOF(ADOBE):
1406
case YY_STATE_EOF(FONT):
1409
case YY_END_OF_BUFFER:
1411
/* Amount of text matched not including the EOB char. */
1412
int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;
1414
/* Undo the effects of YY_DO_BEFORE_ACTION. */
1415
*yy_cp = (yy_hold_char);
1416
YY_RESTORE_YY_MORE_OFFSET
1418
if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
1420
/* We're scanning a new file or input source. It's
1421
* possible that this happened because the user
1422
* just pointed yyin at a new source and called
1423
* yylex(). If so, then we have to assure
1424
* consistency between YY_CURRENT_BUFFER and our
1425
* globals. Here is the right place to do so, because
1426
* this is the first action (other than possibly a
1427
* back-up) that will match for the new input source.
1429
(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
1430
YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
1431
YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
1434
/* Note that here we test for yy_c_buf_p "<=" to the position
1435
* of the first EOB in the buffer, since yy_c_buf_p will
1436
* already have been incremented past the NUL character
1437
* (since all states make transitions on EOB to the
1438
* end-of-buffer state). Contrast this with the test
1441
if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
1442
{ /* This was really a NUL. */
1443
yy_state_type yy_next_state;
1445
(yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text;
1447
yy_current_state = yy_get_previous_state( );
1449
/* Okay, we're now positioned to make the NUL
1450
* transition. We couldn't have
1451
* yy_get_previous_state() go ahead and do it
1452
* for us because it doesn't know how to deal
1453
* with the possibility of jamming (and we don't
1454
* want to build jamming into it because then it
1455
* will run more slowly).
1458
yy_next_state = yy_try_NUL_trans( yy_current_state );
1460
yy_bp = (yytext_ptr) + YY_MORE_ADJ;
1462
if ( yy_next_state )
1464
/* Consume the NUL. */
1465
yy_cp = ++(yy_c_buf_p);
1466
yy_current_state = yy_next_state;
1472
yy_cp = (yy_c_buf_p);
1473
goto yy_find_action;
1477
else switch ( yy_get_next_buffer( ) )
1479
case EOB_ACT_END_OF_FILE:
1481
(yy_did_buffer_switch_on_eof) = 0;
1485
/* Note: because we've taken care in
1486
* yy_get_next_buffer() to have set up
1487
* yytext, we can now set up
1488
* yy_c_buf_p so that if some total
1489
* hoser (like flex itself) wants to
1490
* call the scanner after we return the
1491
* YY_NULL, it'll still work - another
1492
* YY_NULL will get returned.
1494
(yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ;
1496
yy_act = YY_STATE_EOF(YY_START);
1502
if ( ! (yy_did_buffer_switch_on_eof) )
1508
case EOB_ACT_CONTINUE_SCAN:
1510
(yytext_ptr) + yy_amount_of_matched_text;
1512
yy_current_state = yy_get_previous_state( );
1514
yy_cp = (yy_c_buf_p);
1515
yy_bp = (yytext_ptr) + YY_MORE_ADJ;
1518
case EOB_ACT_LAST_MATCH:
1520
&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)];
1522
yy_current_state = yy_get_previous_state( );
1524
yy_cp = (yy_c_buf_p);
1525
yy_bp = (yytext_ptr) + YY_MORE_ADJ;
1526
goto yy_find_action;
1533
"fatal flex scanner internal error--no action found" );
1534
} /* end of action switch */
1535
} /* end of scanning one token */
1536
} /* end of yylex */
1538
/* yy_get_next_buffer - try to read in a new buffer
1540
* Returns a code representing an action:
1541
* EOB_ACT_LAST_MATCH -
1542
* EOB_ACT_CONTINUE_SCAN - continue scanning from current position
1543
* EOB_ACT_END_OF_FILE - end of file
1545
static int yy_get_next_buffer (void)
1547
register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
1548
register char *source = (yytext_ptr);
1549
register int number_to_move, i;
1552
if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )
1554
"fatal flex scanner internal error--end of buffer missed" );
1556
if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
1557
{ /* Don't try to fill the buffer, so this is an EOF. */
1558
if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )
1560
/* We matched a single character, the EOB, so
1561
* treat this as a final EOF.
1563
return EOB_ACT_END_OF_FILE;
1568
/* We matched some text prior to the EOB, first
1571
return EOB_ACT_LAST_MATCH;
1575
/* Try to read more data. */
1577
/* First move last chars to start of buffer. */
1578
number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1;
1580
for ( i = 0; i < number_to_move; ++i )
1581
*(dest++) = *(source++);
1583
if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
1584
/* don't do the read, it's not guaranteed to return an EOF,
1587
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;
1592
YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
1594
while ( num_to_read <= 0 )
1595
{ /* Not enough room in the buffer - grow it. */
1597
/* just a shorter name for the current buffer */
1598
YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
1600
int yy_c_buf_p_offset =
1601
(int) ((yy_c_buf_p) - b->yy_ch_buf);
1603
if ( b->yy_is_our_buffer )
1605
int new_size = b->yy_buf_size * 2;
1607
if ( new_size <= 0 )
1608
b->yy_buf_size += b->yy_buf_size / 8;
1610
b->yy_buf_size *= 2;
1612
b->yy_ch_buf = (char *)
1613
/* Include room in for 2 EOB chars. */
1614
yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 );
1617
/* Can't grow it, we don't own it. */
1620
if ( ! b->yy_ch_buf )
1622
"fatal error - scanner input buffer overflow" );
1624
(yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset];
1626
num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
1631
if ( num_to_read > YY_READ_BUF_SIZE )
1632
num_to_read = YY_READ_BUF_SIZE;
1634
/* Read in more data. */
1635
YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
1636
(yy_n_chars), (size_t) num_to_read );
1638
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
1641
if ( (yy_n_chars) == 0 )
1643
if ( number_to_move == YY_MORE_ADJ )
1645
ret_val = EOB_ACT_END_OF_FILE;
1651
ret_val = EOB_ACT_LAST_MATCH;
1652
YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
1653
YY_BUFFER_EOF_PENDING;
1658
ret_val = EOB_ACT_CONTINUE_SCAN;
1660
(yy_n_chars) += number_to_move;
1661
YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR;
1662
YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR;
1664
(yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
1669
/* yy_get_previous_state - get the state just before the EOB char was reached */
1671
static yy_state_type yy_get_previous_state (void)
1673
register yy_state_type yy_current_state;
1674
register char *yy_cp;
1676
yy_current_state = (yy_start);
1677
yy_current_state += YY_AT_BOL();
1679
for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
1681
register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
1682
if ( yy_accept[yy_current_state] )
1684
(yy_last_accepting_state) = yy_current_state;
1685
(yy_last_accepting_cpos) = yy_cp;
1687
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1689
yy_current_state = (int) yy_def[yy_current_state];
1690
if ( yy_current_state >= 477 )
1691
yy_c = yy_meta[(unsigned int) yy_c];
1693
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1696
return yy_current_state;
1699
/* yy_try_NUL_trans - try to make a transition on the NUL character
1702
* next_state = yy_try_NUL_trans( current_state );
1704
static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state )
1706
register int yy_is_jam;
1707
register char *yy_cp = (yy_c_buf_p);
1709
register YY_CHAR yy_c = 1;
1710
if ( yy_accept[yy_current_state] )
1712
(yy_last_accepting_state) = yy_current_state;
1713
(yy_last_accepting_cpos) = yy_cp;
1715
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1717
yy_current_state = (int) yy_def[yy_current_state];
1718
if ( yy_current_state >= 477 )
1719
yy_c = yy_meta[(unsigned int) yy_c];
1721
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1722
yy_is_jam = (yy_current_state == 476);
1724
return yy_is_jam ? 0 : yy_current_state;
1727
static void yyunput (int c, register char * yy_bp )
1729
register char *yy_cp;
1731
yy_cp = (yy_c_buf_p);
1733
/* undo effects of setting up yytext */
1734
*yy_cp = (yy_hold_char);
1736
if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
1737
{ /* need to shift things up to make room */
1738
/* +2 for EOB chars. */
1739
register int number_to_move = (yy_n_chars) + 2;
1740
register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
1741
YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
1742
register char *source =
1743
&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
1745
while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
1746
*--dest = *--source;
1748
yy_cp += (int) (dest - source);
1749
yy_bp += (int) (dest - source);
1750
YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
1751
(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
1753
if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
1754
YY_FATAL_ERROR( "flex scanner push-back overflow" );
1757
*--yy_cp = (char) c;
1759
(yytext_ptr) = yy_bp;
1760
(yy_hold_char) = *yy_cp;
1761
(yy_c_buf_p) = yy_cp;
1766
static int yyinput (void)
1768
static int input (void)
1774
*(yy_c_buf_p) = (yy_hold_char);
1776
if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR )
1778
/* yy_c_buf_p now points to the character we want to return.
1779
* If this occurs *before* the EOB characters, then it's a
1780
* valid NUL; if not, then we've hit the end of the buffer.
1782
if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
1783
/* This was really a NUL. */
1784
*(yy_c_buf_p) = '\0';
1787
{ /* need more input */
1788
int offset = (yy_c_buf_p) - (yytext_ptr);
1791
switch ( yy_get_next_buffer( ) )
1793
case EOB_ACT_LAST_MATCH:
1794
/* This happens because yy_g_n_b()
1795
* sees that we've accumulated a
1796
* token and flags that we need to
1797
* try matching the token before
1798
* proceeding. But for input(),
1799
* there's no matching to consider.
1800
* So convert the EOB_ACT_LAST_MATCH
1801
* to EOB_ACT_END_OF_FILE.
1804
/* Reset buffer status. */
1809
case EOB_ACT_END_OF_FILE:
1814
if ( ! (yy_did_buffer_switch_on_eof) )
1823
case EOB_ACT_CONTINUE_SCAN:
1824
(yy_c_buf_p) = (yytext_ptr) + offset;
1830
c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */
1831
*(yy_c_buf_p) = '\0'; /* preserve yytext */
1832
(yy_hold_char) = *++(yy_c_buf_p);
1834
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (c == '\n');
1838
#endif /* ifndef YY_NO_INPUT */
1840
/** Immediately switch to a different input stream.
1841
* @param input_file A readable stream.
1843
* @note This function does not reset the start condition to @c INITIAL .
1845
void yyrestart (FILE * input_file )
1848
if ( ! YY_CURRENT_BUFFER ){
1849
yyensure_buffer_stack ();
1850
YY_CURRENT_BUFFER_LVALUE =
1851
yy_create_buffer(yyin,YY_BUF_SIZE );
1854
yy_init_buffer(YY_CURRENT_BUFFER,input_file );
1855
yy_load_buffer_state( );
1858
/** Switch to a different input buffer.
1859
* @param new_buffer The new input buffer.
1862
void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer )
1865
/* TODO. We should be able to replace this entire function body
1867
* yypop_buffer_state();
1868
* yypush_buffer_state(new_buffer);
1870
yyensure_buffer_stack ();
1871
if ( YY_CURRENT_BUFFER == new_buffer )
1874
if ( YY_CURRENT_BUFFER )
1876
/* Flush out information for old buffer. */
1877
*(yy_c_buf_p) = (yy_hold_char);
1878
YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
1879
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
1882
YY_CURRENT_BUFFER_LVALUE = new_buffer;
1883
yy_load_buffer_state( );
1885
/* We don't actually know whether we did this switch during
1886
* EOF (yywrap()) processing, but the only time this flag
1887
* is looked at is after yywrap() is called, so it's safe
1888
* to go ahead and always set it.
1890
(yy_did_buffer_switch_on_eof) = 1;
1893
static void yy_load_buffer_state (void)
1895
(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
1896
(yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
1897
yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
1898
(yy_hold_char) = *(yy_c_buf_p);
1901
/** Allocate and initialize an input buffer state.
1902
* @param file A readable stream.
1903
* @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
1905
* @return the allocated buffer state.
1907
YY_BUFFER_STATE yy_create_buffer (FILE * file, int size )
1911
b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) );
1913
YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
1915
b->yy_buf_size = size;
1917
/* yy_ch_buf has to be 2 characters longer than the size given because
1918
* we need to put in 2 end-of-buffer characters.
1920
b->yy_ch_buf = (char *) yyalloc(b->yy_buf_size + 2 );
1921
if ( ! b->yy_ch_buf )
1922
YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
1924
b->yy_is_our_buffer = 1;
1926
yy_init_buffer(b,file );
1931
/** Destroy the buffer.
1932
* @param b a buffer created with yy_create_buffer()
1935
void yy_delete_buffer (YY_BUFFER_STATE b )
1941
if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
1942
YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
1944
if ( b->yy_is_our_buffer )
1945
yyfree((void *) b->yy_ch_buf );
1947
yyfree((void *) b );
1951
extern int isatty (int );
1952
#endif /* __cplusplus */
1954
/* Initializes or reinitializes a buffer.
1955
* This function is sometimes called more than once on the same buffer,
1956
* such as during a yyrestart() or at EOF.
1958
static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file )
1963
yy_flush_buffer(b );
1965
b->yy_input_file = file;
1966
b->yy_fill_buffer = 1;
1968
/* If b is the current buffer, then yy_init_buffer was _probably_
1969
* called from yyrestart() or through yy_get_next_buffer.
1970
* In that case, we don't want to reset the lineno or column.
1972
if (b != YY_CURRENT_BUFFER){
1973
b->yy_bs_lineno = 1;
1974
b->yy_bs_column = 0;
1977
b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
1982
/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
1983
* @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
1986
void yy_flush_buffer (YY_BUFFER_STATE b )
1993
/* We always need two end-of-buffer characters. The first causes
1994
* a transition to the end-of-buffer state. The second causes
1995
* a jam in that state.
1997
b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
1998
b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
2000
b->yy_buf_pos = &b->yy_ch_buf[0];
2003
b->yy_buffer_status = YY_BUFFER_NEW;
2005
if ( b == YY_CURRENT_BUFFER )
2006
yy_load_buffer_state( );
2009
/** Pushes the new state onto the stack. The new state becomes
2010
* the current state. This function will allocate the stack
2012
* @param new_buffer The new state.
2015
void yypush_buffer_state (YY_BUFFER_STATE new_buffer )
2017
if (new_buffer == NULL)
2020
yyensure_buffer_stack();
2022
/* This block is copied from yy_switch_to_buffer. */
2023
if ( YY_CURRENT_BUFFER )
2025
/* Flush out information for old buffer. */
2026
*(yy_c_buf_p) = (yy_hold_char);
2027
YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
2028
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
2031
/* Only push if top exists. Otherwise, replace top. */
2032
if (YY_CURRENT_BUFFER)
2033
(yy_buffer_stack_top)++;
2034
YY_CURRENT_BUFFER_LVALUE = new_buffer;
2036
/* copied from yy_switch_to_buffer. */
2037
yy_load_buffer_state( );
2038
(yy_did_buffer_switch_on_eof) = 1;
2041
/** Removes and deletes the top of the stack, if present.
2042
* The next element becomes the new top.
2045
void yypop_buffer_state (void)
2047
if (!YY_CURRENT_BUFFER)
2050
yy_delete_buffer(YY_CURRENT_BUFFER );
2051
YY_CURRENT_BUFFER_LVALUE = NULL;
2052
if ((yy_buffer_stack_top) > 0)
2053
--(yy_buffer_stack_top);
2055
if (YY_CURRENT_BUFFER) {
2056
yy_load_buffer_state( );
2057
(yy_did_buffer_switch_on_eof) = 1;
2061
/* Allocates the stack if it does not exist.
2062
* Guarantees space for at least one push.
2064
static void yyensure_buffer_stack (void)
2068
if (!(yy_buffer_stack)) {
2070
/* First allocation is just for 2 elements, since we don't know if this
2071
* scanner will even need a stack. We use 2 instead of 1 to avoid an
2072
* immediate realloc on the next call.
2075
(yy_buffer_stack) = (struct yy_buffer_state**)yyalloc
2076
(num_to_alloc * sizeof(struct yy_buffer_state*)
2079
memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
2081
(yy_buffer_stack_max) = num_to_alloc;
2082
(yy_buffer_stack_top) = 0;
2086
if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){
2088
/* Increase the buffer to prepare for a possible push. */
2089
int grow_size = 8 /* arbitrary grow size */;
2091
num_to_alloc = (yy_buffer_stack_max) + grow_size;
2092
(yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc
2094
num_to_alloc * sizeof(struct yy_buffer_state*)
2097
/* zero only the new slots.*/
2098
memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));
2099
(yy_buffer_stack_max) = num_to_alloc;
2103
/** Setup the input buffer state to scan directly from a user-specified character buffer.
2104
* @param base the character buffer
2105
* @param size the size in bytes of the character buffer
2107
* @return the newly allocated buffer state object.
2109
YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size )
2114
base[size-2] != YY_END_OF_BUFFER_CHAR ||
2115
base[size-1] != YY_END_OF_BUFFER_CHAR )
2116
/* They forgot to leave room for the EOB's. */
2119
b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) );
2121
YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
2123
b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
2124
b->yy_buf_pos = b->yy_ch_buf = base;
2125
b->yy_is_our_buffer = 0;
2126
b->yy_input_file = 0;
2127
b->yy_n_chars = b->yy_buf_size;
2128
b->yy_is_interactive = 0;
2130
b->yy_fill_buffer = 0;
2131
b->yy_buffer_status = YY_BUFFER_NEW;
2133
yy_switch_to_buffer(b );
2138
/** Setup the input buffer state to scan a string. The next call to yylex() will
2139
* scan from a @e copy of @a str.
2140
* @param yystr a NUL-terminated string to scan
2142
* @return the newly allocated buffer state object.
2143
* @note If you want to scan bytes that may contain NUL values, then use
2144
* yy_scan_bytes() instead.
2146
YY_BUFFER_STATE yy_scan_string (yyconst char * yystr )
2149
return yy_scan_bytes(yystr,strlen(yystr) );
2152
/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
2153
* scan from a @e copy of @a bytes.
2154
* @param bytes the byte buffer to scan
2155
* @param len the number of bytes in the buffer pointed to by @a bytes.
2157
* @return the newly allocated buffer state object.
2159
YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, int _yybytes_len )
2166
/* Get memory for full buffer, including space for trailing EOB's. */
2167
n = _yybytes_len + 2;
2168
buf = (char *) yyalloc(n );
2170
YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
2172
for ( i = 0; i < _yybytes_len; ++i )
2173
buf[i] = yybytes[i];
2175
buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
2177
b = yy_scan_buffer(buf,n );
2179
YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
2181
/* It's okay to grow etc. this buffer, and we should throw it
2182
* away when we're done.
2184
b->yy_is_our_buffer = 1;
2189
#ifndef YY_EXIT_FAILURE
2190
#define YY_EXIT_FAILURE 2
2193
static void yy_fatal_error (yyconst char* msg )
2195
(void) fprintf( stderr, "%s\n", msg );
2196
exit( YY_EXIT_FAILURE );
2199
/* Redefine yyless() so it works in section 3 code. */
2205
/* Undo effects of setting up yytext. */ \
2206
int yyless_macro_arg = (n); \
2207
YY_LESS_LINENO(yyless_macro_arg);\
2208
yytext[yyleng] = (yy_hold_char); \
2209
(yy_c_buf_p) = yytext + yyless_macro_arg; \
2210
(yy_hold_char) = *(yy_c_buf_p); \
2211
*(yy_c_buf_p) = '\0'; \
2212
yyleng = yyless_macro_arg; \
2216
/* Accessor methods (get/set functions) to struct members. */
2218
/** Get the current line number.
2221
int yyget_lineno (void)
2227
/** Get the input stream.
2230
FILE *yyget_in (void)
2235
/** Get the output stream.
2238
FILE *yyget_out (void)
2243
/** Get the length of the current token.
2246
int yyget_leng (void)
2251
/** Get the current token.
2255
char *yyget_text (void)
2260
/** Set the current line number.
2261
* @param line_number
2264
void yyset_lineno (int line_number )
2267
yylineno = line_number;
2270
/** Set the input stream. This does not discard the current
2272
* @param in_str A readable stream.
2274
* @see yy_switch_to_buffer
2276
void yyset_in (FILE * in_str )
2281
void yyset_out (FILE * out_str )
2286
int yyget_debug (void)
2288
return yy_flex_debug;
2291
void yyset_debug (int bdebug )
2293
yy_flex_debug = bdebug ;
2296
static int yy_init_globals (void)
2298
/* Initialization is the same as for the non-reentrant scanner.
2299
* This function is called from yylex_destroy(), so don't allocate here.
2302
(yy_buffer_stack) = 0;
2303
(yy_buffer_stack_top) = 0;
2304
(yy_buffer_stack_max) = 0;
2305
(yy_c_buf_p) = (char *) 0;
2309
/* Defined in main.c */
2318
/* For future reference: Set errno on error, since we are called by
2324
/* yylex_destroy is for both reentrant and non-reentrant scanners. */
2325
int yylex_destroy (void)
2328
/* Pop the buffer stack, destroying each element. */
2329
while(YY_CURRENT_BUFFER){
2330
yy_delete_buffer(YY_CURRENT_BUFFER );
2331
YY_CURRENT_BUFFER_LVALUE = NULL;
2332
yypop_buffer_state();
2335
/* Destroy the stack itself. */
2336
yyfree((yy_buffer_stack) );
2337
(yy_buffer_stack) = NULL;
2339
/* Reset the globals. This is important in a non-reentrant scanner so the next time
2340
* yylex() is called, initialization will occur. */
2347
* Internal utility routines.
2351
static void yy_flex_strncpy (char* s1, yyconst char * s2, int n )
2354
for ( i = 0; i < n; ++i )
2359
#ifdef YY_NEED_STRLEN
2360
static int yy_flex_strlen (yyconst char * s )
2363
for ( n = 0; s[n]; ++n )
2370
void *yyalloc (yy_size_t size )
2372
return (void *) malloc( size );
2375
void *yyrealloc (void * ptr, yy_size_t size )
2377
/* The cast to (char *) in the following accommodates both
2378
* implementations that use char* generic pointers, and those
2379
* that use void* generic pointers. It works with the latter
2380
* because both ANSI C and C++ allow castless assignment from
2381
* any pointer type to void*, and deal with argument conversions
2382
* as though doing an assignment.
2384
return (void *) realloc( (char *) ptr, size );
2387
void yyfree (void * ptr )
2389
free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
2392
#define YYTABLES_NAME "yytables"
2407
GetTempPath(_MAX_PATH, tmpdir);
2409
if (!(tmpdir = getenv("TMPDIR")))
2412
pid = (int) getpid ();
2414
/* at the end always reassemble the file and clean up ... */
2415
reassemble(adobe, font, body, adobefname, fontfname, bodyfname);
2421
reassemble (adobe, font, body, adobefname, fontfname, bodyfname)
2431
/* put everything in right order ... */
2432
if( adobe != NULL ){
2434
while( (xx = getc( adobe )) != EOF ){
2443
while( (xx = getc( font )) != EOF ){
2450
if( ifendsetup == 1){
2451
fprintf(yyout,"%%%%EndSetup:\n");
2457
fprintf(yyout,"NTPSOct95 /PageSV save put\n");
2458
while( (xx = getc( body )) != EOF ){