/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.cpp

Go to the documentation of this file.
00001 #line 2 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.cpp"
00002 
00003 #line 4 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.cpp"
00004 
00005 #define  YY_INT_ALIGNED short int
00006 
00007 /* A lexical scanner generated by flex */
00008 
00009 #define FLEX_SCANNER
00010 #define YY_FLEX_MAJOR_VERSION 2
00011 #define YY_FLEX_MINOR_VERSION 5
00012 #define YY_FLEX_SUBMINOR_VERSION 33
00013 #if YY_FLEX_SUBMINOR_VERSION > 0
00014 #define FLEX_BETA
00015 #endif
00016 
00017 /* First, we deal with  platform-specific or compiler-specific issues. */
00018 
00019 /* begin standard C headers. */
00020 #include <stdio.h>
00021 #include <string.h>
00022 #include <errno.h>
00023 #include <stdlib.h>
00024 
00025 /* end standard C headers. */
00026 
00027 /* flex integer type definitions */
00028 
00029 #ifndef FLEXINT_H
00030 #define FLEXINT_H
00031 
00032 /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
00033 
00034 #if __STDC_VERSION__ >= 199901L
00035 
00036 /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
00037  * if you want the limit (max/min) macros for int types. 
00038  */
00039 #ifndef __STDC_LIMIT_MACROS
00040 #define __STDC_LIMIT_MACROS 1
00041 #endif
00042 
00043 #include <inttypes.h>
00044 typedef int8_t flex_int8_t;
00045 typedef uint8_t flex_uint8_t;
00046 typedef int16_t flex_int16_t;
00047 typedef uint16_t flex_uint16_t;
00048 typedef int32_t flex_int32_t;
00049 typedef uint32_t flex_uint32_t;
00050 #else
00051 typedef signed char flex_int8_t;
00052 typedef short int flex_int16_t;
00053 typedef int flex_int32_t;
00054 typedef unsigned char flex_uint8_t; 
00055 typedef unsigned short int flex_uint16_t;
00056 typedef unsigned int flex_uint32_t;
00057 #endif /* ! C99 */
00058 
00059 /* Limits of integral types. */
00060 #ifndef INT8_MIN
00061 #define INT8_MIN               (-128)
00062 #endif
00063 #ifndef INT16_MIN
00064 #define INT16_MIN              (-32767-1)
00065 #endif
00066 #ifndef INT32_MIN
00067 #define INT32_MIN              (-2147483647-1)
00068 #endif
00069 #ifndef INT8_MAX
00070 #define INT8_MAX               (127)
00071 #endif
00072 #ifndef INT16_MAX
00073 #define INT16_MAX              (32767)
00074 #endif
00075 #ifndef INT32_MAX
00076 #define INT32_MAX              (2147483647)
00077 #endif
00078 #ifndef UINT8_MAX
00079 #define UINT8_MAX              (255U)
00080 #endif
00081 #ifndef UINT16_MAX
00082 #define UINT16_MAX             (65535U)
00083 #endif
00084 #ifndef UINT32_MAX
00085 #define UINT32_MAX             (4294967295U)
00086 #endif
00087 
00088 #endif /* ! FLEXINT_H */
00089 
00090 #ifdef __cplusplus
00091 
00092 /* The "const" storage-class-modifier is valid. */
00093 #define YY_USE_CONST
00094 
00095 #else   /* ! __cplusplus */
00096 
00097 #if __STDC__
00098 
00099 #define YY_USE_CONST
00100 
00101 #endif  /* __STDC__ */
00102 #endif  /* ! __cplusplus */
00103 
00104 #ifdef YY_USE_CONST
00105 #define yyconst const
00106 #else
00107 #define yyconst
00108 #endif
00109 
00110 /* Returned upon end-of-file. */
00111 #define YY_NULL 0
00112 
00113 /* Promotes a possibly negative, possibly signed char to an unsigned
00114  * integer for use as an array index.  If the signed char is negative,
00115  * we want to instead treat it as an 8-bit unsigned char, hence the
00116  * double cast.
00117  */
00118 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
00119 
00120 /* An opaque pointer. */
00121 #ifndef YY_TYPEDEF_YY_SCANNER_T
00122 #define YY_TYPEDEF_YY_SCANNER_T
00123 typedef void* yyscan_t;
00124 #endif
00125 
00126 /* For convenience, these vars (plus the bison vars far below)
00127    are macros in the reentrant scanner. */
00128 #define yyin yyg->yyin_r
00129 #define yyout yyg->yyout_r
00130 #define yyextra yyg->yyextra_r
00131 #define yyleng yyg->yyleng_r
00132 #define yytext yyg->yytext_r
00133 #define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
00134 #define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
00135 #define yy_flex_debug yyg->yy_flex_debug_r
00136 
00137 int osollex_init (yyscan_t* scanner);
00138 
00139 /* Enter a start condition.  This macro really ought to take a parameter,
00140  * but we do it the disgusting crufty way forced on us by the ()-less
00141  * definition of BEGIN.
00142  */
00143 #define BEGIN yyg->yy_start = 1 + 2 *
00144 
00145 /* Translate the current start state into a value that can be later handed
00146  * to BEGIN to return to the state.  The YYSTATE alias is for lex
00147  * compatibility.
00148  */
00149 #define YY_START ((yyg->yy_start - 1) / 2)
00150 #define YYSTATE YY_START
00151 
00152 /* Action number for EOF rule of a given start state. */
00153 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
00154 
00155 /* Special action meaning "start processing a new file". */
00156 #define YY_NEW_FILE osolrestart(yyin ,yyscanner )
00157 
00158 #define YY_END_OF_BUFFER_CHAR 0
00159 
00160 /* Size of default input buffer. */
00161 #ifndef YY_BUF_SIZE
00162 #define YY_BUF_SIZE 16384
00163 #endif
00164 
00165 /* The state buf must be large enough to hold one state per character in the main buffer.
00166  */
00167 #define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
00168 
00169 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
00170 #define YY_TYPEDEF_YY_BUFFER_STATE
00171 typedef struct yy_buffer_state *YY_BUFFER_STATE;
00172 #endif
00173 
00174 #define EOB_ACT_CONTINUE_SCAN 0
00175 #define EOB_ACT_END_OF_FILE 1
00176 #define EOB_ACT_LAST_MATCH 2
00177 
00178     /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
00179      *       access to the local variable yy_act. Since yyless() is a macro, it would break
00180      *       existing scanners that call yyless() from OUTSIDE osollex. 
00181      *       One obvious solution it to make yy_act a global. I tried that, and saw
00182      *       a 5% performance hit in a non-yylineno scanner, because yy_act is
00183      *       normally declared as a register variable-- so it is not worth it.
00184      */
00185     #define  YY_LESS_LINENO(n) \
00186             do { \
00187                 int yyl;\
00188                 for ( yyl = n; yyl < yyleng; ++yyl )\
00189                     if ( yytext[yyl] == '\n' )\
00190                         --yylineno;\
00191             }while(0)
00192     
00193 /* Return all but the first "n" matched characters back to the input stream. */
00194 #define yyless(n) \
00195         do \
00196                 { \
00197                 /* Undo effects of setting up yytext. */ \
00198         int yyless_macro_arg = (n); \
00199         YY_LESS_LINENO(yyless_macro_arg);\
00200                 *yy_cp = yyg->yy_hold_char; \
00201                 YY_RESTORE_YY_MORE_OFFSET \
00202                 yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
00203                 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
00204                 } \
00205         while ( 0 )
00206 
00207 #define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
00208 
00209 /* The following is because we cannot portably get our hands on size_t
00210  * (without autoconf's help, which isn't available because we want
00211  * flex-generated scanners to compile on their own).
00212  */
00213 
00214 #ifndef YY_TYPEDEF_YY_SIZE_T
00215 #define YY_TYPEDEF_YY_SIZE_T
00216 typedef unsigned int yy_size_t;
00217 #endif
00218 
00219 #ifndef YY_STRUCT_YY_BUFFER_STATE
00220 #define YY_STRUCT_YY_BUFFER_STATE
00221 struct yy_buffer_state
00222         {
00223         FILE *yy_input_file;
00224 
00225         char *yy_ch_buf;                /* input buffer */
00226         char *yy_buf_pos;               /* current position in input buffer */
00227 
00228         /* Size of input buffer in bytes, not including room for EOB
00229          * characters.
00230          */
00231         yy_size_t yy_buf_size;
00232 
00233         /* Number of characters read into yy_ch_buf, not including EOB
00234          * characters.
00235          */
00236         int yy_n_chars;
00237 
00238         /* Whether we "own" the buffer - i.e., we know we created it,
00239          * and can realloc() it to grow it, and should free() it to
00240          * delete it.
00241          */
00242         int yy_is_our_buffer;
00243 
00244         /* Whether this is an "interactive" input source; if so, and
00245          * if we're using stdio for input, then we want to use getc()
00246          * instead of fread(), to make sure we stop fetching input after
00247          * each newline.
00248          */
00249         int yy_is_interactive;
00250 
00251         /* Whether we're considered to be at the beginning of a line.
00252          * If so, '^' rules will be active on the next match, otherwise
00253          * not.
00254          */
00255         int yy_at_bol;
00256 
00257     int yy_bs_lineno; 
00258     int yy_bs_column; 
00260         /* Whether to try to fill the input buffer when we reach the
00261          * end of it.
00262          */
00263         int yy_fill_buffer;
00264 
00265         int yy_buffer_status;
00266 
00267 #define YY_BUFFER_NEW 0
00268 #define YY_BUFFER_NORMAL 1
00269         /* When an EOF's been seen but there's still some text to process
00270          * then we mark the buffer as YY_EOF_PENDING, to indicate that we
00271          * shouldn't try reading from the input source any more.  We might
00272          * still have a bunch of tokens to match, though, because of
00273          * possible backing-up.
00274          *
00275          * When we actually see the EOF, we change the status to "new"
00276          * (via osolrestart()), so that the user can continue scanning by
00277          * just pointing yyin at a new input file.
00278          */
00279 #define YY_BUFFER_EOF_PENDING 2
00280 
00281         };
00282 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
00283 
00284 /* We provide macros for accessing buffer states in case in the
00285  * future we want to put the buffer states in a more general
00286  * "scanner state".
00287  *
00288  * Returns the top of the stack, or NULL.
00289  */
00290 #define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
00291                           ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
00292                           : NULL)
00293 
00294 /* Same as previous macro, but useful when we know that the buffer stack is not
00295  * NULL or when we need an lvalue. For internal use only.
00296  */
00297 #define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
00298 
00299 void osolrestart (FILE *input_file ,yyscan_t yyscanner );
00300 void osol_switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
00301 YY_BUFFER_STATE osol_create_buffer (FILE *file,int size ,yyscan_t yyscanner );
00302 void osol_delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
00303 void osol_flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
00304 void osolpush_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
00305 void osolpop_buffer_state (yyscan_t yyscanner );
00306 
00307 static void osolensure_buffer_stack (yyscan_t yyscanner );
00308 static void osol_load_buffer_state (yyscan_t yyscanner );
00309 static void osol_init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
00310 
00311 #define YY_FLUSH_BUFFER osol_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
00312 
00313 YY_BUFFER_STATE osol_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
00314 YY_BUFFER_STATE osol_scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
00315 YY_BUFFER_STATE osol_scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
00316 
00317 void *osolalloc (yy_size_t ,yyscan_t yyscanner );
00318 void *osolrealloc (void *,yy_size_t ,yyscan_t yyscanner );
00319 void osolfree (void * ,yyscan_t yyscanner );
00320 
00321 #define yy_new_buffer osol_create_buffer
00322 
00323 #define yy_set_interactive(is_interactive) \
00324         { \
00325         if ( ! YY_CURRENT_BUFFER ){ \
00326         osolensure_buffer_stack (yyscanner); \
00327                 YY_CURRENT_BUFFER_LVALUE =    \
00328             osol_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
00329         } \
00330         YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
00331         }
00332 
00333 #define yy_set_bol(at_bol) \
00334         { \
00335         if ( ! YY_CURRENT_BUFFER ){\
00336         osolensure_buffer_stack (yyscanner); \
00337                 YY_CURRENT_BUFFER_LVALUE =    \
00338             osol_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
00339         } \
00340         YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
00341         }
00342 
00343 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
00344 
00345 /* Begin user sect3 */
00346 
00347 #define osolwrap(n) 1
00348 #define YY_SKIP_YYWRAP
00349 
00350 typedef unsigned char YY_CHAR;
00351 
00352 typedef int yy_state_type;
00353 
00354 #define yytext_ptr yytext_r
00355 
00356 static yy_state_type yy_get_previous_state (yyscan_t yyscanner );
00357 static yy_state_type yy_try_NUL_trans (yy_state_type current_state  ,yyscan_t yyscanner);
00358 static int yy_get_next_buffer (yyscan_t yyscanner );
00359 static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner );
00360 
00361 /* Done after the current pattern has been matched and before the
00362  * corresponding action - sets up yytext.
00363  */
00364 #define YY_DO_BEFORE_ACTION \
00365         yyg->yytext_ptr = yy_bp; \
00366         yyleng = (size_t) (yy_cp - yy_bp); \
00367         yyg->yy_hold_char = *yy_cp; \
00368         *yy_cp = '\0'; \
00369         yyg->yy_c_buf_p = yy_cp;
00370 
00371 #define YY_NUM_RULES 3
00372 #define YY_END_OF_BUFFER 4
00373 /* This struct is not used in this scanner,
00374    but its presence is necessary. */
00375 struct yy_trans_info
00376         {
00377         flex_int32_t yy_verify;
00378         flex_int32_t yy_nxt;
00379         };
00380 static yyconst flex_int16_t yy_accept[17] =
00381     {   0,
00382         1,    1,    4,    3,    1,    3,    3,    2,    1,    0,
00383         2,    2,    0,    0,    2,    0
00384     } ;
00385 
00386 static yyconst flex_int32_t yy_ec[256] =
00387     {   0,
00388         1,    1,    1,    1,    1,    1,    1,    1,    2,    2,
00389         1,    1,    2,    1,    1,    1,    1,    1,    1,    1,
00390         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00391         1,    2,    1,    1,    1,    1,    1,    1,    1,    1,
00392         1,    1,    3,    1,    4,    5,    1,    6,    6,    6,
00393         6,    6,    6,    6,    6,    6,    6,    1,    1,    1,
00394         1,    1,    1,    1,    1,    1,    1,    1,    7,    1,
00395         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00396         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00397         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00398 
00399         7,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00400         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00401         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00402         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00403         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00404         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00405         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00406         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00407         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00408         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00409 
00410         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00411         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00412         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00413         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00414         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00415         1,    1,    1,    1,    1
00416     } ;
00417 
00418 static yyconst flex_int32_t yy_meta[8] =
00419     {   0,
00420         1,    1,    2,    2,    1,    2,    1
00421     } ;
00422 
00423 static yyconst flex_int16_t yy_base[18] =
00424     {   0,
00425         0,    0,   21,   22,   18,    3,   13,   11,   15,   10,
00426         0,    4,    9,    8,    7,   22,   10
00427     } ;
00428 
00429 static yyconst flex_int16_t yy_def[18] =
00430     {   0,
00431        16,    1,   16,   16,   16,   16,   16,    6,   16,   16,
00432         8,   16,   17,   16,   16,    0,   16
00433     } ;
00434 
00435 static yyconst flex_int16_t yy_nxt[30] =
00436     {   0,
00437         4,    5,    4,    6,    7,    8,    4,   10,   11,   12,
00438        13,   14,   15,   15,   15,   12,    9,   13,   12,    9,
00439        16,    3,   16,   16,   16,   16,   16,   16,   16
00440     } ;
00441 
00442 static yyconst flex_int16_t yy_chk[30] =
00443     {   0,
00444         1,    1,    1,    1,    1,    1,    1,    6,    6,   12,
00445        12,   17,   15,   14,   13,   10,    9,    8,    7,    5,
00446         3,   16,   16,   16,   16,   16,   16,   16,   16
00447     } ;
00448 
00449 /* Table of booleans, true if rule could match eol. */
00450 static yyconst flex_int32_t yy_rule_can_match_eol[4] =
00451     {   0,
00452 1, 0, 0,     };
00453 
00454 /* The intent behind this definition is that it'll catch
00455  * any uses of REJECT which flex missed.
00456  */
00457 #define REJECT reject_used_but_not_detected
00458 #define yymore() yymore_used_but_not_detected
00459 #define YY_MORE_ADJ 0
00460 #define YY_RESTORE_YY_MORE_OFFSET
00461 #line 1 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.l"
00462 
00476 #line 16 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.l"
00477 
00478 #include <iostream>
00479 #include "OSConfig.h"
00480 #ifdef HAVE_CSTDIO
00481 # include <cstdio>
00482 #else
00483 # ifdef HAVE_STDIO_H
00484 #  include <stdio.h>
00485 # else
00486 #  error "don't have header file for stdio"
00487 # endif
00488 #endif
00489 
00490 #ifdef PARSERDEBUG
00491         #define YY_PRINT  printf("%s", osoltext);
00492 #else     
00493         #define YY_PRINT  ;
00494 #endif
00495 
00496 
00497 #ifdef WIN_
00498   #define YY_NO_UNISTD_H
00499   #include <io.h>
00500   #include <process.h>
00501   #ifdef USE_OLD_UNISTD
00502      #include<sys/unistd.h>  
00503   #endif
00504 #endif
00505      
00506 #line 507 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.cpp"
00507 
00508 #define INITIAL 0
00509 
00510 #ifndef YY_NO_UNISTD_H
00511 /* Special case for "unistd.h", since it is non-ANSI. We include it way
00512  * down here because we want the user's section 1 to have been scanned first.
00513  * The user has a chance to override it with an option.
00514  */
00515 #include <unistd.h>
00516 #endif
00517 
00518 #ifndef YY_EXTRA_TYPE
00519 #define YY_EXTRA_TYPE void *
00520 #endif
00521 
00522 /* Holds the entire state of the reentrant scanner. */
00523 struct yyguts_t
00524     {
00525 
00526     /* User-defined. Not touched by flex. */
00527     YY_EXTRA_TYPE yyextra_r;
00528 
00529     /* The rest are the same as the globals declared in the non-reentrant scanner. */
00530     FILE *yyin_r, *yyout_r;
00531     size_t yy_buffer_stack_top; 
00532     size_t yy_buffer_stack_max; 
00533     YY_BUFFER_STATE * yy_buffer_stack; 
00534     char yy_hold_char;
00535     int yy_n_chars;
00536     int yyleng_r;
00537     char *yy_c_buf_p;
00538     int yy_init;
00539     int yy_start;
00540     int yy_did_buffer_switch_on_eof;
00541     int yy_start_stack_ptr;
00542     int yy_start_stack_depth;
00543     int *yy_start_stack;
00544     yy_state_type yy_last_accepting_state;
00545     char* yy_last_accepting_cpos;
00546 
00547     int yylineno_r;
00548     int yy_flex_debug_r;
00549 
00550     char *yytext_r;
00551     int yy_more_flag;
00552     int yy_more_len;
00553 
00554     }; /* end struct yyguts_t */
00555 
00556 static int yy_init_globals (yyscan_t yyscanner );
00557 
00558 /* Accessor methods to globals.
00559    These are made visible to non-reentrant scanners for convenience. */
00560 
00561 int osollex_destroy (yyscan_t yyscanner );
00562 
00563 int osolget_debug (yyscan_t yyscanner );
00564 
00565 void osolset_debug (int debug_flag ,yyscan_t yyscanner );
00566 
00567 YY_EXTRA_TYPE osolget_extra (yyscan_t yyscanner );
00568 
00569 void osolset_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
00570 
00571 FILE *osolget_in (yyscan_t yyscanner );
00572 
00573 void osolset_in  (FILE * in_str ,yyscan_t yyscanner );
00574 
00575 FILE *osolget_out (yyscan_t yyscanner );
00576 
00577 void osolset_out  (FILE * out_str ,yyscan_t yyscanner );
00578 
00579 int osolget_leng (yyscan_t yyscanner );
00580 
00581 char *osolget_text (yyscan_t yyscanner );
00582 
00583 int osolget_lineno (yyscan_t yyscanner );
00584 
00585 void osolset_lineno (int line_number ,yyscan_t yyscanner );
00586 
00587 /* Macros after this point can all be overridden by user definitions in
00588  * section 1.
00589  */
00590 
00591 #ifndef YY_SKIP_YYWRAP
00592 #ifdef __cplusplus
00593 extern "C" int osolwrap (yyscan_t yyscanner );
00594 #else
00595 extern int osolwrap (yyscan_t yyscanner );
00596 #endif
00597 #endif
00598 
00599     static void yyunput (int c,char *buf_ptr  ,yyscan_t yyscanner);
00600     
00601 #ifndef yytext_ptr
00602 static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner);
00603 #endif
00604 
00605 #ifdef YY_NEED_STRLEN
00606 static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner);
00607 #endif
00608 
00609 #ifndef YY_NO_INPUT
00610 
00611 #ifdef __cplusplus
00612 static int yyinput (yyscan_t yyscanner );
00613 #else
00614 static int input (yyscan_t yyscanner );
00615 #endif
00616 
00617 #endif
00618 
00619 /* Amount of stuff to slurp up with each read. */
00620 #ifndef YY_READ_BUF_SIZE
00621 #define YY_READ_BUF_SIZE 8192
00622 #endif
00623 
00624 /* Copy whatever the last rule matched to the standard output. */
00625 #ifndef ECHO
00626 /* This used to be an fputs(), but since the string might contain NUL's,
00627  * we now use fwrite().
00628  */
00629 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
00630 #endif
00631 
00632 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
00633  * is returned in "result".
00634  */
00635 #ifndef YY_INPUT
00636 #define YY_INPUT(buf,result,max_size) \
00637         if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
00638                 { \
00639                 int c = '*'; \
00640                 size_t n; \
00641                 for ( n = 0; n < max_size && \
00642                              (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
00643                         buf[n] = (char) c; \
00644                 if ( c == '\n' ) \
00645                         buf[n++] = (char) c; \
00646                 if ( c == EOF && ferror( yyin ) ) \
00647                         YY_FATAL_ERROR( "input in flex scanner failed" ); \
00648                 result = n; \
00649                 } \
00650         else \
00651                 { \
00652                 errno=0; \
00653                 while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
00654                         { \
00655                         if( errno != EINTR) \
00656                                 { \
00657                                 YY_FATAL_ERROR( "input in flex scanner failed" ); \
00658                                 break; \
00659                                 } \
00660                         errno=0; \
00661                         clearerr(yyin); \
00662                         } \
00663                 }\
00664 \
00665 
00666 #endif
00667 
00668 /* No semi-colon after return; correct usage is to write "yyterminate();" -
00669  * we don't want an extra ';' after the "return" because that will cause
00670  * some compilers to complain about unreachable statements.
00671  */
00672 #ifndef yyterminate
00673 #define yyterminate() return YY_NULL
00674 #endif
00675 
00676 /* Number of entries by which start-condition stack grows. */
00677 #ifndef YY_START_STACK_INCR
00678 #define YY_START_STACK_INCR 25
00679 #endif
00680 
00681 /* Report a fatal error. */
00682 #ifndef YY_FATAL_ERROR
00683 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
00684 #endif
00685 
00686 /* end tables serialization structures and prototypes */
00687 
00688 /* Default declaration of generated scanner - a define so the user can
00689  * easily add parameters.
00690  */
00691 #ifndef YY_DECL
00692 #define YY_DECL_IS_OURS 1
00693 
00694 extern int osollex (yyscan_t yyscanner);
00695 
00696 #define YY_DECL int osollex (yyscan_t yyscanner)
00697 #endif /* !YY_DECL */
00698 
00699 /* Code executed at the beginning of each rule, after yytext and yyleng
00700  * have been set up.
00701  */
00702 #ifndef YY_USER_ACTION
00703 #define YY_USER_ACTION
00704 #endif
00705 
00706 /* Code executed at the end of each rule. */
00707 #ifndef YY_BREAK
00708 #define YY_BREAK break;
00709 #endif
00710 
00711 #define YY_RULE_SETUP \
00712         YY_USER_ACTION
00713 
00716 YY_DECL
00717 {
00718         register yy_state_type yy_current_state;
00719         register char *yy_cp, *yy_bp;
00720         register int yy_act;
00721     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
00722 
00723 #line 59 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.l"
00724 
00725 
00726 #line 727 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.cpp"
00727 
00728         if ( !yyg->yy_init )
00729                 {
00730                 yyg->yy_init = 1;
00731 
00732 #ifdef YY_USER_INIT
00733                 YY_USER_INIT;
00734 #endif
00735 
00736                 if ( ! yyg->yy_start )
00737                         yyg->yy_start = 1;      /* first start state */
00738 
00739                 if ( ! yyin )
00740                         yyin = stdin;
00741 
00742                 if ( ! yyout )
00743                         yyout = stdout;
00744 
00745                 if ( ! YY_CURRENT_BUFFER ) {
00746                         osolensure_buffer_stack (yyscanner);
00747                         YY_CURRENT_BUFFER_LVALUE =
00748                                 osol_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
00749                 }
00750 
00751                 osol_load_buffer_state(yyscanner );
00752                 }
00753 
00754         while ( 1 )             /* loops until end-of-file is reached */
00755                 {
00756                 yy_cp = yyg->yy_c_buf_p;
00757 
00758                 /* Support of yytext. */
00759                 *yy_cp = yyg->yy_hold_char;
00760 
00761                 /* yy_bp points to the position in yy_ch_buf of the start of
00762                  * the current run.
00763                  */
00764                 yy_bp = yy_cp;
00765 
00766                 yy_current_state = yyg->yy_start;
00767 yy_match:
00768                 do
00769                         {
00770                         register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
00771                         if ( yy_accept[yy_current_state] )
00772                                 {
00773                                 yyg->yy_last_accepting_state = yy_current_state;
00774                                 yyg->yy_last_accepting_cpos = yy_cp;
00775                                 }
00776                         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
00777                                 {
00778                                 yy_current_state = (int) yy_def[yy_current_state];
00779                                 if ( yy_current_state >= 17 )
00780                                         yy_c = yy_meta[(unsigned int) yy_c];
00781                                 }
00782                         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
00783                         ++yy_cp;
00784                         }
00785                 while ( yy_base[yy_current_state] != 22 );
00786 
00787 yy_find_action:
00788                 yy_act = yy_accept[yy_current_state];
00789                 if ( yy_act == 0 )
00790                         { /* have to back up */
00791                         yy_cp = yyg->yy_last_accepting_cpos;
00792                         yy_current_state = yyg->yy_last_accepting_state;
00793                         yy_act = yy_accept[yy_current_state];
00794                         }
00795 
00796                 YY_DO_BEFORE_ACTION;
00797 
00798                 if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
00799                         {
00800                         int yyl;
00801                         for ( yyl = 0; yyl < yyleng; ++yyl )
00802                                 if ( yytext[yyl] == '\n' )
00803                                            
00804     do{ yylineno++;
00805         yycolumn=0;
00806     }while(0)
00807 ;
00808                         }
00809 
00810 do_action:      /* This label is used only to access EOF actions. */
00811 
00812                 switch ( yy_act )
00813         { /* beginning of action switch */
00814                         case 0: /* must back up */
00815                         /* undo the effects of YY_DO_BEFORE_ACTION */
00816                         *yy_cp = yyg->yy_hold_char;
00817                         yy_cp = yyg->yy_last_accepting_cpos;
00818                         yy_current_state = yyg->yy_last_accepting_state;
00819                         goto yy_find_action;
00820 
00821 case 1:
00822 /* rule 1 can match eol */
00823 YY_RULE_SETUP
00824 #line 61 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.l"
00825 
00826         YY_BREAK
00827 case 2:
00828 YY_RULE_SETUP
00829 #line 63 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.l"
00830 
00831         YY_BREAK
00832 case 3:
00833 YY_RULE_SETUP
00834 #line 65 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.l"
00835 ECHO;
00836         YY_BREAK
00837 #line 838 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.cpp"
00838 case YY_STATE_EOF(INITIAL):
00839         yyterminate();
00840 
00841         case YY_END_OF_BUFFER:
00842                 {
00843                 /* Amount of text matched not including the EOB char. */
00844                 int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
00845 
00846                 /* Undo the effects of YY_DO_BEFORE_ACTION. */
00847                 *yy_cp = yyg->yy_hold_char;
00848                 YY_RESTORE_YY_MORE_OFFSET
00849 
00850                 if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
00851                         {
00852                         /* We're scanning a new file or input source.  It's
00853                          * possible that this happened because the user
00854                          * just pointed yyin at a new source and called
00855                          * osollex().  If so, then we have to assure
00856                          * consistency between YY_CURRENT_BUFFER and our
00857                          * globals.  Here is the right place to do so, because
00858                          * this is the first action (other than possibly a
00859                          * back-up) that will match for the new input source.
00860                          */
00861                         yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
00862                         YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
00863                         YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
00864                         }
00865 
00866                 /* Note that here we test for yy_c_buf_p "<=" to the position
00867                  * of the first EOB in the buffer, since yy_c_buf_p will
00868                  * already have been incremented past the NUL character
00869                  * (since all states make transitions on EOB to the
00870                  * end-of-buffer state).  Contrast this with the test
00871                  * in input().
00872                  */
00873                 if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
00874                         { /* This was really a NUL. */
00875                         yy_state_type yy_next_state;
00876 
00877                         yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
00878 
00879                         yy_current_state = yy_get_previous_state( yyscanner );
00880 
00881                         /* Okay, we're now positioned to make the NUL
00882                          * transition.  We couldn't have
00883                          * yy_get_previous_state() go ahead and do it
00884                          * for us because it doesn't know how to deal
00885                          * with the possibility of jamming (and we don't
00886                          * want to build jamming into it because then it
00887                          * will run more slowly).
00888                          */
00889 
00890                         yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
00891 
00892                         yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
00893 
00894                         if ( yy_next_state )
00895                                 {
00896                                 /* Consume the NUL. */
00897                                 yy_cp = ++yyg->yy_c_buf_p;
00898                                 yy_current_state = yy_next_state;
00899                                 goto yy_match;
00900                                 }
00901 
00902                         else
00903                                 {
00904                                 yy_cp = yyg->yy_c_buf_p;
00905                                 goto yy_find_action;
00906                                 }
00907                         }
00908 
00909                 else switch ( yy_get_next_buffer( yyscanner ) )
00910                         {
00911                         case EOB_ACT_END_OF_FILE:
00912                                 {
00913                                 yyg->yy_did_buffer_switch_on_eof = 0;
00914 
00915                                 if ( osolwrap(yyscanner ) )
00916                                         {
00917                                         /* Note: because we've taken care in
00918                                          * yy_get_next_buffer() to have set up
00919                                          * yytext, we can now set up
00920                                          * yy_c_buf_p so that if some total
00921                                          * hoser (like flex itself) wants to
00922                                          * call the scanner after we return the
00923                                          * YY_NULL, it'll still work - another
00924                                          * YY_NULL will get returned.
00925                                          */
00926                                         yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
00927 
00928                                         yy_act = YY_STATE_EOF(YY_START);
00929                                         goto do_action;
00930                                         }
00931 
00932                                 else
00933                                         {
00934                                         if ( ! yyg->yy_did_buffer_switch_on_eof )
00935                                                 YY_NEW_FILE;
00936                                         }
00937                                 break;
00938                                 }
00939 
00940                         case EOB_ACT_CONTINUE_SCAN:
00941                                 yyg->yy_c_buf_p =
00942                                         yyg->yytext_ptr + yy_amount_of_matched_text;
00943 
00944                                 yy_current_state = yy_get_previous_state( yyscanner );
00945 
00946                                 yy_cp = yyg->yy_c_buf_p;
00947                                 yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
00948                                 goto yy_match;
00949 
00950                         case EOB_ACT_LAST_MATCH:
00951                                 yyg->yy_c_buf_p =
00952                                 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
00953 
00954                                 yy_current_state = yy_get_previous_state( yyscanner );
00955 
00956                                 yy_cp = yyg->yy_c_buf_p;
00957                                 yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
00958                                 goto yy_find_action;
00959                         }
00960                 break;
00961                 }
00962 
00963         default:
00964                 YY_FATAL_ERROR(
00965                         "fatal flex scanner internal error--no action found" );
00966         } /* end of action switch */
00967                 } /* end of scanning one token */
00968 } /* end of osollex */
00969 
00970 /* yy_get_next_buffer - try to read in a new buffer
00971  *
00972  * Returns a code representing an action:
00973  *      EOB_ACT_LAST_MATCH -
00974  *      EOB_ACT_CONTINUE_SCAN - continue scanning from current position
00975  *      EOB_ACT_END_OF_FILE - end of file
00976  */
00977 static int yy_get_next_buffer (yyscan_t yyscanner)
00978 {
00979     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
00980         register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
00981         register char *source = yyg->yytext_ptr;
00982         register int number_to_move, i;
00983         int ret_val;
00984 
00985         if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
00986                 YY_FATAL_ERROR(
00987                 "fatal flex scanner internal error--end of buffer missed" );
00988 
00989         if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
00990                 { /* Don't try to fill the buffer, so this is an EOF. */
00991                 if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
00992                         {
00993                         /* We matched a single character, the EOB, so
00994                          * treat this as a final EOF.
00995                          */
00996                         return EOB_ACT_END_OF_FILE;
00997                         }
00998 
00999                 else
01000                         {
01001                         /* We matched some text prior to the EOB, first
01002                          * process it.
01003                          */
01004                         return EOB_ACT_LAST_MATCH;
01005                         }
01006                 }
01007 
01008         /* Try to read more data. */
01009 
01010         /* First move last chars to start of buffer. */
01011         number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr) - 1;
01012 
01013         for ( i = 0; i < number_to_move; ++i )
01014                 *(dest++) = *(source++);
01015 
01016         if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
01017                 /* don't do the read, it's not guaranteed to return an EOF,
01018                  * just force an EOF
01019                  */
01020                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
01021 
01022         else
01023                 {
01024                         int num_to_read =
01025                         YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
01026 
01027                 while ( num_to_read <= 0 )
01028                         { /* Not enough room in the buffer - grow it. */
01029 
01030                         /* just a shorter name for the current buffer */
01031                         YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
01032 
01033                         int yy_c_buf_p_offset =
01034                                 (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
01035 
01036                         if ( b->yy_is_our_buffer )
01037                                 {
01038                                 int new_size = b->yy_buf_size * 2;
01039 
01040                                 if ( new_size <= 0 )
01041                                         b->yy_buf_size += b->yy_buf_size / 8;
01042                                 else
01043                                         b->yy_buf_size *= 2;
01044 
01045                                 b->yy_ch_buf = (char *)
01046                                         /* Include room in for 2 EOB chars. */
01047                                         osolrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner );
01048                                 }
01049                         else
01050                                 /* Can't grow it, we don't own it. */
01051                                 b->yy_ch_buf = 0;
01052 
01053                         if ( ! b->yy_ch_buf )
01054                                 YY_FATAL_ERROR(
01055                                 "fatal error - scanner input buffer overflow" );
01056 
01057                         yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
01058 
01059                         num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
01060                                                 number_to_move - 1;
01061 
01062                         }
01063 
01064                 if ( num_to_read > YY_READ_BUF_SIZE )
01065                         num_to_read = YY_READ_BUF_SIZE;
01066 
01067                 /* Read in more data. */
01068                 YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
01069                         yyg->yy_n_chars, num_to_read );
01070 
01071                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
01072                 }
01073 
01074         if ( yyg->yy_n_chars == 0 )
01075                 {
01076                 if ( number_to_move == YY_MORE_ADJ )
01077                         {
01078                         ret_val = EOB_ACT_END_OF_FILE;
01079                         osolrestart(yyin  ,yyscanner);
01080                         }
01081 
01082                 else
01083                         {
01084                         ret_val = EOB_ACT_LAST_MATCH;
01085                         YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
01086                                 YY_BUFFER_EOF_PENDING;
01087                         }
01088                 }
01089 
01090         else
01091                 ret_val = EOB_ACT_CONTINUE_SCAN;
01092 
01093         yyg->yy_n_chars += number_to_move;
01094         YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
01095         YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
01096 
01097         yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
01098 
01099         return ret_val;
01100 }
01101 
01102 /* yy_get_previous_state - get the state just before the EOB char was reached */
01103 
01104     static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
01105 {
01106         register yy_state_type yy_current_state;
01107         register char *yy_cp;
01108     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01109 
01110         yy_current_state = yyg->yy_start;
01111 
01112         for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
01113                 {
01114                 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
01115                 if ( yy_accept[yy_current_state] )
01116                         {
01117                         yyg->yy_last_accepting_state = yy_current_state;
01118                         yyg->yy_last_accepting_cpos = yy_cp;
01119                         }
01120                 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
01121                         {
01122                         yy_current_state = (int) yy_def[yy_current_state];
01123                         if ( yy_current_state >= 17 )
01124                                 yy_c = yy_meta[(unsigned int) yy_c];
01125                         }
01126                 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01127                 }
01128 
01129         return yy_current_state;
01130 }
01131 
01132 /* yy_try_NUL_trans - try to make a transition on the NUL character
01133  *
01134  * synopsis
01135  *      next_state = yy_try_NUL_trans( current_state );
01136  */
01137     static yy_state_type yy_try_NUL_trans  (yy_state_type yy_current_state , yyscan_t yyscanner)
01138 {
01139         register int yy_is_jam;
01140     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
01141         register char *yy_cp = yyg->yy_c_buf_p;
01142 
01143         register YY_CHAR yy_c = 1;
01144         if ( yy_accept[yy_current_state] )
01145                 {
01146                 yyg->yy_last_accepting_state = yy_current_state;
01147                 yyg->yy_last_accepting_cpos = yy_cp;
01148                 }
01149         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
01150                 {
01151                 yy_current_state = (int) yy_def[yy_current_state];
01152                 if ( yy_current_state >= 17 )
01153                         yy_c = yy_meta[(unsigned int) yy_c];
01154                 }
01155         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01156         yy_is_jam = (yy_current_state == 16);
01157 
01158         return yy_is_jam ? 0 : yy_current_state;
01159 }
01160 
01161     static void yyunput (int c, register char * yy_bp , yyscan_t yyscanner)
01162 {
01163         register char *yy_cp;
01164     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01165 
01166     yy_cp = yyg->yy_c_buf_p;
01167 
01168         /* undo effects of setting up yytext */
01169         *yy_cp = yyg->yy_hold_char;
01170 
01171         if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
01172                 { /* need to shift things up to make room */
01173                 /* +2 for EOB chars. */
01174                 register int number_to_move = yyg->yy_n_chars + 2;
01175                 register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
01176                                         YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
01177                 register char *source =
01178                                 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
01179 
01180                 while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
01181                         *--dest = *--source;
01182 
01183                 yy_cp += (int) (dest - source);
01184                 yy_bp += (int) (dest - source);
01185                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
01186                         yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
01187 
01188                 if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
01189                         YY_FATAL_ERROR( "flex scanner push-back overflow" );
01190                 }
01191 
01192         *--yy_cp = (char) c;
01193 
01194     if ( c == '\n' ){
01195         --yylineno;
01196     }
01197 
01198         yyg->yytext_ptr = yy_bp;
01199         yyg->yy_hold_char = *yy_cp;
01200         yyg->yy_c_buf_p = yy_cp;
01201 }
01202 
01203 #ifndef YY_NO_INPUT
01204 #ifdef __cplusplus
01205     static int yyinput (yyscan_t yyscanner)
01206 #else
01207     static int input  (yyscan_t yyscanner)
01208 #endif
01209 
01210 {
01211         int c;
01212     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01213 
01214         *yyg->yy_c_buf_p = yyg->yy_hold_char;
01215 
01216         if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
01217                 {
01218                 /* yy_c_buf_p now points to the character we want to return.
01219                  * If this occurs *before* the EOB characters, then it's a
01220                  * valid NUL; if not, then we've hit the end of the buffer.
01221                  */
01222                 if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
01223                         /* This was really a NUL. */
01224                         *yyg->yy_c_buf_p = '\0';
01225 
01226                 else
01227                         { /* need more input */
01228                         int offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
01229                         ++yyg->yy_c_buf_p;
01230 
01231                         switch ( yy_get_next_buffer( yyscanner ) )
01232                                 {
01233                                 case EOB_ACT_LAST_MATCH:
01234                                         /* This happens because yy_g_n_b()
01235                                          * sees that we've accumulated a
01236                                          * token and flags that we need to
01237                                          * try matching the token before
01238                                          * proceeding.  But for input(),
01239                                          * there's no matching to consider.
01240                                          * So convert the EOB_ACT_LAST_MATCH
01241                                          * to EOB_ACT_END_OF_FILE.
01242                                          */
01243 
01244                                         /* Reset buffer status. */
01245                                         osolrestart(yyin ,yyscanner);
01246 
01247                                         /*FALLTHROUGH*/
01248 
01249                                 case EOB_ACT_END_OF_FILE:
01250                                         {
01251                                         if ( osolwrap(yyscanner ) )
01252                                                 return EOF;
01253 
01254                                         if ( ! yyg->yy_did_buffer_switch_on_eof )
01255                                                 YY_NEW_FILE;
01256 #ifdef __cplusplus
01257                                         return yyinput(yyscanner);
01258 #else
01259                                         return input(yyscanner);
01260 #endif
01261                                         }
01262 
01263                                 case EOB_ACT_CONTINUE_SCAN:
01264                                         yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
01265                                         break;
01266                                 }
01267                         }
01268                 }
01269 
01270         c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
01271         *yyg->yy_c_buf_p = '\0';        /* preserve yytext */
01272         yyg->yy_hold_char = *++yyg->yy_c_buf_p;
01273 
01274         if ( c == '\n' )
01275                    
01276     do{ yylineno++;
01277         yycolumn=0;
01278     }while(0)
01279 ;
01280 
01281         return c;
01282 }
01283 #endif  /* ifndef YY_NO_INPUT */
01284 
01290     void osolrestart  (FILE * input_file , yyscan_t yyscanner)
01291 {
01292     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01293 
01294         if ( ! YY_CURRENT_BUFFER ){
01295         osolensure_buffer_stack (yyscanner);
01296                 YY_CURRENT_BUFFER_LVALUE =
01297             osol_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
01298         }
01299 
01300         osol_init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner);
01301         osol_load_buffer_state(yyscanner );
01302 }
01303 
01308     void osol_switch_to_buffer  (YY_BUFFER_STATE  new_buffer , yyscan_t yyscanner)
01309 {
01310     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01311 
01312         /* TODO. We should be able to replace this entire function body
01313          * with
01314          *              osolpop_buffer_state();
01315          *              osolpush_buffer_state(new_buffer);
01316      */
01317         osolensure_buffer_stack (yyscanner);
01318         if ( YY_CURRENT_BUFFER == new_buffer )
01319                 return;
01320 
01321         if ( YY_CURRENT_BUFFER )
01322                 {
01323                 /* Flush out information for old buffer. */
01324                 *yyg->yy_c_buf_p = yyg->yy_hold_char;
01325                 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
01326                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
01327                 }
01328 
01329         YY_CURRENT_BUFFER_LVALUE = new_buffer;
01330         osol_load_buffer_state(yyscanner );
01331 
01332         /* We don't actually know whether we did this switch during
01333          * EOF (osolwrap()) processing, but the only time this flag
01334          * is looked at is after osolwrap() is called, so it's safe
01335          * to go ahead and always set it.
01336          */
01337         yyg->yy_did_buffer_switch_on_eof = 1;
01338 }
01339 
01340 static void osol_load_buffer_state  (yyscan_t yyscanner)
01341 {
01342     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01343         yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
01344         yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
01345         yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
01346         yyg->yy_hold_char = *yyg->yy_c_buf_p;
01347 }
01348 
01355     YY_BUFFER_STATE osol_create_buffer  (FILE * file, int  size , yyscan_t yyscanner)
01356 {
01357         YY_BUFFER_STATE b;
01358     
01359         b = (YY_BUFFER_STATE) osolalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
01360         if ( ! b )
01361                 YY_FATAL_ERROR( "out of dynamic memory in osol_create_buffer()" );
01362 
01363         b->yy_buf_size = size;
01364 
01365         /* yy_ch_buf has to be 2 characters longer than the size given because
01366          * we need to put in 2 end-of-buffer characters.
01367          */
01368         b->yy_ch_buf = (char *) osolalloc(b->yy_buf_size + 2 ,yyscanner );
01369         if ( ! b->yy_ch_buf )
01370                 YY_FATAL_ERROR( "out of dynamic memory in osol_create_buffer()" );
01371 
01372         b->yy_is_our_buffer = 1;
01373 
01374         osol_init_buffer(b,file ,yyscanner);
01375 
01376         return b;
01377 }
01378 
01383     void osol_delete_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
01384 {
01385     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01386 
01387         if ( ! b )
01388                 return;
01389 
01390         if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
01391                 YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
01392 
01393         if ( b->yy_is_our_buffer )
01394                 osolfree((void *) b->yy_ch_buf ,yyscanner );
01395 
01396         osolfree((void *) b ,yyscanner );
01397 }
01398 
01399 #ifndef __cplusplus
01400 extern int isatty (int );
01401 #endif /* __cplusplus */
01402     
01403 /* Initializes or reinitializes a buffer.
01404  * This function is sometimes called more than once on the same buffer,
01405  * such as during a osolrestart() or at EOF.
01406  */
01407     static void osol_init_buffer  (YY_BUFFER_STATE  b, FILE * file , yyscan_t yyscanner)
01408 
01409 {
01410         int oerrno = errno;
01411     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01412 
01413         osol_flush_buffer(b ,yyscanner);
01414 
01415         b->yy_input_file = file;
01416         b->yy_fill_buffer = 1;
01417 
01418     /* If b is the current buffer, then osol_init_buffer was _probably_
01419      * called from osolrestart() or through yy_get_next_buffer.
01420      * In that case, we don't want to reset the lineno or column.
01421      */
01422     if (b != YY_CURRENT_BUFFER){
01423         b->yy_bs_lineno = 1;
01424         b->yy_bs_column = 0;
01425     }
01426 
01427         b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
01428     
01429         errno = oerrno;
01430 }
01431 
01436     void osol_flush_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
01437 {
01438     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01439         if ( ! b )
01440                 return;
01441 
01442         b->yy_n_chars = 0;
01443 
01444         /* We always need two end-of-buffer characters.  The first causes
01445          * a transition to the end-of-buffer state.  The second causes
01446          * a jam in that state.
01447          */
01448         b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
01449         b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
01450 
01451         b->yy_buf_pos = &b->yy_ch_buf[0];
01452 
01453         b->yy_at_bol = 1;
01454         b->yy_buffer_status = YY_BUFFER_NEW;
01455 
01456         if ( b == YY_CURRENT_BUFFER )
01457                 osol_load_buffer_state(yyscanner );
01458 }
01459 
01466 void osolpush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
01467 {
01468     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01469         if (new_buffer == NULL)
01470                 return;
01471 
01472         osolensure_buffer_stack(yyscanner);
01473 
01474         /* This block is copied from osol_switch_to_buffer. */
01475         if ( YY_CURRENT_BUFFER )
01476                 {
01477                 /* Flush out information for old buffer. */
01478                 *yyg->yy_c_buf_p = yyg->yy_hold_char;
01479                 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
01480                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
01481                 }
01482 
01483         /* Only push if top exists. Otherwise, replace top. */
01484         if (YY_CURRENT_BUFFER)
01485                 yyg->yy_buffer_stack_top++;
01486         YY_CURRENT_BUFFER_LVALUE = new_buffer;
01487 
01488         /* copied from osol_switch_to_buffer. */
01489         osol_load_buffer_state(yyscanner );
01490         yyg->yy_did_buffer_switch_on_eof = 1;
01491 }
01492 
01497 void osolpop_buffer_state (yyscan_t yyscanner)
01498 {
01499     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01500         if (!YY_CURRENT_BUFFER)
01501                 return;
01502 
01503         osol_delete_buffer(YY_CURRENT_BUFFER ,yyscanner);
01504         YY_CURRENT_BUFFER_LVALUE = NULL;
01505         if (yyg->yy_buffer_stack_top > 0)
01506                 --yyg->yy_buffer_stack_top;
01507 
01508         if (YY_CURRENT_BUFFER) {
01509                 osol_load_buffer_state(yyscanner );
01510                 yyg->yy_did_buffer_switch_on_eof = 1;
01511         }
01512 }
01513 
01514 /* Allocates the stack if it does not exist.
01515  *  Guarantees space for at least one push.
01516  */
01517 static void osolensure_buffer_stack (yyscan_t yyscanner)
01518 {
01519         int num_to_alloc;
01520     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01521 
01522         if (!yyg->yy_buffer_stack) {
01523 
01524                 /* First allocation is just for 2 elements, since we don't know if this
01525                  * scanner will even need a stack. We use 2 instead of 1 to avoid an
01526                  * immediate realloc on the next call.
01527          */
01528                 num_to_alloc = 1;
01529                 yyg->yy_buffer_stack = (struct yy_buffer_state**)osolalloc
01530                                                                 (num_to_alloc * sizeof(struct yy_buffer_state*)
01531                                                                 , yyscanner);
01532                 
01533                 memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
01534                                 
01535                 yyg->yy_buffer_stack_max = num_to_alloc;
01536                 yyg->yy_buffer_stack_top = 0;
01537                 return;
01538         }
01539 
01540         if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
01541 
01542                 /* Increase the buffer to prepare for a possible push. */
01543                 int grow_size = 8 /* arbitrary grow size */;
01544 
01545                 num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
01546                 yyg->yy_buffer_stack = (struct yy_buffer_state**)osolrealloc
01547                                                                 (yyg->yy_buffer_stack,
01548                                                                 num_to_alloc * sizeof(struct yy_buffer_state*)
01549                                                                 , yyscanner);
01550 
01551                 /* zero only the new slots.*/
01552                 memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
01553                 yyg->yy_buffer_stack_max = num_to_alloc;
01554         }
01555 }
01556 
01563 YY_BUFFER_STATE osol_scan_buffer  (char * base, yy_size_t  size , yyscan_t yyscanner)
01564 {
01565         YY_BUFFER_STATE b;
01566     
01567         if ( size < 2 ||
01568              base[size-2] != YY_END_OF_BUFFER_CHAR ||
01569              base[size-1] != YY_END_OF_BUFFER_CHAR )
01570                 /* They forgot to leave room for the EOB's. */
01571                 return 0;
01572 
01573         b = (YY_BUFFER_STATE) osolalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
01574         if ( ! b )
01575                 YY_FATAL_ERROR( "out of dynamic memory in osol_scan_buffer()" );
01576 
01577         b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
01578         b->yy_buf_pos = b->yy_ch_buf = base;
01579         b->yy_is_our_buffer = 0;
01580         b->yy_input_file = 0;
01581         b->yy_n_chars = b->yy_buf_size;
01582         b->yy_is_interactive = 0;
01583         b->yy_at_bol = 1;
01584         b->yy_fill_buffer = 0;
01585         b->yy_buffer_status = YY_BUFFER_NEW;
01586 
01587         osol_switch_to_buffer(b ,yyscanner );
01588 
01589         return b;
01590 }
01591 
01600 YY_BUFFER_STATE osol_scan_string (yyconst char * yystr , yyscan_t yyscanner)
01601 {
01602     
01603         return osol_scan_bytes(yystr,strlen(yystr) ,yyscanner);
01604 }
01605 
01613 YY_BUFFER_STATE osol_scan_bytes  (yyconst char * yybytes, int  _yybytes_len , yyscan_t yyscanner)
01614 {
01615         YY_BUFFER_STATE b;
01616         char *buf;
01617         yy_size_t n;
01618         int i;
01619     
01620         /* Get memory for full buffer, including space for trailing EOB's. */
01621         n = _yybytes_len + 2;
01622         buf = (char *) osolalloc(n ,yyscanner );
01623         if ( ! buf )
01624                 YY_FATAL_ERROR( "out of dynamic memory in osol_scan_bytes()" );
01625 
01626         for ( i = 0; i < _yybytes_len; ++i )
01627                 buf[i] = yybytes[i];
01628 
01629         buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
01630 
01631         b = osol_scan_buffer(buf,n ,yyscanner);
01632         if ( ! b )
01633                 YY_FATAL_ERROR( "bad buffer in osol_scan_bytes()" );
01634 
01635         /* It's okay to grow etc. this buffer, and we should throw it
01636          * away when we're done.
01637          */
01638         b->yy_is_our_buffer = 1;
01639 
01640         return b;
01641 }
01642 
01643 #ifndef YY_EXIT_FAILURE
01644 #define YY_EXIT_FAILURE 2
01645 #endif
01646 
01647 static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
01648 {
01649         (void) fprintf( stderr, "%s\n", msg );
01650         exit( YY_EXIT_FAILURE );
01651 }
01652 
01653 /* Redefine yyless() so it works in section 3 code. */
01654 
01655 #undef yyless
01656 #define yyless(n) \
01657         do \
01658                 { \
01659                 /* Undo effects of setting up yytext. */ \
01660         int yyless_macro_arg = (n); \
01661         YY_LESS_LINENO(yyless_macro_arg);\
01662                 yytext[yyleng] = yyg->yy_hold_char; \
01663                 yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
01664                 yyg->yy_hold_char = *yyg->yy_c_buf_p; \
01665                 *yyg->yy_c_buf_p = '\0'; \
01666                 yyleng = yyless_macro_arg; \
01667                 } \
01668         while ( 0 )
01669 
01670 /* Accessor  methods (get/set functions) to struct members. */
01671 
01675 YY_EXTRA_TYPE osolget_extra  (yyscan_t yyscanner)
01676 {
01677     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01678     return yyextra;
01679 }
01680 
01684 int osolget_lineno  (yyscan_t yyscanner)
01685 {
01686     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01687     
01688         if (! YY_CURRENT_BUFFER)
01689             return 0;
01690     
01691     return yylineno;
01692 }
01693 
01697 int osolget_column  (yyscan_t yyscanner)
01698 {
01699     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01700     
01701         if (! YY_CURRENT_BUFFER)
01702             return 0;
01703     
01704     return yycolumn;
01705 }
01706 
01710 FILE *osolget_in  (yyscan_t yyscanner)
01711 {
01712     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01713     return yyin;
01714 }
01715 
01719 FILE *osolget_out  (yyscan_t yyscanner)
01720 {
01721     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01722     return yyout;
01723 }
01724 
01728 int osolget_leng  (yyscan_t yyscanner)
01729 {
01730     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01731     return yyleng;
01732 }
01733 
01738 char *osolget_text  (yyscan_t yyscanner)
01739 {
01740     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01741     return yytext;
01742 }
01743 
01748 void osolset_extra (YY_EXTRA_TYPE  user_defined , yyscan_t yyscanner)
01749 {
01750     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01751     yyextra = user_defined ;
01752 }
01753 
01758 void osolset_lineno (int  line_number , yyscan_t yyscanner)
01759 {
01760     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01761 
01762         /* lineno is only valid if an input buffer exists. */
01763         if (! YY_CURRENT_BUFFER )
01764            yy_fatal_error( "osolset_lineno called with no buffer" , yyscanner); 
01765     
01766     yylineno = line_number;
01767 }
01768 
01773 void osolset_column (int  column_no , yyscan_t yyscanner)
01774 {
01775     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01776 
01777         /* column is only valid if an input buffer exists. */
01778         if (! YY_CURRENT_BUFFER )
01779            yy_fatal_error( "osolset_column called with no buffer" , yyscanner); 
01780     
01781     yycolumn = column_no;
01782 }
01783 
01790 void osolset_in (FILE *  in_str , yyscan_t yyscanner)
01791 {
01792     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01793     yyin = in_str ;
01794 }
01795 
01796 void osolset_out (FILE *  out_str , yyscan_t yyscanner)
01797 {
01798     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01799     yyout = out_str ;
01800 }
01801 
01802 int osolget_debug  (yyscan_t yyscanner)
01803 {
01804     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01805     return yy_flex_debug;
01806 }
01807 
01808 void osolset_debug (int  bdebug , yyscan_t yyscanner)
01809 {
01810     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01811     yy_flex_debug = bdebug ;
01812 }
01813 
01814 /* Accessor methods for yylval and yylloc */
01815 
01816 /* User-visible API */
01817 
01818 /* osollex_init is special because it creates the scanner itself, so it is
01819  * the ONLY reentrant function that doesn't take the scanner as the last argument.
01820  * That's why we explicitly handle the declaration, instead of using our macros.
01821  */
01822 
01823 int osollex_init(yyscan_t* ptr_yy_globals)
01824 
01825 {
01826     if (ptr_yy_globals == NULL){
01827         errno = EINVAL;
01828         return 1;
01829     }
01830 
01831     *ptr_yy_globals = (yyscan_t) osolalloc ( sizeof( struct yyguts_t ), NULL );
01832 
01833     if (*ptr_yy_globals == NULL){
01834         errno = ENOMEM;
01835         return 1;
01836     }
01837 
01838     /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
01839     memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
01840 
01841     return yy_init_globals ( *ptr_yy_globals );
01842 }
01843 
01844 static int yy_init_globals (yyscan_t yyscanner)
01845 {
01846     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01847     /* Initialization is the same as for the non-reentrant scanner.
01848      * This function is called from osollex_destroy(), so don't allocate here.
01849      */
01850 
01851     yyg->yy_buffer_stack = 0;
01852     yyg->yy_buffer_stack_top = 0;
01853     yyg->yy_buffer_stack_max = 0;
01854     yyg->yy_c_buf_p = (char *) 0;
01855     yyg->yy_init = 0;
01856     yyg->yy_start = 0;
01857 
01858     yyg->yy_start_stack_ptr = 0;
01859     yyg->yy_start_stack_depth = 0;
01860     yyg->yy_start_stack =  NULL;
01861 
01862 /* Defined in main.c */
01863 #ifdef YY_STDINIT
01864     yyin = stdin;
01865     yyout = stdout;
01866 #else
01867     yyin = (FILE *) 0;
01868     yyout = (FILE *) 0;
01869 #endif
01870 
01871     /* For future reference: Set errno on error, since we are called by
01872      * osollex_init()
01873      */
01874     return 0;
01875 }
01876 
01877 /* osollex_destroy is for both reentrant and non-reentrant scanners. */
01878 int osollex_destroy  (yyscan_t yyscanner)
01879 {
01880     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01881 
01882     /* Pop the buffer stack, destroying each element. */
01883         while(YY_CURRENT_BUFFER){
01884                 osol_delete_buffer(YY_CURRENT_BUFFER ,yyscanner );
01885                 YY_CURRENT_BUFFER_LVALUE = NULL;
01886                 osolpop_buffer_state(yyscanner);
01887         }
01888 
01889         /* Destroy the stack itself. */
01890         osolfree(yyg->yy_buffer_stack ,yyscanner);
01891         yyg->yy_buffer_stack = NULL;
01892 
01893     /* Destroy the start condition stack. */
01894         osolfree(yyg->yy_start_stack ,yyscanner );
01895         yyg->yy_start_stack = NULL;
01896 
01897     /* Reset the globals. This is important in a non-reentrant scanner so the next time
01898      * osollex() is called, initialization will occur. */
01899     yy_init_globals( yyscanner);
01900 
01901     /* Destroy the main struct (reentrant only). */
01902     osolfree ( yyscanner , yyscanner );
01903     yyscanner = NULL;
01904     return 0;
01905 }
01906 
01907 /*
01908  * Internal utility routines.
01909  */
01910 
01911 #ifndef yytext_ptr
01912 static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner)
01913 {
01914         register int i;
01915         for ( i = 0; i < n; ++i )
01916                 s1[i] = s2[i];
01917 }
01918 #endif
01919 
01920 #ifdef YY_NEED_STRLEN
01921 static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
01922 {
01923         register int n;
01924         for ( n = 0; s[n]; ++n )
01925                 ;
01926 
01927         return n;
01928 }
01929 #endif
01930 
01931 void *osolalloc (yy_size_t  size , yyscan_t yyscanner)
01932 {
01933         return (void *) malloc( size );
01934 }
01935 
01936 void *osolrealloc  (void * ptr, yy_size_t  size , yyscan_t yyscanner)
01937 {
01938         /* The cast to (char *) in the following accommodates both
01939          * implementations that use char* generic pointers, and those
01940          * that use void* generic pointers.  It works with the latter
01941          * because both ANSI C and C++ allow castless assignment from
01942          * any pointer type to void*, and deal with argument conversions
01943          * as though doing an assignment.
01944          */
01945         return (void *) realloc( (char *) ptr, size );
01946 }
01947 
01948 void osolfree (void * ptr , yyscan_t yyscanner)
01949 {
01950         free( (char *) ptr );   /* see osolrealloc() for (char *) cast */
01951 }
01952 
01953 #define YYTABLES_NAME "yytables"
01954 
01955 #line 65 "/Users/kmartin/Documents/files/code/cpp/OScpp/COIN-OS/OS/src/OSParsers/OSParseosol.l"
01956 
01957 
01958 
01959 
01960 

Generated on Sat Mar 29 22:38:02 2008 by  doxygen 1.5.3