Flutter Engine
 
Loading...
Searching...
No Matches
comments.cc
Go to the documentation of this file.
1#line 1 "comments.cc"
2// No linting because it's generated code.
3// FLUTTER_NOLINT: https://github.com/flutter/flutter/issues/167141
4
5#line 5 "comments.cc"
6
7#define YY_INT_ALIGNED short int
8
9/* A lexical scanner generated by flex */
10
11#define FLEX_SCANNER
12#define YY_FLEX_MAJOR_VERSION 2
13#define YY_FLEX_MINOR_VERSION 6
14#define YY_FLEX_SUBMINOR_VERSION 4
15#if YY_FLEX_SUBMINOR_VERSION > 0
16#define FLEX_BETA
17#endif
18
19/* First, we deal with platform-specific or compiler-specific issues. */
20
21/* begin standard C headers. */
22#include <errno.h>
23#include <stdio.h>
24#include <stdlib.h>
25#include <string.h>
26
27/* end standard C headers. */
28
29/* flex integer type definitions */
30
31#ifndef FLEXINT_H
32#define FLEXINT_H
33
34/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
35
36#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
37
38/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
39 * if you want the limit (max/min) macros for int types.
40 */
41#ifndef __STDC_LIMIT_MACROS
42#define __STDC_LIMIT_MACROS 1
43#endif
44
45#include <inttypes.h>
46typedef int8_t flex_int8_t;
47typedef uint8_t flex_uint8_t;
48typedef int16_t flex_int16_t;
49typedef uint16_t flex_uint16_t;
50typedef int32_t flex_int32_t;
51typedef uint32_t flex_uint32_t;
52typedef uint64_t flex_uint64_t;
53#else
54typedef signed char flex_int8_t;
55typedef short int flex_int16_t;
56typedef int flex_int32_t;
57typedef unsigned char flex_uint8_t;
58typedef unsigned short int flex_uint16_t;
59typedef unsigned int flex_uint32_t;
60
61/* Limits of integral types. */
62#ifndef INT8_MIN
63#define INT8_MIN (-128)
64#endif
65#ifndef INT16_MIN
66#define INT16_MIN (-32767 - 1)
67#endif
68#ifndef INT32_MIN
69#define INT32_MIN (-2147483647 - 1)
70#endif
71#ifndef INT8_MAX
72#define INT8_MAX (127)
73#endif
74#ifndef INT16_MAX
75#define INT16_MAX (32767)
76#endif
77#ifndef INT32_MAX
78#define INT32_MAX (2147483647)
79#endif
80#ifndef UINT8_MAX
81#define UINT8_MAX (255U)
82#endif
83#ifndef UINT16_MAX
84#define UINT16_MAX (65535U)
85#endif
86#ifndef UINT32_MAX
87#define UINT32_MAX (4294967295U)
88#endif
89
90#ifndef SIZE_MAX
91#define SIZE_MAX (~(size_t)0)
92#endif
93
94#endif /* ! C99 */
95
96#endif /* ! FLEXINT_H */
97
98/* begin standard C++ headers. */
99
100/* TODO: this is always defined, so inline it */
101#define yyconst const
102
103#if defined(__GNUC__) && __GNUC__ >= 3
104#define yynoreturn __attribute__((__noreturn__))
105#else
106#define yynoreturn
107#endif
108
109/* Returned upon end-of-file. */
110#define YY_NULL 0
111
112/* Promotes a possibly negative, possibly signed char to an
113 * integer in range [0..255] for use as an array index.
114 */
115#define YY_SC_TO_UI(c) ((YY_CHAR)(c))
116
117/* An opaque pointer. */
118#ifndef YY_TYPEDEF_YY_SCANNER_T
119#define YY_TYPEDEF_YY_SCANNER_T
120typedef void* yyscan_t;
121#endif
122
123/* For convenience, these vars (plus the bison vars far below)
124 are macros in the reentrant scanner. */
125#define yyin yyg->yyin_r
126#define yyout yyg->yyout_r
127#define yyextra yyg->yyextra_r
128#define yyleng yyg->yyleng_r
129#define yytext yyg->yytext_r
130#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
131#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
132#define yy_flex_debug yyg->yy_flex_debug_r
133
134/* Enter a start condition. This macro really ought to take a parameter,
135 * but we do it the disgusting crufty way forced on us by the ()-less
136 * definition of BEGIN.
137 */
138#define BEGIN yyg->yy_start = 1 + 2 *
139/* Translate the current start state into a value that can be later handed
140 * to BEGIN to return to the state. The YYSTATE alias is for lex
141 * compatibility.
142 */
143#define YY_START ((yyg->yy_start - 1) / 2)
144#define YYSTATE YY_START
145/* Action number for EOF rule of a given start state. */
146#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
147/* Special action meaning "start processing a new file". */
148#define YY_NEW_FILE yyrestart(yyin, yyscanner)
149#define YY_END_OF_BUFFER_CHAR 0
150
151/* Size of default input buffer. */
152#ifndef YY_BUF_SIZE
153#ifdef __ia64__
154/* On IA-64, the buffer size is 16k, not 8k.
155 * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
156 * Ditto for the __ia64__ case accordingly.
157 */
158#define YY_BUF_SIZE 32768
159#else
160#define YY_BUF_SIZE 16384
161#endif /* __ia64__ */
162#endif
163
164/* The state buf must be large enough to hold one state per character in the
165 * 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
172#endif
173
174#ifndef YY_TYPEDEF_YY_SIZE_T
175#define YY_TYPEDEF_YY_SIZE_T
176typedef size_t yy_size_t;
177#endif
178
179#define EOB_ACT_CONTINUE_SCAN 0
180#define EOB_ACT_END_OF_FILE 1
181#define EOB_ACT_LAST_MATCH 2
182
183#define YY_LESS_LINENO(n)
184#define YY_LINENO_REWIND_TO(ptr)
185
186/* Return all but the first "n" matched characters back to the input stream. */
187#define yyless(n) \
188 do { \
189 /* Undo effects of setting up yytext. */ \
190 int yyless_macro_arg = (n); \
191 YY_LESS_LINENO(yyless_macro_arg); \
192 *yy_cp = yyg->yy_hold_char; \
193 YY_RESTORE_YY_MORE_OFFSET \
194 yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
195 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
196 } while (0)
197#define unput(c) yyunput(c, yyg->yytext_ptr, yyscanner)
198
199#ifndef YY_STRUCT_YY_BUFFER_STATE
200#define YY_STRUCT_YY_BUFFER_STATE
203
204 char* yy_ch_buf; /* input buffer */
205 char* yy_buf_pos; /* current position in input buffer */
206
207 /* Size of input buffer in bytes, not including room for EOB
208 * characters.
209 */
211
212 /* Number of characters read into yy_ch_buf, not including EOB
213 * characters.
214 */
216
217 /* Whether we "own" the buffer - i.e., we know we created it,
218 * and can realloc() it to grow it, and should free() it to
219 * delete it.
220 */
222
223 /* Whether this is an "interactive" input source; if so, and
224 * if we're using stdio for input, then we want to use getc()
225 * instead of fread(), to make sure we stop fetching input after
226 * each newline.
227 */
229
230 /* Whether we're considered to be at the beginning of a line.
231 * If so, '^' rules will be active on the next match, otherwise
232 * not.
233 */
235
236 int yy_bs_lineno; /**< The line count. */
237 int yy_bs_column; /**< The column count. */
238
239 /* Whether to try to fill the input buffer when we reach the
240 * end of it.
241 */
243
245
246#define YY_BUFFER_NEW 0
247#define YY_BUFFER_NORMAL 1
248 /* When an EOF's been seen but there's still some text to process
249 * then we mark the buffer as YY_EOF_PENDING, to indicate that we
250 * shouldn't try reading from the input source any more. We might
251 * still have a bunch of tokens to match, though, because of
252 * possible backing-up.
253 *
254 * When we actually see the EOF, we change the status to "new"
255 * (via yyrestart()), so that the user can continue scanning by
256 * just pointing yyin at a new input file.
257 */
258#define YY_BUFFER_EOF_PENDING 2
259};
260#endif /* !YY_STRUCT_YY_BUFFER_STATE */
261
262/* We provide macros for accessing buffer states in case in the
263 * future we want to put the buffer states in a more general
264 * "scanner state".
265 *
266 * Returns the top of the stack, or NULL.
267 */
268#define YY_CURRENT_BUFFER \
269 (yyg->yy_buffer_stack ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] : NULL)
270/* Same as previous macro, but useful when we know that the buffer stack is not
271 * NULL or when we need an lvalue. For internal use only.
272 */
273#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
274
275void yyrestart(FILE* input_file, yyscan_t yyscanner);
276void yy_switch_to_buffer(YY_BUFFER_STATE new_buffer, yyscan_t yyscanner);
277YY_BUFFER_STATE yy_create_buffer(FILE* file, int size, yyscan_t yyscanner);
280void yypush_buffer_state(YY_BUFFER_STATE new_buffer, yyscan_t yyscanner);
282
283static void yyensure_buffer_stack(yyscan_t yyscanner);
284static void yy_load_buffer_state(yyscan_t yyscanner);
285static void yy_init_buffer(YY_BUFFER_STATE b, FILE* file, yyscan_t yyscanner);
286#define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER, yyscanner)
287
289YY_BUFFER_STATE yy_scan_string(const char* yy_str, yyscan_t yyscanner);
291 yy_size_t len,
292 yyscan_t yyscanner);
293
294void* yyalloc(yy_size_t, yyscan_t yyscanner);
295void* yyrealloc(void*, yy_size_t, yyscan_t yyscanner);
296void yyfree(void*, yyscan_t yyscanner);
297
298#define yy_new_buffer yy_create_buffer
299#define yy_set_interactive(is_interactive) \
300 { \
301 if (!YY_CURRENT_BUFFER) { \
302 yyensure_buffer_stack(yyscanner); \
303 YY_CURRENT_BUFFER_LVALUE = \
304 yy_create_buffer(yyin, YY_BUF_SIZE, yyscanner); \
305 } \
306 YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
307 }
308#define yy_set_bol(at_bol) \
309 { \
310 if (!YY_CURRENT_BUFFER) { \
311 yyensure_buffer_stack(yyscanner); \
312 YY_CURRENT_BUFFER_LVALUE = \
313 yy_create_buffer(yyin, YY_BUF_SIZE, yyscanner); \
314 } \
315 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
316 }
317#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
318
319/* Begin user sect3 */
320
321#define yywrap(yyscanner) (/*CONSTCOND*/ 1)
322#define YY_SKIP_YYWRAP
324
325typedef int yy_state_type;
326
327#define yytext_ptr yytext_r
328
331 yyscan_t yyscanner);
332static int yy_get_next_buffer(yyscan_t yyscanner);
333static void yynoreturn yy_fatal_error(const char* msg, yyscan_t yyscanner);
334
335/* Done after the current pattern has been matched and before the
336 * corresponding action - sets up yytext.
337 */
338#define YY_DO_BEFORE_ACTION \
339 yyg->yytext_ptr = yy_bp; \
340 yyleng = (yy_size_t)(yy_cp - yy_bp); \
341 yyg->yy_hold_char = *yy_cp; \
342 *yy_cp = '\0'; \
343 yyg->yy_c_buf_p = yy_cp;
344#define YY_NUM_RULES 8
345#define YY_END_OF_BUFFER 9
346/* This struct is not used in this scanner,
347 but its presence is necessary. */
352static const flex_int16_t yy_accept[37] = {
353 0, 0, 0, 0, 0, 0, 0, 9, 7, 7, 1, 7, 8, 4, 8, 6, 6, 0, 1,
354 0, 1, 2, 0, 4, 0, 0, 0, 5, 0, 2, 2, 0, 3, 0, 5, 0, 0};
355
356static const YY_CHAR yy_ec[256] = {
357 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
358 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 4, 1, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 6, 1, 1,
359 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
360 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
361 1,
362
363 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
364 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
365 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
366 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
367
368 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
369 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
370 1, 1, 1, 1, 1};
371
372static const YY_CHAR yy_meta[7] = {0, 1, 1, 2, 1, 1, 3};
373
374static const flex_int16_t yy_base[45] = {
375 0, 0, 0, 4, 7, 18, 13, 14, 62, 11, 0, 13, 17, 62, 20,
376 62, 25, 0, 0, 0, 0, 29, 5, 62, 0, 32, 0, 0, 0, 62,
377 0, 35, 62, 2, 0, 0, 62, 40, 43, 46, 49, 52, 55, 58, 0};
378
379static const flex_int16_t yy_def[45] = {
380 0, 37, 37, 38, 38, 39, 39, 36, 36, 36, 40, 36, 41, 36, 41,
381 36, 36, 9, 40, 11, 40, 36, 14, 36, 14, 42, 16, 43, 44, 36,
382 21, 42, 36, 31, 43, 31, 0, 36, 36, 36, 36, 36, 36, 36, 36};
383
384static const flex_int16_t yy_nxt[69] = {
385 0, 36, 9, 27, 10, 36, 11, 13, 35, 14, 13, 22, 14, 17, 36, 18, 16, 19,
386 21, 18, 23, 16, 24, 23, 36, 24, 25, 26, 36, 27, 36, 28, 29, 36, 30, 32,
387 36, 33, 32, 36, 33, 8, 8, 8, 12, 12, 12, 15, 15, 15, 20, 36, 20, 22,
388 22, 22, 31, 31, 31, 34, 36, 34, 7, 36, 36, 36, 36, 36, 36};
389
390static const flex_int16_t yy_chk[69] = {
391 0, 0, 2, 44, 2, 0, 2, 3, 33, 3, 4, 22, 4, 9, 7, 9, 6, 9,
392 11, 11, 12, 5, 12, 14, 0, 14, 14, 16, 0, 16, 0, 16, 21, 0, 21, 25,
393 0, 25, 31, 0, 31, 37, 37, 37, 38, 38, 38, 39, 39, 39, 40, 0, 40, 41,
394 41, 41, 42, 42, 42, 43, 0, 43, 36, 36, 36, 36, 36, 36, 36};
395
396/* The intent behind this definition is that it'll catch
397 * any uses of REJECT which flex missed.
398 */
399#define REJECT reject_used_but_not_detected
400#define yymore() yymore_used_but_not_detected
401#define YY_MORE_ADJ 0
402#define YY_RESTORE_YY_MORE_OFFSET
403#line 1 "comments.l"
404/**
405 * Copyright 2013 The Flutter Authors. All rights reserved.
406 * Use of this source code is governed by a BSD-style license that can be
407 * found in the LICENSE file.
408 */
409/**
410 * To regenerate comments.cc run:
411 * flex -o comments.cc comments.l
412 */
413
414#line 20 "comments.l"
417#pragma clang diagnostic ignored "-Wsign-compare"
418#pragma clang diagnostic ignored "-Wunused-function"
419#pragma clang diagnostic ignored "-Wunused-function"
420typedef void* yyscan_t;
421
422#include <string>
423
425 std::function<void(std::string_view)> callback;
426 std::string buffer;
427};
428#line 471 "comments.cc"
429
430#line 473 "comments.cc"
431
432#define INITIAL 0
433#define C_COMMENT 1
434#define BLOCK 2
435
436#ifndef YY_NO_UNISTD_H
437/* Special case for "unistd.h", since it is non-ANSI. We include it way
438 * down here because we want the user's section 1 to have been scanned first.
439 * The user has a chance to override it with an option.
440 */
441#include <unistd.h>
442#endif
443
444#define YY_EXTRA_TYPE LexerContext*
445
446/* Holds the entire state of the reentrant scanner. */
447struct yyguts_t {
448 /* User-defined. Not touched by flex. */
450
451 /* The rest are the same as the globals declared in the non-reentrant scanner.
452 */
454 size_t yy_buffer_stack_top; /**< index of top of stack. */
455 size_t yy_buffer_stack_max; /**< capacity of stack. */
456 YY_BUFFER_STATE* yy_buffer_stack; /**< Stack as an array. */
469
472
473 char* yytext_r;
476
477}; /* end struct yyguts_t */
478
479static int yy_init_globals(yyscan_t yyscanner);
480
481int yylex_init(yyscan_t* scanner);
482
483int yylex_init_extra(YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
484
485/* Accessor methods to globals.
486 These are made visible to non-reentrant scanners for convenience. */
487
488int yylex_destroy(yyscan_t yyscanner);
489
490int yyget_debug(yyscan_t yyscanner);
491
492void yyset_debug(int debug_flag, yyscan_t yyscanner);
493
495
496void yyset_extra(YY_EXTRA_TYPE user_defined, yyscan_t yyscanner);
497
498FILE* yyget_in(yyscan_t yyscanner);
499
500void yyset_in(FILE* _in_str, yyscan_t yyscanner);
501
502FILE* yyget_out(yyscan_t yyscanner);
503
504void yyset_out(FILE* _out_str, yyscan_t yyscanner);
505
507
508char* yyget_text(yyscan_t yyscanner);
509
510int yyget_lineno(yyscan_t yyscanner);
511
512void yyset_lineno(int _line_number, yyscan_t yyscanner);
513
514int yyget_column(yyscan_t yyscanner);
515
516void yyset_column(int _column_no, yyscan_t yyscanner);
517
518/* Macros after this point can all be overridden by user definitions in
519 * section 1.
520 */
521
522#ifndef YY_SKIP_YYWRAP
523#ifdef __cplusplus
524extern "C" int yywrap(yyscan_t yyscanner);
525#else
526extern int yywrap(yyscan_t yyscanner);
527#endif
528#endif
529
530#ifndef YY_NO_UNPUT
531
532static void yyunput(int c, char* buf_ptr, yyscan_t yyscanner);
533
534#endif
535
536#ifndef yytext_ptr
537static void yy_flex_strncpy(char*, const char*, int, yyscan_t yyscanner);
538#endif
539
540#ifdef YY_NEED_STRLEN
541static int yy_flex_strlen(const char*, yyscan_t yyscanner);
542#endif
543
544#ifndef YY_NO_INPUT
545#ifdef __cplusplus
546static int yyinput(yyscan_t yyscanner);
547#else
548static int input(yyscan_t yyscanner);
549#endif
550
551#endif
552
553/* Amount of stuff to slurp up with each read. */
554#ifndef YY_READ_BUF_SIZE
555#ifdef __ia64__
556/* On IA-64, the buffer size is 16k, not 8k */
557#define YY_READ_BUF_SIZE 16384
558#else
559#define YY_READ_BUF_SIZE 8192
560#endif /* __ia64__ */
561#endif
562
563/* Copy whatever the last rule matched to the standard output. */
564#ifndef ECHO
565/* This used to be an fputs(), but since the string might contain NUL's,
566 * we now use fwrite().
567 */
568#define ECHO \
569 do { \
570 if (fwrite(yytext, (size_t)yyleng, 1, yyout)) { \
571 } \
572 } while (0)
573#endif
574
575/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
576 * is returned in "result".
577 */
578#ifndef YY_INPUT
579#define YY_INPUT(buf, result, max_size) \
580 if (YY_CURRENT_BUFFER_LVALUE->yy_is_interactive) { \
581 int c = '*'; \
582 yy_size_t n; \
583 for (n = 0; n < max_size && (c = getc(yyin)) != EOF && c != '\n'; ++n) \
584 buf[n] = (char)c; \
585 if (c == '\n') \
586 buf[n++] = (char)c; \
587 if (c == EOF && ferror(yyin)) \
588 YY_FATAL_ERROR("input in flex scanner failed"); \
589 result = n; \
590 } else { \
591 errno = 0; \
592 while ((result = (int)fread(buf, 1, (yy_size_t)max_size, yyin)) == 0 && \
593 ferror(yyin)) { \
594 if (errno != EINTR) { \
595 YY_FATAL_ERROR("input in flex scanner failed"); \
596 break; \
597 } \
598 errno = 0; \
599 clearerr(yyin); \
600 } \
601 }
602
603#endif
604
605/* No semi-colon after return; correct usage is to write "yyterminate();" -
606 * we don't want an extra ';' after the "return" because that will cause
607 * some compilers to complain about unreachable statements.
608 */
609#ifndef yyterminate
610#define yyterminate() return YY_NULL
611#endif
612
613/* Number of entries by which start-condition stack grows. */
614#ifndef YY_START_STACK_INCR
615#define YY_START_STACK_INCR 25
616#endif
617
618/* Report a fatal error. */
619#ifndef YY_FATAL_ERROR
620#define YY_FATAL_ERROR(msg) yy_fatal_error(msg, yyscanner)
621#endif
622
623/* end tables serialization structures and prototypes */
624
625/* Default declaration of generated scanner - a define so the user can
626 * easily add parameters.
627 */
628#ifndef YY_DECL
629#define YY_DECL_IS_OURS 1
630
631extern int yylex(yyscan_t yyscanner);
632
633#define YY_DECL int yylex(yyscan_t yyscanner)
634#endif /* !YY_DECL */
635
636/* Code executed at the beginning of each rule, after yytext and yyleng
637 * have been set up.
638 */
639#ifndef YY_USER_ACTION
640#define YY_USER_ACTION
641#endif
642
643/* Code executed at the end of each rule. */
644#ifndef YY_BREAK
645#define YY_BREAK /*LINTED*/ break;
646#endif
647
648#define YY_RULE_SETUP \
649 if (yyleng > 0) \
650 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (yytext[yyleng - 1] == '\n'); \
651 YY_USER_ACTION
652
653/** The main scanner function which does all the work.
654 */
656 yy_state_type yy_current_state;
657 char *yy_cp, *yy_bp;
659 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
660
661 if (!yyg->yy_init) {
662 yyg->yy_init = 1;
663
664#ifdef YY_USER_INIT
665 YY_USER_INIT;
666#endif
667
668 if (!yyg->yy_start)
669 yyg->yy_start = 1; /* first start state */
670
671 if (!yyin)
672 yyin = stdin;
673
674 if (!yyout)
675 yyout = stdout;
676
677 if (!YY_CURRENT_BUFFER) {
678 yyensure_buffer_stack(yyscanner);
680 }
681
682 yy_load_buffer_state(yyscanner);
683 }
684
685 {
686#line 40 "comments.l"
687
688#line 738 "comments.cc"
689
690 while (/*CONSTCOND*/ 1) /* loops until end-of-file is reached */
691 {
693
694 /* Support of yytext. */
696
697 /* yy_bp points to the position in yy_ch_buf of the start of
698 * the current run.
699 */
700 yy_bp = yy_cp;
701
702 yy_current_state = yyg->yy_start;
703 yy_current_state += YY_AT_BOL();
704 yy_match:
705 do {
706 YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
707 if (yy_accept[yy_current_state]) {
708 yyg->yy_last_accepting_state = yy_current_state;
710 }
711 while (yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state) {
712 yy_current_state = (int)yy_def[yy_current_state];
713 if (yy_current_state >= 37)
714 yy_c = yy_meta[yy_c];
715 }
716 yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
717 ++yy_cp;
718 } while (yy_base[yy_current_state] != 62);
719
720 yy_find_action:
721 yy_act = yy_accept[yy_current_state];
722 if (yy_act == 0) { /* have to back up */
724 yy_current_state = yyg->yy_last_accepting_state;
725 yy_act = yy_accept[yy_current_state];
726 }
727
729
730 do_action: /* This label is used only to access EOF actions. */
731
732 switch (yy_act) { /* beginning of action switch */
733 case 0: /* must back up */
734 /* undo the effects of YY_DO_BEFORE_ACTION */
737 yy_current_state = yyg->yy_last_accepting_state;
738 goto yy_find_action;
739
740 case 1:
742#line 41 "comments.l"
743 {
744 BEGIN(BLOCK);
746 }
748 case 2:
749 /* rule 2 can match eol */
751#line 45 "comments.l"
752 {
754 if (!yyextra->buffer.empty()) {
755 // If we go from a block to a c comment, add a newline between
756 // them.
757 yyextra->buffer.append("\n");
758 }
759 }
761
762 case 3:
763 /* rule 3 can match eol */
765#line 54 "comments.l"
766 {
767 BEGIN(INITIAL);
769 }
771 case 4:
772 /* rule 4 can match eol */
774#line 58 "comments.l"
775 {
777 }
779
780 case 5:
781 /* rule 5 can match eol */
783#line 64 "comments.l"
784 {
785 yyextra->buffer.append("\n", 1);
787 }
789 case 6:
790 /* rule 6 can match eol */
792#line 68 "comments.l"
793 {
794 BEGIN(INITIAL);
795 }
797
798 case 7:
799 /* rule 7 can match eol */
801#line 73 "comments.l"
802 {
803 if (!yyextra->buffer.empty()) {
804 yyextra->callback(yyextra->buffer);
805 yyextra->buffer.clear();
806 }
807 }
809 case 8:
811#line 79 "comments.l"
812 ECHO;
814#line 870 "comments.cc"
815 case YY_STATE_EOF(INITIAL):
817 case YY_STATE_EOF(BLOCK):
818 yyterminate();
819
820 case YY_END_OF_BUFFER: {
821 /* Amount of text matched not including the EOB char. */
822 int yy_amount_of_matched_text = (int)(yy_cp - yyg->yytext_ptr) - 1;
823
824 /* Undo the effects of YY_DO_BEFORE_ACTION. */
827
828 if (YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW) {
829 /* We're scanning a new file or input source. It's
830 * possible that this happened because the user
831 * just pointed yyin at a new source and called
832 * yylex(). If so, then we have to assure
833 * consistency between YY_CURRENT_BUFFER and our
834 * globals. Here is the right place to do so, because
835 * this is the first action (other than possibly a
836 * back-up) that will match for the new input source.
837 */
839 YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
840 YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
841 }
842
843 /* Note that here we test for yy_c_buf_p "<=" to the position
844 * of the first EOB in the buffer, since yy_c_buf_p will
845 * already have been incremented past the NUL character
846 * (since all states make transitions on EOB to the
847 * end-of-buffer state). Contrast this with the test
848 * in input().
849 */
850 if (yyg->yy_c_buf_p <=
852 ->yy_ch_buf[yyg->yy_n_chars]) { /* This was really a NUL. */
853 yy_state_type yy_next_state;
854
855 yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
856
857 yy_current_state = yy_get_previous_state(yyscanner);
858
859 /* Okay, we're now positioned to make the NUL
860 * transition. We couldn't have
861 * yy_get_previous_state() go ahead and do it
862 * for us because it doesn't know how to deal
863 * with the possibility of jamming (and we don't
864 * want to build jamming into it because then it
865 * will run more slowly).
866 */
867
868 yy_next_state = yy_try_NUL_trans(yy_current_state, yyscanner);
869
870 yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
871
872 if (yy_next_state) {
873 /* Consume the NUL. */
874 yy_cp = ++yyg->yy_c_buf_p;
875 yy_current_state = yy_next_state;
876 goto yy_match;
877 }
878
879 else {
881 goto yy_find_action;
882 }
883 }
884
885 else
886 switch (yy_get_next_buffer(yyscanner)) {
887 case EOB_ACT_END_OF_FILE: {
889
890 if (yywrap(yyscanner)) {
891 /* Note: because we've taken care in
892 * yy_get_next_buffer() to have set up
893 * yytext, we can now set up
894 * yy_c_buf_p so that if some total
895 * hoser (like flex itself) wants to
896 * call the scanner after we return the
897 * YY_NULL, it'll still work - another
898 * YY_NULL will get returned.
899 */
900 yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
901
903 goto do_action;
904 }
905
906 else {
909 }
910 break;
911 }
912
914 yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
915
916 yy_current_state = yy_get_previous_state(yyscanner);
917
919 yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
920 goto yy_match;
921
923 yyg->yy_c_buf_p =
925
926 yy_current_state = yy_get_previous_state(yyscanner);
927
929 yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
930 goto yy_find_action;
931 }
932 break;
933 }
934
935 default:
936 YY_FATAL_ERROR("fatal flex scanner internal error--no action found");
937 } /* end of action switch */
938 } /* end of scanning one token */
939 } /* end of user's declarations */
940} /* end of yylex */
941
942/* yy_get_next_buffer - try to read in a new buffer
943 *
944 * Returns a code representing an action:
945 * EOB_ACT_LAST_MATCH -
946 * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
947 * EOB_ACT_END_OF_FILE - end of file
948 */
949static int yy_get_next_buffer(yyscan_t yyscanner) {
950 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
951 char* dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
952 char* source = yyg->yytext_ptr;
953 int number_to_move, i;
954 int ret_val;
955
956 if (yyg->yy_c_buf_p >
957 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1])
958 YY_FATAL_ERROR("fatal flex scanner internal error--end of buffer missed");
959
960 if (YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer ==
961 0) { /* Don't try to fill the buffer, so this is an EOF. */
962 if (yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1) {
963 /* We matched a single character, the EOB, so
964 * treat this as a final EOF.
965 */
966 return EOB_ACT_END_OF_FILE;
967 }
968
969 else {
970 /* We matched some text prior to the EOB, first
971 * process it.
972 */
973 return EOB_ACT_LAST_MATCH;
974 }
975 }
976
977 /* Try to read more data. */
978
979 /* First move last chars to start of buffer. */
980 number_to_move = (int)(yyg->yy_c_buf_p - yyg->yytext_ptr - 1);
981
982 for (i = 0; i < number_to_move; ++i)
983 *(dest++) = *(source++);
984
985 if (YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING)
986 /* don't do the read, it's not guaranteed to return an EOF,
987 * just force an EOF
988 */
989 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
990
991 else {
992 yy_size_t num_to_read =
993 YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
994
995 while (num_to_read <= 0) { /* Not enough room in the buffer - grow it. */
996
997 /* just a shorter name for the current buffer */
999
1000 int yy_c_buf_p_offset = (int)(yyg->yy_c_buf_p - b->yy_ch_buf);
1001
1002 if (b->yy_is_our_buffer) {
1003 yy_size_t new_size = b->yy_buf_size * 2;
1004
1005 if (new_size <= 0)
1006 b->yy_buf_size += b->yy_buf_size / 8;
1007 else
1008 b->yy_buf_size *= 2;
1009
1010 b->yy_ch_buf = (char*)
1011 /* Include room in for 2 EOB chars. */
1012 yyrealloc((void*)b->yy_ch_buf, (yy_size_t)(b->yy_buf_size + 2),
1013 yyscanner);
1014 } else
1015 /* Can't grow it, we don't own it. */
1016 b->yy_ch_buf = NULL;
1017
1018 if (!b->yy_ch_buf)
1019 YY_FATAL_ERROR("fatal error - scanner input buffer overflow");
1020
1021 yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
1022
1023 num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
1024 }
1025
1026 if (num_to_read > YY_READ_BUF_SIZE)
1027 num_to_read = YY_READ_BUF_SIZE;
1028
1029 /* Read in more data. */
1030 YY_INPUT((&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
1031 yyg->yy_n_chars, num_to_read);
1032
1034 }
1035
1036 if (yyg->yy_n_chars == 0) {
1037 if (number_to_move == YY_MORE_ADJ) {
1038 ret_val = EOB_ACT_END_OF_FILE;
1039 yyrestart(yyin, yyscanner);
1040 }
1041
1042 else {
1043 ret_val = EOB_ACT_LAST_MATCH;
1045 }
1046 }
1047
1048 else
1049 ret_val = EOB_ACT_CONTINUE_SCAN;
1050
1051 if ((yyg->yy_n_chars + number_to_move) >
1052 YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
1053 /* Extend the array by 50%, plus the number we really need. */
1054 yy_size_t new_size =
1055 yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
1056 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf =
1057 (char*)yyrealloc((void*)YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,
1058 (yy_size_t)new_size, yyscanner);
1059 if (!YY_CURRENT_BUFFER_LVALUE->yy_ch_buf)
1060 YY_FATAL_ERROR("out of dynamic memory in yy_get_next_buffer()");
1061 /* "- 2" to take care of EOB's */
1062 YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int)(new_size - 2);
1063 }
1064
1065 yyg->yy_n_chars += number_to_move;
1067 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] =
1069
1070 yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
1071
1072 return ret_val;
1073}
1074
1075/* yy_get_previous_state - get the state just before the EOB char was reached */
1076
1078 yy_state_type yy_current_state;
1079 char* yy_cp;
1080 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1081
1082 yy_current_state = yyg->yy_start;
1083 yy_current_state += YY_AT_BOL();
1084
1085 for (yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p;
1086 ++yy_cp) {
1087 YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
1088 if (yy_accept[yy_current_state]) {
1089 yyg->yy_last_accepting_state = yy_current_state;
1091 }
1092 while (yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state) {
1093 yy_current_state = (int)yy_def[yy_current_state];
1094 if (yy_current_state >= 37)
1095 yy_c = yy_meta[yy_c];
1096 }
1097 yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
1098 }
1099
1100 return yy_current_state;
1101}
1102
1103/* yy_try_NUL_trans - try to make a transition on the NUL character
1104 *
1105 * synopsis
1106 * next_state = yy_try_NUL_trans( current_state );
1107 */
1108static yy_state_type yy_try_NUL_trans(yy_state_type yy_current_state,
1109 yyscan_t yyscanner) {
1110 int yy_is_jam;
1111 struct yyguts_t* yyg = (struct yyguts_t*)
1112 yyscanner; /* This var may be unused depending upon options. */
1113 char* yy_cp = yyg->yy_c_buf_p;
1114
1115 YY_CHAR yy_c = 1;
1116 if (yy_accept[yy_current_state]) {
1117 yyg->yy_last_accepting_state = yy_current_state;
1119 }
1120 while (yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state) {
1121 yy_current_state = (int)yy_def[yy_current_state];
1122 if (yy_current_state >= 37)
1123 yy_c = yy_meta[yy_c];
1124 }
1125 yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
1126 yy_is_jam = (yy_current_state == 36);
1127
1128 (void)yyg;
1129 return yy_is_jam ? 0 : yy_current_state;
1130}
1131
1132#ifndef YY_NO_UNPUT
1133
1134static void yyunput(int c, char* yy_bp, yyscan_t yyscanner) {
1135 char* yy_cp;
1136 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1137
1138 yy_cp = yyg->yy_c_buf_p;
1139
1140 /* undo effects of setting up yytext */
1142
1143 if (yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf +
1144 2) { /* need to shift things up to make room */
1145 /* +2 for EOB chars. */
1146 yy_size_t number_to_move = yyg->yy_n_chars + 2;
1147 char* dest = &YY_CURRENT_BUFFER_LVALUE
1148 ->yy_ch_buf[YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
1149 char* source = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
1150
1151 while (source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf)
1152 *--dest = *--source;
1153
1154 yy_cp += (int)(dest - source);
1155 yy_bp += (int)(dest - source);
1156 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars =
1157 (int)YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
1158
1159 if (yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2)
1160 YY_FATAL_ERROR("flex scanner push-back overflow");
1161 }
1162
1163 *--yy_cp = (char)c;
1164
1165 yyg->yytext_ptr = yy_bp;
1167 yyg->yy_c_buf_p = yy_cp;
1168}
1169
1170#endif
1171
1172#ifndef YY_NO_INPUT
1173#ifdef __cplusplus
1174static int yyinput(yyscan_t yyscanner)
1175#else
1176static int input(yyscan_t yyscanner)
1177#endif
1178
1179{
1180 int c;
1181 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1182
1184
1186 /* yy_c_buf_p now points to the character we want to return.
1187 * If this occurs *before* the EOB characters, then it's a
1188 * valid NUL; if not, then we've hit the end of the buffer.
1189 */
1191 /* This was really a NUL. */
1192 *yyg->yy_c_buf_p = '\0';
1193
1194 else { /* need more input */
1195 yy_size_t offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
1196 ++yyg->yy_c_buf_p;
1197
1198 switch (yy_get_next_buffer(yyscanner)) {
1199 case EOB_ACT_LAST_MATCH:
1200 /* This happens because yy_g_n_b()
1201 * sees that we've accumulated a
1202 * token and flags that we need to
1203 * try matching the token before
1204 * proceeding. But for input(),
1205 * there's no matching to consider.
1206 * So convert the EOB_ACT_LAST_MATCH
1207 * to EOB_ACT_END_OF_FILE.
1208 */
1209
1210 /* Reset buffer status. */
1211 yyrestart(yyin, yyscanner);
1212
1213 /*FALLTHROUGH*/
1214
1215 case EOB_ACT_END_OF_FILE: {
1216 if (yywrap(yyscanner))
1217 return 0;
1218
1221#ifdef __cplusplus
1222 return yyinput(yyscanner);
1223#else
1224 return input(yyscanner);
1225#endif
1226 }
1227
1229 yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
1230 break;
1231 }
1232 }
1233 }
1234
1235 c = *(unsigned char*)yyg->yy_c_buf_p; /* cast for 8-bit char's */
1236 *yyg->yy_c_buf_p = '\0'; /* preserve yytext */
1238
1239 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (c == '\n');
1240
1241 return c;
1242}
1243#endif /* ifndef YY_NO_INPUT */
1244
1245/** Immediately switch to a different input stream.
1246 * @param input_file A readable stream.
1247 * @param yyscanner The scanner object.
1248 * @note This function does not reset the start condition to @c INITIAL .
1249 */
1250void yyrestart(FILE* input_file, yyscan_t yyscanner) {
1251 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1252
1253 if (!YY_CURRENT_BUFFER) {
1254 yyensure_buffer_stack(yyscanner);
1256 }
1257
1258 yy_init_buffer(YY_CURRENT_BUFFER, input_file, yyscanner);
1259 yy_load_buffer_state(yyscanner);
1260}
1261
1262/** Switch to a different input buffer.
1263 * @param new_buffer The new input buffer.
1264 * @param yyscanner The scanner object.
1265 */
1266void yy_switch_to_buffer(YY_BUFFER_STATE new_buffer, yyscan_t yyscanner) {
1267 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1268
1269 /* TODO. We should be able to replace this entire function body
1270 * with
1271 * yypop_buffer_state();
1272 * yypush_buffer_state(new_buffer);
1273 */
1274 yyensure_buffer_stack(yyscanner);
1275 if (YY_CURRENT_BUFFER == new_buffer)
1276 return;
1277
1278 if (YY_CURRENT_BUFFER) {
1279 /* Flush out information for old buffer. */
1283 }
1284
1285 YY_CURRENT_BUFFER_LVALUE = new_buffer;
1286 yy_load_buffer_state(yyscanner);
1287
1288 /* We don't actually know whether we did this switch during
1289 * EOF (yywrap()) processing, but the only time this flag
1290 * is looked at is after yywrap() is called, so it's safe
1291 * to go ahead and always set it.
1292 */
1294}
1295
1296static void yy_load_buffer_state(yyscan_t yyscanner) {
1297 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1299 yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
1300 yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
1302}
1303
1304/** Allocate and initialize an input buffer state.
1305 * @param file A readable stream.
1306 * @param size The character buffer size in bytes. When in doubt, use @c
1307 * YY_BUF_SIZE.
1308 * @param yyscanner The scanner object.
1309 * @return the allocated buffer state.
1310 */
1311YY_BUFFER_STATE yy_create_buffer(FILE* file, int size, yyscan_t yyscanner) {
1313
1314 b = (YY_BUFFER_STATE)yyalloc(sizeof(struct yy_buffer_state), yyscanner);
1315 if (!b)
1316 YY_FATAL_ERROR("out of dynamic memory in yy_create_buffer()");
1317
1318 b->yy_buf_size = size;
1319
1320 /* yy_ch_buf has to be 2 characters longer than the size given because
1321 * we need to put in 2 end-of-buffer characters.
1322 */
1323 b->yy_ch_buf = (char*)yyalloc((yy_size_t)(b->yy_buf_size + 2), yyscanner);
1324 if (!b->yy_ch_buf)
1325 YY_FATAL_ERROR("out of dynamic memory in yy_create_buffer()");
1326
1327 b->yy_is_our_buffer = 1;
1328
1329 yy_init_buffer(b, file, yyscanner);
1330
1331 return b;
1332}
1333
1334/** Destroy the buffer.
1335 * @param b a buffer created with yy_create_buffer()
1336 * @param yyscanner The scanner object.
1337 */
1338void yy_delete_buffer(YY_BUFFER_STATE b, yyscan_t yyscanner) {
1339 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1340
1341 if (!b)
1342 return;
1343
1344 if (b == YY_CURRENT_BUFFER) /* Not sure if we should pop here. */
1346
1347 if (b->yy_is_our_buffer)
1348 yyfree((void*)b->yy_ch_buf, yyscanner);
1349
1350 yyfree((void*)b, yyscanner);
1351}
1352
1353/* Initializes or reinitializes a buffer.
1354 * This function is sometimes called more than once on the same buffer,
1355 * such as during a yyrestart() or at EOF.
1356 */
1357static void yy_init_buffer(YY_BUFFER_STATE b, FILE* file, yyscan_t yyscanner)
1358
1359{
1360 int oerrno = errno;
1361 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1362
1363 yy_flush_buffer(b, yyscanner);
1364
1365 b->yy_input_file = file;
1366 b->yy_fill_buffer = 1;
1367
1368 /* If b is the current buffer, then yy_init_buffer was _probably_
1369 * called from yyrestart() or through yy_get_next_buffer.
1370 * In that case, we don't want to reset the lineno or column.
1371 */
1372 if (b != YY_CURRENT_BUFFER) {
1373 b->yy_bs_lineno = 1;
1374 b->yy_bs_column = 0;
1375 }
1376
1377 b->yy_is_interactive = file ? (isatty(fileno(file)) > 0) : 0;
1378
1379 errno = oerrno;
1380}
1381
1382/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
1383 * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
1384 * @param yyscanner The scanner object.
1385 */
1386void yy_flush_buffer(YY_BUFFER_STATE b, yyscan_t yyscanner) {
1387 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1388 if (!b)
1389 return;
1390
1391 b->yy_n_chars = 0;
1392
1393 /* We always need two end-of-buffer characters. The first causes
1394 * a transition to the end-of-buffer state. The second causes
1395 * a jam in that state.
1396 */
1397 b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
1398 b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
1399
1400 b->yy_buf_pos = &b->yy_ch_buf[0];
1401
1402 b->yy_at_bol = 1;
1403 b->yy_buffer_status = YY_BUFFER_NEW;
1404
1405 if (b == YY_CURRENT_BUFFER)
1406 yy_load_buffer_state(yyscanner);
1407}
1408
1409/** Pushes the new state onto the stack. The new state becomes
1410 * the current state. This function will allocate the stack
1411 * if necessary.
1412 * @param new_buffer The new state.
1413 * @param yyscanner The scanner object.
1414 */
1415void yypush_buffer_state(YY_BUFFER_STATE new_buffer, yyscan_t yyscanner) {
1416 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1417 if (new_buffer == NULL)
1418 return;
1419
1420 yyensure_buffer_stack(yyscanner);
1421
1422 /* This block is copied from yy_switch_to_buffer. */
1423 if (YY_CURRENT_BUFFER) {
1424 /* Flush out information for old buffer. */
1428 }
1429
1430 /* Only push if top exists. Otherwise, replace top. */
1433 YY_CURRENT_BUFFER_LVALUE = new_buffer;
1434
1435 /* copied from yy_switch_to_buffer. */
1436 yy_load_buffer_state(yyscanner);
1438}
1439
1440/** Removes and deletes the top of the stack, if present.
1441 * The next element becomes the new top.
1442 * @param yyscanner The scanner object.
1443 */
1444void yypop_buffer_state(yyscan_t yyscanner) {
1445 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1446 if (!YY_CURRENT_BUFFER)
1447 return;
1448
1451 if (yyg->yy_buffer_stack_top > 0)
1453
1454 if (YY_CURRENT_BUFFER) {
1455 yy_load_buffer_state(yyscanner);
1457 }
1458}
1459
1460/* Allocates the stack if it does not exist.
1461 * Guarantees space for at least one push.
1462 */
1463static void yyensure_buffer_stack(yyscan_t yyscanner) {
1464 yy_size_t num_to_alloc;
1465 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1466
1467 if (!yyg->yy_buffer_stack) {
1468 /* First allocation is just for 2 elements, since we don't know if this
1469 * scanner will even need a stack. We use 2 instead of 1 to avoid an
1470 * immediate realloc on the next call.
1471 */
1472 num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
1474 num_to_alloc * sizeof(struct yy_buffer_state*), yyscanner);
1475 if (!yyg->yy_buffer_stack)
1476 YY_FATAL_ERROR("out of dynamic memory in yyensure_buffer_stack()");
1477
1478 memset(yyg->yy_buffer_stack, 0,
1479 num_to_alloc * sizeof(struct yy_buffer_state*));
1480
1481 yyg->yy_buffer_stack_max = num_to_alloc;
1483 return;
1484 }
1485
1487 /* Increase the buffer to prepare for a possible push. */
1488 yy_size_t grow_size = 8 /* arbitrary grow size */;
1489
1490 num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
1492 yyg->yy_buffer_stack, num_to_alloc * sizeof(struct yy_buffer_state*),
1493 yyscanner);
1494 if (!yyg->yy_buffer_stack)
1495 YY_FATAL_ERROR("out of dynamic memory in yyensure_buffer_stack()");
1496
1497 /* zero only the new slots.*/
1499 grow_size * sizeof(struct yy_buffer_state*));
1500 yyg->yy_buffer_stack_max = num_to_alloc;
1501 }
1502}
1503
1504/** Setup the input buffer state to scan directly from a user-specified
1505 * character buffer.
1506 * @param base the character buffer
1507 * @param size the size in bytes of the character buffer
1508 * @param yyscanner The scanner object.
1509 * @return the newly allocated buffer state object.
1510 */
1511YY_BUFFER_STATE yy_scan_buffer(char* base, yy_size_t size, yyscan_t yyscanner) {
1513
1514 if (size < 2 || base[size - 2] != YY_END_OF_BUFFER_CHAR ||
1515 base[size - 1] != YY_END_OF_BUFFER_CHAR)
1516 /* They forgot to leave room for the EOB's. */
1517 return NULL;
1518
1519 b = (YY_BUFFER_STATE)yyalloc(sizeof(struct yy_buffer_state), yyscanner);
1520 if (!b)
1521 YY_FATAL_ERROR("out of dynamic memory in yy_scan_buffer()");
1522
1523 b->yy_buf_size = (int)(size - 2); /* "- 2" to take care of EOB's */
1524 b->yy_buf_pos = b->yy_ch_buf = base;
1525 b->yy_is_our_buffer = 0;
1526 b->yy_input_file = NULL;
1527 b->yy_n_chars = b->yy_buf_size;
1528 b->yy_is_interactive = 0;
1529 b->yy_at_bol = 1;
1530 b->yy_fill_buffer = 0;
1531 b->yy_buffer_status = YY_BUFFER_NEW;
1532
1533 yy_switch_to_buffer(b, yyscanner);
1534
1535 return b;
1536}
1537
1538/** Setup the input buffer state to scan a string. The next call to yylex() will
1539 * scan from a @e copy of @a str.
1540 * @param yystr a NUL-terminated string to scan
1541 * @param yyscanner The scanner object.
1542 * @return the newly allocated buffer state object.
1543 * @note If you want to scan bytes that may contain NUL values, then use
1544 * yy_scan_bytes() instead.
1545 */
1546YY_BUFFER_STATE yy_scan_string(const char* yystr, yyscan_t yyscanner) {
1547 return yy_scan_bytes(yystr, (int)strlen(yystr), yyscanner);
1548}
1549
1550/** Setup the input buffer state to scan the given bytes. The next call to
1551 * yylex() will scan from a @e copy of @a bytes.
1552 * @param yybytes the byte buffer to scan
1553 * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
1554 * @param yyscanner The scanner object.
1555 * @return the newly allocated buffer state object.
1556 */
1557YY_BUFFER_STATE yy_scan_bytes(const char* yybytes,
1558 yy_size_t _yybytes_len,
1559 yyscan_t yyscanner) {
1561 char* buf;
1562 yy_size_t n;
1563 yy_size_t i;
1564
1565 /* Get memory for full buffer, including space for trailing EOB's. */
1566 n = (yy_size_t)(_yybytes_len + 2);
1567 buf = (char*)yyalloc(n, yyscanner);
1568 if (!buf)
1569 YY_FATAL_ERROR("out of dynamic memory in yy_scan_bytes()");
1570
1571 for (i = 0; i < _yybytes_len; ++i)
1572 buf[i] = yybytes[i];
1573
1574 buf[_yybytes_len] = buf[_yybytes_len + 1] = YY_END_OF_BUFFER_CHAR;
1575
1576 b = yy_scan_buffer(buf, n, yyscanner);
1577 if (!b)
1578 YY_FATAL_ERROR("bad buffer in yy_scan_bytes()");
1579
1580 /* It's okay to grow etc. this buffer, and we should throw it
1581 * away when we're done.
1582 */
1583 b->yy_is_our_buffer = 1;
1584
1585 return b;
1586}
1587
1588#ifndef YY_EXIT_FAILURE
1589#define YY_EXIT_FAILURE 2
1590#endif
1591
1592static void yynoreturn yy_fatal_error(const char* msg, yyscan_t yyscanner) {
1593 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1594 (void)yyg;
1595 fprintf(stderr, "%s\n", msg);
1596 exit(YY_EXIT_FAILURE);
1597}
1598
1599/* Redefine yyless() so it works in section 3 code. */
1600
1601#undef yyless
1602#define yyless(n) \
1603 do { \
1604 /* Undo effects of setting up yytext. */ \
1605 yy_size_t yyless_macro_arg = (n); \
1606 YY_LESS_LINENO(yyless_macro_arg); \
1607 yytext[yyleng] = yyg->yy_hold_char; \
1608 yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
1609 yyg->yy_hold_char = *yyg->yy_c_buf_p; \
1610 *yyg->yy_c_buf_p = '\0'; \
1611 yyleng = yyless_macro_arg; \
1612 } while (0)
1613
1614/* Accessor methods (get/set functions) to struct members. */
1615
1616/** Get the user-defined data for this scanner.
1617 * @param yyscanner The scanner object.
1618 */
1620 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1621 return yyextra;
1622}
1623
1624/** Get the current line number.
1625 * @param yyscanner The scanner object.
1626 */
1627int yyget_lineno(yyscan_t yyscanner) {
1628 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1629
1630 if (!YY_CURRENT_BUFFER)
1631 return 0;
1632
1633 return yylineno;
1634}
1635
1636/** Get the current column number.
1637 * @param yyscanner The scanner object.
1638 */
1639int yyget_column(yyscan_t yyscanner) {
1640 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1641
1642 if (!YY_CURRENT_BUFFER)
1643 return 0;
1644
1645 return yycolumn;
1646}
1647
1648/** Get the input stream.
1649 * @param yyscanner The scanner object.
1650 */
1651FILE* yyget_in(yyscan_t yyscanner) {
1652 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1653 return yyin;
1654}
1655
1656/** Get the output stream.
1657 * @param yyscanner The scanner object.
1658 */
1659FILE* yyget_out(yyscan_t yyscanner) {
1660 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1661 return yyout;
1662}
1663
1664/** Get the length of the current token.
1665 * @param yyscanner The scanner object.
1666 */
1667yy_size_t yyget_leng(yyscan_t yyscanner) {
1668 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1669 return yyleng;
1670}
1671
1672/** Get the current token.
1673 * @param yyscanner The scanner object.
1674 */
1675
1676char* yyget_text(yyscan_t yyscanner) {
1677 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1678 return yytext;
1679}
1680
1681/** Set the user-defined data. This data is never touched by the scanner.
1682 * @param user_defined The data to be associated with this scanner.
1683 * @param yyscanner The scanner object.
1684 */
1685void yyset_extra(YY_EXTRA_TYPE user_defined, yyscan_t yyscanner) {
1686 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1687 yyextra = user_defined;
1688}
1689
1690/** Set the current line number.
1691 * @param _line_number line number
1692 * @param yyscanner The scanner object.
1693 */
1694void yyset_lineno(int _line_number, yyscan_t yyscanner) {
1695 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1696
1697 /* lineno is only valid if an input buffer exists. */
1698 if (!YY_CURRENT_BUFFER)
1699 YY_FATAL_ERROR("yyset_lineno called with no buffer");
1700
1701 yylineno = _line_number;
1702}
1703
1704/** Set the current column.
1705 * @param _column_no column number
1706 * @param yyscanner The scanner object.
1707 */
1708void yyset_column(int _column_no, yyscan_t yyscanner) {
1709 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1710
1711 /* column is only valid if an input buffer exists. */
1712 if (!YY_CURRENT_BUFFER)
1713 YY_FATAL_ERROR("yyset_column called with no buffer");
1714
1715 yycolumn = _column_no;
1716}
1717
1718/** Set the input stream. This does not discard the current
1719 * input buffer.
1720 * @param _in_str A readable stream.
1721 * @param yyscanner The scanner object.
1722 * @see yy_switch_to_buffer
1723 */
1724void yyset_in(FILE* _in_str, yyscan_t yyscanner) {
1725 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1726 yyin = _in_str;
1727}
1728
1729void yyset_out(FILE* _out_str, yyscan_t yyscanner) {
1730 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1731 yyout = _out_str;
1732}
1733
1734int yyget_debug(yyscan_t yyscanner) {
1735 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1736 return yy_flex_debug;
1737}
1738
1739void yyset_debug(int _bdebug, yyscan_t yyscanner) {
1740 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1741 yy_flex_debug = _bdebug;
1742}
1743
1744/* Accessor methods for yylval and yylloc */
1745
1746/* User-visible API */
1747
1748/* yylex_init is special because it creates the scanner itself, so it is
1749 * the ONLY reentrant function that doesn't take the scanner as the last
1750 * argument. That's why we explicitly handle the declaration, instead of using
1751 * our macros.
1752 */
1753int yylex_init(yyscan_t* ptr_yy_globals) {
1754 if (ptr_yy_globals == NULL) {
1755 errno = EINVAL;
1756 return 1;
1757 }
1758
1759 *ptr_yy_globals = (yyscan_t)yyalloc(sizeof(struct yyguts_t), NULL);
1760
1761 if (*ptr_yy_globals == NULL) {
1762 errno = ENOMEM;
1763 return 1;
1764 }
1765
1766 /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for
1767 * releases. */
1768 memset(*ptr_yy_globals, 0x00, sizeof(struct yyguts_t));
1769
1770 return yy_init_globals(*ptr_yy_globals);
1771}
1772
1773/* yylex_init_extra has the same functionality as yylex_init, but follows the
1774 * convention of taking the scanner as the last argument. Note however, that
1775 * this is a *pointer* to a scanner, as it will be allocated by this call (and
1776 * is the reason, too, why this function also must handle its own declaration).
1777 * The user defined value in the first argument will be available to yyalloc in
1778 * the yyextra field.
1779 */
1780int yylex_init_extra(YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals) {
1781 struct yyguts_t dummy_yyguts;
1782
1783 yyset_extra(yy_user_defined, &dummy_yyguts);
1784
1785 if (ptr_yy_globals == NULL) {
1786 errno = EINVAL;
1787 return 1;
1788 }
1789
1790 *ptr_yy_globals = (yyscan_t)yyalloc(sizeof(struct yyguts_t), &dummy_yyguts);
1791
1792 if (*ptr_yy_globals == NULL) {
1793 errno = ENOMEM;
1794 return 1;
1795 }
1796
1797 /* By setting to 0xAA, we expose bugs in
1798 yy_init_globals. Leave at 0x00 for releases. */
1799 memset(*ptr_yy_globals, 0x00, sizeof(struct yyguts_t));
1800
1801 yyset_extra(yy_user_defined, *ptr_yy_globals);
1802
1803 return yy_init_globals(*ptr_yy_globals);
1804}
1805
1806static int yy_init_globals(yyscan_t yyscanner) {
1807 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1808 /* Initialization is the same as for the non-reentrant scanner.
1809 * This function is called from yylex_destroy(), so don't allocate here.
1810 */
1811
1812 yyg->yy_buffer_stack = NULL;
1815 yyg->yy_c_buf_p = NULL;
1816 yyg->yy_init = 0;
1817 yyg->yy_start = 0;
1818
1821 yyg->yy_start_stack = NULL;
1822
1823/* Defined in main.c */
1824#ifdef YY_STDINIT
1825 yyin = stdin;
1826 yyout = stdout;
1827#else
1828 yyin = NULL;
1829 yyout = NULL;
1830#endif
1831
1832 /* For future reference: Set errno on error, since we are called by
1833 * yylex_init()
1834 */
1835 return 0;
1836}
1837
1838/* yylex_destroy is for both reentrant and non-reentrant scanners. */
1839int yylex_destroy(yyscan_t yyscanner) {
1840 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1841
1842 /* Pop the buffer stack, destroying each element. */
1843 while (YY_CURRENT_BUFFER) {
1846 yypop_buffer_state(yyscanner);
1847 }
1848
1849 /* Destroy the stack itself. */
1850 yyfree(yyg->yy_buffer_stack, yyscanner);
1851 yyg->yy_buffer_stack = NULL;
1852
1853 /* Destroy the start condition stack. */
1854 yyfree(yyg->yy_start_stack, yyscanner);
1855 yyg->yy_start_stack = NULL;
1856
1857 /* Reset the globals. This is important in a non-reentrant scanner so the next
1858 * time yylex() is called, initialization will occur. */
1859 yy_init_globals(yyscanner);
1860
1861 /* Destroy the main struct (reentrant only). */
1862 yyfree(yyscanner, yyscanner);
1863 yyscanner = NULL;
1864 return 0;
1865}
1866
1867/*
1868 * Internal utility routines.
1869 */
1870
1871#ifndef yytext_ptr
1872static void yy_flex_strncpy(char* s1,
1873 const char* s2,
1874 int n,
1875 yyscan_t yyscanner) {
1876 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1877 (void)yyg;
1878
1879 int i;
1880 for (i = 0; i < n; ++i)
1881 s1[i] = s2[i];
1882}
1883#endif
1884
1885#ifdef YY_NEED_STRLEN
1886static int yy_flex_strlen(const char* s, yyscan_t yyscanner) {
1887 int n;
1888 for (n = 0; s[n]; ++n)
1889 ;
1890
1891 return n;
1892}
1893#endif
1894
1895void* yyalloc(yy_size_t size, yyscan_t yyscanner) {
1896 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1897 (void)yyg;
1898 return malloc(size);
1899}
1900
1901void* yyrealloc(void* ptr, yy_size_t size, yyscan_t yyscanner) {
1902 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1903 (void)yyg;
1904
1905 /* The cast to (char *) in the following accommodates both
1906 * implementations that use char* generic pointers, and those
1907 * that use void* generic pointers. It works with the latter
1908 * because both ANSI C and C++ allow castless assignment from
1909 * any pointer type to void*, and deal with argument conversions
1910 * as though doing an assignment.
1911 */
1912 return realloc(ptr, size);
1913}
1914
1915void yyfree(void* ptr, yyscan_t yyscanner) {
1916 struct yyguts_t* yyg = (struct yyguts_t*)yyscanner;
1917 (void)yyg;
1918 free((char*)ptr); /* see yyrealloc() for (char *) cast */
1919}
1920
1921#define YYTABLES_NAME "yytables"
1922
1923#line 79 "comments.l"
1924
1925void IterateComments(const char* buffer,
1926 size_t size,
1927 std::function<void(std::string_view)> callback) {
1928 LexerContext context;
1929 context.buffer.reserve(4096);
1930 context.callback = std::move(callback);
1931 yyscan_t scanner;
1932 yylex_init_extra(&context, &scanner);
1933 YY_BUFFER_STATE yybuffer = yy_scan_bytes(buffer, size, scanner);
1934 yylex(scanner);
1935 if (!context.buffer.empty()) {
1936 context.callback(context.buffer);
1937 }
1938 yy_delete_buffer(yybuffer, scanner);
1939 yylex_destroy(scanner);
1940}
static void AddCEndTrimLine(std::string *buffer, const char *text, size_t length)
static void AddCTrimLine(std::string *buffer, const char *text, size_t length)
static void AddTrimLine(std::string *buffer, const char *text, size_t length)
#define YY_NEW_FILE
Definition comments.cc:148
YY_BUFFER_STATE yy_scan_string(const char *yy_str, yyscan_t yyscanner)
#define yytext
Definition comments.cc:129
unsigned char flex_uint8_t
Definition comments.cc:57
static void yy_load_buffer_state(yyscan_t yyscanner)
void yy_flush_buffer(YY_BUFFER_STATE b, yyscan_t yyscanner)
FILE * yyget_out(yyscan_t yyscanner)
int yylex(yyscan_t yyscanner)
void * yyscan_t
Definition comments.cc:120
static int yy_init_globals(yyscan_t yyscanner)
static void yynoreturn yy_fatal_error(const char *msg, yyscan_t yyscanner)
#define YY_EXTRA_TYPE
Definition comments.cc:444
static int yy_get_next_buffer(yyscan_t yyscanner)
short int flex_int16_t
Definition comments.cc:55
#define yy_flex_debug
Definition comments.cc:132
static const flex_int16_t yy_nxt[69]
Definition comments.cc:384
void yypush_buffer_state(YY_BUFFER_STATE new_buffer, yyscan_t yyscanner)
unsigned int flex_uint32_t
Definition comments.cc:59
static yy_state_type yy_try_NUL_trans(yy_state_type current_state, yyscan_t yyscanner)
yy_size_t yyget_leng(yyscan_t yyscanner)
#define YY_BREAK
Definition comments.cc:645
#define yynoreturn
Definition comments.cc:106
int yy_act
Definition comments.cc:658
struct yy_buffer_state * YY_BUFFER_STATE
Definition comments.cc:171
#define yyout
Definition comments.cc:126
#define BLOCK
Definition comments.cc:434
#define YY_BUFFER_NEW
Definition comments.cc:246
void yyset_in(FILE *_in_str, yyscan_t yyscanner)
#define YY_RESTORE_YY_MORE_OFFSET
Definition comments.cc:402
static int input(yyscan_t yyscanner)
void yyset_lineno(int _line_number, yyscan_t yyscanner)
#define YY_BUFFER_NORMAL
Definition comments.cc:247
static const flex_int16_t yy_base[45]
Definition comments.cc:374
char * yy_cp
Definition comments.cc:657
#define YY_MORE_ADJ
Definition comments.cc:401
#define YY_RULE_SETUP
Definition comments.cc:648
int yylex_init_extra(YY_EXTRA_TYPE user_defined, yyscan_t *scanner)
#define yyextra
Definition comments.cc:127
static const flex_int16_t yy_chk[69]
Definition comments.cc:390
#define YY_AT_BOL()
Definition comments.cc:317
struct yyguts_t * yyg
Definition comments.cc:659
signed char flex_int8_t
Definition comments.cc:54
void yy_switch_to_buffer(YY_BUFFER_STATE new_buffer, yyscan_t yyscanner)
#define EOB_ACT_END_OF_FILE
Definition comments.cc:180
static void yy_init_buffer(YY_BUFFER_STATE b, FILE *file, yyscan_t yyscanner)
static void yyunput(int c, char *buf_ptr, yyscan_t yyscanner)
#define YY_CURRENT_BUFFER_LVALUE
Definition comments.cc:273
static const YY_CHAR yy_meta[7]
Definition comments.cc:372
int flex_int32_t
Definition comments.cc:56
int yyget_lineno(yyscan_t yyscanner)
void yypop_buffer_state(yyscan_t yyscanner)
void yyset_out(FILE *_out_str, yyscan_t yyscanner)
#define YY_START
Definition comments.cc:143
void yyset_extra(YY_EXTRA_TYPE user_defined, yyscan_t yyscanner)
void yyrestart(FILE *input_file, yyscan_t yyscanner)
YY_BUFFER_STATE yy_scan_buffer(char *base, yy_size_t size, yyscan_t yyscanner)
int yyget_debug(yyscan_t yyscanner)
void * yyrealloc(void *, yy_size_t, yyscan_t yyscanner)
int yy_state_type
Definition comments.cc:325
#define yywrap(yyscanner)
Definition comments.cc:321
#define YY_CURRENT_BUFFER
Definition comments.cc:268
#define INITIAL
Definition comments.cc:432
char * yy_bp
Definition comments.cc:657
#define yyin
Definition comments.cc:125
#define YY_READ_BUF_SIZE
Definition comments.cc:559
#define YY_INPUT(buf, result, max_size)
Definition comments.cc:579
#define ECHO
Definition comments.cc:568
int yylex_destroy(yyscan_t yyscanner)
#define YY_END_OF_BUFFER
Definition comments.cc:345
#define YY_STATE_EOF(state)
Definition comments.cc:146
#define BEGIN
Definition comments.cc:138
#define YY_END_OF_BUFFER_CHAR
Definition comments.cc:149
#define YY_FATAL_ERROR(msg)
Definition comments.cc:620
YY_BUFFER_STATE yy_create_buffer(FILE *file, int size, yyscan_t yyscanner)
#define yyterminate()
Definition comments.cc:610
void * yyalloc(yy_size_t, yyscan_t yyscanner)
unsigned short int flex_uint16_t
Definition comments.cc:58
YY_BUFFER_STATE yy_scan_bytes(const char *bytes, yy_size_t len, yyscan_t yyscanner)
flex_uint8_t YY_CHAR
Definition comments.cc:323
#define YY_DO_BEFORE_ACTION
Definition comments.cc:338
void yyfree(void *, yyscan_t yyscanner)
#define EOB_ACT_LAST_MATCH
Definition comments.cc:181
static const flex_int16_t yy_def[45]
Definition comments.cc:379
size_t yy_size_t
Definition comments.cc:176
void yyset_debug(int debug_flag, yyscan_t yyscanner)
#define YY_BUFFER_EOF_PENDING
Definition comments.cc:258
FILE * yyget_in(yyscan_t yyscanner)
#define yylineno
Definition comments.cc:130
static const YY_CHAR yy_ec[256]
Definition comments.cc:356
#define yycolumn
Definition comments.cc:131
#define EOB_ACT_CONTINUE_SCAN
Definition comments.cc:179
#define YY_DECL
Definition comments.cc:633
#define YY_BUF_SIZE
Definition comments.cc:160
void yyset_column(int _column_no, yyscan_t yyscanner)
#define YY_EXIT_FAILURE
static void yyensure_buffer_stack(yyscan_t yyscanner)
int yyget_column(yyscan_t yyscanner)
static yy_state_type yy_get_previous_state(yyscan_t yyscanner)
static const flex_int16_t yy_accept[37]
Definition comments.cc:352
#define YY_SC_TO_UI(c)
Definition comments.cc:115
void yy_delete_buffer(YY_BUFFER_STATE b, yyscan_t yyscanner)
char * yyget_text(yyscan_t yyscanner)
#define yyleng
Definition comments.cc:128
int yylex_init(yyscan_t *scanner)
#define C_COMMENT
Definition comments.cc:433
YY_EXTRA_TYPE yyget_extra(yyscan_t yyscanner)
void IterateComments(const char *buffer, size_t size, std::function< void(std::string_view)> callback)
FlutterDesktopBinaryReply callback
it will be possible to load the file into Perfetto s trace viewer use test Running tests that layout and measure text will not yield consistent results across various platforms Enabling this option will make font resolution default to the Ahem test font on all disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
std::string buffer
Definition comments.cc:426
std::function< void(std::string_view)> callback
Definition comments.cc:425
FILE * yy_input_file
Definition comments.cc:202
char * yy_buf_pos
Definition comments.cc:205
yy_size_t yy_n_chars
Definition comments.cc:215
flex_int32_t yy_verify
Definition comments.cc:349
flex_int32_t yy_nxt
Definition comments.cc:350
FILE * yyin_r
Definition comments.cc:453
int yy_did_buffer_switch_on_eof
Definition comments.cc:463
int yy_start_stack_depth
Definition comments.cc:465
FILE * yyout_r
Definition comments.cc:453
size_t yy_buffer_stack_max
Definition comments.cc:455
char * yy_last_accepting_cpos
Definition comments.cc:468
int yy_flex_debug_r
Definition comments.cc:471
int yy_more_flag
Definition comments.cc:474
int yy_more_len
Definition comments.cc:475
yy_state_type yy_last_accepting_state
Definition comments.cc:467
int yy_start
Definition comments.cc:462
int yylineno_r
Definition comments.cc:470
char * yy_c_buf_p
Definition comments.cc:460
yy_size_t yyleng_r
Definition comments.cc:459
int yy_init
Definition comments.cc:461
yy_size_t yy_n_chars
Definition comments.cc:458
YY_BUFFER_STATE * yy_buffer_stack
Definition comments.cc:456
int yy_start_stack_ptr
Definition comments.cc:464
char yy_hold_char
Definition comments.cc:457
char * yytext_r
Definition comments.cc:473
YY_EXTRA_TYPE yyextra_r
Definition comments.cc:449
int * yy_start_stack
Definition comments.cc:466
size_t yy_buffer_stack_top
Definition comments.cc:454