Root/
Source at commit 1322 created 12 years 8 months ago. By meklort, Add doxygen to utils folder | |
---|---|
1 | ␊ |
2 | #line 3 "<stdout>"␊ |
3 | ␊ |
4 | #define YY_INT_ALIGNED short int␊ |
5 | ␊ |
6 | /* A lexical scanner generated by flex */␊ |
7 | ␊ |
8 | #define yy_create_buffer commentcnvYY_create_buffer␊ |
9 | #define yy_delete_buffer commentcnvYY_delete_buffer␊ |
10 | #define yy_flex_debug commentcnvYY_flex_debug␊ |
11 | #define yy_init_buffer commentcnvYY_init_buffer␊ |
12 | #define yy_flush_buffer commentcnvYY_flush_buffer␊ |
13 | #define yy_load_buffer_state commentcnvYY_load_buffer_state␊ |
14 | #define yy_switch_to_buffer commentcnvYY_switch_to_buffer␊ |
15 | #define yyin commentcnvYYin␊ |
16 | #define yyleng commentcnvYYleng␊ |
17 | #define yylex commentcnvYYlex␊ |
18 | #define yylineno commentcnvYYlineno␊ |
19 | #define yyout commentcnvYYout␊ |
20 | #define yyrestart commentcnvYYrestart␊ |
21 | #define yytext commentcnvYYtext␊ |
22 | #define yywrap commentcnvYYwrap␊ |
23 | #define yyalloc commentcnvYYalloc␊ |
24 | #define yyrealloc commentcnvYYrealloc␊ |
25 | #define yyfree commentcnvYYfree␊ |
26 | ␊ |
27 | #define FLEX_SCANNER␊ |
28 | #define YY_FLEX_MAJOR_VERSION 2␊ |
29 | #define YY_FLEX_MINOR_VERSION 5␊ |
30 | #define YY_FLEX_SUBMINOR_VERSION 35␊ |
31 | #if YY_FLEX_SUBMINOR_VERSION > 0␊ |
32 | #define FLEX_BETA␊ |
33 | #endif␊ |
34 | ␊ |
35 | /* First, we deal with platform-specific or compiler-specific issues. */␊ |
36 | ␊ |
37 | /* begin standard C headers. */␊ |
38 | #include <stdio.h>␊ |
39 | #include <string.h>␊ |
40 | #include <errno.h>␊ |
41 | #include <stdlib.h>␊ |
42 | ␊ |
43 | /* end standard C headers. */␊ |
44 | ␊ |
45 | /* flex integer type definitions */␊ |
46 | ␊ |
47 | #ifndef FLEXINT_H␊ |
48 | #define FLEXINT_H␊ |
49 | ␊ |
50 | /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */␊ |
51 | ␊ |
52 | #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L␊ |
53 | ␊ |
54 | /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,␊ |
55 | * if you want the limit (max/min) macros for int types. ␊ |
56 | */␊ |
57 | #ifndef __STDC_LIMIT_MACROS␊ |
58 | #define __STDC_LIMIT_MACROS 1␊ |
59 | #endif␊ |
60 | ␊ |
61 | #include <inttypes.h>␊ |
62 | typedef int8_t flex_int8_t;␊ |
63 | typedef uint8_t flex_uint8_t;␊ |
64 | typedef int16_t flex_int16_t;␊ |
65 | typedef uint16_t flex_uint16_t;␊ |
66 | typedef int32_t flex_int32_t;␊ |
67 | typedef uint32_t flex_uint32_t;␊ |
68 | #else␊ |
69 | typedef signed char flex_int8_t;␊ |
70 | typedef short int flex_int16_t;␊ |
71 | typedef int flex_int32_t;␊ |
72 | typedef unsigned char flex_uint8_t; ␊ |
73 | typedef unsigned short int flex_uint16_t;␊ |
74 | typedef unsigned int flex_uint32_t;␊ |
75 | #endif /* ! C99 */␊ |
76 | ␊ |
77 | /* Limits of integral types. */␊ |
78 | #ifndef INT8_MIN␊ |
79 | #define INT8_MIN (-128)␊ |
80 | #endif␊ |
81 | #ifndef INT16_MIN␊ |
82 | #define INT16_MIN (-32767-1)␊ |
83 | #endif␊ |
84 | #ifndef INT32_MIN␊ |
85 | #define INT32_MIN (-2147483647-1)␊ |
86 | #endif␊ |
87 | #ifndef INT8_MAX␊ |
88 | #define INT8_MAX (127)␊ |
89 | #endif␊ |
90 | #ifndef INT16_MAX␊ |
91 | #define INT16_MAX (32767)␊ |
92 | #endif␊ |
93 | #ifndef INT32_MAX␊ |
94 | #define INT32_MAX (2147483647)␊ |
95 | #endif␊ |
96 | #ifndef UINT8_MAX␊ |
97 | #define UINT8_MAX (255U)␊ |
98 | #endif␊ |
99 | #ifndef UINT16_MAX␊ |
100 | #define UINT16_MAX (65535U)␊ |
101 | #endif␊ |
102 | #ifndef UINT32_MAX␊ |
103 | #define UINT32_MAX (4294967295U)␊ |
104 | #endif␊ |
105 | ␊ |
106 | #endif /* ! FLEXINT_H */␊ |
107 | ␊ |
108 | #ifdef __cplusplus␊ |
109 | ␊ |
110 | /* The "const" storage-class-modifier is valid. */␊ |
111 | #define YY_USE_CONST␊ |
112 | ␊ |
113 | #else␉/* ! __cplusplus */␊ |
114 | ␊ |
115 | /* C99 requires __STDC__ to be defined as 1. */␊ |
116 | #if defined (__STDC__)␊ |
117 | ␊ |
118 | #define YY_USE_CONST␊ |
119 | ␊ |
120 | #endif␉/* defined (__STDC__) */␊ |
121 | #endif␉/* ! __cplusplus */␊ |
122 | ␊ |
123 | #ifdef YY_USE_CONST␊ |
124 | #define yyconst const␊ |
125 | #else␊ |
126 | #define yyconst␊ |
127 | #endif␊ |
128 | ␊ |
129 | /* Returned upon end-of-file. */␊ |
130 | #define YY_NULL 0␊ |
131 | ␊ |
132 | /* Promotes a possibly negative, possibly signed char to an unsigned␊ |
133 | * integer for use as an array index. If the signed char is negative,␊ |
134 | * we want to instead treat it as an 8-bit unsigned char, hence the␊ |
135 | * double cast.␊ |
136 | */␊ |
137 | #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)␊ |
138 | ␊ |
139 | /* Enter a start condition. This macro really ought to take a parameter,␊ |
140 | * but we do it the disgusting crufty way forced on us by the ()-less␊ |
141 | * definition of BEGIN.␊ |
142 | */␊ |
143 | #define BEGIN (yy_start) = 1 + 2 *␊ |
144 | ␊ |
145 | /* Translate the current start state into a value that can be later handed␊ |
146 | * to BEGIN to return to the state. The YYSTATE alias is for lex␊ |
147 | * compatibility.␊ |
148 | */␊ |
149 | #define YY_START (((yy_start) - 1) / 2)␊ |
150 | #define YYSTATE YY_START␊ |
151 | ␊ |
152 | /* Action number for EOF rule of a given start state. */␊ |
153 | #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)␊ |
154 | ␊ |
155 | /* Special action meaning "start processing a new file". */␊ |
156 | #define YY_NEW_FILE commentcnvYYrestart(commentcnvYYin )␊ |
157 | ␊ |
158 | #define YY_END_OF_BUFFER_CHAR 0␊ |
159 | ␊ |
160 | /* Size of default input buffer. */␊ |
161 | #ifndef YY_BUF_SIZE␊ |
162 | #define YY_BUF_SIZE 262144␊ |
163 | #endif␊ |
164 | ␊ |
165 | /* The state buf must be large enough to hold one state per character in the main buffer.␊ |
166 | */␊ |
167 | #define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))␊ |
168 | ␊ |
169 | #ifndef YY_TYPEDEF_YY_BUFFER_STATE␊ |
170 | #define YY_TYPEDEF_YY_BUFFER_STATE␊ |
171 | typedef struct yy_buffer_state *YY_BUFFER_STATE;␊ |
172 | #endif␊ |
173 | ␊ |
174 | #ifndef YY_TYPEDEF_YY_SIZE_T␊ |
175 | #define YY_TYPEDEF_YY_SIZE_T␊ |
176 | typedef size_t yy_size_t;␊ |
177 | #endif␊ |
178 | ␊ |
179 | extern yy_size_t commentcnvYYleng;␊ |
180 | ␊ |
181 | extern FILE *commentcnvYYin, *commentcnvYYout;␊ |
182 | ␊ |
183 | #define EOB_ACT_CONTINUE_SCAN 0␊ |
184 | #define EOB_ACT_END_OF_FILE 1␊ |
185 | #define EOB_ACT_LAST_MATCH 2␊ |
186 | ␊ |
187 | #define YY_LESS_LINENO(n)␊ |
188 | ␊ |
189 | /* Return all but the first "n" matched characters back to the input stream. */␊ |
190 | #define yyless(n) \␊ |
191 | ␉do \␊ |
192 | ␉␉{ \␊ |
193 | ␉␉/* Undo effects of setting up commentcnvYYtext. */ \␊ |
194 | int yyless_macro_arg = (n); \␊ |
195 | YY_LESS_LINENO(yyless_macro_arg);\␊ |
196 | ␉␉*yy_cp = (yy_hold_char); \␊ |
197 | ␉␉YY_RESTORE_YY_MORE_OFFSET \␊ |
198 | ␉␉(yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \␊ |
199 | ␉␉YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */ \␊ |
200 | ␉␉} \␊ |
201 | ␉while ( 0 )␊ |
202 | ␊ |
203 | #define unput(c) yyunput( c, (yytext_ptr) )␊ |
204 | ␊ |
205 | #ifndef YY_STRUCT_YY_BUFFER_STATE␊ |
206 | #define YY_STRUCT_YY_BUFFER_STATE␊ |
207 | struct yy_buffer_state␊ |
208 | ␉{␊ |
209 | ␉FILE *yy_input_file;␊ |
210 | ␊ |
211 | ␉char *yy_ch_buf;␉␉/* input buffer */␊ |
212 | ␉char *yy_buf_pos;␉␉/* current position in input buffer */␊ |
213 | ␊ |
214 | ␉/* Size of input buffer in bytes, not including room for EOB␊ |
215 | ␉ * characters.␊ |
216 | ␉ */␊ |
217 | ␉yy_size_t yy_buf_size;␊ |
218 | ␊ |
219 | ␉/* Number of characters read into yy_ch_buf, not including EOB␊ |
220 | ␉ * characters.␊ |
221 | ␉ */␊ |
222 | ␉yy_size_t yy_n_chars;␊ |
223 | ␊ |
224 | ␉/* Whether we "own" the buffer - i.e., we know we created it,␊ |
225 | ␉ * and can realloc() it to grow it, and should free() it to␊ |
226 | ␉ * delete it.␊ |
227 | ␉ */␊ |
228 | ␉int yy_is_our_buffer;␊ |
229 | ␊ |
230 | ␉/* Whether this is an "interactive" input source; if so, and␊ |
231 | ␉ * if we're using stdio for input, then we want to use getc()␊ |
232 | ␉ * instead of fread(), to make sure we stop fetching input after␊ |
233 | ␉ * each newline.␊ |
234 | ␉ */␊ |
235 | ␉int yy_is_interactive;␊ |
236 | ␊ |
237 | ␉/* Whether we're considered to be at the beginning of a line.␊ |
238 | ␉ * If so, '^' rules will be active on the next match, otherwise␊ |
239 | ␉ * not.␊ |
240 | ␉ */␊ |
241 | ␉int yy_at_bol;␊ |
242 | ␊ |
243 | int yy_bs_lineno; /**< The line count. */␊ |
244 | int yy_bs_column; /**< The column count. */␊ |
245 | ␊ |
246 | ␉/* Whether to try to fill the input buffer when we reach the␊ |
247 | ␉ * end of it.␊ |
248 | ␉ */␊ |
249 | ␉int yy_fill_buffer;␊ |
250 | ␊ |
251 | ␉int yy_buffer_status;␊ |
252 | ␊ |
253 | #define YY_BUFFER_NEW 0␊ |
254 | #define YY_BUFFER_NORMAL 1␊ |
255 | ␉/* When an EOF's been seen but there's still some text to process␊ |
256 | ␉ * then we mark the buffer as YY_EOF_PENDING, to indicate that we␊ |
257 | ␉ * shouldn't try reading from the input source any more. We might␊ |
258 | ␉ * still have a bunch of tokens to match, though, because of␊ |
259 | ␉ * possible backing-up.␊ |
260 | ␉ *␊ |
261 | ␉ * When we actually see the EOF, we change the status to "new"␊ |
262 | ␉ * (via commentcnvYYrestart()), so that the user can continue scanning by␊ |
263 | ␉ * just pointing commentcnvYYin at a new input file.␊ |
264 | ␉ */␊ |
265 | #define YY_BUFFER_EOF_PENDING 2␊ |
266 | ␊ |
267 | ␉};␊ |
268 | #endif /* !YY_STRUCT_YY_BUFFER_STATE */␊ |
269 | ␊ |
270 | /* Stack of input buffers. */␊ |
271 | static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */␊ |
272 | static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */␊ |
273 | static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */␊ |
274 | ␊ |
275 | /* We provide macros for accessing buffer states in case in the␊ |
276 | * future we want to put the buffer states in a more general␊ |
277 | * "scanner state".␊ |
278 | *␊ |
279 | * Returns the top of the stack, or NULL.␊ |
280 | */␊ |
281 | #define YY_CURRENT_BUFFER ( (yy_buffer_stack) \␊ |
282 | ? (yy_buffer_stack)[(yy_buffer_stack_top)] \␊ |
283 | : NULL)␊ |
284 | ␊ |
285 | /* Same as previous macro, but useful when we know that the buffer stack is not␊ |
286 | * NULL or when we need an lvalue. For internal use only.␊ |
287 | */␊ |
288 | #define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)]␊ |
289 | ␊ |
290 | /* yy_hold_char holds the character lost when commentcnvYYtext is formed. */␊ |
291 | static char yy_hold_char;␊ |
292 | static yy_size_t yy_n_chars;␉␉/* number of characters read into yy_ch_buf */␊ |
293 | yy_size_t commentcnvYYleng;␊ |
294 | ␊ |
295 | /* Points to current character in buffer. */␊ |
296 | static char *yy_c_buf_p = (char *) 0;␊ |
297 | static int yy_init = 0;␉␉/* whether we need to initialize */␊ |
298 | static int yy_start = 0;␉/* start state number */␊ |
299 | ␊ |
300 | /* Flag which is used to allow commentcnvYYwrap()'s to do buffer switches␊ |
301 | * instead of setting up a fresh commentcnvYYin. A bit of a hack ...␊ |
302 | */␊ |
303 | static int yy_did_buffer_switch_on_eof;␊ |
304 | ␊ |
305 | void commentcnvYYrestart (FILE *input_file );␊ |
306 | void commentcnvYY_switch_to_buffer (YY_BUFFER_STATE new_buffer );␊ |
307 | YY_BUFFER_STATE commentcnvYY_create_buffer (FILE *file,int size );␊ |
308 | void commentcnvYY_delete_buffer (YY_BUFFER_STATE b );␊ |
309 | void commentcnvYY_flush_buffer (YY_BUFFER_STATE b );␊ |
310 | void commentcnvYYpush_buffer_state (YY_BUFFER_STATE new_buffer );␊ |
311 | void commentcnvYYpop_buffer_state (void );␊ |
312 | ␊ |
313 | static void commentcnvYYensure_buffer_stack (void );␊ |
314 | static void commentcnvYY_load_buffer_state (void );␊ |
315 | static void commentcnvYY_init_buffer (YY_BUFFER_STATE b,FILE *file );␊ |
316 | ␊ |
317 | #define YY_FLUSH_BUFFER commentcnvYY_flush_buffer(YY_CURRENT_BUFFER )␊ |
318 | ␊ |
319 | YY_BUFFER_STATE commentcnvYY_scan_buffer (char *base,yy_size_t size );␊ |
320 | YY_BUFFER_STATE commentcnvYY_scan_string (yyconst char *yy_str );␊ |
321 | YY_BUFFER_STATE commentcnvYY_scan_bytes (yyconst char *bytes,yy_size_t len );␊ |
322 | ␊ |
323 | void *commentcnvYYalloc (yy_size_t );␊ |
324 | void *commentcnvYYrealloc (void *,yy_size_t );␊ |
325 | void commentcnvYYfree (void * );␊ |
326 | ␊ |
327 | #define yy_new_buffer commentcnvYY_create_buffer␊ |
328 | ␊ |
329 | #define yy_set_interactive(is_interactive) \␊ |
330 | ␉{ \␊ |
331 | ␉if ( ! YY_CURRENT_BUFFER ){ \␊ |
332 | commentcnvYYensure_buffer_stack (); \␊ |
333 | ␉␉YY_CURRENT_BUFFER_LVALUE = \␊ |
334 | commentcnvYY_create_buffer(commentcnvYYin,YY_BUF_SIZE ); \␊ |
335 | ␉} \␊ |
336 | ␉YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \␊ |
337 | ␉}␊ |
338 | ␊ |
339 | #define yy_set_bol(at_bol) \␊ |
340 | ␉{ \␊ |
341 | ␉if ( ! YY_CURRENT_BUFFER ){\␊ |
342 | commentcnvYYensure_buffer_stack (); \␊ |
343 | ␉␉YY_CURRENT_BUFFER_LVALUE = \␊ |
344 | commentcnvYY_create_buffer(commentcnvYYin,YY_BUF_SIZE ); \␊ |
345 | ␉} \␊ |
346 | ␉YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \␊ |
347 | ␉}␊ |
348 | ␊ |
349 | #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)␊ |
350 | ␊ |
351 | /* Begin user sect3 */␊ |
352 | ␊ |
353 | #define commentcnvYYwrap(n) 1␊ |
354 | #define YY_SKIP_YYWRAP␊ |
355 | ␊ |
356 | typedef unsigned char YY_CHAR;␊ |
357 | ␊ |
358 | FILE *commentcnvYYin = (FILE *) 0, *commentcnvYYout = (FILE *) 0;␊ |
359 | ␊ |
360 | typedef int yy_state_type;␊ |
361 | ␊ |
362 | extern int commentcnvYYlineno;␊ |
363 | ␊ |
364 | int commentcnvYYlineno = 1;␊ |
365 | ␊ |
366 | extern char *commentcnvYYtext;␊ |
367 | #define yytext_ptr commentcnvYYtext␊ |
368 | ␊ |
369 | static yy_state_type yy_get_previous_state (void );␊ |
370 | static yy_state_type yy_try_NUL_trans (yy_state_type current_state );␊ |
371 | static int yy_get_next_buffer (void );␊ |
372 | static void yy_fatal_error (yyconst char msg[] );␊ |
373 | ␊ |
374 | /* Done after the current pattern has been matched and before the␊ |
375 | * corresponding action - sets up commentcnvYYtext.␊ |
376 | */␊ |
377 | #define YY_DO_BEFORE_ACTION \␊ |
378 | ␉(yytext_ptr) = yy_bp; \␊ |
379 | ␉commentcnvYYleng = (size_t) (yy_cp - yy_bp); \␊ |
380 | ␉(yy_hold_char) = *yy_cp; \␊ |
381 | ␉*yy_cp = '\0'; \␊ |
382 | ␉(yy_c_buf_p) = yy_cp;␊ |
383 | ␊ |
384 | #define YY_NUM_RULES 76␊ |
385 | #define YY_END_OF_BUFFER 77␊ |
386 | /* This struct is not used in this scanner,␊ |
387 | but its presence is necessary. */␊ |
388 | struct yy_trans_info␊ |
389 | ␉{␊ |
390 | ␉flex_int32_t yy_verify;␊ |
391 | ␉flex_int32_t yy_nxt;␊ |
392 | ␉};␊ |
393 | static yyconst flex_int16_t yy_acclist[295] =␊ |
394 | { 0,␊ |
395 | 1, 1, 36, 36, 24, 24, 24, 24, 63, 63,␊ |
396 | 77, 76, 1, 18, 76, 6, 76, 18, 76, 4,␊ |
397 | 18, 76, 11, 18, 76, 5, 18, 76, 18, 76,␊ |
398 | 18, 76, 18, 76, 30, 76, 31, 76, 29, 30,␊ |
399 | 76, 30, 76, 34, 76, 35, 76, 33, 34, 76,␊ |
400 | 34, 76, 57, 76, 76, 76, 36, 44, 76, 39,␊ |
401 | 76, 44, 76, 36, 44, 76, 37, 44, 76, 44,␊ |
402 | 76, 44, 76, 24, 27, 76, 25, 76, 27, 76,␊ |
403 | 27, 76, 24, 27, 76, 27, 76, 27, 76, 20,␊ |
404 | 27, 76, 21, 27, 76, 24, 27, 76, 27, 76,␊ |
405 | ␊ |
406 | 75, 76, 58, 76, 75, 76, 65, 76, 63, 65,␊ |
407 | 76, 62, 65, 76, 69, 74, 76, 71, 76, 74,␊ |
408 | 76, 70, 74, 76, 72, 74, 76, 73, 74, 76,␊ |
409 | 69, 74, 76, 69, 74, 76, 1, 3, 13, 11,␊ |
410 | 10, 28, 32, 36, 41, 42, 43, 41, 42, 43,␊ |
411 | 41, 42, 42, 43, 41, 43, 36, 37, 37, 40,␊ |
412 | 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,␊ |
413 | 66, 24, 24, 24, 23, 58, 63, 62, 69, 69,␊ |
414 | 69, 69, 12, 10, 9,16391, 49, 36, 38, 59,␊ |
415 | 66, 67, 66, 66, 66, 16, 16, 67, 66, 66,␊ |
416 | ␊ |
417 | 66, 66, 66, 66, 66, 19, 26, 23, 23, 26,␊ |
418 | 69,16452, 2,16391, 9, 52,16435,16434,16439,16431,␊ |
419 | 45, 59, 59, 66, 66, 66, 66, 16, 66, 66,␊ |
420 | 66, 66, 66, 66, 8260, 69, 8260,16438,16437,16440,␊ |
421 | 16432, 46, 8243, 8242, 8247, 8239, 66, 15, 15, 67,␊ |
422 | 66, 66, 66, 66, 66, 66, 66, 8246, 8245, 8248,␊ |
423 | 8240, 60, 64, 66, 66, 66, 66, 66, 66, 66,␊ |
424 | 66, 66, 66, 66, 66, 66, 66, 14, 22, 8199,␊ |
425 | 66, 66, 66, 66, 66, 61, 61, 67, 66, 17,␊ |
426 | 17, 67, 8, 9␊ |
427 | ␊ |
428 | } ;␊ |
429 | ␊ |
430 | static yyconst flex_int16_t yy_accept[330] =␊ |
431 | { 0,␊ |
432 | 1, 1, 1, 2, 3, 3, 3, 3, 3, 3,␊ |
433 | 3, 4, 5, 6, 7, 8, 9, 9, 9, 10,␊ |
434 | 11, 11, 11, 12, 13, 16, 18, 20, 23, 26,␊ |
435 | 29, 31, 33, 35, 37, 39, 42, 44, 46, 48,␊ |
436 | 51, 53, 55, 56, 57, 60, 62, 64, 67, 70,␊ |
437 | 72, 74, 77, 79, 81, 83, 86, 88, 90, 93,␊ |
438 | 96, 99, 101, 103, 105, 107, 109, 112, 115, 118,␊ |
439 | 120, 122, 125, 128, 131, 134, 137, 138, 140, 140,␊ |
440 | 141, 141, 142, 142, 143, 144, 144, 144, 144, 144,␊ |
441 | 144, 145, 148, 151, 153, 155, 157, 158, 159, 160,␊ |
442 | ␊ |
443 | 161, 161, 162, 163, 164, 165, 166, 167, 168, 169,␊ |
444 | 170, 171, 172, 172, 173, 173, 173, 174, 174, 174,␊ |
445 | 174, 175, 175, 176, 176, 177, 178, 179, 180, 181,␊ |
446 | 182, 183, 183, 184, 185, 185, 186, 187, 187, 187,␊ |
447 | 188, 188, 188, 190, 191, 192, 193, 194, 195, 196,␊ |
448 | 197, 199, 200, 201, 202, 203, 204, 205, 206, 206,␊ |
449 | 206, 207, 208, 208, 209, 211, 213, 214, 215, 216,␊ |
450 | 216, 217, 217, 217, 218, 219, 220, 221, 222, 222,␊ |
451 | 223, 224, 225, 226, 227, 228, 229, 230, 231, 232,␊ |
452 | 233, 234, 235, 235, 235, 235, 237, 238, 238, 238,␊ |
453 | ␊ |
454 | 238, 239, 240, 241, 242, 243, 243, 243, 244, 244,␊ |
455 | 245, 245, 246, 246, 247, 248, 249, 251, 252, 253,␊ |
456 | 254, 255, 256, 257, 258, 258, 258, 258, 258, 258,␊ |
457 | 258, 258, 258, 258, 258, 258, 258, 258, 259, 259,␊ |
458 | 260, 260, 261, 261, 262, 263, 264, 264, 265, 266,␊ |
459 | 267, 268, 269, 270, 271, 271, 271, 271, 271, 271,␊ |
460 | 271, 271, 271, 271, 271, 271, 271, 272, 273, 274,␊ |
461 | 275, 276, 277, 278, 279, 279, 279, 279, 279, 279,␊ |
462 | 279, 279, 280, 281, 281, 282, 283, 284, 285, 286,␊ |
463 | 286, 286, 286, 286, 286, 286, 286, 287, 289, 290,␊ |
464 | ␊ |
465 | 291, 293, 293, 293, 293, 293, 293, 293, 293, 293,␊ |
466 | 293, 293, 293, 293, 293, 293, 293, 293, 293, 293,␊ |
467 | 293, 293, 293, 293, 293, 293, 293, 295, 295␊ |
468 | } ;␊ |
469 | ␊ |
470 | static yyconst flex_int32_t yy_ec[256] =␊ |
471 | { 0,␊ |
472 | 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,␊ |
473 | 1, 1, 4, 1, 1, 1, 1, 1, 1, 1,␊ |
474 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
475 | 1, 2, 5, 6, 7, 8, 1, 1, 9, 1,␊ |
476 | 1, 10, 1, 1, 11, 12, 13, 14, 14, 14,␊ |
477 | 14, 14, 14, 14, 14, 14, 14, 1, 1, 15,␊ |
478 | 1, 16, 1, 17, 18, 18, 18, 19, 18, 18,␊ |
479 | 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,␊ |
480 | 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,␊ |
481 | 20, 21, 22, 1, 18, 1, 23, 24, 25, 26,␊ |
482 | ␊ |
483 | 27, 28, 29, 30, 31, 29, 29, 32, 33, 34,␊ |
484 | 35, 29, 29, 36, 37, 38, 39, 40, 29, 41,␊ |
485 | 42, 29, 43, 1, 44, 45, 1, 1, 1, 1,␊ |
486 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
487 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
488 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
489 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
490 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
491 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
492 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
493 | ␊ |
494 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
495 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
496 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
497 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
498 | 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,␊ |
499 | 1, 1, 1, 1, 1␊ |
500 | } ;␊ |
501 | ␊ |
502 | static yyconst flex_int32_t yy_meta[46] =␊ |
503 | { 0,␊ |
504 | 1, 2, 3, 1, 4, 5, 5, 1, 5, 6,␊ |
505 | 7, 8, 9, 10, 1, 1, 11, 12, 12, 1,␊ |
506 | 13, 1, 14, 14, 14, 14, 14, 14, 14, 14,␊ |
507 | 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,␊ |
508 | 14, 14, 15, 16, 17␊ |
509 | } ;␊ |
510 | ␊ |
511 | static yyconst flex_int16_t yy_base[369] =␊ |
512 | { 0,␊ |
513 | 0, 0, 0, 19, 12, 13, 14, 28, 1153, 39,␊ |
514 | 50, 91, 26, 133, 33, 176, 41, 42, 220, 0,␊ |
515 | 62, 264, 1155, 1157, 0, 1157, 1138, 1147, 1145, 1157,␊ |
516 | 1140, 38, 1157, 1157, 1157, 1157, 0, 1157, 1157, 1157,␊ |
517 | 0, 25, 55, 1137, 0, 73, 1157, 1143, 51, 292,␊ |
518 | 1131, 0, 1157, 1157, 46, 77, 1134, 1119, 1157, 1157,␊ |
519 | 79, 1132, 1141, 1157, 0, 1157, 1141, 0, 0, 1157,␊ |
520 | 1157, 1157, 1157, 1157, 85, 1129, 0, 1157, 1135, 1157,␊ |
521 | 1135, 81, 7, 1157, 1157, 86, 1126, 87, 1125, 97,␊ |
522 | 0, 1157, 109, 1157, 1157, 1157, 1131, 72, 105, 1157,␊ |
523 | ␊ |
524 | 0, 1093, 60, 74, 79, 99, 83, 100, 101, 87,␊ |
525 | 102, 94, 1110, 0, 1100, 125, 126, 1120, 1119, 1097,␊ |
526 | 138, 1117, 136, 1126, 1157, 1126, 0, 0, 146, 1114,␊ |
527 | 147, 1121, 1157, 1157, 1122, 1157, 1121, 1, 148, 1108,␊ |
528 | 1090, 153, 0, 1004, 861, 1157, 131, 120, 138, 1157,␊ |
529 | 0, 129, 130, 137, 142, 147, 148, 151, 852, 857,␊ |
530 | 1157, 1157, 855, 1157, 1157, 258, 1157, 876, 185, 167,␊ |
531 | 863, 870, 179, 873, 872, 871, 870, 1157, 192, 816,␊ |
532 | 814, 161, 170, 334, 174, 0, 168, 175, 166, 171,␊ |
533 | 245, 172, 787, 240, 257, 338, 0, 273, 799, 268,␊ |
534 | ␊ |
535 | 807, 787, 786, 784, 1157, 281, 777, 1157, 774, 1157,␊ |
536 | 770, 1157, 768, 1157, 358, 1157, 1157, 173, 252, 169,␊ |
537 | 255, 257, 269, 262, 742, 724, 737, 725, 709, 718,␊ |
538 | 710, 706, 700, 691, 301, 349, 723, 1157, 715, 1157,␊ |
539 | 693, 1157, 691, 1157, 361, 1157, 364, 337, 341, 348,␊ |
540 | 261, 326, 347, 344, 129, 659, 649, 651, 656, 631,␊ |
541 | 618, 617, 601, 612, 0, 350, 360, 356, 359, 330,␊ |
542 | 352, 361, 354, 1157, 603, 607, 598, 456, 466, 454,␊ |
543 | 460, 1157, 1157, 367, 404, 380, 386, 449, 394, 451,␊ |
544 | 444, 450, 449, 459, 447, 436, 1157, 1157, 388, 1157,␊ |
545 | ␊ |
546 | 1157, 446, 444, 446, 445, 437, 414, 433, 411, 407,␊ |
547 | 398, 393, 403, 390, 395, 386, 325, 266, 465, 255,␊ |
548 | 435, 441, 439, 442, 275, 200, 1157, 1157, 494, 511,␊ |
549 | 528, 545, 562, 579, 596, 613, 630, 647, 664, 681,␊ |
550 | 698, 715, 732, 749, 760, 774, 791, 797, 805, 820,␊ |
551 | 837, 854, 870, 52, 884, 901, 918, 935, 952, 969,␊ |
552 | 986, 1003, 1020, 1037, 1054, 1071, 1088, 1105␊ |
553 | } ;␊ |
554 | ␊ |
555 | static yyconst flex_int16_t yy_def[369] =␊ |
556 | { 0,␊ |
557 | 329, 329, 330, 330, 331, 331, 332, 332, 329, 329,␊ |
558 | 333, 333, 334, 334, 334, 334, 335, 335, 328, 19,␊ |
559 | 336, 336, 328, 328, 337, 328, 328, 328, 328, 328,␊ |
560 | 328, 328, 328, 328, 328, 328, 338, 328, 328, 328,␊ |
561 | 339, 328, 328, 328, 340, 341, 328, 340, 342, 328,␊ |
562 | 328, 343, 328, 328, 328, 343, 328, 328, 328, 328,␊ |
563 | 343, 328, 344, 328, 50, 328, 328, 345, 346, 328,␊ |
564 | 328, 328, 328, 328, 346, 346, 337, 328, 328, 328,␊ |
565 | 328, 328, 347, 328, 328, 328, 328, 328, 328, 328,␊ |
566 | 340, 328, 341, 328, 328, 328, 340, 342, 342, 328,␊ |
567 | ␊ |
568 | 348, 349, 349, 349, 349, 349, 349, 349, 349, 349,␊ |
569 | 349, 349, 328, 343, 328, 328, 343, 328, 328, 328,␊ |
570 | 343, 328, 328, 344, 328, 328, 345, 346, 346, 346,␊ |
571 | 346, 328, 328, 328, 347, 328, 350, 347, 328, 351,␊ |
572 | 328, 352, 340, 353, 349, 328, 349, 349, 349, 328,␊ |
573 | 354, 349, 349, 349, 349, 349, 349, 349, 328, 328,␊ |
574 | 328, 328, 328, 328, 328, 355, 328, 350, 328, 347,␊ |
575 | 356, 328, 357, 358, 359, 360, 361, 328, 328, 328,␊ |
576 | 353, 349, 349, 349, 349, 354, 349, 349, 349, 349,␊ |
577 | 349, 349, 328, 328, 328, 355, 362, 328, 328, 347,␊ |
578 | ␊ |
579 | 363, 364, 365, 366, 328, 328, 358, 328, 359, 328,␊ |
580 | 360, 328, 361, 328, 349, 328, 328, 349, 349, 349,␊ |
581 | 349, 349, 349, 349, 328, 328, 328, 328, 328, 328,␊ |
582 | 328, 328, 328, 328, 328, 347, 363, 328, 364, 328,␊ |
583 | 365, 328, 366, 328, 328, 328, 328, 349, 349, 349,␊ |
584 | 349, 349, 349, 349, 328, 328, 328, 328, 328, 328,␊ |
585 | 328, 328, 328, 328, 367, 347, 349, 349, 349, 349,␊ |
586 | 349, 349, 349, 328, 328, 328, 328, 328, 328, 328,␊ |
587 | 328, 328, 328, 347, 349, 349, 349, 349, 349, 328,␊ |
588 | 328, 328, 328, 328, 328, 347, 328, 328, 349, 328,␊ |
589 | ␊ |
590 | 328, 328, 328, 328, 328, 328, 328, 347, 328, 328,␊ |
591 | 328, 328, 328, 328, 347, 328, 328, 328, 347, 328,␊ |
592 | 347, 347, 347, 347, 368, 368, 328, 0, 328, 328,␊ |
593 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
594 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
595 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
596 | 328, 328, 328, 328, 328, 328, 328, 328␊ |
597 | } ;␊ |
598 | ␊ |
599 | static yyconst flex_int16_t yy_nxt[1203] =␊ |
600 | { 0,␊ |
601 | 328, 328, 26, 136, 27, 28, 29, 170, 30, 136,␊ |
602 | 31, 137, 32, 138, 35, 35, 39, 36, 36, 137,␊ |
603 | 33, 26, 40, 27, 28, 29, 86, 30, 53, 31,␊ |
604 | 39, 32, 37, 37, 41, 53, 40, 87, 54, 33,␊ |
605 | 43, 42, 55, 64, 64, 54, 55, 82, 41, 58,␊ |
606 | 83, 44, 46, 58, 47, 48, 88, 65, 65, 49,␊ |
607 | 99, 65, 65, 100, 70, 186, 50, 89, 54, 54,␊ |
608 | 50, 71, 115, 116, 93, 59, 60, 94, 117, 95,␊ |
609 | 121, 328, 72, 96, 328, 134, 129, 86, 88, 118,␊ |
610 | 134, 122, 51, 46, 147, 47, 48, 130, 87, 89,␊ |
611 | ␊ |
612 | 49, 140, 146, 141, 73, 74, 150, 50, 148, 142,␊ |
613 | 93, 50, 149, 94, 99, 95, 146, 100, 150, 96,␊ |
614 | 152, 146, 153, 154, 156, 146, 158, 117, 157, 146,␊ |
615 | 274, 274, 161, 51, 56, 53, 146, 155, 118, 121,␊ |
616 | 164, 151, 146, 146, 146, 57, 161, 129, 165, 55,␊ |
617 | 122, 166, 171, 55, 172, 178, 182, 184, 130, 166,␊ |
618 | 173, 187, 146, 185, 183, 179, 184, 188, 161, 136,␊ |
619 | 189, 146, 146, 146, 190, 54, 54, 61, 53, 146,␊ |
620 | 146, 205, 192, 191, 146, 200, 198, 184, 62, 146,␊ |
621 | 146, 206, 58, 146, 178, 215, 58, 199, 218, 219,␊ |
622 | ␊ |
623 | 221, 220, 327, 146, 179, 222, 224, 248, 146, 250,␊ |
624 | 146, 146, 146, 146, 146, 146, 146, 146, 59, 60,␊ |
625 | 66, 67, 24, 66, 66, 66, 66, 66, 66, 66,␊ |
626 | 66, 66, 66, 66, 66, 66, 66, 68, 68, 66,␊ |
627 | 66, 66, 68, 68, 68, 68, 68, 68, 68, 68,␊ |
628 | 68, 68, 68, 68, 68, 68, 68, 68, 68, 68,␊ |
629 | 68, 68, 66, 66, 66, 75, 70, 197, 223, 226,␊ |
630 | 136, 227, 228, 71, 198, 229, 76, 327, 197, 230,␊ |
631 | 231, 232, 233, 205, 72, 199, 249, 146, 251, 234,␊ |
632 | 252, 253, 270, 206, 146, 254, 161, 146, 161, 146,␊ |
633 | ␊ |
634 | 197, 197, 236, 146, 146, 265, 73, 74, 101, 102,␊ |
635 | 102, 146, 101, 265, 102, 102, 103, 104, 105, 106,␊ |
636 | 102, 107, 102, 108, 109, 102, 102, 110, 102, 102,␊ |
637 | 102, 111, 112, 102, 216, 216, 216, 216, 216, 216,␊ |
638 | 216, 216, 216, 216, 216, 216, 216, 197, 216, 216,␊ |
639 | 216, 136, 136, 216, 216, 216, 320, 271, 197, 245,␊ |
640 | 246, 247, 245, 246, 247, 247, 246, 247, 146, 136,␊ |
641 | 267, 288, 146, 266, 268, 273, 217, 216, 216, 146,␊ |
642 | 197, 197, 269, 146, 272, 285, 146, 286, 284, 146,␊ |
643 | 146, 289, 287, 288, 146, 288, 146, 136, 146, 296,␊ |
644 | ␊ |
645 | 146, 146, 146, 146, 297, 297, 297, 297, 297, 297,␊ |
646 | 297, 297, 297, 297, 297, 297, 297, 299, 297, 297,␊ |
647 | 297, 288, 146, 297, 297, 297, 288, 161, 146, 288,␊ |
648 | 146, 161, 319, 318, 161, 136, 146, 136, 136, 161,␊ |
649 | 317, 136, 316, 136, 136, 314, 298, 297, 297, 300,␊ |
650 | 300, 300, 300, 300, 300, 300, 300, 300, 300, 300,␊ |
651 | 300, 300, 308, 300, 300, 300, 315, 136, 300, 300,␊ |
652 | 300, 323, 322, 324, 313, 325, 312, 311, 310, 309,␊ |
653 | 307, 306, 305, 304, 303, 302, 282, 321, 295, 294,␊ |
654 | 293, 301, 300, 300, 24, 24, 24, 24, 24, 24,␊ |
655 | ␊ |
656 | 24, 24, 24, 24, 24, 24, 24, 24, 24, 24,␊ |
657 | 24, 25, 25, 25, 25, 25, 25, 25, 25, 25,␊ |
658 | 25, 25, 25, 25, 25, 25, 25, 25, 34, 34,␊ |
659 | 34, 34, 34, 34, 34, 34, 34, 34, 34, 34,␊ |
660 | 34, 34, 34, 34, 34, 38, 38, 38, 38, 38,␊ |
661 | 38, 38, 38, 38, 38, 38, 38, 38, 38, 38,␊ |
662 | 38, 38, 45, 45, 45, 45, 45, 45, 45, 45,␊ |
663 | 45, 45, 45, 45, 45, 45, 45, 45, 45, 52,␊ |
664 | 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,␊ |
665 | 52, 52, 52, 52, 52, 52, 63, 63, 63, 63,␊ |
666 | ␊ |
667 | 63, 63, 63, 63, 63, 63, 63, 63, 63, 63,␊ |
668 | 63, 63, 63, 69, 69, 69, 69, 69, 69, 69,␊ |
669 | 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,␊ |
670 | 77, 77, 292, 291, 290, 77, 282, 77, 282, 77,␊ |
671 | 77, 77, 281, 77, 77, 77, 77, 84, 84, 280,␊ |
672 | 84, 84, 84, 84, 84, 84, 84, 84, 84, 84,␊ |
673 | 84, 84, 84, 84, 85, 85, 279, 85, 85, 85,␊ |
674 | 85, 85, 85, 85, 85, 85, 85, 85, 85, 85,␊ |
675 | 85, 91, 91, 278, 277, 91, 276, 91, 91, 91,␊ |
676 | 91, 275, 91, 244, 91, 242, 91, 91, 92, 92,␊ |
677 | ␊ |
678 | 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,␊ |
679 | 92, 92, 92, 92, 92, 98, 98, 240, 98, 98,␊ |
680 | 98, 98, 98, 98, 98, 238, 98, 264, 98, 98,␊ |
681 | 98, 98, 114, 114, 263, 114, 114, 114, 114, 114,␊ |
682 | 262, 114, 261, 114, 260, 114, 259, 258, 114, 124,␊ |
683 | 124, 124, 124, 124, 124, 124, 124, 124, 124, 257,␊ |
684 | 124, 256, 124, 124, 124, 124, 127, 127, 255, 127,␊ |
685 | 214, 127, 212, 127, 128, 128, 210, 128, 128, 208,␊ |
686 | 128, 128, 128, 128, 128, 128, 244, 128, 242, 240,␊ |
687 | 128, 135, 135, 135, 135, 135, 135, 135, 135, 135,␊ |
688 | ␊ |
689 | 135, 135, 135, 135, 135, 135, 135, 135, 144, 238,␊ |
690 | 144, 235, 225, 144, 145, 180, 145, 180, 145, 145,␊ |
691 | 168, 168, 168, 168, 168, 168, 168, 168, 168, 168,␊ |
692 | 168, 168, 168, 168, 168, 168, 168, 174, 174, 174,␊ |
693 | 174, 174, 174, 174, 174, 174, 174, 174, 174, 174,␊ |
694 | 174, 174, 174, 174, 177, 177, 177, 177, 177, 177,␊ |
695 | 177, 177, 177, 177, 177, 177, 177, 177, 177, 177,␊ |
696 | 177, 181, 214, 212, 210, 208, 203, 202, 169, 181,␊ |
697 | 195, 181, 194, 181, 196, 196, 193, 196, 196, 196,␊ |
698 | 196, 196, 196, 196, 196, 196, 196, 196, 196, 196,␊ |
699 | ␊ |
700 | 196, 201, 201, 146, 201, 201, 201, 201, 201, 201,␊ |
701 | 201, 201, 201, 201, 201, 201, 201, 201, 204, 204,␊ |
702 | 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,␊ |
703 | 204, 204, 204, 204, 204, 207, 207, 207, 207, 207,␊ |
704 | 207, 207, 207, 207, 207, 207, 207, 207, 207, 207,␊ |
705 | 207, 207, 209, 209, 209, 209, 209, 209, 209, 209,␊ |
706 | 209, 209, 209, 209, 209, 209, 209, 209, 209, 211,␊ |
707 | 211, 211, 211, 211, 211, 211, 211, 211, 211, 211,␊ |
708 | 211, 211, 211, 211, 211, 211, 213, 213, 213, 213,␊ |
709 | 213, 213, 213, 213, 213, 213, 213, 213, 213, 213,␊ |
710 | ␊ |
711 | 213, 213, 213, 197, 197, 180, 197, 197, 197, 197,␊ |
712 | 197, 197, 197, 197, 197, 197, 197, 197, 197, 197,␊ |
713 | 237, 237, 237, 237, 237, 237, 237, 237, 237, 237,␊ |
714 | 237, 237, 237, 237, 237, 237, 237, 239, 239, 239,␊ |
715 | 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,␊ |
716 | 239, 239, 239, 239, 241, 241, 241, 241, 241, 241,␊ |
717 | 241, 241, 241, 241, 241, 241, 241, 241, 241, 241,␊ |
718 | 241, 243, 243, 243, 243, 243, 243, 243, 243, 243,␊ |
719 | 243, 243, 243, 243, 243, 243, 243, 243, 283, 283,␊ |
720 | 283, 283, 283, 283, 283, 283, 176, 283, 283, 283,␊ |
721 | ␊ |
722 | 283, 283, 283, 283, 283, 326, 326, 326, 326, 326,␊ |
723 | 326, 326, 326, 326, 326, 326, 326, 326, 326, 326,␊ |
724 | 326, 326, 175, 169, 136, 167, 131, 126, 125, 123,␊ |
725 | 163, 162, 119, 160, 159, 146, 143, 90, 139, 133,␊ |
726 | 132, 131, 126, 125, 123, 120, 119, 113, 97, 90,␊ |
727 | 81, 80, 79, 78, 328, 42, 23, 328, 328, 328,␊ |
728 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
729 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
730 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
731 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
732 | ␊ |
733 | 328, 328␊ |
734 | } ;␊ |
735 | ␊ |
736 | static yyconst flex_int16_t yy_chk[1203] =␊ |
737 | { 0,␊ |
738 | 0, 0, 3, 138, 3, 3, 3, 138, 3, 83,␊ |
739 | 3, 83, 3, 83, 5, 6, 7, 5, 6, 83,␊ |
740 | 3, 4, 7, 4, 4, 4, 42, 4, 13, 4,␊ |
741 | 8, 4, 5, 6, 7, 15, 8, 42, 13, 4,␊ |
742 | 10, 10, 13, 17, 18, 15, 13, 32, 8, 15,␊ |
743 | 32, 10, 11, 15, 11, 11, 43, 17, 18, 11,␊ |
744 | 49, 17, 18, 49, 21, 354, 11, 43, 13, 13,␊ |
745 | 11, 21, 55, 55, 46, 15, 15, 46, 56, 46,␊ |
746 | 61, 98, 21, 46, 98, 82, 75, 86, 88, 56,␊ |
747 | 82, 61, 11, 12, 103, 12, 12, 75, 86, 88,␊ |
748 | ␊ |
749 | 12, 90, 103, 90, 21, 21, 106, 12, 104, 90,␊ |
750 | 93, 12, 105, 93, 99, 93, 104, 99, 106, 93,␊ |
751 | 107, 105, 108, 109, 110, 107, 112, 117, 111, 110,␊ |
752 | 255, 255, 116, 12, 14, 14, 112, 109, 117, 121,␊ |
753 | 123, 106, 108, 109, 111, 14, 116, 129, 123, 14,␊ |
754 | 121, 131, 139, 14, 139, 142, 147, 148, 129, 131,␊ |
755 | 139, 152, 148, 149, 147, 142, 155, 153, 116, 170,␊ |
756 | 154, 152, 153, 147, 156, 14, 14, 16, 16, 154,␊ |
757 | 149, 173, 158, 157, 155, 170, 169, 182, 16, 156,␊ |
758 | 157, 173, 16, 158, 179, 183, 16, 169, 185, 187,␊ |
759 | ␊ |
760 | 189, 188, 326, 182, 179, 190, 192, 218, 189, 220,␊ |
761 | 187, 220, 183, 190, 192, 218, 185, 188, 16, 16,␊ |
762 | 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,␊ |
763 | 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,␊ |
764 | 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,␊ |
765 | 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,␊ |
766 | 19, 19, 19, 19, 19, 22, 22, 166, 191, 194,␊ |
767 | 200, 194, 194, 22, 198, 194, 22, 325, 166, 194,␊ |
768 | 194, 195, 195, 206, 22, 198, 219, 191, 221, 195,␊ |
769 | 222, 223, 251, 206, 219, 224, 320, 221, 318, 222,␊ |
770 | ␊ |
771 | 166, 166, 200, 251, 224, 235, 22, 22, 50, 50,␊ |
772 | 50, 223, 50, 235, 50, 50, 50, 50, 50, 50,␊ |
773 | 50, 50, 50, 50, 50, 50, 50, 50, 50, 50,␊ |
774 | 50, 50, 50, 50, 184, 184, 184, 184, 184, 184,␊ |
775 | 184, 184, 184, 184, 184, 184, 184, 196, 184, 184,␊ |
776 | 184, 236, 266, 184, 184, 184, 317, 252, 196, 215,␊ |
777 | 215, 215, 245, 245, 245, 247, 247, 247, 252, 284,␊ |
778 | 248, 270, 270, 236, 249, 254, 184, 184, 184, 248,␊ |
779 | 196, 196, 250, 249, 253, 267, 254, 268, 266, 253,␊ |
780 | 250, 272, 269, 271, 271, 273, 273, 315, 268, 284,␊ |
781 | ␊ |
782 | 215, 269, 267, 272, 285, 285, 285, 285, 285, 285,␊ |
783 | 285, 285, 285, 285, 285, 285, 285, 287, 285, 285,␊ |
784 | 285, 286, 286, 285, 285, 285, 289, 316, 287, 299,␊ |
785 | 299, 314, 315, 313, 312, 308, 289, 321, 296, 311,␊ |
786 | 310, 323, 309, 322, 324, 307, 285, 285, 285, 288,␊ |
787 | 288, 288, 288, 288, 288, 288, 288, 288, 288, 288,␊ |
788 | 288, 288, 296, 288, 288, 288, 308, 319, 288, 288,␊ |
789 | 288, 322, 321, 323, 306, 324, 305, 304, 303, 302,␊ |
790 | 295, 294, 293, 292, 291, 290, 281, 319, 280, 279,␊ |
791 | 278, 288, 288, 288, 329, 329, 329, 329, 329, 329,␊ |
792 | ␊ |
793 | 329, 329, 329, 329, 329, 329, 329, 329, 329, 329,␊ |
794 | 329, 330, 330, 330, 330, 330, 330, 330, 330, 330,␊ |
795 | 330, 330, 330, 330, 330, 330, 330, 330, 331, 331,␊ |
796 | 331, 331, 331, 331, 331, 331, 331, 331, 331, 331,␊ |
797 | 331, 331, 331, 331, 331, 332, 332, 332, 332, 332,␊ |
798 | 332, 332, 332, 332, 332, 332, 332, 332, 332, 332,␊ |
799 | 332, 332, 333, 333, 333, 333, 333, 333, 333, 333,␊ |
800 | 333, 333, 333, 333, 333, 333, 333, 333, 333, 334,␊ |
801 | 334, 334, 334, 334, 334, 334, 334, 334, 334, 334,␊ |
802 | 334, 334, 334, 334, 334, 334, 335, 335, 335, 335,␊ |
803 | ␊ |
804 | 335, 335, 335, 335, 335, 335, 335, 335, 335, 335,␊ |
805 | 335, 335, 335, 336, 336, 336, 336, 336, 336, 336,␊ |
806 | 336, 336, 336, 336, 336, 336, 336, 336, 336, 336,␊ |
807 | 337, 337, 277, 276, 275, 337, 264, 337, 263, 337,␊ |
808 | 337, 337, 262, 337, 337, 337, 337, 338, 338, 261,␊ |
809 | 338, 338, 338, 338, 338, 338, 338, 338, 338, 338,␊ |
810 | 338, 338, 338, 338, 339, 339, 260, 339, 339, 339,␊ |
811 | 339, 339, 339, 339, 339, 339, 339, 339, 339, 339,␊ |
812 | 339, 340, 340, 259, 258, 340, 257, 340, 340, 340,␊ |
813 | 340, 256, 340, 243, 340, 241, 340, 340, 341, 341,␊ |
814 | ␊ |
815 | 341, 341, 341, 341, 341, 341, 341, 341, 341, 341,␊ |
816 | 341, 341, 341, 341, 341, 342, 342, 239, 342, 342,␊ |
817 | 342, 342, 342, 342, 342, 237, 342, 234, 342, 342,␊ |
818 | 342, 342, 343, 343, 233, 343, 343, 343, 343, 343,␊ |
819 | 232, 343, 231, 343, 230, 343, 229, 228, 343, 344,␊ |
820 | 344, 344, 344, 344, 344, 344, 344, 344, 344, 227,␊ |
821 | 344, 226, 344, 344, 344, 344, 345, 345, 225, 345,␊ |
822 | 213, 345, 211, 345, 346, 346, 209, 346, 346, 207,␊ |
823 | 346, 346, 346, 346, 346, 346, 204, 346, 203, 202,␊ |
824 | 346, 347, 347, 347, 347, 347, 347, 347, 347, 347,␊ |
825 | ␊ |
826 | 347, 347, 347, 347, 347, 347, 347, 347, 348, 201,␊ |
827 | 348, 199, 193, 348, 349, 181, 349, 180, 349, 349,␊ |
828 | 350, 350, 350, 350, 350, 350, 350, 350, 350, 350,␊ |
829 | 350, 350, 350, 350, 350, 350, 350, 351, 351, 351,␊ |
830 | 351, 351, 351, 351, 351, 351, 351, 351, 351, 351,␊ |
831 | 351, 351, 351, 351, 352, 352, 352, 352, 352, 352,␊ |
832 | 352, 352, 352, 352, 352, 352, 352, 352, 352, 352,␊ |
833 | 352, 353, 177, 176, 175, 174, 172, 171, 168, 353,␊ |
834 | 163, 353, 160, 353, 355, 355, 159, 355, 355, 355,␊ |
835 | 355, 355, 355, 355, 355, 355, 355, 355, 355, 355,␊ |
836 | ␊ |
837 | 355, 356, 356, 145, 356, 356, 356, 356, 356, 356,␊ |
838 | 356, 356, 356, 356, 356, 356, 356, 356, 357, 357,␊ |
839 | 357, 357, 357, 357, 357, 357, 357, 357, 357, 357,␊ |
840 | 357, 357, 357, 357, 357, 358, 358, 358, 358, 358,␊ |
841 | 358, 358, 358, 358, 358, 358, 358, 358, 358, 358,␊ |
842 | 358, 358, 359, 359, 359, 359, 359, 359, 359, 359,␊ |
843 | 359, 359, 359, 359, 359, 359, 359, 359, 359, 360,␊ |
844 | 360, 360, 360, 360, 360, 360, 360, 360, 360, 360,␊ |
845 | 360, 360, 360, 360, 360, 360, 361, 361, 361, 361,␊ |
846 | 361, 361, 361, 361, 361, 361, 361, 361, 361, 361,␊ |
847 | ␊ |
848 | 361, 361, 361, 362, 362, 144, 362, 362, 362, 362,␊ |
849 | 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,␊ |
850 | 363, 363, 363, 363, 363, 363, 363, 363, 363, 363,␊ |
851 | 363, 363, 363, 363, 363, 363, 363, 364, 364, 364,␊ |
852 | 364, 364, 364, 364, 364, 364, 364, 364, 364, 364,␊ |
853 | 364, 364, 364, 364, 365, 365, 365, 365, 365, 365,␊ |
854 | 365, 365, 365, 365, 365, 365, 365, 365, 365, 365,␊ |
855 | 365, 366, 366, 366, 366, 366, 366, 366, 366, 366,␊ |
856 | 366, 366, 366, 366, 366, 366, 366, 366, 367, 367,␊ |
857 | 367, 367, 367, 367, 367, 367, 141, 367, 367, 367,␊ |
858 | ␊ |
859 | 367, 367, 367, 367, 367, 368, 368, 368, 368, 368,␊ |
860 | 368, 368, 368, 368, 368, 368, 368, 368, 368, 368,␊ |
861 | 368, 368, 140, 137, 135, 132, 130, 126, 124, 122,␊ |
862 | 120, 119, 118, 115, 113, 102, 97, 89, 87, 81,␊ |
863 | 79, 76, 67, 63, 62, 58, 57, 51, 48, 44,␊ |
864 | 31, 29, 28, 27, 23, 9, 328, 328, 328, 328,␊ |
865 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
866 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
867 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
868 | 328, 328, 328, 328, 328, 328, 328, 328, 328, 328,␊ |
869 | ␊ |
870 | 328, 328␊ |
871 | } ;␊ |
872 | ␊ |
873 | extern int commentcnvYY_flex_debug;␊ |
874 | int commentcnvYY_flex_debug = 0;␊ |
875 | ␊ |
876 | static yy_state_type *yy_state_buf=0, *yy_state_ptr=0;␊ |
877 | static char *yy_full_match;␊ |
878 | static int yy_lp;␊ |
879 | static int yy_looking_for_trail_begin = 0;␊ |
880 | static int yy_full_lp;␊ |
881 | static int *yy_full_state;␊ |
882 | #define YY_TRAILING_MASK 0x2000␊ |
883 | #define YY_TRAILING_HEAD_MASK 0x4000␊ |
884 | #define REJECT \␊ |
885 | { \␊ |
886 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */ \␊ |
887 | yy_cp = (yy_full_match); /* restore poss. backed-over text */ \␊ |
888 | (yy_lp) = (yy_full_lp); /* restore orig. accepting pos. */ \␊ |
889 | (yy_state_ptr) = (yy_full_state); /* restore orig. state */ \␊ |
890 | yy_current_state = *(yy_state_ptr); /* restore curr. state */ \␊ |
891 | ++(yy_lp); \␊ |
892 | goto find_rule; \␊ |
893 | }␊ |
894 | ␊ |
895 | #define yymore() yymore_used_but_not_detected␊ |
896 | #define YY_MORE_ADJ 0␊ |
897 | #define YY_RESTORE_YY_MORE_OFFSET␊ |
898 | char *commentcnvYYtext;␊ |
899 | #line 1 "commentcnv.l"␊ |
900 | /*****************************************************************************␊ |
901 | *␊ |
902 | * $Id: commentcnv.l,v 1.80 2001/03/19 19:27:41 root Exp $␊ |
903 | *␊ |
904 | * Copyright (C) 1997-2011 by Dimitri van Heesch.␊ |
905 | *␊ |
906 | * Permission to use, copy, modify, and distribute this software and its␊ |
907 | * documentation under the terms of the GNU General Public License is hereby ␊ |
908 | * granted. No representations are made about the suitability of this software ␊ |
909 | * for any purpose. It is provided "as is" without express or implied warranty.␊ |
910 | * See the GNU General Public License for more details.␊ |
911 | *␊ |
912 | * Documents produced by Doxygen are derivative works derived from the␊ |
913 | * input used in their production; they are not affected by this license.␊ |
914 | *␊ |
915 | */␊ |
916 | #line 19 "commentcnv.l"␊ |
917 | ␊ |
918 | #define YY_NEVER_INTERACTIVE 1␊ |
919 | ␊ |
920 | #include <stdio.h>␊ |
921 | #include <stdlib.h>␊ |
922 | ␊ |
923 | #include <qstack.h>␊ |
924 | #include <qregexp.h>␊ |
925 | #include <qtextstream.h>␊ |
926 | #include <qglobal.h>␊ |
927 | ␊ |
928 | #include "bufstr.h"␊ |
929 | #include "debug.h"␊ |
930 | #include "message.h"␊ |
931 | #include "config.h"␊ |
932 | #include "doxygen.h"␊ |
933 | #include "util.h"␊ |
934 | ␊ |
935 | #include <assert.h>␊ |
936 | ␊ |
937 | #define ADDCHAR(c) g_outBuf->addChar(c)␊ |
938 | #define ADDARRAY(a,s) g_outBuf->addArray(a,s)␊ |
939 | ␊ |
940 | struct CondCtx␊ |
941 | {␊ |
942 | CondCtx(int line,QCString id,bool b) ␊ |
943 | : lineNr(line),sectionId(id), skip(b) {}␊ |
944 | int lineNr;␊ |
945 | QCString sectionId;␊ |
946 | bool skip;␊ |
947 | };␊ |
948 | ␊ |
949 | static BufStr * g_inBuf;␊ |
950 | static BufStr * g_outBuf;␊ |
951 | static int g_inBufPos;␊ |
952 | static int g_col;␊ |
953 | static int g_blockHeadCol;␊ |
954 | static bool g_mlBrief;␊ |
955 | static int g_readLineCtx;␊ |
956 | static bool g_skip;␊ |
957 | static QCString g_fileName;␊ |
958 | static int g_lineNr;␊ |
959 | static int g_condCtx;␊ |
960 | static QStack<CondCtx> g_condStack;␊ |
961 | static QCString g_blockName;␊ |
962 | static int g_lastCommentContext;␊ |
963 | static bool g_inSpecialComment;␊ |
964 | static bool g_inRoseComment;␊ |
965 | static int g_javaBlock;␊ |
966 | static bool g_specialComment;␊ |
967 | ␊ |
968 | static QCString g_aliasString;␊ |
969 | static int g_blockCount;␊ |
970 | static bool g_lastEscaped;␊ |
971 | static int g_lastBlockContext;␊ |
972 | static bool g_pythonDocString;␊ |
973 | ␊ |
974 | ␊ |
975 | static SrcLangExt g_lang;␊ |
976 | ␊ |
977 | static void replaceCommentMarker(const char *s,int len)␊ |
978 | {␊ |
979 | const char *p=s;␊ |
980 | char c;␊ |
981 | // copy blanks␊ |
982 | while ((c=*p) && (c==' ' || c=='\t' || c=='\n')) ␊ |
983 | {␊ |
984 | ADDCHAR(c);␊ |
985 | g_lineNr += c=='\n';␊ |
986 | p++;␊ |
987 | }␊ |
988 | // replace start of comment marker by spaces␊ |
989 | while ((c=*p) && (c=='/' || c=='!' || c=='#')) ␊ |
990 | {␊ |
991 | ADDCHAR(' ');␊ |
992 | p++;␊ |
993 | if (*p=='<') // comment-after-item marker ␊ |
994 | { ␊ |
995 | ADDCHAR(' '); ␊ |
996 | p++; ␊ |
997 | }␊ |
998 | if (c=='!') // end after first !␊ |
999 | {␊ |
1000 | break;␊ |
1001 | }␊ |
1002 | }␊ |
1003 | // copy comment line to output␊ |
1004 | ADDARRAY(p,len-(p-s));␊ |
1005 | }␊ |
1006 | ␊ |
1007 | static inline int computeIndent(const char *s)␊ |
1008 | {␊ |
1009 | int col=0;␊ |
1010 | static int tabSize=Config_getInt("TAB_SIZE");␊ |
1011 | const char *p=s;␊ |
1012 | char c;␊ |
1013 | while ((c=*p++))␊ |
1014 | {␊ |
1015 | if (c==' ') col++;␊ |
1016 | else if (c=='\t') col+=tabSize-(col%tabSize); ␊ |
1017 | else break;␊ |
1018 | }␊ |
1019 | return col;␊ |
1020 | }␊ |
1021 | ␊ |
1022 | static inline void copyToOutput(const char *s,int len)␊ |
1023 | {␊ |
1024 | int i;␊ |
1025 | if (g_skip) // only add newlines.␊ |
1026 | {␊ |
1027 | for (i=0;i<len;i++) ␊ |
1028 | {␊ |
1029 | if (s[i]=='\n') ␊ |
1030 | {␊ |
1031 | ␉ADDCHAR('\n');␊ |
1032 | ␉//fprintf(stderr,"---> skip %d\n",g_lineNr);␊ |
1033 | ␉g_lineNr++;␊ |
1034 | }␊ |
1035 | }␊ |
1036 | }␊ |
1037 | else if (len>0)␊ |
1038 | {␊ |
1039 | ADDARRAY(s,len);␊ |
1040 | static int tabSize=Config_getInt("TAB_SIZE");␊ |
1041 | for (i=0;i<len;i++) ␊ |
1042 | {␊ |
1043 | switch (s[i])␊ |
1044 | {␊ |
1045 | ␉case '\n': g_col=0; ␊ |
1046 | ␉ //fprintf(stderr,"---> copy %d\n",g_lineNr);␊ |
1047 | ␉␉ g_lineNr++; break;␊ |
1048 | ␉case '\t': g_col+=tabSize-(g_col%tabSize); break;␊ |
1049 | ␉default: g_col++; break;␊ |
1050 | }␊ |
1051 | }␊ |
1052 | }␊ |
1053 | }␊ |
1054 | ␊ |
1055 | static void startCondSection(const char *sectId)␊ |
1056 | {␊ |
1057 | g_condStack.push(new CondCtx(g_lineNr,sectId,g_skip));␊ |
1058 | if (Config_getList("ENABLED_SECTIONS").find(sectId)!=-1)␊ |
1059 | {␊ |
1060 | //printf("*** Section is enabled!\n");␊ |
1061 | }␊ |
1062 | else␊ |
1063 | {␊ |
1064 | //printf("*** Section is disabled!\n");␊ |
1065 | g_skip=TRUE;␊ |
1066 | }␊ |
1067 | }␊ |
1068 | ␊ |
1069 | static void endCondSection()␊ |
1070 | {␊ |
1071 | if (g_condStack.isEmpty())␊ |
1072 | {␊ |
1073 | warn(g_fileName,g_lineNr,"Found \\endcond command without matching \\cond");␊ |
1074 | g_skip=FALSE;␊ |
1075 | }␊ |
1076 | else␊ |
1077 | {␊ |
1078 | CondCtx *ctx = g_condStack.pop();␊ |
1079 | g_skip=ctx->skip;␊ |
1080 | }␊ |
1081 | }␊ |
1082 | ␊ |
1083 | #if 0␊ |
1084 | /** remove and executes cond and endcond commands in \a s */␊ |
1085 | static QCString handleCondCmdInAliases(const QCString &s)␊ |
1086 | {␊ |
1087 | QCString result;␊ |
1088 | //printf("handleCondCmdInAliases(%s)\n",s.data());␊ |
1089 | static QRegExp cmdPat("[\\\\@][a-z_A-Z][a-z_A-Z0-9]*");␊ |
1090 | int p=0,i,l;␊ |
1091 | while ((i=cmdPat.match(s,p,&l))!=-1)␊ |
1092 | {␊ |
1093 | result+=s.mid(p,i-p);␊ |
1094 | QCString cmd = s.mid(i+1,l-1);␊ |
1095 | //printf("Found command %s\n",cmd.data());␊ |
1096 | if (cmd=="cond")␊ |
1097 | {␊ |
1098 | int sp=i+l,ep;␊ |
1099 | const char *arg=s.data()+sp;␊ |
1100 | char c;␊ |
1101 | // skip spaces␊ |
1102 | while ((c=*arg) && (c==' ' || c=='\t')) arg++,sp++;␊ |
1103 | // read argument␊ |
1104 | if (*arg=='\n') // no arg␊ |
1105 | {␊ |
1106 | ␉startCondSection(" ");␊ |
1107 | ␉ep=sp;␊ |
1108 | }␊ |
1109 | else // get argument␊ |
1110 | {␊ |
1111 | ␉ep=sp;␊ |
1112 | ␉while ((c=*arg) && isId(c)) arg++,ep++;␊ |
1113 | ␉if (ep>sp)␊ |
1114 | ␉{␊ |
1115 | ␉ QCString id = s.mid(sp,ep-sp);␊ |
1116 | ␉ //printf("Found conditional section id %s\n",id.data());␊ |
1117 | ␉ startCondSection(id);␊ |
1118 | ␉}␊ |
1119 | ␉else // invalid identifier␊ |
1120 | ␉{␊ |
1121 | ␉}␊ |
1122 | }␊ |
1123 | p=ep;␊ |
1124 | }␊ |
1125 | else if (cmd=="endcond")␊ |
1126 | {␊ |
1127 | endCondSection();␊ |
1128 | p=i+l;␊ |
1129 | }␊ |
1130 | else␊ |
1131 | {␊ |
1132 | result+=s.mid(i,l);␊ |
1133 | p=i+l;␊ |
1134 | }␊ |
1135 | }␊ |
1136 | result+=s.right(s.length()-p);␊ |
1137 | return result;␊ |
1138 | }␊ |
1139 | #endif␊ |
1140 | ␊ |
1141 | /** copies string \a s with length \a len to the output, while ␊ |
1142 | * replacing any alias commands found in the string.␊ |
1143 | */␊ |
1144 | static void replaceAliases(const char *s)␊ |
1145 | {␊ |
1146 | QCString result = resolveAliasCmd(s);␊ |
1147 | //printf("replaceAliases(%s)->'%s'\n",s,result.data());␊ |
1148 | copyToOutput(result,result.length());␊ |
1149 | }␊ |
1150 | ␊ |
1151 | ␊ |
1152 | #undef YY_INPUT␊ |
1153 | #define YY_INPUT(buf,result,max_size) result=yyread(buf,max_size);␊ |
1154 | ␊ |
1155 | static int yyread(char *buf,int max_size)␊ |
1156 | {␊ |
1157 | int bytesInBuf = g_inBuf->curPos()-g_inBufPos;␊ |
1158 | int bytesToCopy = QMIN(max_size,bytesInBuf);␊ |
1159 | memcpy(buf,g_inBuf->data()+g_inBufPos,bytesToCopy);␊ |
1160 | g_inBufPos+=bytesToCopy;␊ |
1161 | return bytesToCopy;␊ |
1162 | }␊ |
1163 | ␊ |
1164 | void replaceComment(int offset);␊ |
1165 | ␊ |
1166 | ␊ |
1167 | ␊ |
1168 | ␊ |
1169 | ␊ |
1170 | ␊ |
1171 | ␊ |
1172 | ␊ |
1173 | ␊ |
1174 | ␊ |
1175 | ␊ |
1176 | #line 1177 "<stdout>"␊ |
1177 | ␊ |
1178 | #define INITIAL 0␊ |
1179 | #define Scan 1␊ |
1180 | #define SkipString 2␊ |
1181 | #define SkipChar 3␊ |
1182 | #define SComment 4␊ |
1183 | #define CComment 5␊ |
1184 | #define Verbatim 6␊ |
1185 | #define VerbatimCode 7␊ |
1186 | #define ReadLine 8␊ |
1187 | #define CondLine 9␊ |
1188 | #define ReadAliasArgs 10␊ |
1189 | ␊ |
1190 | #ifndef YY_NO_UNISTD_H␊ |
1191 | /* Special case for "unistd.h", since it is non-ANSI. We include it way␊ |
1192 | * down here because we want the user's section 1 to have been scanned first.␊ |
1193 | * The user has a chance to override it with an option.␊ |
1194 | */␊ |
1195 | #include <unistd.h>␊ |
1196 | #endif␊ |
1197 | ␊ |
1198 | #ifndef YY_EXTRA_TYPE␊ |
1199 | #define YY_EXTRA_TYPE void *␊ |
1200 | #endif␊ |
1201 | ␊ |
1202 | static int yy_init_globals (void );␊ |
1203 | ␊ |
1204 | /* Accessor methods to globals.␊ |
1205 | These are made visible to non-reentrant scanners for convenience. */␊ |
1206 | ␊ |
1207 | int commentcnvYYlex_destroy (void );␊ |
1208 | ␊ |
1209 | int commentcnvYYget_debug (void );␊ |
1210 | ␊ |
1211 | void commentcnvYYset_debug (int debug_flag );␊ |
1212 | ␊ |
1213 | YY_EXTRA_TYPE commentcnvYYget_extra (void );␊ |
1214 | ␊ |
1215 | void commentcnvYYset_extra (YY_EXTRA_TYPE user_defined );␊ |
1216 | ␊ |
1217 | FILE *commentcnvYYget_in (void );␊ |
1218 | ␊ |
1219 | void commentcnvYYset_in (FILE * in_str );␊ |
1220 | ␊ |
1221 | FILE *commentcnvYYget_out (void );␊ |
1222 | ␊ |
1223 | void commentcnvYYset_out (FILE * out_str );␊ |
1224 | ␊ |
1225 | yy_size_t commentcnvYYget_leng (void );␊ |
1226 | ␊ |
1227 | char *commentcnvYYget_text (void );␊ |
1228 | ␊ |
1229 | int commentcnvYYget_lineno (void );␊ |
1230 | ␊ |
1231 | void commentcnvYYset_lineno (int line_number );␊ |
1232 | ␊ |
1233 | /* Macros after this point can all be overridden by user definitions in␊ |
1234 | * section 1.␊ |
1235 | */␊ |
1236 | ␊ |
1237 | #ifndef YY_SKIP_YYWRAP␊ |
1238 | #ifdef __cplusplus␊ |
1239 | extern "C" int commentcnvYYwrap (void );␊ |
1240 | #else␊ |
1241 | extern int commentcnvYYwrap (void );␊ |
1242 | #endif␊ |
1243 | #endif␊ |
1244 | ␊ |
1245 | static void yyunput (int c,char *buf_ptr );␊ |
1246 | ␊ |
1247 | #ifndef yytext_ptr␊ |
1248 | static void yy_flex_strncpy (char *,yyconst char *,int );␊ |
1249 | #endif␊ |
1250 | ␊ |
1251 | #ifdef YY_NEED_STRLEN␊ |
1252 | static int yy_flex_strlen (yyconst char * );␊ |
1253 | #endif␊ |
1254 | ␊ |
1255 | #ifndef YY_NO_INPUT␊ |
1256 | ␊ |
1257 | #ifdef __cplusplus␊ |
1258 | static int yyinput (void );␊ |
1259 | #else␊ |
1260 | static int input (void );␊ |
1261 | #endif␊ |
1262 | ␊ |
1263 | #endif␊ |
1264 | ␊ |
1265 | /* Amount of stuff to slurp up with each read. */␊ |
1266 | #ifndef YY_READ_BUF_SIZE␊ |
1267 | #define YY_READ_BUF_SIZE 262144␊ |
1268 | #endif␊ |
1269 | ␊ |
1270 | /* Copy whatever the last rule matched to the standard output. */␊ |
1271 | #ifndef ECHO␊ |
1272 | /* This used to be an fputs(), but since the string might contain NUL's,␊ |
1273 | * we now use fwrite().␊ |
1274 | */␊ |
1275 | #define ECHO fwrite( commentcnvYYtext, commentcnvYYleng, 1, commentcnvYYout )␊ |
1276 | #endif␊ |
1277 | ␊ |
1278 | /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,␊ |
1279 | * is returned in "result".␊ |
1280 | */␊ |
1281 | #ifndef YY_INPUT␊ |
1282 | #define YY_INPUT(buf,result,max_size) \␊ |
1283 | ␉if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \␊ |
1284 | ␉␉{ \␊ |
1285 | ␉␉int c = '*'; \␊ |
1286 | ␉␉yy_size_t n; \␊ |
1287 | ␉␉for ( n = 0; n < max_size && \␊ |
1288 | ␉␉␉ (c = getc( commentcnvYYin )) != EOF && c != '\n'; ++n ) \␊ |
1289 | ␉␉␉buf[n] = (char) c; \␊ |
1290 | ␉␉if ( c == '\n' ) \␊ |
1291 | ␉␉␉buf[n++] = (char) c; \␊ |
1292 | ␉␉if ( c == EOF && ferror( commentcnvYYin ) ) \␊ |
1293 | ␉␉␉YY_FATAL_ERROR( "input in flex scanner failed" ); \␊ |
1294 | ␉␉result = n; \␊ |
1295 | ␉␉} \␊ |
1296 | ␉else \␊ |
1297 | ␉␉{ \␊ |
1298 | ␉␉errno=0; \␊ |
1299 | ␉␉while ( (result = fread(buf, 1, max_size, commentcnvYYin))==0 && ferror(commentcnvYYin)) \␊ |
1300 | ␉␉␉{ \␊ |
1301 | ␉␉␉if( errno != EINTR) \␊ |
1302 | ␉␉␉␉{ \␊ |
1303 | ␉␉␉␉YY_FATAL_ERROR( "input in flex scanner failed" ); \␊ |
1304 | ␉␉␉␉break; \␊ |
1305 | ␉␉␉␉} \␊ |
1306 | ␉␉␉errno=0; \␊ |
1307 | ␉␉␉clearerr(commentcnvYYin); \␊ |
1308 | ␉␉␉} \␊ |
1309 | ␉␉}\␊ |
1310 | \␊ |
1311 | ␊ |
1312 | #endif␊ |
1313 | ␊ |
1314 | /* No semi-colon after return; correct usage is to write "yyterminate();" -␊ |
1315 | * we don't want an extra ';' after the "return" because that will cause␊ |
1316 | * some compilers to complain about unreachable statements.␊ |
1317 | */␊ |
1318 | #ifndef yyterminate␊ |
1319 | #define yyterminate() return YY_NULL␊ |
1320 | #endif␊ |
1321 | ␊ |
1322 | /* Number of entries by which start-condition stack grows. */␊ |
1323 | #ifndef YY_START_STACK_INCR␊ |
1324 | #define YY_START_STACK_INCR 25␊ |
1325 | #endif␊ |
1326 | ␊ |
1327 | /* Report a fatal error. */␊ |
1328 | #ifndef YY_FATAL_ERROR␊ |
1329 | #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )␊ |
1330 | #endif␊ |
1331 | ␊ |
1332 | /* end tables serialization structures and prototypes */␊ |
1333 | ␊ |
1334 | /* Default declaration of generated scanner - a define so the user can␊ |
1335 | * easily add parameters.␊ |
1336 | */␊ |
1337 | #ifndef YY_DECL␊ |
1338 | #define YY_DECL_IS_OURS 1␊ |
1339 | ␊ |
1340 | extern int commentcnvYYlex (void);␊ |
1341 | ␊ |
1342 | #define YY_DECL int commentcnvYYlex (void)␊ |
1343 | #endif /* !YY_DECL */␊ |
1344 | ␊ |
1345 | /* Code executed at the beginning of each rule, after commentcnvYYtext and commentcnvYYleng␊ |
1346 | * have been set up.␊ |
1347 | */␊ |
1348 | #ifndef YY_USER_ACTION␊ |
1349 | #define YY_USER_ACTION␊ |
1350 | #endif␊ |
1351 | ␊ |
1352 | /* Code executed at the end of each rule. */␊ |
1353 | #ifndef YY_BREAK␊ |
1354 | #define YY_BREAK break;␊ |
1355 | #endif␊ |
1356 | ␊ |
1357 | #define YY_RULE_SETUP \␊ |
1358 | ␉if ( commentcnvYYleng > 0 ) \␊ |
1359 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_at_bol = \␊ |
1360 | ␉␉␉␉(commentcnvYYtext[commentcnvYYleng - 1] == '\n'); \␊ |
1361 | ␉YY_USER_ACTION␊ |
1362 | ␊ |
1363 | /** The main scanner function which does all the work.␊ |
1364 | */␊ |
1365 | YY_DECL␊ |
1366 | {␊ |
1367 | ␉register yy_state_type yy_current_state;␊ |
1368 | ␉register char *yy_cp, *yy_bp;␊ |
1369 | ␉register int yy_act;␊ |
1370 | ␊ |
1371 | #line 283 "commentcnv.l"␊ |
1372 | ␊ |
1373 | ␊ |
1374 | #line 1375 "<stdout>"␊ |
1375 | ␊ |
1376 | ␉if ( !(yy_init) )␊ |
1377 | ␉␉{␊ |
1378 | ␉␉(yy_init) = 1;␊ |
1379 | ␊ |
1380 | #ifdef YY_USER_INIT␊ |
1381 | ␉␉YY_USER_INIT;␊ |
1382 | #endif␊ |
1383 | ␊ |
1384 | /* Create the reject buffer large enough to save one state per allowed character. */␊ |
1385 | if ( ! (yy_state_buf) )␊ |
1386 | (yy_state_buf) = (yy_state_type *)commentcnvYYalloc(YY_STATE_BUF_SIZE );␊ |
1387 | if ( ! (yy_state_buf) )␊ |
1388 | YY_FATAL_ERROR( "out of dynamic memory in commentcnvYYlex()" );␊ |
1389 | ␊ |
1390 | ␉␉if ( ! (yy_start) )␊ |
1391 | ␉␉␉(yy_start) = 1;␉/* first start state */␊ |
1392 | ␊ |
1393 | ␉␉if ( ! commentcnvYYin )␊ |
1394 | ␉␉␉commentcnvYYin = stdin;␊ |
1395 | ␊ |
1396 | ␉␉if ( ! commentcnvYYout )␊ |
1397 | ␉␉␉commentcnvYYout = stdout;␊ |
1398 | ␊ |
1399 | ␉␉if ( ! YY_CURRENT_BUFFER ) {␊ |
1400 | ␉␉␉commentcnvYYensure_buffer_stack ();␊ |
1401 | ␉␉␉YY_CURRENT_BUFFER_LVALUE =␊ |
1402 | ␉␉␉␉commentcnvYY_create_buffer(commentcnvYYin,YY_BUF_SIZE );␊ |
1403 | ␉␉}␊ |
1404 | ␊ |
1405 | ␉␉commentcnvYY_load_buffer_state( );␊ |
1406 | ␉␉}␊ |
1407 | ␊ |
1408 | ␉while ( 1 )␉␉/* loops until end-of-file is reached */␊ |
1409 | ␉␉{␊ |
1410 | ␉␉yy_cp = (yy_c_buf_p);␊ |
1411 | ␊ |
1412 | ␉␉/* Support of commentcnvYYtext. */␊ |
1413 | ␉␉*yy_cp = (yy_hold_char);␊ |
1414 | ␊ |
1415 | ␉␉/* yy_bp points to the position in yy_ch_buf of the start of␊ |
1416 | ␉␉ * the current run.␊ |
1417 | ␉␉ */␊ |
1418 | ␉␉yy_bp = yy_cp;␊ |
1419 | ␊ |
1420 | ␉␉yy_current_state = (yy_start);␊ |
1421 | ␉␉yy_current_state += YY_AT_BOL();␊ |
1422 | ␊ |
1423 | ␉␉(yy_state_ptr) = (yy_state_buf);␊ |
1424 | ␉␉*(yy_state_ptr)++ = yy_current_state;␊ |
1425 | ␊ |
1426 | yy_match:␊ |
1427 | ␉␉do␊ |
1428 | ␉␉␉{␊ |
1429 | ␉␉␉register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];␊ |
1430 | ␉␉␉while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )␊ |
1431 | ␉␉␉␉{␊ |
1432 | ␉␉␉␉yy_current_state = (int) yy_def[yy_current_state];␊ |
1433 | ␉␉␉␉if ( yy_current_state >= 329 )␊ |
1434 | ␉␉␉␉␉yy_c = yy_meta[(unsigned int) yy_c];␊ |
1435 | ␉␉␉␉}␊ |
1436 | ␉␉␉yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];␊ |
1437 | ␉␉␉*(yy_state_ptr)++ = yy_current_state;␊ |
1438 | ␉␉␉++yy_cp;␊ |
1439 | ␉␉␉}␊ |
1440 | ␉␉while ( yy_base[yy_current_state] != 1157 );␊ |
1441 | ␊ |
1442 | yy_find_action:␊ |
1443 | ␉␉yy_current_state = *--(yy_state_ptr);␊ |
1444 | ␉␉(yy_lp) = yy_accept[yy_current_state];␊ |
1445 | goto find_rule; /* Shut up GCC warning -Wall */␊ |
1446 | find_rule: /* we branch to this label when backing up */␊ |
1447 | ␉␉for ( ; ; ) /* until we find what rule we matched */␊ |
1448 | ␉␉␉{␊ |
1449 | ␉␉␉if ( (yy_lp) && (yy_lp) < yy_accept[yy_current_state + 1] )␊ |
1450 | ␉␉␉␉{␊ |
1451 | ␉␉␉␉yy_act = yy_acclist[(yy_lp)];␊ |
1452 | ␉␉␉␉if ( yy_act & YY_TRAILING_HEAD_MASK ||␊ |
1453 | ␉␉␉␉ (yy_looking_for_trail_begin) )␊ |
1454 | ␉␉␉␉␉{␊ |
1455 | ␉␉␉␉␉if ( yy_act == (yy_looking_for_trail_begin) )␊ |
1456 | ␉␉␉␉␉␉{␊ |
1457 | ␉␉␉␉␉␉(yy_looking_for_trail_begin) = 0;␊ |
1458 | ␉␉␉␉␉␉yy_act &= ~YY_TRAILING_HEAD_MASK;␊ |
1459 | ␉␉␉␉␉␉break;␊ |
1460 | ␉␉␉␉␉␉}␊ |
1461 | ␉␉␉␉␉}␊ |
1462 | ␉␉␉␉else if ( yy_act & YY_TRAILING_MASK )␊ |
1463 | ␉␉␉␉␉{␊ |
1464 | ␉␉␉␉␉(yy_looking_for_trail_begin) = yy_act & ~YY_TRAILING_MASK;␊ |
1465 | ␉␉␉␉␉(yy_looking_for_trail_begin) |= YY_TRAILING_HEAD_MASK;␊ |
1466 | ␉␉␉␉␉(yy_full_match) = yy_cp;␊ |
1467 | ␉␉␉␉␉(yy_full_state) = (yy_state_ptr);␊ |
1468 | ␉␉␉␉␉(yy_full_lp) = (yy_lp);␊ |
1469 | ␉␉␉␉␉}␊ |
1470 | ␉␉␉␉else␊ |
1471 | ␉␉␉␉␉{␊ |
1472 | ␉␉␉␉␉(yy_full_match) = yy_cp;␊ |
1473 | ␉␉␉␉␉(yy_full_state) = (yy_state_ptr);␊ |
1474 | ␉␉␉␉␉(yy_full_lp) = (yy_lp);␊ |
1475 | ␉␉␉␉␉break;␊ |
1476 | ␉␉␉␉␉}␊ |
1477 | ␉␉␉␉++(yy_lp);␊ |
1478 | ␉␉␉␉goto find_rule;␊ |
1479 | ␉␉␉␉}␊ |
1480 | ␉␉␉--yy_cp;␊ |
1481 | ␉␉␉yy_current_state = *--(yy_state_ptr);␊ |
1482 | ␉␉␉(yy_lp) = yy_accept[yy_current_state];␊ |
1483 | ␉␉␉}␊ |
1484 | ␊ |
1485 | ␉␉YY_DO_BEFORE_ACTION;␊ |
1486 | ␊ |
1487 | do_action:␉/* This label is used only to access EOF actions. */␊ |
1488 | ␊ |
1489 | ␉␉switch ( yy_act )␊ |
1490 | ␉{ /* beginning of action switch */␊ |
1491 | case 1:␊ |
1492 | YY_RULE_SETUP␊ |
1493 | #line 285 "commentcnv.l"␊ |
1494 | { /* eat anything that is not " / or \n */ ␊ |
1495 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1496 | ␉␉␉␉ }␊ |
1497 | ␉YY_BREAK␊ |
1498 | case 2:␊ |
1499 | YY_RULE_SETUP␊ |
1500 | #line 288 "commentcnv.l"␊ |
1501 | { /* start of python long comment */␊ |
1502 | if (g_lang!=SrcLangExt_Python)␊ |
1503 | ␉␉␉␉ {␊ |
1504 | ␉␉␉␉ REJECT;␊ |
1505 | ␉␉␉␉ }␊ |
1506 | ␉␉␉␉ else␊ |
1507 | ␉␉␉␉ {␊ |
1508 | g_pythonDocString = TRUE;␊ |
1509 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1510 | ␉␉␉␉ BEGIN(CComment);␊ |
1511 | ␉␉␉␉ }␊ |
1512 | }␊ |
1513 | ␉YY_BREAK␊ |
1514 | case 3:␊ |
1515 | YY_RULE_SETUP␊ |
1516 | #line 300 "commentcnv.l"␊ |
1517 | {␊ |
1518 | ␉␉␉ if (g_lang!=SrcLangExt_F90)␊ |
1519 | ␉␉␉␉ {␊ |
1520 | ␉␉␉␉ REJECT;␊ |
1521 | ␉␉␉␉ }␊ |
1522 | ␉␉␉␉ else␊ |
1523 | ␉␉␉␉ {␊ |
1524 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1525 | ␉␉␉␉ BEGIN(CComment);␊ |
1526 | ␉␉␉␉ }␊ |
1527 | }␊ |
1528 | ␉YY_BREAK␊ |
1529 | case 4:␊ |
1530 | YY_RULE_SETUP␊ |
1531 | #line 311 "commentcnv.l"␊ |
1532 | { /* start of a string */ ␊ |
1533 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1534 | ␉␉␉␉ BEGIN(SkipString); ␊ |
1535 | }␊ |
1536 | ␉YY_BREAK␊ |
1537 | case 5:␊ |
1538 | YY_RULE_SETUP␊ |
1539 | #line 315 "commentcnv.l"␊ |
1540 | {␊ |
1541 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1542 | ␉␉␉␉ BEGIN(SkipChar);␊ |
1543 | ␉␉␉␉ }␊ |
1544 | ␉YY_BREAK␊ |
1545 | case 6:␊ |
1546 | /* rule 6 can match eol */␊ |
1547 | YY_RULE_SETUP␊ |
1548 | #line 319 "commentcnv.l"␊ |
1549 | { /* new line */ ␊ |
1550 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1551 | }␊ |
1552 | ␉YY_BREAK␊ |
1553 | case 7:␊ |
1554 | /* rule 7 can match eol */␊ |
1555 | YY_RULE_SETUP␊ |
1556 | #line 322 "commentcnv.l"␊ |
1557 | { /* start C++ style special comment block */␊ |
1558 | ␉␉␉␉ if (g_mlBrief) ␊ |
1559 | ␉␉␉␉ {␊ |
1560 | ␉␉␉␉ REJECT; // bail out if we do not need to convert␊ |
1561 | ␉␉␉␉ }␊ |
1562 | ␉␉␉␉ else␊ |
1563 | ␉␉␉␉ {␊ |
1564 | ␉␉␉␉ int i=3;␊ |
1565 | ␉␉␉␉ if (commentcnvYYtext[2]=='/')␊ |
1566 | ␉␉␉␉ {␊ |
1567 | ␉␉␉␉␉ while (i<(int)commentcnvYYleng && commentcnvYYtext[i]=='/') i++;␊ |
1568 | ␉␉␉␉ }␊ |
1569 | ␉␉␉␉ g_blockHeadCol=g_col;␊ |
1570 | ␉␉␉␉ copyToOutput("/**",3); ␊ |
1571 | ␉␉␉␉ replaceAliases(commentcnvYYtext+i);␊ |
1572 | ␉␉␉␉ g_inSpecialComment=TRUE;␊ |
1573 | ␉␉␉␉ BEGIN(SComment); ␊ |
1574 | ␉␉␉␉ }␊ |
1575 | }␊ |
1576 | ␉YY_BREAK␊ |
1577 | case 8:␊ |
1578 | /* rule 8 can match eol */␊ |
1579 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1580 | (yy_c_buf_p) = yy_cp -= 1;␊ |
1581 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1582 | YY_RULE_SETUP␊ |
1583 | #line 341 "commentcnv.l"␊ |
1584 | { /* Start of Rational Rose ANSI C++ comment block */␊ |
1585 | if (g_mlBrief) REJECT;␊ |
1586 | int i=17; //=strlen("//##Documentation");␊ |
1587 | ␉␉␉␉ g_blockHeadCol=g_col;␊ |
1588 | ␉␉␉␉ copyToOutput("/**",3);␊ |
1589 | ␉␉␉␉ replaceAliases(commentcnvYYtext+i);␊ |
1590 | ␉␉␉␉ g_inRoseComment=TRUE;␊ |
1591 | ␉␉␉␉ BEGIN(SComment);␊ |
1592 | ␉␉␉␉ }␊ |
1593 | ␉YY_BREAK␊ |
1594 | case 9:␊ |
1595 | /* rule 9 can match eol */␊ |
1596 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1597 | (yy_c_buf_p) = yy_cp = yy_bp + 2;␊ |
1598 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1599 | YY_RULE_SETUP␊ |
1600 | #line 350 "commentcnv.l"␊ |
1601 | { /* one line C++ comment */ ␊ |
1602 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1603 | ␉␉␉␉ g_readLineCtx=YY_START;␊ |
1604 | ␉␉␉␉ BEGIN(ReadLine);␊ |
1605 | ␉␉␉␉ }␊ |
1606 | ␉YY_BREAK␊ |
1607 | case 10:␊ |
1608 | YY_RULE_SETUP␊ |
1609 | #line 355 "commentcnv.l"␊ |
1610 | { /* start of a C comment */␊ |
1611 | ␉␉␉ g_specialComment=commentcnvYYleng==3;␊ |
1612 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1613 | ␉␉␉␉ BEGIN(CComment); ␊ |
1614 | }␊ |
1615 | ␉YY_BREAK␊ |
1616 | case 11:␊ |
1617 | YY_RULE_SETUP␊ |
1618 | #line 360 "commentcnv.l"␊ |
1619 | {␊ |
1620 | if (g_lang!=SrcLangExt_Python)␊ |
1621 | ␉␉␉␉ {␊ |
1622 | ␉␉␉␉ REJECT;␊ |
1623 | ␉␉␉␉ }␊ |
1624 | ␉␉␉␉ else␊ |
1625 | ␉␉␉␉ {␊ |
1626 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1627 | ␉␉␉␉ BEGIN(CComment);␊ |
1628 | ␉␉␉␉ }␊ |
1629 | ␉␉␉␉ }␊ |
1630 | ␉YY_BREAK␊ |
1631 | case 12:␊ |
1632 | YY_RULE_SETUP␊ |
1633 | #line 371 "commentcnv.l"␊ |
1634 | {␊ |
1635 | if (g_lang!=SrcLangExt_VHDL)␊ |
1636 | ␉␉␉␉ {␊ |
1637 | ␉␉␉␉ REJECT;␊ |
1638 | ␉␉␉␉ }␊ |
1639 | ␉␉␉␉ else␊ |
1640 | ␉␉␉␉ {␊ |
1641 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1642 | ␉␉␉␉ BEGIN(CComment);␊ |
1643 | ␉␉␉␉ }␊ |
1644 | ␉␉␉␉ }␊ |
1645 | ␉YY_BREAK␊ |
1646 | case 13:␊ |
1647 | YY_RULE_SETUP␊ |
1648 | #line 382 "commentcnv.l"␊ |
1649 | {␊ |
1650 | if (g_lang!=SrcLangExt_F90)␊ |
1651 | ␉␉␉␉ {␊ |
1652 | ␉␉␉␉ REJECT;␊ |
1653 | ␉␉␉␉ }␊ |
1654 | ␉␉␉␉ else␊ |
1655 | ␉␉␉␉ {␊ |
1656 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1657 | ␉␉␉␉ BEGIN(CComment);␊ |
1658 | ␉␉␉␉ }␊ |
1659 | ␉␉␉␉ }␊ |
1660 | ␉YY_BREAK␊ |
1661 | case 14:␊ |
1662 | /* rule 14 can match eol */␊ |
1663 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1664 | (yy_c_buf_p) = yy_cp = yy_bp + 6;␊ |
1665 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1666 | YY_RULE_SETUP␊ |
1667 | #line 393 "commentcnv.l"␊ |
1668 | {␊ |
1669 | copyToOutput("@code",5); ␊ |
1670 | ␉␉␉␉ g_lastCommentContext = YY_START;␊ |
1671 | ␉␉␉␉ g_javaBlock=1;␊ |
1672 | ␉␉␉␉ g_blockName=&commentcnvYYtext[1];␊ |
1673 | BEGIN(VerbatimCode);␊ |
1674 | ␉␉␉␉ }␊ |
1675 | ␉YY_BREAK␊ |
1676 | case 15:␊ |
1677 | /* rule 15 can match eol */␊ |
1678 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1679 | (yy_c_buf_p) = yy_cp -= 1;␊ |
1680 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1681 | YY_RULE_SETUP␊ |
1682 | #line 400 "commentcnv.l"␊ |
1683 | { /* start of a verbatim block */␊ |
1684 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1685 | ␉␉␉␉ g_lastCommentContext = YY_START;␊ |
1686 | ␉␉␉␉ g_javaBlock=0;␊ |
1687 | ␉␉␉␉ g_blockName=&commentcnvYYtext[1];␊ |
1688 | BEGIN(VerbatimCode);␊ |
1689 | ␉␉␉␉ }␊ |
1690 | ␉YY_BREAK␊ |
1691 | case 16:␊ |
1692 | YY_RULE_SETUP␊ |
1693 | #line 407 "commentcnv.l"␊ |
1694 | {␊ |
1695 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1696 | ␉␉␉␉ g_blockName=&commentcnvYYtext[1];␊ |
1697 | ␉␉␉␉ if (g_blockName.at(1)=='[')␊ |
1698 | ␉␉␉␉ {␊ |
1699 | ␉␉␉␉ g_blockName.at(1)=']';␊ |
1700 | ␉␉␉␉ }␊ |
1701 | ␉␉␉␉ else if (g_blockName.at(1)=='{')␊ |
1702 | ␉␉␉␉ {␊ |
1703 | ␉␉␉␉ g_blockName.at(1)='}';␊ |
1704 | ␉␉␉␉ }␊ |
1705 | ␉␉␉␉ g_lastCommentContext = YY_START;␊ |
1706 | ␉␉␉␉ BEGIN(Verbatim);␊ |
1707 | ␉␉␉ }␊ |
1708 | ␉YY_BREAK␊ |
1709 | case 17:␊ |
1710 | /* rule 17 can match eol */␊ |
1711 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1712 | (yy_c_buf_p) = yy_cp -= 1;␊ |
1713 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1714 | YY_RULE_SETUP␊ |
1715 | #line 421 "commentcnv.l"␊ |
1716 | { /* start of a verbatim block */␊ |
1717 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1718 | ␉␉␉␉ g_blockName=&commentcnvYYtext[1];␊ |
1719 | ␉␉␉␉ g_lastCommentContext = YY_START;␊ |
1720 | BEGIN(Verbatim);␊ |
1721 | }␊ |
1722 | ␉YY_BREAK␊ |
1723 | case 18:␊ |
1724 | YY_RULE_SETUP␊ |
1725 | #line 427 "commentcnv.l"␊ |
1726 | { /* any other character */␊ |
1727 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1728 | }␊ |
1729 | ␉YY_BREAK␊ |
1730 | case 19:␊ |
1731 | YY_RULE_SETUP␊ |
1732 | #line 430 "commentcnv.l"␊ |
1733 | { /* end of verbatim block */␊ |
1734 | copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1735 | ␉␉␉␉ if (commentcnvYYtext[1]=='f') // end of formula␊ |
1736 | ␉␉␉␉ {␊ |
1737 | ␉␉␉␉ BEGIN(g_lastCommentContext);␊ |
1738 | ␉␉␉␉ }␊ |
1739 | ␉␉␉␉ else if (&commentcnvYYtext[4]==g_blockName)␊ |
1740 | ␉␉␉␉ {␊ |
1741 | ␉␉␉␉ BEGIN(g_lastCommentContext);␊ |
1742 | ␉␉␉␉ }␊ |
1743 | }␊ |
1744 | ␉YY_BREAK␊ |
1745 | case 20:␊ |
1746 | YY_RULE_SETUP␊ |
1747 | #line 441 "commentcnv.l"␊ |
1748 | {␊ |
1749 | if (g_javaBlock==0)␊ |
1750 | ␉␉␉␉ {␊ |
1751 | ␉␉␉␉ REJECT;␊ |
1752 | ␉␉␉␉ }␊ |
1753 | ␉␉␉␉ else␊ |
1754 | ␉␉␉␉ {␊ |
1755 | ␉␉␉␉ g_javaBlock++;␊ |
1756 | copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1757 | ␉␉␉␉ }␊ |
1758 | }␊ |
1759 | ␉YY_BREAK␊ |
1760 | case 21:␊ |
1761 | YY_RULE_SETUP␊ |
1762 | #line 452 "commentcnv.l"␊ |
1763 | {␊ |
1764 | if (g_javaBlock==0)␊ |
1765 | ␉␉␉␉ {␊ |
1766 | ␉␉␉␉ REJECT;␊ |
1767 | ␉␉␉␉ }␊ |
1768 | ␉␉␉␉ else␊ |
1769 | ␉␉␉␉ {␊ |
1770 | ␉␉␉␉ g_javaBlock--;␊ |
1771 | ␉␉␉␉ if (g_javaBlock==0)␊ |
1772 | ␉␉␉␉ {␊ |
1773 | copyToOutput(" @endcode ",10);␊ |
1774 | ␉␉␉␉ BEGIN(g_lastCommentContext);␊ |
1775 | ␉␉␉␉ }␊ |
1776 | ␉␉␉␉ else␊ |
1777 | ␉␉␉␉ {␊ |
1778 | copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1779 | ␉␉␉␉ }␊ |
1780 | ␉␉␉␉ }␊ |
1781 | ␉␉␉␉ }␊ |
1782 | ␉YY_BREAK␊ |
1783 | case 22:␊ |
1784 | YY_RULE_SETUP␊ |
1785 | #line 471 "commentcnv.l"␊ |
1786 | { /* end of verbatim block */␊ |
1787 | copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1788 | ␉␉␉␉ if (&commentcnvYYtext[4]==g_blockName)␊ |
1789 | ␉␉␉␉ {␊ |
1790 | ␉␉␉␉ BEGIN(g_lastCommentContext);␊ |
1791 | ␉␉␉␉ }␊ |
1792 | }␊ |
1793 | ␉YY_BREAK␊ |
1794 | case 23:␊ |
1795 | YY_RULE_SETUP␊ |
1796 | #line 478 "commentcnv.l"␊ |
1797 | { /* skip leading comments */␊ |
1798 | ␉␉␉␉ if (!g_inSpecialComment)␊ |
1799 | ␉␉␉␉ {␊ |
1800 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1801 | ␉␉␉␉ }␊ |
1802 | ␉␉␉␉ }␊ |
1803 | ␉YY_BREAK␊ |
1804 | case 24:␊ |
1805 | YY_RULE_SETUP␊ |
1806 | #line 484 "commentcnv.l"␊ |
1807 | { /* any character not a backslash or new line or } */␊ |
1808 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1809 | }␊ |
1810 | ␉YY_BREAK␊ |
1811 | case 25:␊ |
1812 | /* rule 25 can match eol */␊ |
1813 | YY_RULE_SETUP␊ |
1814 | #line 487 "commentcnv.l"␊ |
1815 | { /* new line in verbatim block */␊ |
1816 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1817 | }␊ |
1818 | ␉YY_BREAK␊ |
1819 | case 26:␊ |
1820 | YY_RULE_SETUP␊ |
1821 | #line 490 "commentcnv.l"␊ |
1822 | {␊ |
1823 | ␉␉␉␉ if (g_blockName=="dot" || g_blockName=="msc" || g_blockName.at(0)=='f')␊ |
1824 | ␉␉␉␉ {␊ |
1825 | ␉␉␉␉ // see bug 487871, strip /// from dot images and formulas.␊ |
1826 | ␉␉␉␉ copyToOutput(" ",3);␊ |
1827 | ␉␉␉␉ }␊ |
1828 | ␉␉␉␉ else // even slashes are verbatim (e.g. \verbatim, \code)␊ |
1829 | ␉␉␉␉ {␊ |
1830 | ␉␉␉␉ REJECT;␊ |
1831 | ␉␉␉␉ }␊ |
1832 | ␉␉␉␉ }␊ |
1833 | ␉YY_BREAK␊ |
1834 | case 27:␊ |
1835 | YY_RULE_SETUP␊ |
1836 | #line 501 "commentcnv.l"␊ |
1837 | { /* any other character */␊ |
1838 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1839 | }␊ |
1840 | ␉YY_BREAK␊ |
1841 | case 28:␊ |
1842 | YY_RULE_SETUP␊ |
1843 | #line 504 "commentcnv.l"␊ |
1844 | { /* escaped character in string */␊ |
1845 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1846 | }␊ |
1847 | ␉YY_BREAK␊ |
1848 | case 29:␊ |
1849 | YY_RULE_SETUP␊ |
1850 | #line 507 "commentcnv.l"␊ |
1851 | { /* end of string */ ␊ |
1852 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1853 | ␉␉␉␉ BEGIN(Scan); ␊ |
1854 | }␊ |
1855 | ␉YY_BREAK␊ |
1856 | case 30:␊ |
1857 | YY_RULE_SETUP␊ |
1858 | #line 511 "commentcnv.l"␊ |
1859 | { /* any other string character */ ␊ |
1860 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1861 | }␊ |
1862 | ␉YY_BREAK␊ |
1863 | case 31:␊ |
1864 | /* rule 31 can match eol */␊ |
1865 | YY_RULE_SETUP␊ |
1866 | #line 514 "commentcnv.l"␊ |
1867 | { /* new line inside string (illegal for some compilers) */ ␊ |
1868 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1869 | }␊ |
1870 | ␉YY_BREAK␊ |
1871 | case 32:␊ |
1872 | YY_RULE_SETUP␊ |
1873 | #line 517 "commentcnv.l"␊ |
1874 | { /* escaped character */␊ |
1875 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1876 | }␊ |
1877 | ␉YY_BREAK␊ |
1878 | case 33:␊ |
1879 | YY_RULE_SETUP␊ |
1880 | #line 520 "commentcnv.l"␊ |
1881 | { /* end of character literal */ ␊ |
1882 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1883 | BEGIN(Scan);␊ |
1884 | }␊ |
1885 | ␉YY_BREAK␊ |
1886 | case 34:␊ |
1887 | YY_RULE_SETUP␊ |
1888 | #line 524 "commentcnv.l"␊ |
1889 | { /* any other string character */ ␊ |
1890 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1891 | }␊ |
1892 | ␉YY_BREAK␊ |
1893 | case 35:␊ |
1894 | /* rule 35 can match eol */␊ |
1895 | YY_RULE_SETUP␊ |
1896 | #line 527 "commentcnv.l"␊ |
1897 | { /* new line character */␊ |
1898 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1899 | }␊ |
1900 | ␉YY_BREAK␊ |
1901 | case 36:␊ |
1902 | YY_RULE_SETUP␊ |
1903 | #line 531 "commentcnv.l"␊ |
1904 | { /* anything that is not a '*' or command */ ␊ |
1905 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1906 | }␊ |
1907 | ␉YY_BREAK␊ |
1908 | case 37:␊ |
1909 | YY_RULE_SETUP␊ |
1910 | #line 534 "commentcnv.l"␊ |
1911 | { /* stars without slashes */␊ |
1912 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1913 | }␊ |
1914 | ␉YY_BREAK␊ |
1915 | case 38:␊ |
1916 | YY_RULE_SETUP␊ |
1917 | #line 537 "commentcnv.l"␊ |
1918 | { /* end of Python docstring */␊ |
1919 | if (g_lang!=SrcLangExt_Python)␊ |
1920 | ␉␉␉␉ {␊ |
1921 | ␉␉␉␉ REJECT;␊ |
1922 | ␉␉␉␉ }␊ |
1923 | ␉␉␉␉ else␊ |
1924 | ␉␉␉␉ {␊ |
1925 | g_pythonDocString = FALSE;␊ |
1926 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1927 | ␉␉␉␉ BEGIN(Scan);␊ |
1928 | ␉␉␉␉ }␊ |
1929 | ␉␉␉␉ }␊ |
1930 | ␉YY_BREAK␊ |
1931 | case 39:␊ |
1932 | /* rule 39 can match eol */␊ |
1933 | YY_RULE_SETUP␊ |
1934 | #line 549 "commentcnv.l"␊ |
1935 | { /* new line in comment */␊ |
1936 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
1937 | }␊ |
1938 | ␉YY_BREAK␊ |
1939 | case 40:␊ |
1940 | YY_RULE_SETUP␊ |
1941 | #line 552 "commentcnv.l"␊ |
1942 | { /* end of C comment */␊ |
1943 | if (g_lang==SrcLangExt_Python)␊ |
1944 | ␉␉␉␉ {␊ |
1945 | ␉␉␉␉ REJECT;␊ |
1946 | ␉␉␉␉ }␊ |
1947 | ␉␉␉␉ else␊ |
1948 | ␉␉␉␉ {␊ |
1949 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1950 | ␉␉␉␉ BEGIN(Scan);␊ |
1951 | ␉␉␉␉ }␊ |
1952 | }␊ |
1953 | ␉YY_BREAK␊ |
1954 | case 41:␊ |
1955 | /* rule 41 can match eol */␊ |
1956 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1957 | (yy_c_buf_p) = yy_cp = yy_bp + 1;␊ |
1958 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1959 | YY_RULE_SETUP␊ |
1960 | #line 563 "commentcnv.l"␊ |
1961 | { /* end of Python comment */␊ |
1962 | if (g_lang!=SrcLangExt_Python || g_pythonDocString)␊ |
1963 | ␉␉␉␉ {␊ |
1964 | ␉␉␉␉ REJECT;␊ |
1965 | ␉␉␉␉ }␊ |
1966 | ␉␉␉␉ else␊ |
1967 | ␉␉␉␉ {␊ |
1968 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1969 | ␉␉␉␉ BEGIN(Scan);␊ |
1970 | ␉␉␉␉ }␊ |
1971 | ␉␉␉␉ }␊ |
1972 | ␉YY_BREAK␊ |
1973 | case 42:␊ |
1974 | /* rule 42 can match eol */␊ |
1975 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1976 | (yy_c_buf_p) = yy_cp = yy_bp + 1;␊ |
1977 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1978 | YY_RULE_SETUP␊ |
1979 | #line 574 "commentcnv.l"␊ |
1980 | { /* end of VHDL comment */␊ |
1981 | if (g_lang!=SrcLangExt_VHDL)␊ |
1982 | ␉␉␉␉ {␊ |
1983 | ␉␉␉␉ REJECT;␊ |
1984 | ␉␉␉␉ }␊ |
1985 | ␉␉␉␉ else␊ |
1986 | ␉␉␉␉ {␊ |
1987 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
1988 | ␉␉␉␉ BEGIN(Scan);␊ |
1989 | ␉␉␉␉ }␊ |
1990 | ␉␉␉␉ }␊ |
1991 | ␉YY_BREAK␊ |
1992 | case 43:␊ |
1993 | /* rule 43 can match eol */␊ |
1994 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
1995 | (yy_c_buf_p) = yy_cp = yy_bp + 1;␊ |
1996 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
1997 | YY_RULE_SETUP␊ |
1998 | #line 585 "commentcnv.l"␊ |
1999 | { /* end of Fortran comment */␊ |
2000 | ␉␉␉␉ if (g_lang!=SrcLangExt_F90)␊ |
2001 | ␉␉␉␉ {␊ |
2002 | ␉␉␉␉ REJECT;␊ |
2003 | ␉␉␉␉ }␊ |
2004 | ␉␉␉␉ else␊ |
2005 | ␉␉␉␉ {␊ |
2006 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
2007 | ␉␉␉␉ BEGIN(Scan);␊ |
2008 | ␉␉␉␉ }␊ |
2009 | ␉␉␉␉ }␊ |
2010 | ␉YY_BREAK␊ |
2011 | case 44:␊ |
2012 | YY_RULE_SETUP␊ |
2013 | #line 596 "commentcnv.l"␊ |
2014 | {␊ |
2015 | copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
2016 | ␉␉␉␉ }␊ |
2017 | ␉YY_BREAK␊ |
2018 | case 45:␊ |
2019 | /* rule 45 can match eol */␊ |
2020 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
2021 | (yy_c_buf_p) = yy_cp -= 1;␊ |
2022 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
2023 | YY_RULE_SETUP␊ |
2024 | #line 599 "commentcnv.l"␊ |
2025 | {␊ |
2026 | ␉␉␉␉ replaceComment(0);␊ |
2027 | ␉␉␉␉ }␊ |
2028 | ␉YY_BREAK␊ |
2029 | case 46:␊ |
2030 | /* rule 46 can match eol */␊ |
2031 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
2032 | (yy_c_buf_p) = yy_cp -= 1;␊ |
2033 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
2034 | YY_RULE_SETUP␊ |
2035 | #line 602 "commentcnv.l"␊ |
2036 | {␊ |
2037 | replaceComment(1); ␊ |
2038 | }␊ |
2039 | ␉YY_BREAK␊ |
2040 | case 47:␊ |
2041 | /* rule 47 can match eol */␊ |
2042 | YY_RULE_SETUP␊ |
2043 | #line 605 "commentcnv.l"␊ |
2044 | { ␊ |
2045 | ␉␉␉␉ replaceComment(0);␊ |
2046 | ␉␉␉␉ g_readLineCtx=YY_START;␊ |
2047 | ␉␉␉␉ BEGIN(ReadLine);␊ |
2048 | ␉␉␉␉ }␊ |
2049 | ␉YY_BREAK␊ |
2050 | case 48:␊ |
2051 | /* rule 48 can match eol */␊ |
2052 | YY_RULE_SETUP␊ |
2053 | #line 610 "commentcnv.l"␊ |
2054 | { ␊ |
2055 | replaceComment(1); ␊ |
2056 | ␉␉␉␉ g_readLineCtx=YY_START;␊ |
2057 | ␉␉␉␉ BEGIN(ReadLine);␊ |
2058 | ␉␉␉␉ }␊ |
2059 | ␉YY_BREAK␊ |
2060 | case 49:␊ |
2061 | #line 616 "commentcnv.l"␊ |
2062 | case 50:␊ |
2063 | /* rule 50 can match eol */␊ |
2064 | #line 617 "commentcnv.l"␊ |
2065 | case 51:␊ |
2066 | /* rule 51 can match eol */␊ |
2067 | YY_RULE_SETUP␊ |
2068 | #line 617 "commentcnv.l"␊ |
2069 | { // or //!something␊ |
2070 | ␉␉␉␉ replaceComment(0);␊ |
2071 | ␉␉␉␉ g_readLineCtx=YY_START;␊ |
2072 | ␉␉␉␉ BEGIN(ReadLine);␊ |
2073 | }␊ |
2074 | ␉YY_BREAK␊ |
2075 | case 52:␊ |
2076 | /* rule 52 can match eol */␊ |
2077 | #line 623 "commentcnv.l"␊ |
2078 | case 53:␊ |
2079 | /* rule 53 can match eol */␊ |
2080 | #line 624 "commentcnv.l"␊ |
2081 | case 54:␊ |
2082 | /* rule 54 can match eol */␊ |
2083 | YY_RULE_SETUP␊ |
2084 | #line 624 "commentcnv.l"␊ |
2085 | { ␊ |
2086 | replaceComment(1); ␊ |
2087 | ␉␉␉␉ g_readLineCtx=YY_START;␊ |
2088 | ␉␉␉␉ BEGIN(ReadLine);␊ |
2089 | }␊ |
2090 | ␉YY_BREAK␊ |
2091 | case 55:␊ |
2092 | /* rule 55 can match eol */␊ |
2093 | YY_RULE_SETUP␊ |
2094 | #line 629 "commentcnv.l"␊ |
2095 | {␊ |
2096 | if (!g_inRoseComment)␊ |
2097 | ␉␉␉␉ {␊ |
2098 | ␉␉␉␉ REJECT;␊ |
2099 | ␉␉␉␉ }␊ |
2100 | ␉␉␉␉ else␊ |
2101 | ␉␉␉␉ {␊ |
2102 | ␉␉␉␉ replaceComment(0);␊ |
2103 | ␉␉␉␉ g_readLineCtx=YY_START;␊ |
2104 | ␉␉␉␉ BEGIN(ReadLine);␊ |
2105 | ␉␉␉␉ }␊ |
2106 | }␊ |
2107 | ␉YY_BREAK␊ |
2108 | case 56:␊ |
2109 | /* rule 56 can match eol */␊ |
2110 | YY_RULE_SETUP␊ |
2111 | #line 641 "commentcnv.l"␊ |
2112 | {␊ |
2113 | if (!g_inRoseComment)␊ |
2114 | ␉␉␉␉ {␊ |
2115 | ␉␉␉␉ REJECT;␊ |
2116 | ␉␉␉␉ }␊ |
2117 | ␉␉␉␉ else␊ |
2118 | ␉␉␉␉ {␊ |
2119 | replaceComment(1); ␊ |
2120 | ␉␉␉␉ g_readLineCtx=YY_START;␊ |
2121 | ␉␉␉␉ BEGIN(ReadLine);␊ |
2122 | ␉␉␉␉ }␊ |
2123 | }␊ |
2124 | ␉YY_BREAK␊ |
2125 | case 57:␊ |
2126 | /* rule 57 can match eol */␊ |
2127 | YY_RULE_SETUP␊ |
2128 | #line 653 "commentcnv.l"␊ |
2129 | { /* end of special comment */␊ |
2130 | copyToOutput(" */",3); ␊ |
2131 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng); ␊ |
2132 | ␉␉␉␉ g_inSpecialComment=FALSE;␊ |
2133 | ␉␉␉␉ g_inRoseComment=FALSE;␊ |
2134 | ␉␉␉␉ BEGIN(Scan); ␊ |
2135 | }␊ |
2136 | ␉YY_BREAK␊ |
2137 | case 58:␊ |
2138 | /* rule 58 can match eol */␊ |
2139 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
2140 | (yy_c_buf_p) = yy_cp -= 1;␊ |
2141 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
2142 | YY_RULE_SETUP␊ |
2143 | #line 660 "commentcnv.l"␊ |
2144 | {␊ |
2145 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
2146 | BEGIN(g_readLineCtx);␊ |
2147 | ␉␉␉␉ }␊ |
2148 | ␉YY_BREAK␊ |
2149 | case 59:␊ |
2150 | YY_RULE_SETUP␊ |
2151 | #line 664 "commentcnv.l"␊ |
2152 | { // escaped command␊ |
2153 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
2154 | ␉␉␉␉ }␊ |
2155 | ␉YY_BREAK␊ |
2156 | case 60:␊ |
2157 | YY_RULE_SETUP␊ |
2158 | #line 667 "commentcnv.l"␊ |
2159 | { // conditional section␊ |
2160 | ␉␉␉␉ g_condCtx = YY_START; ␊ |
2161 | ␉␉␉␉ BEGIN(CondLine);␊ |
2162 | ␉␉␉␉ }␊ |
2163 | ␉YY_BREAK␊ |
2164 | case 61:␊ |
2165 | /* rule 61 can match eol */␊ |
2166 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
2167 | (yy_c_buf_p) = yy_cp = yy_bp + 8;␊ |
2168 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
2169 | YY_RULE_SETUP␊ |
2170 | #line 671 "commentcnv.l"␊ |
2171 | { // end of conditional section␊ |
2172 | ␉␉␉␉ bool oldSkip=g_skip;␊ |
2173 | ␉␉␉␉ endCondSection();␊ |
2174 | ␉␉␉␉ if (YY_START==CComment && oldSkip && !g_skip) ␊ |
2175 | ␉␉␉ {␊ |
2176 | ␉␉␉␉ //printf("** Adding start of comment!\n");␊ |
2177 | ␉␉␉␉ if (g_lang!=SrcLangExt_Python &&␊ |
2178 | ␉␉␉␉␉ g_lang!=SrcLangExt_VHDL &&␊ |
2179 | ␉␉␉␉␉ g_lang!=SrcLangExt_F90)␊ |
2180 | ␉␉␉␉ {␊ |
2181 | ␉␉␉␉ ADDCHAR('/');␊ |
2182 | ␉␉␉␉ ADDCHAR('*');␊ |
2183 | ␉␉␉␉␉ if (g_specialComment)␊ |
2184 | ␉␉␉␉␉ {␊ |
2185 | ␉␉␉␉␉ ADDCHAR('*');␊ |
2186 | ␉␉␉␉␉ }␊ |
2187 | ␉␉␉␉ }␊ |
2188 | ␉␉␉␉ }␊ |
2189 | ␉␉␉␉ }␊ |
2190 | ␉YY_BREAK␊ |
2191 | case 62:␊ |
2192 | YY_RULE_SETUP␊ |
2193 | #line 690 "commentcnv.l"␊ |
2194 | {␊ |
2195 | ␉␉␉␉ bool oldSkip=g_skip;␊ |
2196 | startCondSection(commentcnvYYtext);␊ |
2197 | ␉␉␉␉ if (g_condCtx==CComment && !oldSkip && g_skip) ␊ |
2198 | ␉␉␉ {␊ |
2199 | ␉␉␉␉ //printf("** Adding terminator for comment!\n");␊ |
2200 | ␉␉␉␉ if (g_lang!=SrcLangExt_Python &&␊ |
2201 | ␉␉␉␉␉ g_lang!=SrcLangExt_VHDL &&␊ |
2202 | ␉␉␉␉␉ g_lang!=SrcLangExt_F90)␊ |
2203 | ␉␉␉␉ {␊ |
2204 | ␉␉␉␉ ADDCHAR('*');␊ |
2205 | ␉␉␉␉ ADDCHAR('/');␊ |
2206 | ␉␉␉␉ }␊ |
2207 | ␉␉␉␉ }␊ |
2208 | ␉␉␉␉ BEGIN(g_condCtx);␊ |
2209 | ␉␉␉␉ }␊ |
2210 | ␉YY_BREAK␊ |
2211 | case 63:␊ |
2212 | YY_RULE_SETUP␊ |
2213 | #line 706 "commentcnv.l"␊ |
2214 | ␊ |
2215 | ␉YY_BREAK␊ |
2216 | case 64:␊ |
2217 | /* rule 64 can match eol */␊ |
2218 | *yy_cp = (yy_hold_char); /* undo effects of setting up commentcnvYYtext */␊ |
2219 | (yy_c_buf_p) = yy_cp -= 1;␊ |
2220 | YY_DO_BEFORE_ACTION; /* set up commentcnvYYtext again */␊ |
2221 | #line 708 "commentcnv.l"␊ |
2222 | case 65:␊ |
2223 | /* rule 65 can match eol */␊ |
2224 | YY_RULE_SETUP␊ |
2225 | #line 708 "commentcnv.l"␊ |
2226 | { // forgot section id?␊ |
2227 | ␉␉␉␉ if (YY_START!=CondLine) g_condCtx=YY_START;␊ |
2228 | ␉␉␉␉ bool oldSkip=g_skip;␊ |
2229 | ␉␉␉␉ startCondSection(" "); // fake section id causing the section to be hidden unconditionally␊ |
2230 | ␉␉␉␉ if (g_condCtx==CComment && !oldSkip && g_skip) ␊ |
2231 | ␉␉␉ {␊ |
2232 | ␉␉␉␉ //printf("** Adding terminator for comment!\n");␊ |
2233 | ␉␉␉␉ if (g_lang!=SrcLangExt_Python &&␊ |
2234 | ␉␉␉␉␉ g_lang!=SrcLangExt_VHDL)␊ |
2235 | ␉␉␉␉ {␊ |
2236 | ␉␉␉␉ ADDCHAR('*');␊ |
2237 | ␉␉␉␉ ADDCHAR('/');␊ |
2238 | ␉␉␉␉ }␊ |
2239 | ␉␉␉␉ }␊ |
2240 | ␉␉␉␉ if (*commentcnvYYtext=='\n') g_lineNr++;␊ |
2241 | ␉␉␉␉ BEGIN(g_condCtx);␊ |
2242 | ␉␉␉␉ }␊ |
2243 | ␉YY_BREAK␊ |
2244 | case 66:␊ |
2245 | YY_RULE_SETUP␊ |
2246 | #line 725 "commentcnv.l"␊ |
2247 | { // expand alias without arguments␊ |
2248 | ␉␉␉␉ replaceAliases(commentcnvYYtext);␊ |
2249 | ␉␉␉␉ }␊ |
2250 | ␉YY_BREAK␊ |
2251 | case 67:␊ |
2252 | YY_RULE_SETUP␊ |
2253 | #line 728 "commentcnv.l"␊ |
2254 | { // expand alias with arguments␊ |
2255 | g_lastBlockContext=YY_START;␊ |
2256 | ␉␉␉␉ g_blockCount=1;␊ |
2257 | ␉␉␉␉ g_aliasString=commentcnvYYtext;␊ |
2258 | ␉␉␉␉ g_lastEscaped=0;␊ |
2259 | ␉␉␉␉ BEGIN( ReadAliasArgs );␊ |
2260 | ␉␉␉␉ }␊ |
2261 | ␉YY_BREAK␊ |
2262 | case 68:␊ |
2263 | YY_RULE_SETUP␊ |
2264 | #line 735 "commentcnv.l"␊ |
2265 | { // skip leading special comments (see bug 618079)␊ |
2266 | ␉␉␉␉ }␊ |
2267 | ␉YY_BREAK␊ |
2268 | case 69:␊ |
2269 | YY_RULE_SETUP␊ |
2270 | #line 737 "commentcnv.l"␊ |
2271 | {␊ |
2272 | g_aliasString+=commentcnvYYtext;␊ |
2273 | ␉␉␉␉ g_lastEscaped=FALSE;␊ |
2274 | ␉␉␉␉ }␊ |
2275 | ␉YY_BREAK␊ |
2276 | case 70:␊ |
2277 | YY_RULE_SETUP␊ |
2278 | #line 741 "commentcnv.l"␊ |
2279 | {␊ |
2280 | if (g_lastEscaped) g_lastEscaped=FALSE;␊ |
2281 | else g_lastEscaped=TRUE;␊ |
2282 | g_aliasString+=commentcnvYYtext;␊ |
2283 | }␊ |
2284 | ␉YY_BREAK␊ |
2285 | case 71:␊ |
2286 | /* rule 71 can match eol */␊ |
2287 | YY_RULE_SETUP␊ |
2288 | #line 746 "commentcnv.l"␊ |
2289 | {␊ |
2290 | g_aliasString+=commentcnvYYtext;␊ |
2291 | g_lineNr++;␊ |
2292 | ␉␉␉␉ g_lastEscaped=FALSE;␊ |
2293 | ␉␉␉␉ }␊ |
2294 | ␉YY_BREAK␊ |
2295 | case 72:␊ |
2296 | YY_RULE_SETUP␊ |
2297 | #line 751 "commentcnv.l"␊ |
2298 | {␊ |
2299 | g_aliasString+=commentcnvYYtext;␊ |
2300 | if (!g_lastEscaped) g_blockCount++;␊ |
2301 | ␉␉␉␉ g_lastEscaped=FALSE;␊ |
2302 | }␊ |
2303 | ␉YY_BREAK␊ |
2304 | case 73:␊ |
2305 | YY_RULE_SETUP␊ |
2306 | #line 756 "commentcnv.l"␊ |
2307 | {␊ |
2308 | g_aliasString+=commentcnvYYtext;␊ |
2309 | ␉␉␉␉ if (!g_lastEscaped) g_blockCount--;␊ |
2310 | ␉␉␉␉ if (g_blockCount==0)␊ |
2311 | ␉␉␉␉ {␊ |
2312 | ␉␉␉␉ replaceAliases(g_aliasString);␊ |
2313 | ␉␉␉␉ BEGIN( g_lastBlockContext );␊ |
2314 | ␉␉␉␉ }␊ |
2315 | ␉␉␉␉ g_lastEscaped=FALSE;␊ |
2316 | ␉␉␉ }␊ |
2317 | ␉YY_BREAK␊ |
2318 | case 74:␊ |
2319 | YY_RULE_SETUP␊ |
2320 | #line 766 "commentcnv.l"␊ |
2321 | {␊ |
2322 | g_aliasString+=commentcnvYYtext;␊ |
2323 | ␉␉␉␉ g_lastEscaped=FALSE;␊ |
2324 | ␉␉␉␉ }␊ |
2325 | ␉YY_BREAK␊ |
2326 | case 75:␊ |
2327 | YY_RULE_SETUP␊ |
2328 | #line 770 "commentcnv.l"␊ |
2329 | {␊ |
2330 | ␉␉␉␉ copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
2331 | ␉␉␉␉ }␊ |
2332 | ␉YY_BREAK␊ |
2333 | case 76:␊ |
2334 | YY_RULE_SETUP␊ |
2335 | #line 774 "commentcnv.l"␊ |
2336 | ECHO;␊ |
2337 | ␉YY_BREAK␊ |
2338 | #line 2339 "<stdout>"␊ |
2339 | ␉␉␉case YY_STATE_EOF(INITIAL):␊ |
2340 | ␉␉␉case YY_STATE_EOF(Scan):␊ |
2341 | ␉␉␉case YY_STATE_EOF(SkipString):␊ |
2342 | ␉␉␉case YY_STATE_EOF(SkipChar):␊ |
2343 | ␉␉␉case YY_STATE_EOF(SComment):␊ |
2344 | ␉␉␉case YY_STATE_EOF(CComment):␊ |
2345 | ␉␉␉case YY_STATE_EOF(Verbatim):␊ |
2346 | ␉␉␉case YY_STATE_EOF(VerbatimCode):␊ |
2347 | ␉␉␉case YY_STATE_EOF(ReadLine):␊ |
2348 | ␉␉␉case YY_STATE_EOF(CondLine):␊ |
2349 | ␉␉␉case YY_STATE_EOF(ReadAliasArgs):␊ |
2350 | ␉␉␉␉yyterminate();␊ |
2351 | ␊ |
2352 | ␉case YY_END_OF_BUFFER:␊ |
2353 | ␉␉{␊ |
2354 | ␉␉/* Amount of text matched not including the EOB char. */␊ |
2355 | ␉␉int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;␊ |
2356 | ␊ |
2357 | ␉␉/* Undo the effects of YY_DO_BEFORE_ACTION. */␊ |
2358 | ␉␉*yy_cp = (yy_hold_char);␊ |
2359 | ␉␉YY_RESTORE_YY_MORE_OFFSET␊ |
2360 | ␊ |
2361 | ␉␉if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )␊ |
2362 | ␉␉␉{␊ |
2363 | ␉␉␉/* We're scanning a new file or input source. It's␊ |
2364 | ␉␉␉ * possible that this happened because the user␊ |
2365 | ␉␉␉ * just pointed commentcnvYYin at a new source and called␊ |
2366 | ␉␉␉ * commentcnvYYlex(). If so, then we have to assure␊ |
2367 | ␉␉␉ * consistency between YY_CURRENT_BUFFER and our␊ |
2368 | ␉␉␉ * globals. Here is the right place to do so, because␊ |
2369 | ␉␉␉ * this is the first action (other than possibly a␊ |
2370 | ␉␉␉ * back-up) that will match for the new input source.␊ |
2371 | ␉␉␉ */␊ |
2372 | ␉␉␉(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;␊ |
2373 | ␉␉␉YY_CURRENT_BUFFER_LVALUE->yy_input_file = commentcnvYYin;␊ |
2374 | ␉␉␉YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;␊ |
2375 | ␉␉␉}␊ |
2376 | ␊ |
2377 | ␉␉/* Note that here we test for yy_c_buf_p "<=" to the position␊ |
2378 | ␉␉ * of the first EOB in the buffer, since yy_c_buf_p will␊ |
2379 | ␉␉ * already have been incremented past the NUL character␊ |
2380 | ␉␉ * (since all states make transitions on EOB to the␊ |
2381 | ␉␉ * end-of-buffer state). Contrast this with the test␊ |
2382 | ␉␉ * in input().␊ |
2383 | ␉␉ */␊ |
2384 | ␉␉if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )␊ |
2385 | ␉␉␉{ /* This was really a NUL. */␊ |
2386 | ␉␉␉yy_state_type yy_next_state;␊ |
2387 | ␊ |
2388 | ␉␉␉(yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text;␊ |
2389 | ␊ |
2390 | ␉␉␉yy_current_state = yy_get_previous_state( );␊ |
2391 | ␊ |
2392 | ␉␉␉/* Okay, we're now positioned to make the NUL␊ |
2393 | ␉␉␉ * transition. We couldn't have␊ |
2394 | ␉␉␉ * yy_get_previous_state() go ahead and do it␊ |
2395 | ␉␉␉ * for us because it doesn't know how to deal␊ |
2396 | ␉␉␉ * with the possibility of jamming (and we don't␊ |
2397 | ␉␉␉ * want to build jamming into it because then it␊ |
2398 | ␉␉␉ * will run more slowly).␊ |
2399 | ␉␉␉ */␊ |
2400 | ␊ |
2401 | ␉␉␉yy_next_state = yy_try_NUL_trans( yy_current_state );␊ |
2402 | ␊ |
2403 | ␉␉␉yy_bp = (yytext_ptr) + YY_MORE_ADJ;␊ |
2404 | ␊ |
2405 | ␉␉␉if ( yy_next_state )␊ |
2406 | ␉␉␉␉{␊ |
2407 | ␉␉␉␉/* Consume the NUL. */␊ |
2408 | ␉␉␉␉yy_cp = ++(yy_c_buf_p);␊ |
2409 | ␉␉␉␉yy_current_state = yy_next_state;␊ |
2410 | ␉␉␉␉goto yy_match;␊ |
2411 | ␉␉␉␉}␊ |
2412 | ␊ |
2413 | ␉␉␉else␊ |
2414 | ␉␉␉␉{␊ |
2415 | ␉␉␉␉yy_cp = (yy_c_buf_p);␊ |
2416 | ␉␉␉␉goto yy_find_action;␊ |
2417 | ␉␉␉␉}␊ |
2418 | ␉␉␉}␊ |
2419 | ␊ |
2420 | ␉␉else switch ( yy_get_next_buffer( ) )␊ |
2421 | ␉␉␉{␊ |
2422 | ␉␉␉case EOB_ACT_END_OF_FILE:␊ |
2423 | ␉␉␉␉{␊ |
2424 | ␉␉␉␉(yy_did_buffer_switch_on_eof) = 0;␊ |
2425 | ␊ |
2426 | ␉␉␉␉if ( commentcnvYYwrap( ) )␊ |
2427 | ␉␉␉␉␉{␊ |
2428 | ␉␉␉␉␉/* Note: because we've taken care in␊ |
2429 | ␉␉␉␉␉ * yy_get_next_buffer() to have set up␊ |
2430 | ␉␉␉␉␉ * commentcnvYYtext, we can now set up␊ |
2431 | ␉␉␉␉␉ * yy_c_buf_p so that if some total␊ |
2432 | ␉␉␉␉␉ * hoser (like flex itself) wants to␊ |
2433 | ␉␉␉␉␉ * call the scanner after we return the␊ |
2434 | ␉␉␉␉␉ * YY_NULL, it'll still work - another␊ |
2435 | ␉␉␉␉␉ * YY_NULL will get returned.␊ |
2436 | ␉␉␉␉␉ */␊ |
2437 | ␉␉␉␉␉(yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ;␊ |
2438 | ␊ |
2439 | ␉␉␉␉␉yy_act = YY_STATE_EOF(YY_START);␊ |
2440 | ␉␉␉␉␉goto do_action;␊ |
2441 | ␉␉␉␉␉}␊ |
2442 | ␊ |
2443 | ␉␉␉␉else␊ |
2444 | ␉␉␉␉␉{␊ |
2445 | ␉␉␉␉␉if ( ! (yy_did_buffer_switch_on_eof) )␊ |
2446 | ␉␉␉␉␉␉YY_NEW_FILE;␊ |
2447 | ␉␉␉␉␉}␊ |
2448 | ␉␉␉␉break;␊ |
2449 | ␉␉␉␉}␊ |
2450 | ␊ |
2451 | ␉␉␉case EOB_ACT_CONTINUE_SCAN:␊ |
2452 | ␉␉␉␉(yy_c_buf_p) =␊ |
2453 | ␉␉␉␉␉(yytext_ptr) + yy_amount_of_matched_text;␊ |
2454 | ␊ |
2455 | ␉␉␉␉yy_current_state = yy_get_previous_state( );␊ |
2456 | ␊ |
2457 | ␉␉␉␉yy_cp = (yy_c_buf_p);␊ |
2458 | ␉␉␉␉yy_bp = (yytext_ptr) + YY_MORE_ADJ;␊ |
2459 | ␉␉␉␉goto yy_match;␊ |
2460 | ␊ |
2461 | ␉␉␉case EOB_ACT_LAST_MATCH:␊ |
2462 | ␉␉␉␉(yy_c_buf_p) =␊ |
2463 | ␉␉␉␉&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)];␊ |
2464 | ␊ |
2465 | ␉␉␉␉yy_current_state = yy_get_previous_state( );␊ |
2466 | ␊ |
2467 | ␉␉␉␉yy_cp = (yy_c_buf_p);␊ |
2468 | ␉␉␉␉yy_bp = (yytext_ptr) + YY_MORE_ADJ;␊ |
2469 | ␉␉␉␉goto yy_find_action;␊ |
2470 | ␉␉␉}␊ |
2471 | ␉␉break;␊ |
2472 | ␉␉}␊ |
2473 | ␊ |
2474 | ␉default:␊ |
2475 | ␉␉YY_FATAL_ERROR(␊ |
2476 | ␉␉␉"fatal flex scanner internal error--no action found" );␊ |
2477 | ␉} /* end of action switch */␊ |
2478 | ␉␉} /* end of scanning one token */␊ |
2479 | } /* end of commentcnvYYlex */␊ |
2480 | ␊ |
2481 | /* yy_get_next_buffer - try to read in a new buffer␊ |
2482 | *␊ |
2483 | * Returns a code representing an action:␊ |
2484 | *␉EOB_ACT_LAST_MATCH -␊ |
2485 | *␉EOB_ACT_CONTINUE_SCAN - continue scanning from current position␊ |
2486 | *␉EOB_ACT_END_OF_FILE - end of file␊ |
2487 | */␊ |
2488 | static int yy_get_next_buffer (void)␊ |
2489 | {␊ |
2490 | ␉register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;␊ |
2491 | ␉register char *source = (yytext_ptr);␊ |
2492 | ␉register int number_to_move, i;␊ |
2493 | ␉int ret_val;␊ |
2494 | ␊ |
2495 | ␉if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )␊ |
2496 | ␉␉YY_FATAL_ERROR(␊ |
2497 | ␉␉"fatal flex scanner internal error--end of buffer missed" );␊ |
2498 | ␊ |
2499 | ␉if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )␊ |
2500 | ␉␉{ /* Don't try to fill the buffer, so this is an EOF. */␊ |
2501 | ␉␉if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )␊ |
2502 | ␉␉␉{␊ |
2503 | ␉␉␉/* We matched a single character, the EOB, so␊ |
2504 | ␉␉␉ * treat this as a final EOF.␊ |
2505 | ␉␉␉ */␊ |
2506 | ␉␉␉return EOB_ACT_END_OF_FILE;␊ |
2507 | ␉␉␉}␊ |
2508 | ␊ |
2509 | ␉␉else␊ |
2510 | ␉␉␉{␊ |
2511 | ␉␉␉/* We matched some text prior to the EOB, first␊ |
2512 | ␉␉␉ * process it.␊ |
2513 | ␉␉␉ */␊ |
2514 | ␉␉␉return EOB_ACT_LAST_MATCH;␊ |
2515 | ␉␉␉}␊ |
2516 | ␉␉}␊ |
2517 | ␊ |
2518 | ␉/* Try to read more data. */␊ |
2519 | ␊ |
2520 | ␉/* First move last chars to start of buffer. */␊ |
2521 | ␉number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1;␊ |
2522 | ␊ |
2523 | ␉for ( i = 0; i < number_to_move; ++i )␊ |
2524 | ␉␉*(dest++) = *(source++);␊ |
2525 | ␊ |
2526 | ␉if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )␊ |
2527 | ␉␉/* don't do the read, it's not guaranteed to return an EOF,␊ |
2528 | ␉␉ * just force an EOF␊ |
2529 | ␉␉ */␊ |
2530 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;␊ |
2531 | ␊ |
2532 | ␉else␊ |
2533 | ␉␉{␊ |
2534 | ␉␉␉yy_size_t num_to_read =␊ |
2535 | ␉␉␉YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;␊ |
2536 | ␊ |
2537 | ␉␉while ( num_to_read <= 0 )␊ |
2538 | ␉␉␉{ /* Not enough room in the buffer - grow it. */␊ |
2539 | ␊ |
2540 | ␉␉␉YY_FATAL_ERROR(␊ |
2541 | "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );␊ |
2542 | ␊ |
2543 | ␉␉␉}␊ |
2544 | ␊ |
2545 | ␉␉if ( num_to_read > YY_READ_BUF_SIZE )␊ |
2546 | ␉␉␉num_to_read = YY_READ_BUF_SIZE;␊ |
2547 | ␊ |
2548 | ␉␉/* Read in more data. */␊ |
2549 | ␉␉YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),␊ |
2550 | ␉␉␉(yy_n_chars), num_to_read );␊ |
2551 | ␊ |
2552 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);␊ |
2553 | ␉␉}␊ |
2554 | ␊ |
2555 | ␉if ( (yy_n_chars) == 0 )␊ |
2556 | ␉␉{␊ |
2557 | ␉␉if ( number_to_move == YY_MORE_ADJ )␊ |
2558 | ␉␉␉{␊ |
2559 | ␉␉␉ret_val = EOB_ACT_END_OF_FILE;␊ |
2560 | ␉␉␉commentcnvYYrestart(commentcnvYYin );␊ |
2561 | ␉␉␉}␊ |
2562 | ␊ |
2563 | ␉␉else␊ |
2564 | ␉␉␉{␊ |
2565 | ␉␉␉ret_val = EOB_ACT_LAST_MATCH;␊ |
2566 | ␉␉␉YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =␊ |
2567 | ␉␉␉␉YY_BUFFER_EOF_PENDING;␊ |
2568 | ␉␉␉}␊ |
2569 | ␉␉}␊ |
2570 | ␊ |
2571 | ␉else␊ |
2572 | ␉␉ret_val = EOB_ACT_CONTINUE_SCAN;␊ |
2573 | ␊ |
2574 | ␉if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {␊ |
2575 | ␉␉/* Extend the array by 50%, plus the number we really need. */␊ |
2576 | ␉␉yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);␊ |
2577 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) commentcnvYYrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size );␊ |
2578 | ␉␉if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )␊ |
2579 | ␉␉␉YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );␊ |
2580 | ␉}␊ |
2581 | ␊ |
2582 | ␉(yy_n_chars) += number_to_move;␊ |
2583 | ␉YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR;␊ |
2584 | ␉YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR;␊ |
2585 | ␊ |
2586 | ␉(yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];␊ |
2587 | ␊ |
2588 | ␉return ret_val;␊ |
2589 | }␊ |
2590 | ␊ |
2591 | /* yy_get_previous_state - get the state just before the EOB char was reached */␊ |
2592 | ␊ |
2593 | static yy_state_type yy_get_previous_state (void)␊ |
2594 | {␊ |
2595 | ␉register yy_state_type yy_current_state;␊ |
2596 | ␉register char *yy_cp;␊ |
2597 | ␊ |
2598 | ␉yy_current_state = (yy_start);␊ |
2599 | ␉yy_current_state += YY_AT_BOL();␊ |
2600 | ␊ |
2601 | ␉(yy_state_ptr) = (yy_state_buf);␊ |
2602 | ␉*(yy_state_ptr)++ = yy_current_state;␊ |
2603 | ␊ |
2604 | ␉for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )␊ |
2605 | ␉␉{␊ |
2606 | ␉␉register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);␊ |
2607 | ␉␉while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )␊ |
2608 | ␉␉␉{␊ |
2609 | ␉␉␉yy_current_state = (int) yy_def[yy_current_state];␊ |
2610 | ␉␉␉if ( yy_current_state >= 329 )␊ |
2611 | ␉␉␉␉yy_c = yy_meta[(unsigned int) yy_c];␊ |
2612 | ␉␉␉}␊ |
2613 | ␉␉yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];␊ |
2614 | ␉␉*(yy_state_ptr)++ = yy_current_state;␊ |
2615 | ␉␉}␊ |
2616 | ␊ |
2617 | ␉return yy_current_state;␊ |
2618 | }␊ |
2619 | ␊ |
2620 | /* yy_try_NUL_trans - try to make a transition on the NUL character␊ |
2621 | *␊ |
2622 | * synopsis␊ |
2623 | *␉next_state = yy_try_NUL_trans( current_state );␊ |
2624 | */␊ |
2625 | static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state )␊ |
2626 | {␊ |
2627 | ␉register int yy_is_jam;␊ |
2628 | ␊ |
2629 | ␉register YY_CHAR yy_c = 1;␊ |
2630 | ␉while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )␊ |
2631 | ␉␉{␊ |
2632 | ␉␉yy_current_state = (int) yy_def[yy_current_state];␊ |
2633 | ␉␉if ( yy_current_state >= 329 )␊ |
2634 | ␉␉␉yy_c = yy_meta[(unsigned int) yy_c];␊ |
2635 | ␉␉}␊ |
2636 | ␉yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];␊ |
2637 | ␉yy_is_jam = (yy_current_state == 328);␊ |
2638 | ␉if ( ! yy_is_jam )␊ |
2639 | ␉␉*(yy_state_ptr)++ = yy_current_state;␊ |
2640 | ␊ |
2641 | ␉return yy_is_jam ? 0 : yy_current_state;␊ |
2642 | }␊ |
2643 | ␊ |
2644 | static void yyunput (int c, register char * yy_bp )␊ |
2645 | {␊ |
2646 | ␉register char *yy_cp;␊ |
2647 | ␊ |
2648 | yy_cp = (yy_c_buf_p);␊ |
2649 | ␊ |
2650 | ␉/* undo effects of setting up commentcnvYYtext */␊ |
2651 | ␉*yy_cp = (yy_hold_char);␊ |
2652 | ␊ |
2653 | ␉if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )␊ |
2654 | ␉␉{ /* need to shift things up to make room */␊ |
2655 | ␉␉/* +2 for EOB chars. */␊ |
2656 | ␉␉register yy_size_t number_to_move = (yy_n_chars) + 2;␊ |
2657 | ␉␉register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[␊ |
2658 | ␉␉␉␉␉YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];␊ |
2659 | ␉␉register char *source =␊ |
2660 | ␉␉␉␉&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];␊ |
2661 | ␊ |
2662 | ␉␉while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )␊ |
2663 | ␉␉␉*--dest = *--source;␊ |
2664 | ␊ |
2665 | ␉␉yy_cp += (int) (dest - source);␊ |
2666 | ␉␉yy_bp += (int) (dest - source);␊ |
2667 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_n_chars =␊ |
2668 | ␉␉␉(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;␊ |
2669 | ␊ |
2670 | ␉␉if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )␊ |
2671 | ␉␉␉YY_FATAL_ERROR( "flex scanner push-back overflow" );␊ |
2672 | ␉␉}␊ |
2673 | ␊ |
2674 | ␉*--yy_cp = (char) c;␊ |
2675 | ␊ |
2676 | ␉(yytext_ptr) = yy_bp;␊ |
2677 | ␉(yy_hold_char) = *yy_cp;␊ |
2678 | ␉(yy_c_buf_p) = yy_cp;␊ |
2679 | }␊ |
2680 | ␊ |
2681 | #ifndef YY_NO_INPUT␊ |
2682 | #ifdef __cplusplus␊ |
2683 | static int yyinput (void)␊ |
2684 | #else␊ |
2685 | static int input (void)␊ |
2686 | #endif␊ |
2687 | ␊ |
2688 | {␊ |
2689 | ␉int c;␊ |
2690 | ␊ |
2691 | ␉*(yy_c_buf_p) = (yy_hold_char);␊ |
2692 | ␊ |
2693 | ␉if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR )␊ |
2694 | ␉␉{␊ |
2695 | ␉␉/* yy_c_buf_p now points to the character we want to return.␊ |
2696 | ␉␉ * If this occurs *before* the EOB characters, then it's a␊ |
2697 | ␉␉ * valid NUL; if not, then we've hit the end of the buffer.␊ |
2698 | ␉␉ */␊ |
2699 | ␉␉if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )␊ |
2700 | ␉␉␉/* This was really a NUL. */␊ |
2701 | ␉␉␉*(yy_c_buf_p) = '\0';␊ |
2702 | ␊ |
2703 | ␉␉else␊ |
2704 | ␉␉␉{ /* need more input */␊ |
2705 | ␉␉␉yy_size_t offset = (yy_c_buf_p) - (yytext_ptr);␊ |
2706 | ␉␉␉++(yy_c_buf_p);␊ |
2707 | ␊ |
2708 | ␉␉␉switch ( yy_get_next_buffer( ) )␊ |
2709 | ␉␉␉␉{␊ |
2710 | ␉␉␉␉case EOB_ACT_LAST_MATCH:␊ |
2711 | ␉␉␉␉␉/* This happens because yy_g_n_b()␊ |
2712 | ␉␉␉␉␉ * sees that we've accumulated a␊ |
2713 | ␉␉␉␉␉ * token and flags that we need to␊ |
2714 | ␉␉␉␉␉ * try matching the token before␊ |
2715 | ␉␉␉␉␉ * proceeding. But for input(),␊ |
2716 | ␉␉␉␉␉ * there's no matching to consider.␊ |
2717 | ␉␉␉␉␉ * So convert the EOB_ACT_LAST_MATCH␊ |
2718 | ␉␉␉␉␉ * to EOB_ACT_END_OF_FILE.␊ |
2719 | ␉␉␉␉␉ */␊ |
2720 | ␊ |
2721 | ␉␉␉␉␉/* Reset buffer status. */␊ |
2722 | ␉␉␉␉␉commentcnvYYrestart(commentcnvYYin );␊ |
2723 | ␊ |
2724 | ␉␉␉␉␉/*FALLTHROUGH*/␊ |
2725 | ␊ |
2726 | ␉␉␉␉case EOB_ACT_END_OF_FILE:␊ |
2727 | ␉␉␉␉␉{␊ |
2728 | ␉␉␉␉␉if ( commentcnvYYwrap( ) )␊ |
2729 | ␉␉␉␉␉␉return 0;␊ |
2730 | ␊ |
2731 | ␉␉␉␉␉if ( ! (yy_did_buffer_switch_on_eof) )␊ |
2732 | ␉␉␉␉␉␉YY_NEW_FILE;␊ |
2733 | #ifdef __cplusplus␊ |
2734 | ␉␉␉␉␉return yyinput();␊ |
2735 | #else␊ |
2736 | ␉␉␉␉␉return input();␊ |
2737 | #endif␊ |
2738 | ␉␉␉␉␉}␊ |
2739 | ␊ |
2740 | ␉␉␉␉case EOB_ACT_CONTINUE_SCAN:␊ |
2741 | ␉␉␉␉␉(yy_c_buf_p) = (yytext_ptr) + offset;␊ |
2742 | ␉␉␉␉␉break;␊ |
2743 | ␉␉␉␉}␊ |
2744 | ␉␉␉}␊ |
2745 | ␉␉}␊ |
2746 | ␊ |
2747 | ␉c = *(unsigned char *) (yy_c_buf_p);␉/* cast for 8-bit char's */␊ |
2748 | ␉*(yy_c_buf_p) = '\0';␉/* preserve commentcnvYYtext */␊ |
2749 | ␉(yy_hold_char) = *++(yy_c_buf_p);␊ |
2750 | ␊ |
2751 | ␉YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (c == '\n');␊ |
2752 | ␊ |
2753 | ␉return c;␊ |
2754 | }␊ |
2755 | #endif␉/* ifndef YY_NO_INPUT */␊ |
2756 | ␊ |
2757 | /** Immediately switch to a different input stream.␊ |
2758 | * @param input_file A readable stream.␊ |
2759 | * ␊ |
2760 | * @note This function does not reset the start condition to @c INITIAL .␊ |
2761 | */␊ |
2762 | void commentcnvYYrestart (FILE * input_file )␊ |
2763 | {␊ |
2764 | ␊ |
2765 | ␉if ( ! YY_CURRENT_BUFFER ){␊ |
2766 | commentcnvYYensure_buffer_stack ();␊ |
2767 | ␉␉YY_CURRENT_BUFFER_LVALUE =␊ |
2768 | commentcnvYY_create_buffer(commentcnvYYin,YY_BUF_SIZE );␊ |
2769 | ␉}␊ |
2770 | ␊ |
2771 | ␉commentcnvYY_init_buffer(YY_CURRENT_BUFFER,input_file );␊ |
2772 | ␉commentcnvYY_load_buffer_state( );␊ |
2773 | }␊ |
2774 | ␊ |
2775 | /** Switch to a different input buffer.␊ |
2776 | * @param new_buffer The new input buffer.␊ |
2777 | * ␊ |
2778 | */␊ |
2779 | void commentcnvYY_switch_to_buffer (YY_BUFFER_STATE new_buffer )␊ |
2780 | {␊ |
2781 | ␊ |
2782 | ␉/* TODO. We should be able to replace this entire function body␊ |
2783 | ␉ * with␊ |
2784 | ␉ *␉␉commentcnvYYpop_buffer_state();␊ |
2785 | ␉ *␉␉commentcnvYYpush_buffer_state(new_buffer);␊ |
2786 | */␊ |
2787 | ␉commentcnvYYensure_buffer_stack ();␊ |
2788 | ␉if ( YY_CURRENT_BUFFER == new_buffer )␊ |
2789 | ␉␉return;␊ |
2790 | ␊ |
2791 | ␉if ( YY_CURRENT_BUFFER )␊ |
2792 | ␉␉{␊ |
2793 | ␉␉/* Flush out information for old buffer. */␊ |
2794 | ␉␉*(yy_c_buf_p) = (yy_hold_char);␊ |
2795 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);␊ |
2796 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);␊ |
2797 | ␉␉}␊ |
2798 | ␊ |
2799 | ␉YY_CURRENT_BUFFER_LVALUE = new_buffer;␊ |
2800 | ␉commentcnvYY_load_buffer_state( );␊ |
2801 | ␊ |
2802 | ␉/* We don't actually know whether we did this switch during␊ |
2803 | ␉ * EOF (commentcnvYYwrap()) processing, but the only time this flag␊ |
2804 | ␉ * is looked at is after commentcnvYYwrap() is called, so it's safe␊ |
2805 | ␉ * to go ahead and always set it.␊ |
2806 | ␉ */␊ |
2807 | ␉(yy_did_buffer_switch_on_eof) = 1;␊ |
2808 | }␊ |
2809 | ␊ |
2810 | static void commentcnvYY_load_buffer_state (void)␊ |
2811 | {␊ |
2812 | ␉(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;␊ |
2813 | ␉(yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;␊ |
2814 | ␉commentcnvYYin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;␊ |
2815 | ␉(yy_hold_char) = *(yy_c_buf_p);␊ |
2816 | }␊ |
2817 | ␊ |
2818 | /** Allocate and initialize an input buffer state.␊ |
2819 | * @param file A readable stream.␊ |
2820 | * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.␊ |
2821 | * ␊ |
2822 | * @return the allocated buffer state.␊ |
2823 | */␊ |
2824 | YY_BUFFER_STATE commentcnvYY_create_buffer (FILE * file, int size )␊ |
2825 | {␊ |
2826 | ␉YY_BUFFER_STATE b;␊ |
2827 | ␊ |
2828 | ␉b = (YY_BUFFER_STATE) commentcnvYYalloc(sizeof( struct yy_buffer_state ) );␊ |
2829 | ␉if ( ! b )␊ |
2830 | ␉␉YY_FATAL_ERROR( "out of dynamic memory in commentcnvYY_create_buffer()" );␊ |
2831 | ␊ |
2832 | ␉b->yy_buf_size = size;␊ |
2833 | ␊ |
2834 | ␉/* yy_ch_buf has to be 2 characters longer than the size given because␊ |
2835 | ␉ * we need to put in 2 end-of-buffer characters.␊ |
2836 | ␉ */␊ |
2837 | ␉b->yy_ch_buf = (char *) commentcnvYYalloc(b->yy_buf_size + 2 );␊ |
2838 | ␉if ( ! b->yy_ch_buf )␊ |
2839 | ␉␉YY_FATAL_ERROR( "out of dynamic memory in commentcnvYY_create_buffer()" );␊ |
2840 | ␊ |
2841 | ␉b->yy_is_our_buffer = 1;␊ |
2842 | ␊ |
2843 | ␉commentcnvYY_init_buffer(b,file );␊ |
2844 | ␊ |
2845 | ␉return b;␊ |
2846 | }␊ |
2847 | ␊ |
2848 | /** Destroy the buffer.␊ |
2849 | * @param b a buffer created with commentcnvYY_create_buffer()␊ |
2850 | * ␊ |
2851 | */␊ |
2852 | void commentcnvYY_delete_buffer (YY_BUFFER_STATE b )␊ |
2853 | {␊ |
2854 | ␊ |
2855 | ␉if ( ! b )␊ |
2856 | ␉␉return;␊ |
2857 | ␊ |
2858 | ␉if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */␊ |
2859 | ␉␉YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;␊ |
2860 | ␊ |
2861 | ␉if ( b->yy_is_our_buffer )␊ |
2862 | ␉␉commentcnvYYfree((void *) b->yy_ch_buf );␊ |
2863 | ␊ |
2864 | ␉commentcnvYYfree((void *) b );␊ |
2865 | }␊ |
2866 | ␊ |
2867 | #ifndef __cplusplus␊ |
2868 | extern int isatty (int );␊ |
2869 | #endif /* __cplusplus */␊ |
2870 | ␊ |
2871 | /* Initializes or reinitializes a buffer.␊ |
2872 | * This function is sometimes called more than once on the same buffer,␊ |
2873 | * such as during a commentcnvYYrestart() or at EOF.␊ |
2874 | */␊ |
2875 | static void commentcnvYY_init_buffer (YY_BUFFER_STATE b, FILE * file )␊ |
2876 | ␊ |
2877 | {␊ |
2878 | ␉int oerrno = errno;␊ |
2879 | ␊ |
2880 | ␉commentcnvYY_flush_buffer(b );␊ |
2881 | ␊ |
2882 | ␉b->yy_input_file = file;␊ |
2883 | ␉b->yy_fill_buffer = 1;␊ |
2884 | ␊ |
2885 | /* If b is the current buffer, then commentcnvYY_init_buffer was _probably_␊ |
2886 | * called from commentcnvYYrestart() or through yy_get_next_buffer.␊ |
2887 | * In that case, we don't want to reset the lineno or column.␊ |
2888 | */␊ |
2889 | if (b != YY_CURRENT_BUFFER){␊ |
2890 | b->yy_bs_lineno = 1;␊ |
2891 | b->yy_bs_column = 0;␊ |
2892 | }␊ |
2893 | ␊ |
2894 | b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;␊ |
2895 | ␊ |
2896 | ␉errno = oerrno;␊ |
2897 | }␊ |
2898 | ␊ |
2899 | /** Discard all buffered characters. On the next scan, YY_INPUT will be called.␊ |
2900 | * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.␊ |
2901 | * ␊ |
2902 | */␊ |
2903 | void commentcnvYY_flush_buffer (YY_BUFFER_STATE b )␊ |
2904 | {␊ |
2905 | ␉if ( ! b )␊ |
2906 | ␉␉return;␊ |
2907 | ␊ |
2908 | ␉b->yy_n_chars = 0;␊ |
2909 | ␊ |
2910 | ␉/* We always need two end-of-buffer characters. The first causes␊ |
2911 | ␉ * a transition to the end-of-buffer state. The second causes␊ |
2912 | ␉ * a jam in that state.␊ |
2913 | ␉ */␊ |
2914 | ␉b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;␊ |
2915 | ␉b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;␊ |
2916 | ␊ |
2917 | ␉b->yy_buf_pos = &b->yy_ch_buf[0];␊ |
2918 | ␊ |
2919 | ␉b->yy_at_bol = 1;␊ |
2920 | ␉b->yy_buffer_status = YY_BUFFER_NEW;␊ |
2921 | ␊ |
2922 | ␉if ( b == YY_CURRENT_BUFFER )␊ |
2923 | ␉␉commentcnvYY_load_buffer_state( );␊ |
2924 | }␊ |
2925 | ␊ |
2926 | /** Pushes the new state onto the stack. The new state becomes␊ |
2927 | * the current state. This function will allocate the stack␊ |
2928 | * if necessary.␊ |
2929 | * @param new_buffer The new state.␊ |
2930 | * ␊ |
2931 | */␊ |
2932 | void commentcnvYYpush_buffer_state (YY_BUFFER_STATE new_buffer )␊ |
2933 | {␊ |
2934 | ␉if (new_buffer == NULL)␊ |
2935 | ␉␉return;␊ |
2936 | ␊ |
2937 | ␉commentcnvYYensure_buffer_stack();␊ |
2938 | ␊ |
2939 | ␉/* This block is copied from commentcnvYY_switch_to_buffer. */␊ |
2940 | ␉if ( YY_CURRENT_BUFFER )␊ |
2941 | ␉␉{␊ |
2942 | ␉␉/* Flush out information for old buffer. */␊ |
2943 | ␉␉*(yy_c_buf_p) = (yy_hold_char);␊ |
2944 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);␊ |
2945 | ␉␉YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);␊ |
2946 | ␉␉}␊ |
2947 | ␊ |
2948 | ␉/* Only push if top exists. Otherwise, replace top. */␊ |
2949 | ␉if (YY_CURRENT_BUFFER)␊ |
2950 | ␉␉(yy_buffer_stack_top)++;␊ |
2951 | ␉YY_CURRENT_BUFFER_LVALUE = new_buffer;␊ |
2952 | ␊ |
2953 | ␉/* copied from commentcnvYY_switch_to_buffer. */␊ |
2954 | ␉commentcnvYY_load_buffer_state( );␊ |
2955 | ␉(yy_did_buffer_switch_on_eof) = 1;␊ |
2956 | }␊ |
2957 | ␊ |
2958 | /** Removes and deletes the top of the stack, if present.␊ |
2959 | * The next element becomes the new top.␊ |
2960 | * ␊ |
2961 | */␊ |
2962 | void commentcnvYYpop_buffer_state (void)␊ |
2963 | {␊ |
2964 | ␉if (!YY_CURRENT_BUFFER)␊ |
2965 | ␉␉return;␊ |
2966 | ␊ |
2967 | ␉commentcnvYY_delete_buffer(YY_CURRENT_BUFFER );␊ |
2968 | ␉YY_CURRENT_BUFFER_LVALUE = NULL;␊ |
2969 | ␉if ((yy_buffer_stack_top) > 0)␊ |
2970 | ␉␉--(yy_buffer_stack_top);␊ |
2971 | ␊ |
2972 | ␉if (YY_CURRENT_BUFFER) {␊ |
2973 | ␉␉commentcnvYY_load_buffer_state( );␊ |
2974 | ␉␉(yy_did_buffer_switch_on_eof) = 1;␊ |
2975 | ␉}␊ |
2976 | }␊ |
2977 | ␊ |
2978 | /* Allocates the stack if it does not exist.␊ |
2979 | * Guarantees space for at least one push.␊ |
2980 | */␊ |
2981 | static void commentcnvYYensure_buffer_stack (void)␊ |
2982 | {␊ |
2983 | ␉yy_size_t num_to_alloc;␊ |
2984 | ␊ |
2985 | ␉if (!(yy_buffer_stack)) {␊ |
2986 | ␊ |
2987 | ␉␉/* First allocation is just for 2 elements, since we don't know if this␊ |
2988 | ␉␉ * scanner will even need a stack. We use 2 instead of 1 to avoid an␊ |
2989 | ␉␉ * immediate realloc on the next call.␊ |
2990 | */␊ |
2991 | ␉␉num_to_alloc = 1;␊ |
2992 | ␉␉(yy_buffer_stack) = (struct yy_buffer_state**)commentcnvYYalloc␊ |
2993 | ␉␉␉␉␉␉␉␉(num_to_alloc * sizeof(struct yy_buffer_state*)␊ |
2994 | ␉␉␉␉␉␉␉␉);␊ |
2995 | ␉␉if ( ! (yy_buffer_stack) )␊ |
2996 | ␉␉␉YY_FATAL_ERROR( "out of dynamic memory in commentcnvYYensure_buffer_stack()" );␊ |
2997 | ␉␉␉␉␉␉␉␉ ␊ |
2998 | ␉␉memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));␊ |
2999 | ␉␉␉␉␊ |
3000 | ␉␉(yy_buffer_stack_max) = num_to_alloc;␊ |
3001 | ␉␉(yy_buffer_stack_top) = 0;␊ |
3002 | ␉␉return;␊ |
3003 | ␉}␊ |
3004 | ␊ |
3005 | ␉if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){␊ |
3006 | ␊ |
3007 | ␉␉/* Increase the buffer to prepare for a possible push. */␊ |
3008 | ␉␉int grow_size = 8 /* arbitrary grow size */;␊ |
3009 | ␊ |
3010 | ␉␉num_to_alloc = (yy_buffer_stack_max) + grow_size;␊ |
3011 | ␉␉(yy_buffer_stack) = (struct yy_buffer_state**)commentcnvYYrealloc␊ |
3012 | ␉␉␉␉␉␉␉␉((yy_buffer_stack),␊ |
3013 | ␉␉␉␉␉␉␉␉num_to_alloc * sizeof(struct yy_buffer_state*)␊ |
3014 | ␉␉␉␉␉␉␉␉);␊ |
3015 | ␉␉if ( ! (yy_buffer_stack) )␊ |
3016 | ␉␉␉YY_FATAL_ERROR( "out of dynamic memory in commentcnvYYensure_buffer_stack()" );␊ |
3017 | ␊ |
3018 | ␉␉/* zero only the new slots.*/␊ |
3019 | ␉␉memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));␊ |
3020 | ␉␉(yy_buffer_stack_max) = num_to_alloc;␊ |
3021 | ␉}␊ |
3022 | }␊ |
3023 | ␊ |
3024 | /** Setup the input buffer state to scan directly from a user-specified character buffer.␊ |
3025 | * @param base the character buffer␊ |
3026 | * @param size the size in bytes of the character buffer␊ |
3027 | * ␊ |
3028 | * @return the newly allocated buffer state object. ␊ |
3029 | */␊ |
3030 | YY_BUFFER_STATE commentcnvYY_scan_buffer (char * base, yy_size_t size )␊ |
3031 | {␊ |
3032 | ␉YY_BUFFER_STATE b;␊ |
3033 | ␊ |
3034 | ␉if ( size < 2 ||␊ |
3035 | ␉ base[size-2] != YY_END_OF_BUFFER_CHAR ||␊ |
3036 | ␉ base[size-1] != YY_END_OF_BUFFER_CHAR )␊ |
3037 | ␉␉/* They forgot to leave room for the EOB's. */␊ |
3038 | ␉␉return 0;␊ |
3039 | ␊ |
3040 | ␉b = (YY_BUFFER_STATE) commentcnvYYalloc(sizeof( struct yy_buffer_state ) );␊ |
3041 | ␉if ( ! b )␊ |
3042 | ␉␉YY_FATAL_ERROR( "out of dynamic memory in commentcnvYY_scan_buffer()" );␊ |
3043 | ␊ |
3044 | ␉b->yy_buf_size = size - 2;␉/* "- 2" to take care of EOB's */␊ |
3045 | ␉b->yy_buf_pos = b->yy_ch_buf = base;␊ |
3046 | ␉b->yy_is_our_buffer = 0;␊ |
3047 | ␉b->yy_input_file = 0;␊ |
3048 | ␉b->yy_n_chars = b->yy_buf_size;␊ |
3049 | ␉b->yy_is_interactive = 0;␊ |
3050 | ␉b->yy_at_bol = 1;␊ |
3051 | ␉b->yy_fill_buffer = 0;␊ |
3052 | ␉b->yy_buffer_status = YY_BUFFER_NEW;␊ |
3053 | ␊ |
3054 | ␉commentcnvYY_switch_to_buffer(b );␊ |
3055 | ␊ |
3056 | ␉return b;␊ |
3057 | }␊ |
3058 | ␊ |
3059 | /** Setup the input buffer state to scan a string. The next call to commentcnvYYlex() will␊ |
3060 | * scan from a @e copy of @a str.␊ |
3061 | * @param yystr a NUL-terminated string to scan␊ |
3062 | * ␊ |
3063 | * @return the newly allocated buffer state object.␊ |
3064 | * @note If you want to scan bytes that may contain NUL values, then use␊ |
3065 | * commentcnvYY_scan_bytes() instead.␊ |
3066 | */␊ |
3067 | YY_BUFFER_STATE commentcnvYY_scan_string (yyconst char * yystr )␊ |
3068 | {␊ |
3069 | ␊ |
3070 | ␉return commentcnvYY_scan_bytes(yystr,strlen(yystr) );␊ |
3071 | }␊ |
3072 | ␊ |
3073 | /** Setup the input buffer state to scan the given bytes. The next call to commentcnvYYlex() will␊ |
3074 | * scan from a @e copy of @a bytes.␊ |
3075 | * @param bytes the byte buffer to scan␊ |
3076 | * @param len the number of bytes in the buffer pointed to by @a bytes.␊ |
3077 | * ␊ |
3078 | * @return the newly allocated buffer state object.␊ |
3079 | */␊ |
3080 | YY_BUFFER_STATE commentcnvYY_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len )␊ |
3081 | {␊ |
3082 | ␉YY_BUFFER_STATE b;␊ |
3083 | ␉char *buf;␊ |
3084 | ␉yy_size_t n, i;␊ |
3085 | ␊ |
3086 | ␉/* Get memory for full buffer, including space for trailing EOB's. */␊ |
3087 | ␉n = _yybytes_len + 2;␊ |
3088 | ␉buf = (char *) commentcnvYYalloc(n );␊ |
3089 | ␉if ( ! buf )␊ |
3090 | ␉␉YY_FATAL_ERROR( "out of dynamic memory in commentcnvYY_scan_bytes()" );␊ |
3091 | ␊ |
3092 | ␉for ( i = 0; i < _yybytes_len; ++i )␊ |
3093 | ␉␉buf[i] = yybytes[i];␊ |
3094 | ␊ |
3095 | ␉buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;␊ |
3096 | ␊ |
3097 | ␉b = commentcnvYY_scan_buffer(buf,n );␊ |
3098 | ␉if ( ! b )␊ |
3099 | ␉␉YY_FATAL_ERROR( "bad buffer in commentcnvYY_scan_bytes()" );␊ |
3100 | ␊ |
3101 | ␉/* It's okay to grow etc. this buffer, and we should throw it␊ |
3102 | ␉ * away when we're done.␊ |
3103 | ␉ */␊ |
3104 | ␉b->yy_is_our_buffer = 1;␊ |
3105 | ␊ |
3106 | ␉return b;␊ |
3107 | }␊ |
3108 | ␊ |
3109 | #ifndef YY_EXIT_FAILURE␊ |
3110 | #define YY_EXIT_FAILURE 2␊ |
3111 | #endif␊ |
3112 | ␊ |
3113 | static void yy_fatal_error (yyconst char* msg )␊ |
3114 | {␊ |
3115 | ␉(void) fprintf( stderr, "%s\n", msg );␊ |
3116 | ␉exit( YY_EXIT_FAILURE );␊ |
3117 | }␊ |
3118 | ␊ |
3119 | /* Redefine yyless() so it works in section 3 code. */␊ |
3120 | ␊ |
3121 | #undef yyless␊ |
3122 | #define yyless(n) \␊ |
3123 | ␉do \␊ |
3124 | ␉␉{ \␊ |
3125 | ␉␉/* Undo effects of setting up commentcnvYYtext. */ \␊ |
3126 | int yyless_macro_arg = (n); \␊ |
3127 | YY_LESS_LINENO(yyless_macro_arg);\␊ |
3128 | ␉␉commentcnvYYtext[commentcnvYYleng] = (yy_hold_char); \␊ |
3129 | ␉␉(yy_c_buf_p) = commentcnvYYtext + yyless_macro_arg; \␊ |
3130 | ␉␉(yy_hold_char) = *(yy_c_buf_p); \␊ |
3131 | ␉␉*(yy_c_buf_p) = '\0'; \␊ |
3132 | ␉␉commentcnvYYleng = yyless_macro_arg; \␊ |
3133 | ␉␉} \␊ |
3134 | ␉while ( 0 )␊ |
3135 | ␊ |
3136 | /* Accessor methods (get/set functions) to struct members. */␊ |
3137 | ␊ |
3138 | /** Get the current line number.␊ |
3139 | * ␊ |
3140 | */␊ |
3141 | int commentcnvYYget_lineno (void)␊ |
3142 | {␊ |
3143 | ␊ |
3144 | return commentcnvYYlineno;␊ |
3145 | }␊ |
3146 | ␊ |
3147 | /** Get the input stream.␊ |
3148 | * ␊ |
3149 | */␊ |
3150 | FILE *commentcnvYYget_in (void)␊ |
3151 | {␊ |
3152 | return commentcnvYYin;␊ |
3153 | }␊ |
3154 | ␊ |
3155 | /** Get the output stream.␊ |
3156 | * ␊ |
3157 | */␊ |
3158 | FILE *commentcnvYYget_out (void)␊ |
3159 | {␊ |
3160 | return commentcnvYYout;␊ |
3161 | }␊ |
3162 | ␊ |
3163 | /** Get the length of the current token.␊ |
3164 | * ␊ |
3165 | */␊ |
3166 | yy_size_t commentcnvYYget_leng (void)␊ |
3167 | {␊ |
3168 | return commentcnvYYleng;␊ |
3169 | }␊ |
3170 | ␊ |
3171 | /** Get the current token.␊ |
3172 | * ␊ |
3173 | */␊ |
3174 | ␊ |
3175 | char *commentcnvYYget_text (void)␊ |
3176 | {␊ |
3177 | return commentcnvYYtext;␊ |
3178 | }␊ |
3179 | ␊ |
3180 | /** Set the current line number.␊ |
3181 | * @param line_number␊ |
3182 | * ␊ |
3183 | */␊ |
3184 | void commentcnvYYset_lineno (int line_number )␊ |
3185 | {␊ |
3186 | ␊ |
3187 | commentcnvYYlineno = line_number;␊ |
3188 | }␊ |
3189 | ␊ |
3190 | /** Set the input stream. This does not discard the current␊ |
3191 | * input buffer.␊ |
3192 | * @param in_str A readable stream.␊ |
3193 | * ␊ |
3194 | * @see commentcnvYY_switch_to_buffer␊ |
3195 | */␊ |
3196 | void commentcnvYYset_in (FILE * in_str )␊ |
3197 | {␊ |
3198 | commentcnvYYin = in_str ;␊ |
3199 | }␊ |
3200 | ␊ |
3201 | void commentcnvYYset_out (FILE * out_str )␊ |
3202 | {␊ |
3203 | commentcnvYYout = out_str ;␊ |
3204 | }␊ |
3205 | ␊ |
3206 | int commentcnvYYget_debug (void)␊ |
3207 | {␊ |
3208 | return commentcnvYY_flex_debug;␊ |
3209 | }␊ |
3210 | ␊ |
3211 | void commentcnvYYset_debug (int bdebug )␊ |
3212 | {␊ |
3213 | commentcnvYY_flex_debug = bdebug ;␊ |
3214 | }␊ |
3215 | ␊ |
3216 | static int yy_init_globals (void)␊ |
3217 | {␊ |
3218 | /* Initialization is the same as for the non-reentrant scanner.␊ |
3219 | * This function is called from commentcnvYYlex_destroy(), so don't allocate here.␊ |
3220 | */␊ |
3221 | ␊ |
3222 | (yy_buffer_stack) = 0;␊ |
3223 | (yy_buffer_stack_top) = 0;␊ |
3224 | (yy_buffer_stack_max) = 0;␊ |
3225 | (yy_c_buf_p) = (char *) 0;␊ |
3226 | (yy_init) = 0;␊ |
3227 | (yy_start) = 0;␊ |
3228 | ␊ |
3229 | (yy_state_buf) = 0;␊ |
3230 | (yy_state_ptr) = 0;␊ |
3231 | (yy_full_match) = 0;␊ |
3232 | (yy_lp) = 0;␊ |
3233 | ␊ |
3234 | /* Defined in main.c */␊ |
3235 | #ifdef YY_STDINIT␊ |
3236 | commentcnvYYin = stdin;␊ |
3237 | commentcnvYYout = stdout;␊ |
3238 | #else␊ |
3239 | commentcnvYYin = (FILE *) 0;␊ |
3240 | commentcnvYYout = (FILE *) 0;␊ |
3241 | #endif␊ |
3242 | ␊ |
3243 | /* For future reference: Set errno on error, since we are called by␊ |
3244 | * commentcnvYYlex_init()␊ |
3245 | */␊ |
3246 | return 0;␊ |
3247 | }␊ |
3248 | ␊ |
3249 | /* commentcnvYYlex_destroy is for both reentrant and non-reentrant scanners. */␊ |
3250 | int commentcnvYYlex_destroy (void)␊ |
3251 | {␊ |
3252 | ␊ |
3253 | /* Pop the buffer stack, destroying each element. */␊ |
3254 | ␉while(YY_CURRENT_BUFFER){␊ |
3255 | ␉␉commentcnvYY_delete_buffer(YY_CURRENT_BUFFER );␊ |
3256 | ␉␉YY_CURRENT_BUFFER_LVALUE = NULL;␊ |
3257 | ␉␉commentcnvYYpop_buffer_state();␊ |
3258 | ␉}␊ |
3259 | ␊ |
3260 | ␉/* Destroy the stack itself. */␊ |
3261 | ␉commentcnvYYfree((yy_buffer_stack) );␊ |
3262 | ␉(yy_buffer_stack) = NULL;␊ |
3263 | ␊ |
3264 | commentcnvYYfree ( (yy_state_buf) );␊ |
3265 | (yy_state_buf) = NULL;␊ |
3266 | ␊ |
3267 | /* Reset the globals. This is important in a non-reentrant scanner so the next time␊ |
3268 | * commentcnvYYlex() is called, initialization will occur. */␊ |
3269 | yy_init_globals( );␊ |
3270 | ␊ |
3271 | return 0;␊ |
3272 | }␊ |
3273 | ␊ |
3274 | /*␊ |
3275 | * Internal utility routines.␊ |
3276 | */␊ |
3277 | ␊ |
3278 | #ifndef yytext_ptr␊ |
3279 | static void yy_flex_strncpy (char* s1, yyconst char * s2, int n )␊ |
3280 | {␊ |
3281 | ␉register int i;␊ |
3282 | ␉for ( i = 0; i < n; ++i )␊ |
3283 | ␉␉s1[i] = s2[i];␊ |
3284 | }␊ |
3285 | #endif␊ |
3286 | ␊ |
3287 | #ifdef YY_NEED_STRLEN␊ |
3288 | static int yy_flex_strlen (yyconst char * s )␊ |
3289 | {␊ |
3290 | ␉register int n;␊ |
3291 | ␉for ( n = 0; s[n]; ++n )␊ |
3292 | ␉␉;␊ |
3293 | ␊ |
3294 | ␉return n;␊ |
3295 | }␊ |
3296 | #endif␊ |
3297 | ␊ |
3298 | void *commentcnvYYalloc (yy_size_t size )␊ |
3299 | {␊ |
3300 | ␉return (void *) malloc( size );␊ |
3301 | }␊ |
3302 | ␊ |
3303 | void *commentcnvYYrealloc (void * ptr, yy_size_t size )␊ |
3304 | {␊ |
3305 | ␉/* The cast to (char *) in the following accommodates both␊ |
3306 | ␉ * implementations that use char* generic pointers, and those␊ |
3307 | ␉ * that use void* generic pointers. It works with the latter␊ |
3308 | ␉ * because both ANSI C and C++ allow castless assignment from␊ |
3309 | ␉ * any pointer type to void*, and deal with argument conversions␊ |
3310 | ␉ * as though doing an assignment.␊ |
3311 | ␉ */␊ |
3312 | ␉return (void *) realloc( (char *) ptr, size );␊ |
3313 | }␊ |
3314 | ␊ |
3315 | void commentcnvYYfree (void * ptr )␊ |
3316 | {␊ |
3317 | ␉free( (char *) ptr );␉/* see commentcnvYYrealloc() for (char *) cast */␊ |
3318 | }␊ |
3319 | ␊ |
3320 | #define YYTABLES_NAME "yytables"␊ |
3321 | ␊ |
3322 | #line 774 "commentcnv.l"␊ |
3323 | ␊ |
3324 | ␊ |
3325 | ␊ |
3326 | void replaceComment(int offset)␊ |
3327 | {␊ |
3328 | if (g_mlBrief)␊ |
3329 | {␊ |
3330 | copyToOutput(commentcnvYYtext,commentcnvYYleng);␊ |
3331 | }␊ |
3332 | else␊ |
3333 | {␊ |
3334 | //printf("replaceComment(%s)\n",commentcnvYYtext);␊ |
3335 | int i=computeIndent(&commentcnvYYtext[offset]);␊ |
3336 | if (i==g_blockHeadCol)␊ |
3337 | {␊ |
3338 | replaceCommentMarker(commentcnvYYtext,commentcnvYYleng);␊ |
3339 | }␊ |
3340 | else␊ |
3341 | {␊ |
3342 | copyToOutput(" */",3);␊ |
3343 | int i;for (i=commentcnvYYleng-1;i>=0;i--) unput(commentcnvYYtext[i]);␊ |
3344 | g_inSpecialComment=FALSE;␊ |
3345 | BEGIN(Scan); ␊ |
3346 | } ␊ |
3347 | }␊ |
3348 | }␊ |
3349 | ␊ |
3350 | /*! This function does three things:␊ |
3351 | * -# It converts multi-line C++ style comment blocks (that are aligned)␊ |
3352 | * to C style comment blocks (if MULTILINE_CPP_IS_BRIEF is set to NO).␊ |
3353 | * -# It replaces aliases with their definition (see ALIASES)␊ |
3354 | * -# It handles conditional sections (cond...endcond blocks)␊ |
3355 | */␊ |
3356 | void convertCppComments(BufStr *inBuf,BufStr *outBuf,const char *fileName)␊ |
3357 | {␊ |
3358 | //printf("convertCppComments(%s)\n",fileName);␊ |
3359 | g_inBuf = inBuf;␊ |
3360 | g_outBuf = outBuf;␊ |
3361 | g_inBufPos = 0;␊ |
3362 | g_col = 0;␊ |
3363 | g_mlBrief = Config_getBool("MULTILINE_CPP_IS_BRIEF");␊ |
3364 | g_skip = FALSE;␊ |
3365 | g_fileName = fileName;␊ |
3366 | g_lang = getLanguageFromFileName(fileName);␊ |
3367 | g_pythonDocString = FALSE;␊ |
3368 | g_lineNr = 1;␊ |
3369 | g_condStack.clear();␊ |
3370 | g_condStack.setAutoDelete(TRUE);␊ |
3371 | BEGIN(Scan);␊ |
3372 | commentcnvYYlex();␊ |
3373 | while (!g_condStack.isEmpty())␊ |
3374 | {␊ |
3375 | CondCtx *ctx = g_condStack.pop();␊ |
3376 | QCString sectionInfo = " ";␊ |
3377 | if (ctx->sectionId!=" ") sectionInfo.sprintf(" with label %s ",ctx->sectionId.data()); ␊ |
3378 | warn(g_fileName,ctx->lineNr,"Conditional section%sdoes not have "␊ |
3379 | ␉"a corresponding \\endcond command within this file.",sectionInfo.data());␊ |
3380 | }␊ |
3381 | if (Debug::isFlagSet(Debug::CommentCnv))␊ |
3382 | {␊ |
3383 | g_outBuf->at(g_outBuf->curPos())='\0';␊ |
3384 | msg("-------------\n%s\n-------------\n",g_outBuf->data());␊ |
3385 | }␊ |
3386 | }␊ |
3387 | ␊ |
3388 | ␊ |
3389 | //----------------------------------------------------------------------------␊ |
3390 | #if !defined(YY_FLEX_SUBMINOR_VERSION) ␊ |
3391 | extern "C" { // some bogus code to keep the compiler happy␊ |
3392 | void commentcnvYYdummy() { yy_flex_realloc(0,0); } ␊ |
3393 | }␊ |
3394 | #endif␊ |
3395 | ␊ |
3396 | ␊ |
3397 |