No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

lex.yy.c 49KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951
  1. #line 3 "lex.yy.c"
  2. #define YY_INT_ALIGNED short int
  3. /* A lexical scanner generated by flex */
  4. #define FLEX_SCANNER
  5. #define YY_FLEX_MAJOR_VERSION 2
  6. #define YY_FLEX_MINOR_VERSION 6
  7. #define YY_FLEX_SUBMINOR_VERSION 4
  8. #if YY_FLEX_SUBMINOR_VERSION > 0
  9. #define FLEX_BETA
  10. #endif
  11. /* First, we deal with platform-specific or compiler-specific issues. */
  12. /* begin standard C headers. */
  13. #include <stdio.h>
  14. #include <string.h>
  15. #include <errno.h>
  16. #include <stdlib.h>
  17. /* end standard C headers. */
  18. /* flex integer type definitions */
  19. #ifndef FLEXINT_H
  20. #define FLEXINT_H
  21. /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
  22. #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
  23. /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
  24. * if you want the limit (max/min) macros for int types.
  25. */
  26. #ifndef __STDC_LIMIT_MACROS
  27. #define __STDC_LIMIT_MACROS 1
  28. #endif
  29. #include <inttypes.h>
  30. typedef int8_t flex_int8_t;
  31. typedef uint8_t flex_uint8_t;
  32. typedef int16_t flex_int16_t;
  33. typedef uint16_t flex_uint16_t;
  34. typedef int32_t flex_int32_t;
  35. typedef uint32_t flex_uint32_t;
  36. #else
  37. typedef signed char flex_int8_t;
  38. typedef short int flex_int16_t;
  39. typedef int flex_int32_t;
  40. typedef unsigned char flex_uint8_t;
  41. typedef unsigned short int flex_uint16_t;
  42. typedef unsigned int flex_uint32_t;
  43. /* Limits of integral types. */
  44. #ifndef INT8_MIN
  45. #define INT8_MIN (-128)
  46. #endif
  47. #ifndef INT16_MIN
  48. #define INT16_MIN (-32767-1)
  49. #endif
  50. #ifndef INT32_MIN
  51. #define INT32_MIN (-2147483647-1)
  52. #endif
  53. #ifndef INT8_MAX
  54. #define INT8_MAX (127)
  55. #endif
  56. #ifndef INT16_MAX
  57. #define INT16_MAX (32767)
  58. #endif
  59. #ifndef INT32_MAX
  60. #define INT32_MAX (2147483647)
  61. #endif
  62. #ifndef UINT8_MAX
  63. #define UINT8_MAX (255U)
  64. #endif
  65. #ifndef UINT16_MAX
  66. #define UINT16_MAX (65535U)
  67. #endif
  68. #ifndef UINT32_MAX
  69. #define UINT32_MAX (4294967295U)
  70. #endif
  71. #ifndef SIZE_MAX
  72. #define SIZE_MAX (~(size_t)0)
  73. #endif
  74. #endif /* ! C99 */
  75. #endif /* ! FLEXINT_H */
  76. /* begin standard C++ headers. */
  77. /* TODO: this is always defined, so inline it */
  78. #define yyconst const
  79. #if defined(__GNUC__) && __GNUC__ >= 3
  80. #define yynoreturn __attribute__((__noreturn__))
  81. #else
  82. #define yynoreturn
  83. #endif
  84. /* Returned upon end-of-file. */
  85. #define YY_NULL 0
  86. /* Promotes a possibly negative, possibly signed char to an
  87. * integer in range [0..255] for use as an array index.
  88. */
  89. #define YY_SC_TO_UI(c) ((YY_CHAR) (c))
  90. /* Enter a start condition. This macro really ought to take a parameter,
  91. * but we do it the disgusting crufty way forced on us by the ()-less
  92. * definition of BEGIN.
  93. */
  94. #define BEGIN (yy_start) = 1 + 2 *
  95. /* Translate the current start state into a value that can be later handed
  96. * to BEGIN to return to the state. The YYSTATE alias is for lex
  97. * compatibility.
  98. */
  99. #define YY_START (((yy_start) - 1) / 2)
  100. #define YYSTATE YY_START
  101. /* Action number for EOF rule of a given start state. */
  102. #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
  103. /* Special action meaning "start processing a new file". */
  104. #define YY_NEW_FILE yyrestart( yyin )
  105. #define YY_END_OF_BUFFER_CHAR 0
  106. /* Size of default input buffer. */
  107. #ifndef YY_BUF_SIZE
  108. #ifdef __ia64__
  109. /* On IA-64, the buffer size is 16k, not 8k.
  110. * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
  111. * Ditto for the __ia64__ case accordingly.
  112. */
  113. #define YY_BUF_SIZE 32768
  114. #else
  115. #define YY_BUF_SIZE 16384
  116. #endif /* __ia64__ */
  117. #endif
  118. /* The state buf must be large enough to hold one state per character in the main buffer.
  119. */
  120. #define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
  121. #ifndef YY_TYPEDEF_YY_BUFFER_STATE
  122. #define YY_TYPEDEF_YY_BUFFER_STATE
  123. typedef struct yy_buffer_state *YY_BUFFER_STATE;
  124. #endif
  125. #ifndef YY_TYPEDEF_YY_SIZE_T
  126. #define YY_TYPEDEF_YY_SIZE_T
  127. typedef size_t yy_size_t;
  128. #endif
  129. extern int yyleng;
  130. extern FILE *yyin, *yyout;
  131. #define EOB_ACT_CONTINUE_SCAN 0
  132. #define EOB_ACT_END_OF_FILE 1
  133. #define EOB_ACT_LAST_MATCH 2
  134. #define YY_LESS_LINENO(n)
  135. #define YY_LINENO_REWIND_TO(ptr)
  136. /* Return all but the first "n" matched characters back to the input stream. */
  137. #define yyless(n) \
  138. do \
  139. { \
  140. /* Undo effects of setting up yytext. */ \
  141. int yyless_macro_arg = (n); \
  142. YY_LESS_LINENO(yyless_macro_arg);\
  143. *yy_cp = (yy_hold_char); \
  144. YY_RESTORE_YY_MORE_OFFSET \
  145. (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
  146. YY_DO_BEFORE_ACTION; /* set up yytext again */ \
  147. } \
  148. while ( 0 )
  149. #define unput(c) yyunput( c, (yytext_ptr) )
  150. #ifndef YY_STRUCT_YY_BUFFER_STATE
  151. #define YY_STRUCT_YY_BUFFER_STATE
  152. struct yy_buffer_state
  153. {
  154. FILE *yy_input_file;
  155. char *yy_ch_buf; /* input buffer */
  156. char *yy_buf_pos; /* current position in input buffer */
  157. /* Size of input buffer in bytes, not including room for EOB
  158. * characters.
  159. */
  160. int yy_buf_size;
  161. /* Number of characters read into yy_ch_buf, not including EOB
  162. * characters.
  163. */
  164. int yy_n_chars;
  165. /* Whether we "own" the buffer - i.e., we know we created it,
  166. * and can realloc() it to grow it, and should free() it to
  167. * delete it.
  168. */
  169. int yy_is_our_buffer;
  170. /* Whether this is an "interactive" input source; if so, and
  171. * if we're using stdio for input, then we want to use getc()
  172. * instead of fread(), to make sure we stop fetching input after
  173. * each newline.
  174. */
  175. int yy_is_interactive;
  176. /* Whether we're considered to be at the beginning of a line.
  177. * If so, '^' rules will be active on the next match, otherwise
  178. * not.
  179. */
  180. int yy_at_bol;
  181. int yy_bs_lineno; /**< The line count. */
  182. int yy_bs_column; /**< The column count. */
  183. /* Whether to try to fill the input buffer when we reach the
  184. * end of it.
  185. */
  186. int yy_fill_buffer;
  187. int yy_buffer_status;
  188. #define YY_BUFFER_NEW 0
  189. #define YY_BUFFER_NORMAL 1
  190. /* When an EOF's been seen but there's still some text to process
  191. * then we mark the buffer as YY_EOF_PENDING, to indicate that we
  192. * shouldn't try reading from the input source any more. We might
  193. * still have a bunch of tokens to match, though, because of
  194. * possible backing-up.
  195. *
  196. * When we actually see the EOF, we change the status to "new"
  197. * (via yyrestart()), so that the user can continue scanning by
  198. * just pointing yyin at a new input file.
  199. */
  200. #define YY_BUFFER_EOF_PENDING 2
  201. };
  202. #endif /* !YY_STRUCT_YY_BUFFER_STATE */
  203. /* Stack of input buffers. */
  204. static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */
  205. static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */
  206. static YY_BUFFER_STATE * yy_buffer_stack = NULL; /**< Stack as an array. */
  207. /* We provide macros for accessing buffer states in case in the
  208. * future we want to put the buffer states in a more general
  209. * "scanner state".
  210. *
  211. * Returns the top of the stack, or NULL.
  212. */
  213. #define YY_CURRENT_BUFFER ( (yy_buffer_stack) \
  214. ? (yy_buffer_stack)[(yy_buffer_stack_top)] \
  215. : NULL)
  216. /* Same as previous macro, but useful when we know that the buffer stack is not
  217. * NULL or when we need an lvalue. For internal use only.
  218. */
  219. #define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)]
  220. /* yy_hold_char holds the character lost when yytext is formed. */
  221. static char yy_hold_char;
  222. static int yy_n_chars; /* number of characters read into yy_ch_buf */
  223. int yyleng;
  224. /* Points to current character in buffer. */
  225. static char *yy_c_buf_p = NULL;
  226. static int yy_init = 0; /* whether we need to initialize */
  227. static int yy_start = 0; /* start state number */
  228. /* Flag which is used to allow yywrap()'s to do buffer switches
  229. * instead of setting up a fresh yyin. A bit of a hack ...
  230. */
  231. static int yy_did_buffer_switch_on_eof;
  232. void yyrestart ( FILE *input_file );
  233. void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer );
  234. YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size );
  235. void yy_delete_buffer ( YY_BUFFER_STATE b );
  236. void yy_flush_buffer ( YY_BUFFER_STATE b );
  237. void yypush_buffer_state ( YY_BUFFER_STATE new_buffer );
  238. void yypop_buffer_state ( void );
  239. static void yyensure_buffer_stack ( void );
  240. static void yy_load_buffer_state ( void );
  241. static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file );
  242. #define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER )
  243. YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size );
  244. YY_BUFFER_STATE yy_scan_string ( const char *yy_str );
  245. YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len );
  246. void *yyalloc ( yy_size_t );
  247. void *yyrealloc ( void *, yy_size_t );
  248. void yyfree ( void * );
  249. #define yy_new_buffer yy_create_buffer
  250. #define yy_set_interactive(is_interactive) \
  251. { \
  252. if ( ! YY_CURRENT_BUFFER ){ \
  253. yyensure_buffer_stack (); \
  254. YY_CURRENT_BUFFER_LVALUE = \
  255. yy_create_buffer( yyin, YY_BUF_SIZE ); \
  256. } \
  257. YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
  258. }
  259. #define yy_set_bol(at_bol) \
  260. { \
  261. if ( ! YY_CURRENT_BUFFER ){\
  262. yyensure_buffer_stack (); \
  263. YY_CURRENT_BUFFER_LVALUE = \
  264. yy_create_buffer( yyin, YY_BUF_SIZE ); \
  265. } \
  266. YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
  267. }
  268. #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
  269. /* Begin user sect3 */
  270. typedef flex_uint8_t YY_CHAR;
  271. FILE *yyin = NULL, *yyout = NULL;
  272. typedef int yy_state_type;
  273. extern int yylineno;
  274. int yylineno = 1;
  275. extern char *yytext;
  276. #ifdef yytext_ptr
  277. #undef yytext_ptr
  278. #endif
  279. #define yytext_ptr yytext
  280. static yy_state_type yy_get_previous_state ( void );
  281. static yy_state_type yy_try_NUL_trans ( yy_state_type current_state );
  282. static int yy_get_next_buffer ( void );
  283. static void yynoreturn yy_fatal_error ( const char* msg );
  284. /* Done after the current pattern has been matched and before the
  285. * corresponding action - sets up yytext.
  286. */
  287. #define YY_DO_BEFORE_ACTION \
  288. (yytext_ptr) = yy_bp; \
  289. yyleng = (int) (yy_cp - yy_bp); \
  290. (yy_hold_char) = *yy_cp; \
  291. *yy_cp = '\0'; \
  292. (yy_c_buf_p) = yy_cp;
  293. #define YY_NUM_RULES 33
  294. #define YY_END_OF_BUFFER 34
  295. /* This struct is not used in this scanner,
  296. but its presence is necessary. */
  297. struct yy_trans_info
  298. {
  299. flex_int32_t yy_verify;
  300. flex_int32_t yy_nxt;
  301. };
  302. static const flex_int16_t yy_accept[70] =
  303. { 0,
  304. 0, 0, 34, 33, 10, 11, 20, 33, 5, 6,
  305. 3, 1, 12, 2, 4, 31, 9, 16, 13, 17,
  306. 32, 32, 32, 32, 32, 32, 32, 32, 7, 33,
  307. 8, 15, 26, 31, 32, 0, 18, 14, 19, 32,
  308. 32, 27, 32, 32, 32, 32, 32, 25, 31, 32,
  309. 32, 22, 32, 32, 32, 32, 32, 28, 21, 32,
  310. 32, 32, 30, 32, 32, 29, 23, 24, 0
  311. } ;
  312. static const YY_CHAR yy_ec[256] =
  313. { 0,
  314. 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
  315. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  316. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  317. 1, 4, 5, 1, 1, 1, 1, 6, 1, 7,
  318. 8, 9, 10, 11, 12, 1, 13, 14, 14, 14,
  319. 14, 14, 14, 14, 14, 14, 14, 1, 15, 16,
  320. 17, 18, 1, 1, 19, 19, 19, 19, 19, 19,
  321. 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
  322. 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
  323. 1, 1, 1, 20, 19, 1, 21, 19, 22, 19,
  324. 23, 24, 19, 25, 26, 19, 19, 27, 28, 29,
  325. 30, 31, 19, 32, 33, 34, 35, 19, 36, 19,
  326. 19, 19, 37, 38, 39, 1, 1, 1, 1, 1,
  327. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  328. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  329. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  330. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  331. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  332. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  333. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  334. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  335. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  336. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  337. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  338. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  339. 1, 1, 1, 1, 1
  340. } ;
  341. static const YY_CHAR yy_meta[40] =
  342. { 0,
  343. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  344. 1, 1, 1, 2, 1, 1, 1, 1, 2, 2,
  345. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  346. 2, 2, 2, 2, 2, 2, 1, 1, 1
  347. } ;
  348. static const flex_int16_t yy_base[71] =
  349. { 0,
  350. 0, 0, 116, 117, 117, 117, 98, 108, 117, 117,
  351. 117, 117, 117, 117, 117, 26, 117, 96, 95, 94,
  352. 90, 21, 22, 23, 24, 28, 30, 34, 117, 71,
  353. 117, 117, 117, 41, 88, 93, 117, 117, 117, 36,
  354. 37, 86, 38, 42, 43, 44, 47, 117, 91, 46,
  355. 51, 84, 55, 56, 57, 60, 61, 83, 82, 62,
  356. 66, 68, 81, 69, 70, 80, 77, 74, 117, 81
  357. } ;
  358. static const flex_int16_t yy_def[71] =
  359. { 0,
  360. 69, 1, 69, 69, 69, 69, 69, 69, 69, 69,
  361. 69, 69, 69, 69, 69, 70, 69, 69, 69, 69,
  362. 70, 70, 70, 70, 70, 70, 70, 70, 69, 69,
  363. 69, 69, 69, 70, 70, 69, 69, 69, 69, 70,
  364. 70, 70, 70, 70, 70, 70, 70, 69, 69, 70,
  365. 70, 70, 70, 70, 70, 70, 70, 70, 70, 70,
  366. 70, 70, 70, 70, 70, 70, 70, 70, 0, 69
  367. } ;
  368. static const flex_int16_t yy_nxt[157] =
  369. { 0,
  370. 4, 5, 6, 5, 7, 8, 9, 10, 11, 12,
  371. 13, 14, 15, 16, 17, 18, 19, 20, 21, 4,
  372. 21, 22, 23, 21, 21, 24, 21, 25, 21, 21,
  373. 26, 27, 21, 21, 21, 28, 29, 30, 31, 34,
  374. 69, 69, 69, 69, 44, 36, 42, 69, 41, 69,
  375. 40, 43, 46, 69, 34, 69, 69, 69, 47, 45,
  376. 36, 69, 69, 69, 50, 69, 69, 53, 54, 51,
  377. 69, 52, 56, 58, 69, 69, 69, 55, 57, 69,
  378. 69, 69, 35, 59, 60, 69, 62, 69, 69, 69,
  379. 66, 61, 67, 69, 63, 64, 69, 65, 68, 69,
  380. 69, 69, 69, 69, 49, 69, 49, 69, 48, 69,
  381. 39, 38, 37, 33, 32, 69, 3, 69, 69, 69,
  382. 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,
  383. 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,
  384. 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,
  385. 69, 69, 69, 69, 69, 69
  386. } ;
  387. static const flex_int16_t yy_chk[157] =
  388. { 0,
  389. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  390. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  391. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  392. 1, 1, 1, 1, 1, 1, 1, 1, 1, 16,
  393. 22, 23, 24, 25, 25, 16, 24, 26, 23, 27,
  394. 22, 24, 27, 28, 34, 40, 41, 43, 28, 26,
  395. 34, 44, 45, 46, 40, 50, 47, 44, 45, 41,
  396. 51, 43, 47, 51, 53, 54, 55, 46, 50, 56,
  397. 57, 60, 70, 53, 54, 61, 56, 62, 64, 65,
  398. 62, 55, 64, 68, 57, 60, 67, 61, 65, 66,
  399. 63, 59, 58, 52, 49, 42, 36, 35, 30, 21,
  400. 20, 19, 18, 8, 7, 3, 69, 69, 69, 69,
  401. 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,
  402. 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,
  403. 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,
  404. 69, 69, 69, 69, 69, 69
  405. } ;
  406. static yy_state_type yy_last_accepting_state;
  407. static char *yy_last_accepting_cpos;
  408. extern int yy_flex_debug;
  409. int yy_flex_debug = 0;
  410. /* The intent behind this definition is that it'll catch
  411. * any uses of REJECT which flex missed.
  412. */
  413. #define REJECT reject_used_but_not_detected
  414. #define yymore() yymore_used_but_not_detected
  415. #define YY_MORE_ADJ 0
  416. #define YY_RESTORE_YY_MORE_OFFSET
  417. char *yytext;
  418. #line 1 "analyse_lexicale.lex"
  419. #line 494 "lex.yy.c"
  420. #define INITIAL 0
  421. #ifndef YY_NO_UNISTD_H
  422. /* Special case for "unistd.h", since it is non-ANSI. We include it way
  423. * down here because we want the user's section 1 to have been scanned first.
  424. * The user has a chance to override it with an option.
  425. */
  426. #include <unistd.h>
  427. #endif
  428. #ifndef YY_EXTRA_TYPE
  429. #define YY_EXTRA_TYPE void *
  430. #endif
  431. static int yy_init_globals ( void );
  432. /* Accessor methods to globals.
  433. These are made visible to non-reentrant scanners for convenience. */
  434. int yylex_destroy ( void );
  435. int yyget_debug ( void );
  436. void yyset_debug ( int debug_flag );
  437. YY_EXTRA_TYPE yyget_extra ( void );
  438. void yyset_extra ( YY_EXTRA_TYPE user_defined );
  439. FILE *yyget_in ( void );
  440. void yyset_in ( FILE * _in_str );
  441. FILE *yyget_out ( void );
  442. void yyset_out ( FILE * _out_str );
  443. int yyget_leng ( void );
  444. char *yyget_text ( void );
  445. int yyget_lineno ( void );
  446. void yyset_lineno ( int _line_number );
  447. /* Macros after this point can all be overridden by user definitions in
  448. * section 1.
  449. */
  450. #ifndef YY_SKIP_YYWRAP
  451. #ifdef __cplusplus
  452. extern "C" int yywrap ( void );
  453. #else
  454. extern int yywrap ( void );
  455. #endif
  456. #endif
  457. #ifndef YY_NO_UNPUT
  458. static void yyunput ( int c, char *buf_ptr );
  459. #endif
  460. #ifndef yytext_ptr
  461. static void yy_flex_strncpy ( char *, const char *, int );
  462. #endif
  463. #ifdef YY_NEED_STRLEN
  464. static int yy_flex_strlen ( const char * );
  465. #endif
  466. #ifndef YY_NO_INPUT
  467. #ifdef __cplusplus
  468. static int yyinput ( void );
  469. #else
  470. static int input ( void );
  471. #endif
  472. #endif
  473. /* Amount of stuff to slurp up with each read. */
  474. #ifndef YY_READ_BUF_SIZE
  475. #ifdef __ia64__
  476. /* On IA-64, the buffer size is 16k, not 8k */
  477. #define YY_READ_BUF_SIZE 16384
  478. #else
  479. #define YY_READ_BUF_SIZE 8192
  480. #endif /* __ia64__ */
  481. #endif
  482. /* Copy whatever the last rule matched to the standard output. */
  483. #ifndef ECHO
  484. /* This used to be an fputs(), but since the string might contain NUL's,
  485. * we now use fwrite().
  486. */
  487. #define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
  488. #endif
  489. /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
  490. * is returned in "result".
  491. */
  492. #ifndef YY_INPUT
  493. #define YY_INPUT(buf,result,max_size) \
  494. if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
  495. { \
  496. int c = '*'; \
  497. int n; \
  498. for ( n = 0; n < max_size && \
  499. (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
  500. buf[n] = (char) c; \
  501. if ( c == '\n' ) \
  502. buf[n++] = (char) c; \
  503. if ( c == EOF && ferror( yyin ) ) \
  504. YY_FATAL_ERROR( "input in flex scanner failed" ); \
  505. result = n; \
  506. } \
  507. else \
  508. { \
  509. errno=0; \
  510. while ( (result = (int) fread(buf, 1, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \
  511. { \
  512. if( errno != EINTR) \
  513. { \
  514. YY_FATAL_ERROR( "input in flex scanner failed" ); \
  515. break; \
  516. } \
  517. errno=0; \
  518. clearerr(yyin); \
  519. } \
  520. }\
  521. \
  522. #endif
  523. /* No semi-colon after return; correct usage is to write "yyterminate();" -
  524. * we don't want an extra ';' after the "return" because that will cause
  525. * some compilers to complain about unreachable statements.
  526. */
  527. #ifndef yyterminate
  528. #define yyterminate() return YY_NULL
  529. #endif
  530. /* Number of entries by which start-condition stack grows. */
  531. #ifndef YY_START_STACK_INCR
  532. #define YY_START_STACK_INCR 25
  533. #endif
  534. /* Report a fatal error. */
  535. #ifndef YY_FATAL_ERROR
  536. #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
  537. #endif
  538. /* end tables serialization structures and prototypes */
  539. /* Default declaration of generated scanner - a define so the user can
  540. * easily add parameters.
  541. */
  542. #ifndef YY_DECL
  543. #define YY_DECL_IS_OURS 1
  544. extern int yylex (void);
  545. #define YY_DECL int yylex (void)
  546. #endif /* !YY_DECL */
  547. /* Code executed at the beginning of each rule, after yytext and yyleng
  548. * have been set up.
  549. */
  550. #ifndef YY_USER_ACTION
  551. #define YY_USER_ACTION
  552. #endif
  553. /* Code executed at the end of each rule. */
  554. #ifndef YY_BREAK
  555. #define YY_BREAK /*LINTED*/break;
  556. #endif
  557. #define YY_RULE_SETUP \
  558. YY_USER_ACTION
  559. /** The main scanner function which does all the work.
  560. */
  561. YY_DECL
  562. {
  563. yy_state_type yy_current_state;
  564. char *yy_cp, *yy_bp;
  565. int yy_act;
  566. if ( !(yy_init) )
  567. {
  568. (yy_init) = 1;
  569. #ifdef YY_USER_INIT
  570. YY_USER_INIT;
  571. #endif
  572. if ( ! (yy_start) )
  573. (yy_start) = 1; /* first start state */
  574. if ( ! yyin )
  575. yyin = stdin;
  576. if ( ! yyout )
  577. yyout = stdout;
  578. if ( ! YY_CURRENT_BUFFER ) {
  579. yyensure_buffer_stack ();
  580. YY_CURRENT_BUFFER_LVALUE =
  581. yy_create_buffer( yyin, YY_BUF_SIZE );
  582. }
  583. yy_load_buffer_state( );
  584. }
  585. {
  586. #line 41 "analyse_lexicale.lex"
  587. #line 714 "lex.yy.c"
  588. while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
  589. {
  590. yy_cp = (yy_c_buf_p);
  591. /* Support of yytext. */
  592. *yy_cp = (yy_hold_char);
  593. /* yy_bp points to the position in yy_ch_buf of the start of
  594. * the current run.
  595. */
  596. yy_bp = yy_cp;
  597. yy_current_state = (yy_start);
  598. yy_match:
  599. do
  600. {
  601. YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
  602. if ( yy_accept[yy_current_state] )
  603. {
  604. (yy_last_accepting_state) = yy_current_state;
  605. (yy_last_accepting_cpos) = yy_cp;
  606. }
  607. while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
  608. {
  609. yy_current_state = (int) yy_def[yy_current_state];
  610. if ( yy_current_state >= 70 )
  611. yy_c = yy_meta[yy_c];
  612. }
  613. yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
  614. ++yy_cp;
  615. }
  616. while ( yy_base[yy_current_state] != 117 );
  617. yy_find_action:
  618. yy_act = yy_accept[yy_current_state];
  619. if ( yy_act == 0 )
  620. { /* have to back up */
  621. yy_cp = (yy_last_accepting_cpos);
  622. yy_current_state = (yy_last_accepting_state);
  623. yy_act = yy_accept[yy_current_state];
  624. }
  625. YY_DO_BEFORE_ACTION;
  626. do_action: /* This label is used only to access EOF actions. */
  627. switch ( yy_act )
  628. { /* beginning of action switch */
  629. case 0: /* must back up */
  630. /* undo the effects of YY_DO_BEFORE_ACTION */
  631. *yy_cp = (yy_hold_char);
  632. yy_cp = (yy_last_accepting_cpos);
  633. yy_current_state = (yy_last_accepting_state);
  634. goto yy_find_action;
  635. case 1:
  636. YY_RULE_SETUP
  637. #line 43 "analyse_lexicale.lex"
  638. {return tADD ;}
  639. YY_BREAK
  640. case 2:
  641. YY_RULE_SETUP
  642. #line 44 "analyse_lexicale.lex"
  643. {return tSUB ;}
  644. YY_BREAK
  645. case 3:
  646. YY_RULE_SETUP
  647. #line 45 "analyse_lexicale.lex"
  648. {return tMUL ;}
  649. YY_BREAK
  650. case 4:
  651. YY_RULE_SETUP
  652. #line 46 "analyse_lexicale.lex"
  653. {return tDIV ;}
  654. YY_BREAK
  655. case 5:
  656. YY_RULE_SETUP
  657. #line 48 "analyse_lexicale.lex"
  658. {return tPO ;}
  659. YY_BREAK
  660. case 6:
  661. YY_RULE_SETUP
  662. #line 49 "analyse_lexicale.lex"
  663. {return tPF ;}
  664. YY_BREAK
  665. case 7:
  666. YY_RULE_SETUP
  667. #line 50 "analyse_lexicale.lex"
  668. {return tAO ;}
  669. YY_BREAK
  670. case 8:
  671. YY_RULE_SETUP
  672. #line 51 "analyse_lexicale.lex"
  673. {return tAF ;}
  674. YY_BREAK
  675. case 9:
  676. YY_RULE_SETUP
  677. #line 53 "analyse_lexicale.lex"
  678. {return tPV ;}
  679. YY_BREAK
  680. case 10:
  681. YY_RULE_SETUP
  682. #line 54 "analyse_lexicale.lex"
  683. {}
  684. YY_BREAK
  685. case 11:
  686. /* rule 11 can match eol */
  687. YY_RULE_SETUP
  688. #line 55 "analyse_lexicale.lex"
  689. {}
  690. YY_BREAK
  691. case 12:
  692. YY_RULE_SETUP
  693. #line 56 "analyse_lexicale.lex"
  694. {return tVIRGULE ;}
  695. YY_BREAK
  696. case 13:
  697. YY_RULE_SETUP
  698. #line 58 "analyse_lexicale.lex"
  699. {return tAFFECTATION ;}
  700. YY_BREAK
  701. case 14:
  702. YY_RULE_SETUP
  703. #line 60 "analyse_lexicale.lex"
  704. {return tEGAL ;}
  705. YY_BREAK
  706. case 15:
  707. YY_RULE_SETUP
  708. #line 61 "analyse_lexicale.lex"
  709. {return tDIFF ;}
  710. YY_BREAK
  711. case 16:
  712. YY_RULE_SETUP
  713. #line 62 "analyse_lexicale.lex"
  714. {return tLT ;}
  715. YY_BREAK
  716. case 17:
  717. YY_RULE_SETUP
  718. #line 63 "analyse_lexicale.lex"
  719. {return tGT ;}
  720. YY_BREAK
  721. case 18:
  722. YY_RULE_SETUP
  723. #line 64 "analyse_lexicale.lex"
  724. {return tLTE ;}
  725. YY_BREAK
  726. case 19:
  727. YY_RULE_SETUP
  728. #line 65 "analyse_lexicale.lex"
  729. {return tGTE ;}
  730. YY_BREAK
  731. case 20:
  732. YY_RULE_SETUP
  733. #line 66 "analyse_lexicale.lex"
  734. {return tNOT ;}
  735. YY_BREAK
  736. case 21:
  737. YY_RULE_SETUP
  738. #line 69 "analyse_lexicale.lex"
  739. {return tMAIN ;}
  740. YY_BREAK
  741. case 22:
  742. YY_RULE_SETUP
  743. #line 70 "analyse_lexicale.lex"
  744. {return tINT ;}
  745. YY_BREAK
  746. case 23:
  747. YY_RULE_SETUP
  748. #line 71 "analyse_lexicale.lex"
  749. {return tPRINT ;}
  750. YY_BREAK
  751. case 24:
  752. YY_RULE_SETUP
  753. #line 72 "analyse_lexicale.lex"
  754. {return tRETURN ;}
  755. YY_BREAK
  756. case 25:
  757. YY_RULE_SETUP
  758. #line 74 "analyse_lexicale.lex"
  759. {return tOR ;}
  760. YY_BREAK
  761. case 26:
  762. YY_RULE_SETUP
  763. #line 75 "analyse_lexicale.lex"
  764. {return tAND ;}
  765. YY_BREAK
  766. case 27:
  767. YY_RULE_SETUP
  768. #line 77 "analyse_lexicale.lex"
  769. {return tIF ;}
  770. YY_BREAK
  771. case 28:
  772. YY_RULE_SETUP
  773. #line 78 "analyse_lexicale.lex"
  774. {return tELSE ;}
  775. YY_BREAK
  776. case 29:
  777. YY_RULE_SETUP
  778. #line 79 "analyse_lexicale.lex"
  779. {return tWHILE ;}
  780. YY_BREAK
  781. case 30:
  782. YY_RULE_SETUP
  783. #line 81 "analyse_lexicale.lex"
  784. {return tCONST ;}
  785. YY_BREAK
  786. case 31:
  787. YY_RULE_SETUP
  788. #line 82 "analyse_lexicale.lex"
  789. {return tENTIER ;}
  790. YY_BREAK
  791. case 32:
  792. YY_RULE_SETUP
  793. #line 83 "analyse_lexicale.lex"
  794. {return tVAR ;}
  795. YY_BREAK
  796. case 33:
  797. YY_RULE_SETUP
  798. #line 85 "analyse_lexicale.lex"
  799. ECHO;
  800. YY_BREAK
  801. #line 937 "lex.yy.c"
  802. case YY_STATE_EOF(INITIAL):
  803. yyterminate();
  804. case YY_END_OF_BUFFER:
  805. {
  806. /* Amount of text matched not including the EOB char. */
  807. int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;
  808. /* Undo the effects of YY_DO_BEFORE_ACTION. */
  809. *yy_cp = (yy_hold_char);
  810. YY_RESTORE_YY_MORE_OFFSET
  811. if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
  812. {
  813. /* We're scanning a new file or input source. It's
  814. * possible that this happened because the user
  815. * just pointed yyin at a new source and called
  816. * yylex(). If so, then we have to assure
  817. * consistency between YY_CURRENT_BUFFER and our
  818. * globals. Here is the right place to do so, because
  819. * this is the first action (other than possibly a
  820. * back-up) that will match for the new input source.
  821. */
  822. (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
  823. YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
  824. YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
  825. }
  826. /* Note that here we test for yy_c_buf_p "<=" to the position
  827. * of the first EOB in the buffer, since yy_c_buf_p will
  828. * already have been incremented past the NUL character
  829. * (since all states make transitions on EOB to the
  830. * end-of-buffer state). Contrast this with the test
  831. * in input().
  832. */
  833. if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
  834. { /* This was really a NUL. */
  835. yy_state_type yy_next_state;
  836. (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text;
  837. yy_current_state = yy_get_previous_state( );
  838. /* Okay, we're now positioned to make the NUL
  839. * transition. We couldn't have
  840. * yy_get_previous_state() go ahead and do it
  841. * for us because it doesn't know how to deal
  842. * with the possibility of jamming (and we don't
  843. * want to build jamming into it because then it
  844. * will run more slowly).
  845. */
  846. yy_next_state = yy_try_NUL_trans( yy_current_state );
  847. yy_bp = (yytext_ptr) + YY_MORE_ADJ;
  848. if ( yy_next_state )
  849. {
  850. /* Consume the NUL. */
  851. yy_cp = ++(yy_c_buf_p);
  852. yy_current_state = yy_next_state;
  853. goto yy_match;
  854. }
  855. else
  856. {
  857. yy_cp = (yy_c_buf_p);
  858. goto yy_find_action;
  859. }
  860. }
  861. else switch ( yy_get_next_buffer( ) )
  862. {
  863. case EOB_ACT_END_OF_FILE:
  864. {
  865. (yy_did_buffer_switch_on_eof) = 0;
  866. if ( yywrap( ) )
  867. {
  868. /* Note: because we've taken care in
  869. * yy_get_next_buffer() to have set up
  870. * yytext, we can now set up
  871. * yy_c_buf_p so that if some total
  872. * hoser (like flex itself) wants to
  873. * call the scanner after we return the
  874. * YY_NULL, it'll still work - another
  875. * YY_NULL will get returned.
  876. */
  877. (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ;
  878. yy_act = YY_STATE_EOF(YY_START);
  879. goto do_action;
  880. }
  881. else
  882. {
  883. if ( ! (yy_did_buffer_switch_on_eof) )
  884. YY_NEW_FILE;
  885. }
  886. break;
  887. }
  888. case EOB_ACT_CONTINUE_SCAN:
  889. (yy_c_buf_p) =
  890. (yytext_ptr) + yy_amount_of_matched_text;
  891. yy_current_state = yy_get_previous_state( );
  892. yy_cp = (yy_c_buf_p);
  893. yy_bp = (yytext_ptr) + YY_MORE_ADJ;
  894. goto yy_match;
  895. case EOB_ACT_LAST_MATCH:
  896. (yy_c_buf_p) =
  897. &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)];
  898. yy_current_state = yy_get_previous_state( );
  899. yy_cp = (yy_c_buf_p);
  900. yy_bp = (yytext_ptr) + YY_MORE_ADJ;
  901. goto yy_find_action;
  902. }
  903. break;
  904. }
  905. default:
  906. YY_FATAL_ERROR(
  907. "fatal flex scanner internal error--no action found" );
  908. } /* end of action switch */
  909. } /* end of scanning one token */
  910. } /* end of user's declarations */
  911. } /* end of yylex */
  912. /* yy_get_next_buffer - try to read in a new buffer
  913. *
  914. * Returns a code representing an action:
  915. * EOB_ACT_LAST_MATCH -
  916. * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
  917. * EOB_ACT_END_OF_FILE - end of file
  918. */
  919. static int yy_get_next_buffer (void)
  920. {
  921. char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
  922. char *source = (yytext_ptr);
  923. int number_to_move, i;
  924. int ret_val;
  925. if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )
  926. YY_FATAL_ERROR(
  927. "fatal flex scanner internal error--end of buffer missed" );
  928. if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
  929. { /* Don't try to fill the buffer, so this is an EOF. */
  930. if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )
  931. {
  932. /* We matched a single character, the EOB, so
  933. * treat this as a final EOF.
  934. */
  935. return EOB_ACT_END_OF_FILE;
  936. }
  937. else
  938. {
  939. /* We matched some text prior to the EOB, first
  940. * process it.
  941. */
  942. return EOB_ACT_LAST_MATCH;
  943. }
  944. }
  945. /* Try to read more data. */
  946. /* First move last chars to start of buffer. */
  947. number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr) - 1);
  948. for ( i = 0; i < number_to_move; ++i )
  949. *(dest++) = *(source++);
  950. if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
  951. /* don't do the read, it's not guaranteed to return an EOF,
  952. * just force an EOF
  953. */
  954. YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;
  955. else
  956. {
  957. int num_to_read =
  958. YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
  959. while ( num_to_read <= 0 )
  960. { /* Not enough room in the buffer - grow it. */
  961. /* just a shorter name for the current buffer */
  962. YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
  963. int yy_c_buf_p_offset =
  964. (int) ((yy_c_buf_p) - b->yy_ch_buf);
  965. if ( b->yy_is_our_buffer )
  966. {
  967. int new_size = b->yy_buf_size * 2;
  968. if ( new_size <= 0 )
  969. b->yy_buf_size += b->yy_buf_size / 8;
  970. else
  971. b->yy_buf_size *= 2;
  972. b->yy_ch_buf = (char *)
  973. /* Include room in for 2 EOB chars. */
  974. yyrealloc( (void *) b->yy_ch_buf,
  975. (yy_size_t) (b->yy_buf_size + 2) );
  976. }
  977. else
  978. /* Can't grow it, we don't own it. */
  979. b->yy_ch_buf = NULL;
  980. if ( ! b->yy_ch_buf )
  981. YY_FATAL_ERROR(
  982. "fatal error - scanner input buffer overflow" );
  983. (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset];
  984. num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
  985. number_to_move - 1;
  986. }
  987. if ( num_to_read > YY_READ_BUF_SIZE )
  988. num_to_read = YY_READ_BUF_SIZE;
  989. /* Read in more data. */
  990. YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
  991. (yy_n_chars), num_to_read );
  992. YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
  993. }
  994. if ( (yy_n_chars) == 0 )
  995. {
  996. if ( number_to_move == YY_MORE_ADJ )
  997. {
  998. ret_val = EOB_ACT_END_OF_FILE;
  999. yyrestart( yyin );
  1000. }
  1001. else
  1002. {
  1003. ret_val = EOB_ACT_LAST_MATCH;
  1004. YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
  1005. YY_BUFFER_EOF_PENDING;
  1006. }
  1007. }
  1008. else
  1009. ret_val = EOB_ACT_CONTINUE_SCAN;
  1010. if (((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
  1011. /* Extend the array by 50%, plus the number we really need. */
  1012. int new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);
  1013. YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc(
  1014. (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size );
  1015. if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
  1016. YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
  1017. /* "- 2" to take care of EOB's */
  1018. YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2);
  1019. }
  1020. (yy_n_chars) += number_to_move;
  1021. YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR;
  1022. YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR;
  1023. (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
  1024. return ret_val;
  1025. }
  1026. /* yy_get_previous_state - get the state just before the EOB char was reached */
  1027. static yy_state_type yy_get_previous_state (void)
  1028. {
  1029. yy_state_type yy_current_state;
  1030. char *yy_cp;
  1031. yy_current_state = (yy_start);
  1032. for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
  1033. {
  1034. YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
  1035. if ( yy_accept[yy_current_state] )
  1036. {
  1037. (yy_last_accepting_state) = yy_current_state;
  1038. (yy_last_accepting_cpos) = yy_cp;
  1039. }
  1040. while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
  1041. {
  1042. yy_current_state = (int) yy_def[yy_current_state];
  1043. if ( yy_current_state >= 70 )
  1044. yy_c = yy_meta[yy_c];
  1045. }
  1046. yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
  1047. }
  1048. return yy_current_state;
  1049. }
  1050. /* yy_try_NUL_trans - try to make a transition on the NUL character
  1051. *
  1052. * synopsis
  1053. * next_state = yy_try_NUL_trans( current_state );
  1054. */
  1055. static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state )
  1056. {
  1057. int yy_is_jam;
  1058. char *yy_cp = (yy_c_buf_p);
  1059. YY_CHAR yy_c = 1;
  1060. if ( yy_accept[yy_current_state] )
  1061. {
  1062. (yy_last_accepting_state) = yy_current_state;
  1063. (yy_last_accepting_cpos) = yy_cp;
  1064. }
  1065. while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
  1066. {
  1067. yy_current_state = (int) yy_def[yy_current_state];
  1068. if ( yy_current_state >= 70 )
  1069. yy_c = yy_meta[yy_c];
  1070. }
  1071. yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
  1072. yy_is_jam = (yy_current_state == 69);
  1073. return yy_is_jam ? 0 : yy_current_state;
  1074. }
  1075. #ifndef YY_NO_UNPUT
  1076. static void yyunput (int c, char * yy_bp )
  1077. {
  1078. char *yy_cp;
  1079. yy_cp = (yy_c_buf_p);
  1080. /* undo effects of setting up yytext */
  1081. *yy_cp = (yy_hold_char);
  1082. if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
  1083. { /* need to shift things up to make room */
  1084. /* +2 for EOB chars. */
  1085. int number_to_move = (yy_n_chars) + 2;
  1086. char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
  1087. YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
  1088. char *source =
  1089. &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
  1090. while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
  1091. *--dest = *--source;
  1092. yy_cp += (int) (dest - source);
  1093. yy_bp += (int) (dest - source);
  1094. YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
  1095. (yy_n_chars) = (int) YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
  1096. if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
  1097. YY_FATAL_ERROR( "flex scanner push-back overflow" );
  1098. }
  1099. *--yy_cp = (char) c;
  1100. (yytext_ptr) = yy_bp;
  1101. (yy_hold_char) = *yy_cp;
  1102. (yy_c_buf_p) = yy_cp;
  1103. }
  1104. #endif
  1105. #ifndef YY_NO_INPUT
  1106. #ifdef __cplusplus
  1107. static int yyinput (void)
  1108. #else
  1109. static int input (void)
  1110. #endif
  1111. {
  1112. int c;
  1113. *(yy_c_buf_p) = (yy_hold_char);
  1114. if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR )
  1115. {
  1116. /* yy_c_buf_p now points to the character we want to return.
  1117. * If this occurs *before* the EOB characters, then it's a
  1118. * valid NUL; if not, then we've hit the end of the buffer.
  1119. */
  1120. if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
  1121. /* This was really a NUL. */
  1122. *(yy_c_buf_p) = '\0';
  1123. else
  1124. { /* need more input */
  1125. int offset = (int) ((yy_c_buf_p) - (yytext_ptr));
  1126. ++(yy_c_buf_p);
  1127. switch ( yy_get_next_buffer( ) )
  1128. {
  1129. case EOB_ACT_LAST_MATCH:
  1130. /* This happens because yy_g_n_b()
  1131. * sees that we've accumulated a
  1132. * token and flags that we need to
  1133. * try matching the token before
  1134. * proceeding. But for input(),
  1135. * there's no matching to consider.
  1136. * So convert the EOB_ACT_LAST_MATCH
  1137. * to EOB_ACT_END_OF_FILE.
  1138. */
  1139. /* Reset buffer status. */
  1140. yyrestart( yyin );
  1141. /*FALLTHROUGH*/
  1142. case EOB_ACT_END_OF_FILE:
  1143. {
  1144. if ( yywrap( ) )
  1145. return 0;
  1146. if ( ! (yy_did_buffer_switch_on_eof) )
  1147. YY_NEW_FILE;
  1148. #ifdef __cplusplus
  1149. return yyinput();
  1150. #else
  1151. return input();
  1152. #endif
  1153. }
  1154. case EOB_ACT_CONTINUE_SCAN:
  1155. (yy_c_buf_p) = (yytext_ptr) + offset;
  1156. break;
  1157. }
  1158. }
  1159. }
  1160. c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */
  1161. *(yy_c_buf_p) = '\0'; /* preserve yytext */
  1162. (yy_hold_char) = *++(yy_c_buf_p);
  1163. return c;
  1164. }
  1165. #endif /* ifndef YY_NO_INPUT */
  1166. /** Immediately switch to a different input stream.
  1167. * @param input_file A readable stream.
  1168. *
  1169. * @note This function does not reset the start condition to @c INITIAL .
  1170. */
  1171. void yyrestart (FILE * input_file )
  1172. {
  1173. if ( ! YY_CURRENT_BUFFER ){
  1174. yyensure_buffer_stack ();
  1175. YY_CURRENT_BUFFER_LVALUE =
  1176. yy_create_buffer( yyin, YY_BUF_SIZE );
  1177. }
  1178. yy_init_buffer( YY_CURRENT_BUFFER, input_file );
  1179. yy_load_buffer_state( );
  1180. }
  1181. /** Switch to a different input buffer.
  1182. * @param new_buffer The new input buffer.
  1183. *
  1184. */
  1185. void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer )
  1186. {
  1187. /* TODO. We should be able to replace this entire function body
  1188. * with
  1189. * yypop_buffer_state();
  1190. * yypush_buffer_state(new_buffer);
  1191. */
  1192. yyensure_buffer_stack ();
  1193. if ( YY_CURRENT_BUFFER == new_buffer )
  1194. return;
  1195. if ( YY_CURRENT_BUFFER )
  1196. {
  1197. /* Flush out information for old buffer. */
  1198. *(yy_c_buf_p) = (yy_hold_char);
  1199. YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
  1200. YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
  1201. }
  1202. YY_CURRENT_BUFFER_LVALUE = new_buffer;
  1203. yy_load_buffer_state( );
  1204. /* We don't actually know whether we did this switch during
  1205. * EOF (yywrap()) processing, but the only time this flag
  1206. * is looked at is after yywrap() is called, so it's safe
  1207. * to go ahead and always set it.
  1208. */
  1209. (yy_did_buffer_switch_on_eof) = 1;
  1210. }
  1211. static void yy_load_buffer_state (void)
  1212. {
  1213. (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
  1214. (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
  1215. yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
  1216. (yy_hold_char) = *(yy_c_buf_p);
  1217. }
  1218. /** Allocate and initialize an input buffer state.
  1219. * @param file A readable stream.
  1220. * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
  1221. *
  1222. * @return the allocated buffer state.
  1223. */
  1224. YY_BUFFER_STATE yy_create_buffer (FILE * file, int size )
  1225. {
  1226. YY_BUFFER_STATE b;
  1227. b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) );
  1228. if ( ! b )
  1229. YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
  1230. b->yy_buf_size = size;
  1231. /* yy_ch_buf has to be 2 characters longer than the size given because
  1232. * we need to put in 2 end-of-buffer characters.
  1233. */
  1234. b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) );
  1235. if ( ! b->yy_ch_buf )
  1236. YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
  1237. b->yy_is_our_buffer = 1;
  1238. yy_init_buffer( b, file );
  1239. return b;
  1240. }
  1241. /** Destroy the buffer.
  1242. * @param b a buffer created with yy_create_buffer()
  1243. *
  1244. */
  1245. void yy_delete_buffer (YY_BUFFER_STATE b )
  1246. {
  1247. if ( ! b )
  1248. return;
  1249. if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
  1250. YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
  1251. if ( b->yy_is_our_buffer )
  1252. yyfree( (void *) b->yy_ch_buf );
  1253. yyfree( (void *) b );
  1254. }
  1255. /* Initializes or reinitializes a buffer.
  1256. * This function is sometimes called more than once on the same buffer,
  1257. * such as during a yyrestart() or at EOF.
  1258. */
  1259. static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file )
  1260. {
  1261. int oerrno = errno;
  1262. yy_flush_buffer( b );
  1263. b->yy_input_file = file;
  1264. b->yy_fill_buffer = 1;
  1265. /* If b is the current buffer, then yy_init_buffer was _probably_
  1266. * called from yyrestart() or through yy_get_next_buffer.
  1267. * In that case, we don't want to reset the lineno or column.
  1268. */
  1269. if (b != YY_CURRENT_BUFFER){
  1270. b->yy_bs_lineno = 1;
  1271. b->yy_bs_column = 0;
  1272. }
  1273. b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
  1274. errno = oerrno;
  1275. }
  1276. /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
  1277. * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
  1278. *
  1279. */
  1280. void yy_flush_buffer (YY_BUFFER_STATE b )
  1281. {
  1282. if ( ! b )
  1283. return;
  1284. b->yy_n_chars = 0;
  1285. /* We always need two end-of-buffer characters. The first causes
  1286. * a transition to the end-of-buffer state. The second causes
  1287. * a jam in that state.
  1288. */
  1289. b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
  1290. b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
  1291. b->yy_buf_pos = &b->yy_ch_buf[0];
  1292. b->yy_at_bol = 1;
  1293. b->yy_buffer_status = YY_BUFFER_NEW;
  1294. if ( b == YY_CURRENT_BUFFER )
  1295. yy_load_buffer_state( );
  1296. }
  1297. /** Pushes the new state onto the stack. The new state becomes
  1298. * the current state. This function will allocate the stack
  1299. * if necessary.
  1300. * @param new_buffer The new state.
  1301. *
  1302. */
  1303. void yypush_buffer_state (YY_BUFFER_STATE new_buffer )
  1304. {
  1305. if (new_buffer == NULL)
  1306. return;
  1307. yyensure_buffer_stack();
  1308. /* This block is copied from yy_switch_to_buffer. */
  1309. if ( YY_CURRENT_BUFFER )
  1310. {
  1311. /* Flush out information for old buffer. */
  1312. *(yy_c_buf_p) = (yy_hold_char);
  1313. YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
  1314. YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
  1315. }
  1316. /* Only push if top exists. Otherwise, replace top. */
  1317. if (YY_CURRENT_BUFFER)
  1318. (yy_buffer_stack_top)++;
  1319. YY_CURRENT_BUFFER_LVALUE = new_buffer;
  1320. /* copied from yy_switch_to_buffer. */
  1321. yy_load_buffer_state( );
  1322. (yy_did_buffer_switch_on_eof) = 1;
  1323. }
  1324. /** Removes and deletes the top of the stack, if present.
  1325. * The next element becomes the new top.
  1326. *
  1327. */
  1328. void yypop_buffer_state (void)
  1329. {
  1330. if (!YY_CURRENT_BUFFER)
  1331. return;
  1332. yy_delete_buffer(YY_CURRENT_BUFFER );
  1333. YY_CURRENT_BUFFER_LVALUE = NULL;
  1334. if ((yy_buffer_stack_top) > 0)
  1335. --(yy_buffer_stack_top);
  1336. if (YY_CURRENT_BUFFER) {
  1337. yy_load_buffer_state( );
  1338. (yy_did_buffer_switch_on_eof) = 1;
  1339. }
  1340. }
  1341. /* Allocates the stack if it does not exist.
  1342. * Guarantees space for at least one push.
  1343. */
  1344. static void yyensure_buffer_stack (void)
  1345. {
  1346. yy_size_t num_to_alloc;
  1347. if (!(yy_buffer_stack)) {
  1348. /* First allocation is just for 2 elements, since we don't know if this
  1349. * scanner will even need a stack. We use 2 instead of 1 to avoid an
  1350. * immediate realloc on the next call.
  1351. */
  1352. num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
  1353. (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc
  1354. (num_to_alloc * sizeof(struct yy_buffer_state*)
  1355. );
  1356. if ( ! (yy_buffer_stack) )
  1357. YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
  1358. memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
  1359. (yy_buffer_stack_max) = num_to_alloc;
  1360. (yy_buffer_stack_top) = 0;
  1361. return;
  1362. }
  1363. if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){
  1364. /* Increase the buffer to prepare for a possible push. */
  1365. yy_size_t grow_size = 8 /* arbitrary grow size */;
  1366. num_to_alloc = (yy_buffer_stack_max) + grow_size;
  1367. (yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc
  1368. ((yy_buffer_stack),
  1369. num_to_alloc * sizeof(struct yy_buffer_state*)
  1370. );
  1371. if ( ! (yy_buffer_stack) )
  1372. YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
  1373. /* zero only the new slots.*/
  1374. memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));
  1375. (yy_buffer_stack_max) = num_to_alloc;
  1376. }
  1377. }
  1378. /** Setup the input buffer state to scan directly from a user-specified character buffer.
  1379. * @param base the character buffer
  1380. * @param size the size in bytes of the character buffer
  1381. *
  1382. * @return the newly allocated buffer state object.
  1383. */
  1384. YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size )
  1385. {
  1386. YY_BUFFER_STATE b;
  1387. if ( size < 2 ||
  1388. base[size-2] != YY_END_OF_BUFFER_CHAR ||
  1389. base[size-1] != YY_END_OF_BUFFER_CHAR )
  1390. /* They forgot to leave room for the EOB's. */
  1391. return NULL;
  1392. b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) );
  1393. if ( ! b )
  1394. YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
  1395. b->yy_buf_size = (int) (size - 2); /* "- 2" to take care of EOB's */
  1396. b->yy_buf_pos = b->yy_ch_buf = base;
  1397. b->yy_is_our_buffer = 0;
  1398. b->yy_input_file = NULL;
  1399. b->yy_n_chars = b->yy_buf_size;
  1400. b->yy_is_interactive = 0;
  1401. b->yy_at_bol = 1;
  1402. b->yy_fill_buffer = 0;
  1403. b->yy_buffer_status = YY_BUFFER_NEW;
  1404. yy_switch_to_buffer( b );
  1405. return b;
  1406. }
  1407. /** Setup the input buffer state to scan a string. The next call to yylex() will
  1408. * scan from a @e copy of @a str.
  1409. * @param yystr a NUL-terminated string to scan
  1410. *
  1411. * @return the newly allocated buffer state object.
  1412. * @note If you want to scan bytes that may contain NUL values, then use
  1413. * yy_scan_bytes() instead.
  1414. */
  1415. YY_BUFFER_STATE yy_scan_string (const char * yystr )
  1416. {
  1417. return yy_scan_bytes( yystr, (int) strlen(yystr) );
  1418. }
  1419. /** Setup the input buffer state to scan the given bytes. The next call to yylex() will
  1420. * scan from a @e copy of @a bytes.
  1421. * @param yybytes the byte buffer to scan
  1422. * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
  1423. *
  1424. * @return the newly allocated buffer state object.
  1425. */
  1426. YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, int _yybytes_len )
  1427. {
  1428. YY_BUFFER_STATE b;
  1429. char *buf;
  1430. yy_size_t n;
  1431. int i;
  1432. /* Get memory for full buffer, including space for trailing EOB's. */
  1433. n = (yy_size_t) (_yybytes_len + 2);
  1434. buf = (char *) yyalloc( n );
  1435. if ( ! buf )
  1436. YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
  1437. for ( i = 0; i < _yybytes_len; ++i )
  1438. buf[i] = yybytes[i];
  1439. buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
  1440. b = yy_scan_buffer( buf, n );
  1441. if ( ! b )
  1442. YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
  1443. /* It's okay to grow etc. this buffer, and we should throw it
  1444. * away when we're done.
  1445. */
  1446. b->yy_is_our_buffer = 1;
  1447. return b;
  1448. }
  1449. #ifndef YY_EXIT_FAILURE
  1450. #define YY_EXIT_FAILURE 2
  1451. #endif
  1452. static void yynoreturn yy_fatal_error (const char* msg )
  1453. {
  1454. fprintf( stderr, "%s\n", msg );
  1455. exit( YY_EXIT_FAILURE );
  1456. }
  1457. /* Redefine yyless() so it works in section 3 code. */
  1458. #undef yyless
  1459. #define yyless(n) \
  1460. do \
  1461. { \
  1462. /* Undo effects of setting up yytext. */ \
  1463. int yyless_macro_arg = (n); \
  1464. YY_LESS_LINENO(yyless_macro_arg);\
  1465. yytext[yyleng] = (yy_hold_char); \
  1466. (yy_c_buf_p) = yytext + yyless_macro_arg; \
  1467. (yy_hold_char) = *(yy_c_buf_p); \
  1468. *(yy_c_buf_p) = '\0'; \
  1469. yyleng = yyless_macro_arg; \
  1470. } \
  1471. while ( 0 )
  1472. /* Accessor methods (get/set functions) to struct members. */
  1473. /** Get the current line number.
  1474. *
  1475. */
  1476. int yyget_lineno (void)
  1477. {
  1478. return yylineno;
  1479. }
  1480. /** Get the input stream.
  1481. *
  1482. */
  1483. FILE *yyget_in (void)
  1484. {
  1485. return yyin;
  1486. }
  1487. /** Get the output stream.
  1488. *
  1489. */
  1490. FILE *yyget_out (void)
  1491. {
  1492. return yyout;
  1493. }
  1494. /** Get the length of the current token.
  1495. *
  1496. */
  1497. int yyget_leng (void)
  1498. {
  1499. return yyleng;
  1500. }
  1501. /** Get the current token.
  1502. *
  1503. */
  1504. char *yyget_text (void)
  1505. {
  1506. return yytext;
  1507. }
  1508. /** Set the current line number.
  1509. * @param _line_number line number
  1510. *
  1511. */
  1512. void yyset_lineno (int _line_number )
  1513. {
  1514. yylineno = _line_number;
  1515. }
  1516. /** Set the input stream. This does not discard the current
  1517. * input buffer.
  1518. * @param _in_str A readable stream.
  1519. *
  1520. * @see yy_switch_to_buffer
  1521. */
  1522. void yyset_in (FILE * _in_str )
  1523. {
  1524. yyin = _in_str ;
  1525. }
  1526. void yyset_out (FILE * _out_str )
  1527. {
  1528. yyout = _out_str ;
  1529. }
  1530. int yyget_debug (void)
  1531. {
  1532. return yy_flex_debug;
  1533. }
  1534. void yyset_debug (int _bdebug )
  1535. {
  1536. yy_flex_debug = _bdebug ;
  1537. }
  1538. static int yy_init_globals (void)
  1539. {
  1540. /* Initialization is the same as for the non-reentrant scanner.
  1541. * This function is called from yylex_destroy(), so don't allocate here.
  1542. */
  1543. (yy_buffer_stack) = NULL;
  1544. (yy_buffer_stack_top) = 0;
  1545. (yy_buffer_stack_max) = 0;
  1546. (yy_c_buf_p) = NULL;
  1547. (yy_init) = 0;
  1548. (yy_start) = 0;
  1549. /* Defined in main.c */
  1550. #ifdef YY_STDINIT
  1551. yyin = stdin;
  1552. yyout = stdout;
  1553. #else
  1554. yyin = NULL;
  1555. yyout = NULL;
  1556. #endif
  1557. /* For future reference: Set errno on error, since we are called by
  1558. * yylex_init()
  1559. */
  1560. return 0;
  1561. }
  1562. /* yylex_destroy is for both reentrant and non-reentrant scanners. */
  1563. int yylex_destroy (void)
  1564. {
  1565. /* Pop the buffer stack, destroying each element. */
  1566. while(YY_CURRENT_BUFFER){
  1567. yy_delete_buffer( YY_CURRENT_BUFFER );
  1568. YY_CURRENT_BUFFER_LVALUE = NULL;
  1569. yypop_buffer_state();
  1570. }
  1571. /* Destroy the stack itself. */
  1572. yyfree((yy_buffer_stack) );
  1573. (yy_buffer_stack) = NULL;
  1574. /* Reset the globals. This is important in a non-reentrant scanner so the next time
  1575. * yylex() is called, initialization will occur. */
  1576. yy_init_globals( );
  1577. return 0;
  1578. }
  1579. /*
  1580. * Internal utility routines.
  1581. */
  1582. #ifndef yytext_ptr
  1583. static void yy_flex_strncpy (char* s1, const char * s2, int n )
  1584. {
  1585. int i;
  1586. for ( i = 0; i < n; ++i )
  1587. s1[i] = s2[i];
  1588. }
  1589. #endif
  1590. #ifdef YY_NEED_STRLEN
  1591. static int yy_flex_strlen (const char * s )
  1592. {
  1593. int n;
  1594. for ( n = 0; s[n]; ++n )
  1595. ;
  1596. return n;
  1597. }
  1598. #endif
  1599. void *yyalloc (yy_size_t size )
  1600. {
  1601. return malloc(size);
  1602. }
  1603. void *yyrealloc (void * ptr, yy_size_t size )
  1604. {
  1605. /* The cast to (char *) in the following accommodates both
  1606. * implementations that use char* generic pointers, and those
  1607. * that use void* generic pointers. It works with the latter
  1608. * because both ANSI C and C++ allow castless assignment from
  1609. * any pointer type to void*, and deal with argument conversions
  1610. * as though doing an assignment.
  1611. */
  1612. return realloc(ptr, size);
  1613. }
  1614. void yyfree (void * ptr )
  1615. {
  1616. free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
  1617. }
  1618. #define YYTABLES_NAME "yytables"
  1619. #line 85 "analyse_lexicale.lex"
  1620. int yywrap(void){
  1621. return 1;
  1622. }
  1623. //int main(void){
  1624. // yylex();
  1625. //}