
#line 3 "<stdout>"

#define  TAO_YY_INT_ALIGNED short int

/* A lexical scanner generated by flex */

#define FLEX_SCANNER
#define TAO_YY_FLEX_MAJOR_VERSION 2
#define TAO_YY_FLEX_MINOR_VERSION 5
#define TAO_YY_FLEX_SUBMINOR_VERSION 35
#if TAO_YY_FLEX_SUBMINOR_VERSION > 0
#define FLEX_BETA
#endif

/* First, we deal with  platform-specific or compiler-specific issues. */

/* begin standard C headers. */
#include "ace/OS_NS_stdio.h"
#include "ace/OS_NS_string.h"

/* end standard C headers. */

/* flex integer type definitions */

#ifndef FLEXINT_H
#define FLEXINT_H

/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */

#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L || defined (__HP_aCC)

/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
 * if you want the limit (max/min) macros for int types.
 */
#ifndef __STDC_LIMIT_MACROS
#define __STDC_LIMIT_MACROS 1
#endif
#include <inttypes.h>

typedef int8_t flex_int8_t;
typedef uint8_t flex_uint8_t;
typedef int16_t flex_int16_t;
typedef uint16_t flex_uint16_t;
typedef int32_t flex_int32_t;
typedef uint32_t flex_uint32_t;
#else
typedef signed char flex_int8_t;
typedef short int flex_int16_t;
typedef int flex_int32_t;
typedef unsigned char flex_uint8_t;
typedef unsigned short int flex_uint16_t;
typedef unsigned int flex_uint32_t;

/* Limits of integral types. */
#ifndef INT8_MIN
#define INT8_MIN               (-128)
#endif
#ifndef INT16_MIN
#define INT16_MIN              (-32767-1)
#endif
#ifndef INT32_MIN
#define INT32_MIN              (-2147483647-1)
#endif
#ifndef INT8_MAX
#define INT8_MAX               (127)
#endif
#ifndef INT16_MAX
#define INT16_MAX              (32767)
#endif
#ifndef INT32_MAX
#define INT32_MAX              (2147483647)
#endif
#ifndef UINT8_MAX
#define UINT8_MAX              (255U)
#endif
#ifndef UINT16_MAX
#define UINT16_MAX             (65535U)
#endif
#ifndef UINT32_MAX
#define UINT32_MAX             (4294967295U)
#endif

#endif /* ! C99 */

#endif /* ! FLEXINT_H */

#ifdef __cplusplus

/* The "const" storage-class-modifier is valid. */
#define TAO_YY_USE_CONST

#else        /* ! __cplusplus */

/* C99 requires __STDC__ to be defined as 1. */
#if defined (__STDC__)

#define TAO_YY_USE_CONST

#endif        /* defined (__STDC__) */
#endif        /* ! __cplusplus */

#ifdef TAO_YY_USE_CONST
#define tao_yyconst const
#else
#define tao_yyconst
#endif

/* Returned upon end-of-file. */
#define TAO_YY_NULL 0

/* Promotes a possibly negative, possibly signed char to an unsigned
 * integer for use as an array index.  If the signed char is negative,
 * we want to instead treat it as an 8-bit unsigned char, hence the
 * double cast.
 */
#define TAO_YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)

/* Enter a start condition.  This macro really ought to take a parameter,
 * but we do it the disgusting crufty way forced on us by the ()-less
 * definition of BEGIN.
 */
#define BEGIN (tao_yy_start) = 1 + 2 *

/* Translate the current start state into a value that can be later handed
 * to BEGIN to return to the state.  The TAO_YYSTATE alias is for lex
 * compatibility.
 */
#define TAO_YY_START (((tao_yy_start) - 1) / 2)
#define TAO_YYSTATE TAO_YY_START

/* Action number for EOF rule of a given start state. */
#define TAO_YY_STATE_EOF(state) (TAO_YY_END_OF_BUFFER + state + 1)

/* Special action meaning "start processing a new file". */
#define TAO_YY_NEW_FILE tao_yyrestart(tao_yyin  )

#define TAO_YY_END_OF_BUFFER_CHAR 0

/* Size of default input buffer. */
#ifndef TAO_YY_BUF_SIZE
#ifdef __ia64__
/* On IA-64, the buffer size is 16k, not 8k.
 * Moreover, TAO_YY_BUF_SIZE is 2*TAO_YY_READ_BUF_SIZE in the general case.
 * Ditto for the __ia64__ case accordingly.
 */
#define TAO_YY_BUF_SIZE 32768
#else
#define TAO_YY_BUF_SIZE 16384
#endif /* __ia64__ */
#endif

/* The state buf must be large enough to hold one state per character in the main buffer.
 */
#define TAO_YY_STATE_BUF_SIZE   ((TAO_YY_BUF_SIZE + 2) * sizeof(tao_yy_state_type))

#ifndef TAO_YY_TYPEDEF_TAO_YY_BUFFER_STATE
#define TAO_YY_TYPEDEF_TAO_YY_BUFFER_STATE
typedef struct tao_yy_buffer_state *TAO_YY_BUFFER_STATE;
#endif

extern int tao_yyleng;

extern FILE *tao_yyin, *tao_yyout;

#define EOB_ACT_CONTINUE_SCAN 0
#define EOB_ACT_END_OF_FILE 1
#define EOB_ACT_LAST_MATCH 2

    #define TAO_YY_LESS_LINENO(n)

/* Return all but the first "n" matched characters back to the input stream. */
#define tao_yyless(n) \
        do \
                { \
                /* Undo effects of setting up tao_yytext. */ \
        int tao_yyless_macro_arg = (n); \
        TAO_YY_LESS_LINENO(tao_yyless_macro_arg);\
                *tao_yy_cp = (tao_yy_hold_char); \
                TAO_YY_RESTORE_TAO_YY_MORE_OFFSET \
                (tao_yy_c_buf_p) = tao_yy_cp = tao_yy_bp + tao_yyless_macro_arg - TAO_YY_MORE_ADJ; \
                TAO_YY_DO_BEFORE_ACTION; /* set up tao_yytext again */ \
                } \
        while ( 0 )

#define unput(c) tao_yyunput( c, (tao_yytext_ptr)  )

#ifndef TAO_YY_TYPEDEF_TAO_YY_SIZE_T
#define TAO_YY_TYPEDEF_TAO_YY_SIZE_T
typedef size_t tao_yy_size_t;
#endif

#ifndef TAO_YY_STRUCT_TAO_YY_BUFFER_STATE
#define TAO_YY_STRUCT_TAO_YY_BUFFER_STATE
struct tao_yy_buffer_state
        {
        FILE *tao_yy_input_file;

        char *tao_yy_ch_buf;                /* input buffer */
        char *tao_yy_buf_pos;                /* current position in input buffer */

        /* Size of input buffer in bytes, not including room for EOB
         * characters.
         */
        tao_yy_size_t tao_yy_buf_size;

        /* Number of characters read into tao_yy_ch_buf, not including EOB
         * characters.
         */
        int tao_yy_n_chars;

        /* Whether we "own" the buffer - i.e., we know we created it,
         * and can realloc() it to grow it, and should free() it to
         * delete it.
         */
        int tao_yy_is_our_buffer;

        /* Whether this is an "interactive" input source; if so, and
         * if we're using stdio for input, then we want to use getc()
         * instead of static_cast<int> (fread()), to make sure we stop fetching input after
         * each newline.
         */
        int tao_yy_is_interactive;

        /* Whether we're considered to be at the beginning of a line.
         * If so, '^' rules will be active on the next match, otherwise
         * not.
         */
        int tao_yy_at_bol;

    int tao_yy_bs_lineno; /**< The line count. */
    int tao_yy_bs_column; /**< The column count. */

        /* Whether to try to fill the input buffer when we reach the
         * end of it.
         */
        int tao_yy_fill_buffer;

        int tao_yy_buffer_status;

#define TAO_YY_BUFFER_NEW 0
#define TAO_YY_BUFFER_NORMAL 1
        /* When an EOF's been seen but there's still some text to process
         * then we mark the buffer as TAO_YY_EOF_PENDING, to indicate that we
         * shouldn't try reading from the input source any more.  We might
         * still have a bunch of tokens to match, though, because of
         * possible backing-up.
         *
         * When we actually see the EOF, we change the status to "new"
         * (via tao_yyrestart()), so that the user can continue scanning by
         * just pointing tao_yyin at a new input file.
         */
#define TAO_YY_BUFFER_EOF_PENDING 2

        };
#endif /* !TAO_YY_STRUCT_TAO_YY_BUFFER_STATE */

/* Stack of input buffers. */
static size_t tao_yy_buffer_stack_top = 0; /**< index of top of stack. */
static size_t tao_yy_buffer_stack_max = 0; /**< capacity of stack. */
static TAO_YY_BUFFER_STATE * tao_yy_buffer_stack = 0; /**< Stack as an array. */

/* We provide macros for accessing buffer states in case in the
 * future we want to put the buffer states in a more general
 * "scanner state".
 *
 * Returns the top of the stack, or 0.
 */
#define TAO_YY_CURRENT_BUFFER ( (tao_yy_buffer_stack) \
                          ? (tao_yy_buffer_stack)[(tao_yy_buffer_stack_top)] \
                          : 0)

/* Same as previous macro, but useful when we know that the buffer stack is not
 * 0 or when we need an lvalue. For internal use only.
 */
#define TAO_YY_CURRENT_BUFFER_LVALUE (tao_yy_buffer_stack)[(tao_yy_buffer_stack_top)]

/* tao_yy_hold_char holds the character lost when tao_yytext is formed. */
static char tao_yy_hold_char;
static int tao_yy_n_chars;                /* number of characters read into tao_yy_ch_buf */
int tao_yyleng;

/* Points to current character in buffer. */
static char *tao_yy_c_buf_p = (char *) 0;
static int tao_yy_init = 0;                /* whether we need to initialize */
static int tao_yy_start = 0;        /* start state number */

/* Flag which is used to allow tao_yywrap()'s to do buffer switches
 * instead of setting up a fresh tao_yyin.  A bit of a hack ...
 */
static int tao_yy_did_buffer_switch_on_eof;

void tao_yyrestart (FILE *input_file  );
void tao_yy_switch_to_buffer (TAO_YY_BUFFER_STATE new_buffer  );
TAO_YY_BUFFER_STATE tao_yy_create_buffer (FILE *file,int size  );
void tao_yy_delete_buffer (TAO_YY_BUFFER_STATE b  );
void tao_yy_flush_buffer (TAO_YY_BUFFER_STATE b  );
void tao_yypush_buffer_state (TAO_YY_BUFFER_STATE new_buffer  );
void tao_yypop_buffer_state (void );

static void tao_yyensure_buffer_stack (void );
static void tao_yy_load_buffer_state (void );
static void tao_yy_init_buffer (TAO_YY_BUFFER_STATE b,FILE *file  );

#define TAO_YY_FLUSH_BUFFER tao_yy_flush_buffer(TAO_YY_CURRENT_BUFFER )

TAO_YY_BUFFER_STATE tao_yy_scan_buffer (char *base,tao_yy_size_t size  );
TAO_YY_BUFFER_STATE tao_yy_scan_string (tao_yyconst char *tao_yy_str  );
TAO_YY_BUFFER_STATE tao_yy_scan_bytes (tao_yyconst char *bytes,int len  );

void *tao_yyalloc (tao_yy_size_t  );
void *tao_yyrealloc (void *,tao_yy_size_t  );
void tao_yyfree (void *  );

#define tao_yy_new_buffer tao_yy_create_buffer

#define tao_yy_set_interactive(is_interactive) \
        { \
        if ( ! TAO_YY_CURRENT_BUFFER ){ \
        tao_yyensure_buffer_stack (); \
                TAO_YY_CURRENT_BUFFER_LVALUE =    \
            tao_yy_create_buffer(tao_yyin,TAO_YY_BUF_SIZE ); \
        } \
        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_is_interactive = is_interactive; \
        }

#define tao_yy_set_bol(at_bol) \
        { \
        if ( ! TAO_YY_CURRENT_BUFFER ){\
        tao_yyensure_buffer_stack (); \
                TAO_YY_CURRENT_BUFFER_LVALUE =    \
            tao_yy_create_buffer(tao_yyin,TAO_YY_BUF_SIZE ); \
        } \
        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_at_bol = at_bol; \
        }

#define TAO_YY_AT_BOL() (TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_at_bol)

/* Begin user sect3 */

typedef unsigned char TAO_YY_CHAR;

FILE *tao_yyin = (FILE *) 0, *tao_yyout = (FILE *) 0;

typedef int tao_yy_state_type;

extern int tao_yylineno;

int tao_yylineno = 1;

extern char tao_yytext[];

static tao_yy_state_type tao_yy_get_previous_state (void );
static tao_yy_state_type tao_yy_try_NUL_trans (tao_yy_state_type current_state  );
static int tao_yy_get_next_buffer (void );
static void tao_yy_fatal_error (tao_yyconst char msg[]  );

/* Done after the current pattern has been matched and before the
 * corresponding action - sets up tao_yytext.
 */
#define TAO_YY_DO_BEFORE_ACTION \
        (tao_yytext_ptr) = tao_yy_bp; \
        tao_yyleng = (size_t) (tao_yy_cp - tao_yy_bp); \
        (tao_yy_hold_char) = *tao_yy_cp; \
        *tao_yy_cp = '\0'; \
        if ( tao_yyleng >= TAO_YYLMAX ) \
                TAO_YY_FATAL_ERROR( "token too large, exceeds TAO_YYLMAX" ); \
        tao_yy_flex_strncpy( tao_yytext, (tao_yytext_ptr), tao_yyleng + 1 ); \
        (tao_yy_c_buf_p) = tao_yy_cp;

#define TAO_YY_NUM_RULES 110
#define TAO_YY_END_OF_BUFFER 111
/* This struct is not used in this scanner,
   but its presence is necessary. */
struct tao_yy_trans_info
        {
        flex_int32_t tao_yy_verify;
        flex_int32_t tao_yy_nxt;
        };
static tao_yyconst flex_int16_t tao_yy_accept[592] =
    {   0,
      107,  107,  111,  109,  107,  108,  108,  109,  109,  109,
      109,  109,   82,   78,  109,  109,  109,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,  107,  109,  108,  107,    0,   83,    0,    0,
        0,    0,   81,   77,   75,  106,    0,   75,   82,    0,
        0,    0,   78,   73,   71,   72,   74,   74,    0,    0,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   68,   74,   74,   74,   74,   74,   74,

       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,  107,    0,    0,  101,    0,    0,    0,    0,    0,
        0,    0,   83,    0,    0,    0,   85,    0,   85,    0,
        0,   81,    0,   77,    0,   75,    0,  105,  105,   75,
        0,   76,   80,   74,    0,   84,    0,    0,    0,   74,
       74,   74,   74,    1,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   69,   74,   74,   74,   74,

       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   74,    0,    0,    0,
        0,    0,    0,    0,    0,   88,   86,    0,    0,   79,
        0,   75,   76,   74,   84,    0,    0,    0,    0,   89,
        0,   74,   65,   74,   74,   74,   74,   20,   27,   74,
       74,   74,   74,   74,   74,   74,   74,   13,   74,   74,
       74,   74,   74,   74,   74,   48,   74,   74,   74,   74,
       24,   74,   74,   74,   74,   74,   74,   74,   60,   74,
       74,   74,   74,   74,   74,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   74,   57,   74,   31,   74,

       74,    0,    0,    0,    0,    0,    0,    0,  102,    0,
        0,    0,    0,    0,    0,    0,   86,    0,   87,    0,
       66,    0,    0,    0,   74,   74,   64,   74,   74,   74,
       74,   10,   74,   74,   74,   74,   74,   44,   74,   74,
       74,   74,   18,   22,   74,   74,   67,   74,   33,   74,
       74,   74,   74,   74,   30,   74,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   25,   74,   74,   74,   74,
       74,   74,   74,   74,   74,   17,   74,   74,   28,   74,
       97,    0,    0,    0,    0,    0,    0,    0,    0,    0,
        0,    0,    0,    0,   90,    0,    2,   74,   74,   74,

       74,   74,   74,   74,   35,   74,   23,   74,   74,   74,
       46,   74,   49,   74,   74,   74,    3,   74,   32,   70,
       74,   74,   74,   74,   38,   74,    4,   74,   74,   74,
       14,   12,   74,   19,   74,   74,   55,   74,   74,   74,
       74,   74,    0,   95,    0,    0,    0,    0,    0,    0,
        0,    0,    0,    0,    0,    0,    0,    0,   74,   74,
       29,   74,   74,   74,    8,   21,   74,   74,   36,   74,
       74,   58,   74,   74,   74,   74,   37,   74,   74,   74,
       74,   74,   74,   74,   11,   74,   74,   74,   74,   15,
        0,    0,   93,   93,    0,    0,   99,    0,    0,   98,

        0,    0,    0,    0,    0,    0,    0,   34,   74,   74,
       74,   43,   74,   74,   74,   74,   74,   50,   62,   74,
       52,   74,    5,   16,   74,   39,   74,   59,   74,   26,
       74,    0,  103,  103,    0,    0,    0,    0,   96,    0,
        0,    0,    0,    0,    0,    0,    6,   42,   63,   45,
        7,   47,    9,   74,   74,   53,   54,   74,   74,   41,
        0,    0,    0,   91,   91,    0,    0,   94,   94,    0,
        0,    0,    0,   61,   51,   74,   56,    0,    0,  104,
      104,    0,    0,    0,   40,    0,  100,    0,   92,   92,
        0

    } ;

static tao_yyconst flex_int32_t tao_yy_ec[256] =
    {   0,
        1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
        1,    1,    4,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    5,    1,    6,    7,    1,    1,    1,    8,    1,
        1,    9,   10,    1,   11,   12,   13,   14,   15,   15,
       15,   15,   15,   15,   15,   16,   16,   17,    1,   18,
       19,   20,   21,    1,   22,   23,   23,   23,   24,   25,
       26,   26,   26,   26,   26,   27,   26,   26,   28,   26,
       26,   29,   30,   31,   32,   26,   26,   33,   26,   26,
        1,   34,    1,    1,   26,    1,   35,   36,   37,   38,

       39,   40,   41,   42,   43,   44,   45,   46,   47,   48,
       49,   50,   51,   52,   53,   54,   55,   56,   57,   58,
       59,   26,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,

        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1
    } ;

static tao_yyconst flex_int32_t tao_yy_meta[60] =
    {   0,
        1,    1,    2,    1,    1,    3,    1,    4,    1,    1,
        1,    1,    1,    5,    5,    6,    1,    1,    1,    1,
        3,    6,    6,    6,    6,    7,    7,    7,    7,    7,
        7,    7,    7,    3,    5,    5,    6,    6,    6,    5,
        7,    7,    7,    7,    7,    7,    7,    8,    7,    7,
        7,    8,    7,    8,    9,    8,    7,    8,    7
    } ;

static tao_yyconst flex_int16_t tao_yy_base[620] =
    {   0,
        0,   58, 1159, 1160,   59, 1160, 1160,   56, 1124,   54,
       57,   65,   68,   73, 1140, 1138, 1135,    0, 1132,   69,
     1117, 1123,   45, 1102,   60,   37,   58,   65, 1111, 1100,
       56, 1099,   75, 1112,   80,   70,   59,   90,   61,   83,
       88,   90,  144,  150, 1125,  136,  127,  154,  125, 1137,
      154,  158,  164,  170,  209, 1160,  154,  190,  202,  215,
      236,    0,  244, 1160, 1160, 1160,    0, 1117,  136, 1109,
     1098, 1109, 1087, 1096, 1079, 1083, 1087, 1082, 1099,  144,
     1080, 1092, 1076, 1087, 1074, 1089, 1090, 1089,  119, 1076,
     1070, 1076, 1072,  153,  162, 1073, 1068, 1081, 1072, 1063,

     1062, 1076, 1060, 1061,  140, 1076, 1068, 1075,  144, 1060,
     1056, 1057, 1063, 1050, 1054,  158, 1064, 1056, 1058, 1058,
     1045,  230,    0,  173, 1160, 1092,  258, 1054, 1058, 1052,
     1042, 1074,  238,  232,  236,  261, 1160, 1084, 1083,  263,
     1082,  270,    0,  275,  282, 1160,  297, 1160,  299,    0,
      290,  296,    0, 1059,  247,  311,  293, 1080,  126, 1048,
     1062, 1031, 1049,    0, 1031, 1036, 1042, 1028, 1029,  167,
     1024, 1042, 1040, 1021, 1027, 1025, 1033, 1017, 1032, 1030,
     1033, 1015, 1027, 1016, 1009, 1024, 1027, 1020, 1025, 1007,
     1003, 1003, 1013, 1016,  997,    0,  999,  268,  996, 1005,

      997, 1011,  993,  995,  994,  202,  995,  990,  995, 1003,
      992,  997,  986,  983,  999, 1001,  983, 1028, 1027,  986,
      992,  982,  994,  347,  311, 1160, 1160,  314, 1020,    0,
      316,  319, 1160, 1003,  351, 1020,  313,  352,    0, 1160,
        0,  988,    0,  972,  970,  979,  982,    0,    0,  971,
      980,  210,  979,  968,  961,  969,  961,    0,  959,  962,
      962,  971,  971,  954,  972,    0,  954,  951,  952,  957,
        0,  961,  952,  954,  956,  942,  943,  961,  941,  959,
      958,  949,  948,  951,  940,  949,  952,  932,  937,  947,
      934,  945,  944,  326,  932,  938,    0,  939,    0,  925,

      933,  969,  336,  935,  925,  933,  930,  924, 1160,  331,
      367,  926,  930,  924,  914,  321, 1160,  957, 1160,  956,
        0,  385,  414,  955,  908,  926,    0,  924,  924,  910,
      920,    0,  909,  897,  907,  907,  913,    0,  897,  896,
      897,  896,    0,    0,  904,  892,    0,  905,    0,  905,
      891,  903,  891,  901,    0,  880,  879,  885,  882,  897,
      336,  881,  885,  884,  888,    0,  889,  875,  876,  885,
      891,  886,  886,  888,  870,    0,  873,  866,    0,  871,
     1160,  400,  390,  864,  396,  870,  910,  909,  868,  874,
      864,  876,  373,  441, 1160,  902,    0,  872,  853,  859,

      867,  851,  865,  849,    0,  848,    0,  842,  857,  840,
        0,  737,    0,  754,  720,  694,    0,  695,    0,    0,
      690,  665,  673,  672,    0,  667,    0,  662,  669,  651,
        0,    0,  649,    0,  645,  658,    0,  636,  642,  631,
      609,  626,  468, 1160,  483,  405,  420,  429,  503,  631,
      656,  437,  608,  596,  593,  590,  511,  619,  564,  563,
        0,  563,  553,  547,    0,    0,  548,  539,    0,  548,
      528,    0,  511,  499,  498,  485,    0,  475,  484,  451,
      462,  461,  443,  460,    0,  452,  450,  431,  418,    0,
      538,  414, 1160,  471,  490,  510, 1160,  461,  422, 1160,

      553,  457,  407,  561,  413,  379,  439,    0,  407,  379,
      380,    0,  384,  358,  343,  355,  332,    0,    0,  341,
        0,  322,    0,    0,  307,    0,  318,    0,  300,    0,
      249,  499, 1160,  518,  274,  568,  541,  576, 1160,  591,
      582,  527,  599,  614,  594,  234,    0,    0,    0,    0,
        0,    0,    0,  174,  149,    0,    0,  117,   92,    0,
      619,  634,  622, 1160,  638,  642,  648, 1160,  650,  657,
      142,  115,  559,    0,    0,   57,    0,  670,  661, 1160,
      673,   61,  676,  684,    0,  686, 1160,  689, 1160,  692,
     1160,  713,  722,  727,  734,  742,  751,  756,  762,  771,

      777,  779,  783,  792,  798,  800,  802,  805,  811,  817,
      823,  829,  835,  844,  853,  862,  871,  880,  889
    } ;

static tao_yyconst flex_int16_t tao_yy_def[620] =
    {   0,
      591,    1,  591,  591,  591,  591,  591,  592,  593,  591,
      591,  591,  591,  591,  591,  591,  591,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  591,  591,  591,  591,  592,  591,  595,  591,
      596,  591,  591,  591,  591,  591,  597,   55,  591,  591,
      591,  598,  591,  591,  591,  591,  594,  594,  599,  600,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,

      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  591,   44,   44,  591,  124,  591,  591,  591,  591,
      591,  591,  591,  592,  592,  592,  591,  591,  591,  591,
      601,  591,  602,  591,  591,  591,  597,  591,  597,   58,
      591,  591,  598,  594,  599,  591,  603,  591,  591,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,

      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  604,  591,  591,
      591,  591,  591,  591,  592,  591,  591,  591,  605,  602,
      591,  591,  591,  594,  591,  591,  599,  599,  606,  591,
      607,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,

      594,  604,  591,  591,  591,  591,  591,  224,  591,  224,
      591,  591,  591,  591,  591,  592,  591,  591,  591,  591,
      594,  599,  599,  608,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      591,  591,  591,  591,  591,  591,  609,  591,  591,  591,
      591,  591,  599,  323,  591,  610,  594,  594,  594,  594,

      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  591,  591,  591,  611,  591,  591,  591,  591,
      609,  591,  591,  591,  591,  591,  323,  612,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      591,  611,  591,  611,  613,  591,  591,  614,  591,  591,

      591,  591,  591,  591,  591,  599,  591,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      594,  613,  591,  613,  614,  591,  615,  591,  591,  591,
      616,  591,  591,  591,  591,  591,  594,  594,  594,  594,
      594,  594,  594,  594,  594,  594,  594,  594,  594,  594,
      591,  591,  615,  591,  615,  591,  616,  591,  616,  617,
      618,  591,  591,  594,  594,  594,  594,  591,  617,  591,
      617,  618,  591,  619,  594,  591,  591,  619,  591,  619,
        0,  591,  591,  591,  591,  591,  591,  591,  591,  591,

      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591
    } ;

static tao_yyconst flex_int16_t tao_yy_nxt[1220] =
    {   0,
        4,    5,    6,    7,    5,    8,    4,    9,    4,    4,
       10,   11,   12,   13,   14,   14,   15,   16,    4,   17,
        7,   18,   18,   18,   19,   18,   20,   21,   18,   18,
       22,   18,   18,    4,   23,   24,   25,   26,   27,   28,
       29,   30,   31,   18,   18,   32,   33,   34,   35,   36,
       18,   37,   38,   39,   40,   41,   42,   18,   18,   43,
       46,   48,   43,   46,   44,   52,  583,   53,   54,   54,
       55,   55,   55,   56,   69,   82,   70,   57,   45,   58,
       73,   59,   59,   60,   58,   83,   63,   63,   63,   49,
       74,   61,   75,  107,   78,  585,   61,  108,   76,   88,

       62,   79,   93,   94,   84,   85,   61,   89,   80,   96,
       90,   61,  114,   86,   81,   87,  101,   97,  104,  115,
      571,  105,  118,   98,  106,   62,  120,  102,  109,   99,
      116,  110,   48,  240,  103,  117,  119,   46,  136,  136,
       46,  156,  121,  111,  112,  122,  113,  583,  122,  577,
      123,  124,  125,  125,  126,  133,  148,  149,  133,  134,
       49,  139,  576,  127,  127,  127,  179,  140,  140,  157,
      125,   55,   55,   55,  149,   58,  180,  142,  142,   60,
      241,   58,  198,  144,  144,  144,  141,   61,  199,  128,
      169,  170,  129,   61,  203,  130,  143,  204,  187,  131,

      211,  185,   61,  150,  150,  150,  186,  575,   61,  188,
      212,  141,  591,   58,  251,   59,   59,   60,  591,  252,
      253,  143,   55,   55,   55,   61,   58,  574,   60,   60,
       60,  122,  145,  146,  122,  146,  123,   48,   61,  133,
       61,   48,  133,  134,  289,  151,  151,  145,  146,  152,
      152,  152,  156,   61,  146,   58,  290,   63,   63,   63,
      125,  125,  219,  332,  333,   49,   48,   61,  573,   49,
      227,  127,  127,  127,  225,  225,  228,  228,  125,  536,
      157,   58,   61,  142,  142,   60,   58,  560,  144,  144,
      144,  231,  231,   61,   49,  232,  232,  232,   61,  148,

      149,  148,  149,  152,  152,  152,  238,  238,   61,  152,
      152,  152,  235,   61,  280,  235,   48,  149,  156,  149,
      233,  317,  233,  281,  316,  316,   48,  318,  318,  232,
      232,  232,  232,  232,  232,  233,  387,  236,  381,  381,
      382,  233,  559,  146,   49,  146,  157,  239,  308,  309,
      309,  310,  235,  558,   49,  235,  381,  156,  146,  557,
      311,  311,  311,  372,  146,  322,  322,  309,  373,  309,
      309,  388,  425,  374,  556,  375,  591,  236,  156,  555,
      311,  311,  311,  554,  156,  157,  312,  309,  426,  313,
      156,  446,  314,  553,  446,  552,  315,  448,  393,  393,

      448,  443,  444,  444,  443,  551,  157,  493,  494,  449,
      449,  449,  157,  445,  445,  445,  493,  494,  157,  156,
      444,  495,  550,  537,  495,  494,  537,  394,  394,  394,
      448,  549,  548,  448,  494,  394,  394,  394,  394,  500,
      500,  501,  449,  449,  449,  547,  395,  157,  394,  394,
      394,  394,  394,  394,  457,  457,  457,  500,  541,  546,
      542,  541,  457,  457,  457,  457,  536,  531,  530,  443,
      444,  444,  443,  493,  494,  457,  457,  457,  457,  457,
      457,  491,  491,  491,  443,  444,  444,  443,  444,  529,
      528,  494,  533,  534,  527,  526,  445,  445,  445,  525,

      524,  533,  534,  444,  496,  497,  497,  496,  498,  523,
      534,  496,  497,  497,  496,  498,  449,  449,  449,  534,
      533,  534,  522,  497,  506,  506,  506,  521,  570,  520,
      497,  570,  506,  506,  506,  506,  519,  518,  534,  443,
      444,  444,  443,  564,  565,  506,  506,  506,  506,  506,
      506,  491,  491,  491,  538,  539,  539,  538,  444,  517,
      584,  565,  543,  584,  516,  544,  540,  540,  540,  561,
      497,  497,  561,  539,  545,  545,  545,  538,  539,  539,
      538,  562,  562,  562,  568,  569,  515,  514,  497,  566,
      566,  566,  538,  539,  539,  538,  539,  513,  572,  512,

      543,  511,  569,  544,  540,  540,  540,  545,  545,  545,
      510,  539,  545,  545,  545,  543,  509,  508,  544,  571,
      561,  497,  497,  561,  564,  565,  395,  545,  545,  545,
      505,  504,  562,  562,  562,  578,  497,  497,  578,  497,
      564,  565,  565,  503,  539,  539,  502,  562,  562,  562,
      568,  569,  568,  569,  497,  566,  566,  566,  565,  580,
      581,  452,  539,  580,  581,  499,  490,  489,  569,  488,
      569,  578,  497,  497,  578,  580,  581,  581,  587,  587,
      487,  581,  486,  586,  586,  586,  589,  590,  497,  497,
      497,  589,  590,  581,  589,  590,  587,  485,  484,  586,

      586,  586,  483,  482,  590,  481,  497,  480,  479,  590,
      478,  477,  590,   47,   47,   47,   47,   47,   47,   47,
       47,   47,   50,  476,   50,   50,   50,   50,   50,   50,
       50,   67,   67,   67,   67,   67,  135,  135,  135,  475,
      474,  135,  138,  473,  138,  138,  138,  138,  138,  138,
      138,  147,  147,  147,  147,  147,  147,  147,  147,  147,
      153,  153,  155,  155,  155,  155,  155,  155,  155,  155,
      155,  158,  472,  158,  158,  158,  158,  158,  158,  158,
      229,  229,  229,  230,  230,  237,  237,  237,  471,  470,
      237,  237,  302,  302,  302,  302,  302,  302,  302,  302,

      302,  320,  320,  320,  323,  323,  324,  324,  396,  396,
      396,  451,  451,  451,  451,  451,  451,  451,  451,  451,
      458,  458,  458,  492,  492,  492,  492,  492,  492,  492,
      492,  492,  507,  507,  507,  532,  532,  532,  532,  532,
      532,  532,  532,  532,  535,  535,  535,  535,  535,  535,
      535,  535,  535,  563,  563,  563,  563,  563,  563,  563,
      563,  563,  567,  567,  567,  567,  567,  567,  567,  567,
      567,  579,  579,  579,  579,  579,  579,  579,  579,  579,
      582,  582,  582,  582,  582,  582,  582,  582,  582,  588,
      588,  588,  588,  588,  588,  588,  588,  588,  469,  468,

      467,  466,  465,  464,  463,  462,  461,  460,  459,  395,
      456,  455,  454,  453,  387,  452,  450,  447,  442,  441,
      440,  439,  438,  437,  436,  435,  434,  433,  432,  431,
      430,  429,  428,  427,  424,  423,  422,  421,  420,  419,
      418,  417,  416,  415,  414,  413,  412,  411,  410,  409,
      408,  407,  406,  405,  404,  403,  402,  401,  400,  399,
      398,  397,  395,  319,  317,  392,  391,  390,  389,  591,
      386,  385,  384,  383,  303,  380,  379,  378,  377,  376,
      371,  370,  369,  368,  367,  366,  365,  364,  363,  362,
      361,  360,  359,  358,  357,  356,  355,  354,  353,  352,

      351,  350,  349,  348,  347,  346,  345,  344,  343,  342,
      341,  340,  339,  338,  337,  336,  335,  334,  331,  330,
      329,  328,  327,  326,  325,   69,  321,  319,  307,  306,
      305,  304,  218,  303,  301,  300,  299,  298,  297,  296,
      295,  294,  293,  292,  291,  288,  287,  286,  285,  284,
      283,  282,  279,  278,  277,  276,  275,  274,  273,  272,
      271,  270,  269,  268,  267,  266,  265,  264,  263,  262,
      261,  260,  259,  258,  257,  256,  255,  254,  250,  249,
      248,  247,  246,  245,  244,  243,  242,  240,  234,  226,
      226,  226,  224,  223,  222,  221,  220,  218,  217,  216,

      215,  214,  213,  210,  209,  208,  207,  206,  205,  202,
      201,  200,  197,  196,  195,  194,  193,  192,  191,  190,
      189,  184,  183,  182,  181,  178,  177,  176,  175,  174,
      173,  172,  171,  168,  167,  166,  165,  164,  163,  162,
      161,  160,  159,  154,  137,  132,  100,   95,   92,   91,
       77,   72,   71,   68,   66,   65,   64,   51,  591,    3,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,

      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591
    } ;

static tao_yyconst flex_int16_t tao_yy_chk[1220] =
    {   0,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
        1,    1,    1,    1,    1,    1,    1,    1,    1,    2,
        5,    8,    2,    5,    2,   10,  582,   10,   10,   10,
       11,   11,   11,   12,   20,   26,   20,   12,    2,   13,
       23,   13,   13,   13,   14,   26,   14,   14,   14,    8,
       23,   13,   23,   37,   25,  576,   14,   37,   23,   28,

       13,   25,   31,   31,   27,   27,   13,   28,   25,   33,
       28,   14,   39,   27,   25,   27,   35,   33,   36,   39,
      572,   36,   41,   33,   36,   13,   42,   35,   38,   33,
       40,   38,   47,  159,   35,   40,   41,   46,   49,   49,
       46,   69,   42,   38,   38,   43,   38,  571,   43,  559,
       43,   44,   44,   44,   44,   48,   57,   57,   48,   48,
       47,   51,  558,   44,   44,   44,   89,   51,   51,   69,
       44,   52,   52,   52,   57,   53,   89,   53,   53,   53,
      159,   54,  105,   54,   54,   54,   51,   53,  105,   44,
       80,   80,   44,   54,  109,   44,   53,  109,   95,   44,

      116,   94,   53,   58,   58,   58,   94,  555,   54,   95,
      116,   51,  124,   59,  170,   59,   59,   59,  124,  170,
      170,   53,   55,   55,   55,   59,   60,  554,   60,   60,
       60,  122,   55,   55,  122,   55,  122,  134,   60,  133,
       59,  135,  133,  133,  206,   61,   61,   55,   55,   61,
       61,   61,  155,   60,   55,   63,  206,   63,   63,   63,
      127,  127,  127,  252,  252,  134,  136,   63,  546,  135,
      140,  127,  127,  127,  136,  136,  140,  140,  127,  535,
      155,  142,   63,  142,  142,  142,  144,  531,  144,  144,
      144,  145,  145,  142,  136,  145,  145,  145,  144,  147,

      147,  149,  149,  151,  151,  151,  157,  157,  142,  152,
      152,  152,  156,  144,  198,  156,  225,  147,  237,  149,
      152,  228,  152,  198,  225,  225,  316,  228,  228,  231,
      231,  231,  232,  232,  232,  152,  310,  156,  303,  303,
      303,  152,  529,  232,  225,  232,  237,  157,  224,  224,
      224,  224,  235,  527,  316,  235,  303,  238,  232,  525,
      224,  224,  224,  294,  232,  238,  238,  224,  294,  311,
      311,  311,  361,  294,  522,  294,  310,  235,  393,  520,
      311,  311,  311,  517,  506,  238,  224,  311,  361,  224,
      322,  383,  224,  516,  383,  515,  224,  385,  322,  322,

      385,  382,  382,  382,  382,  514,  393,  446,  446,  385,
      385,  385,  506,  382,  382,  382,  492,  492,  322,  323,
      382,  447,  513,  499,  447,  446,  499,  323,  323,  323,
      448,  511,  510,  448,  492,  323,  323,  323,  323,  452,
      452,  452,  448,  448,  448,  509,  507,  323,  323,  323,
      323,  323,  323,  323,  394,  394,  394,  452,  502,  505,
      503,  502,  394,  394,  394,  394,  498,  489,  488,  443,
      443,  443,  443,  494,  494,  394,  394,  394,  394,  394,
      394,  443,  443,  443,  445,  445,  445,  445,  443,  487,
      486,  494,  495,  495,  484,  483,  445,  445,  445,  482,

      481,  532,  532,  445,  449,  449,  449,  449,  449,  480,
      495,  496,  496,  496,  496,  496,  449,  449,  449,  532,
      534,  534,  479,  449,  457,  457,  457,  478,  542,  476,
      496,  542,  457,  457,  457,  457,  475,  474,  534,  491,
      491,  491,  491,  537,  537,  457,  457,  457,  457,  457,
      457,  491,  491,  491,  501,  501,  501,  501,  491,  473,
      573,  537,  504,  573,  471,  504,  501,  501,  501,  536,
      536,  536,  536,  501,  504,  504,  504,  538,  538,  538,
      538,  536,  536,  536,  541,  541,  470,  468,  536,  538,
      538,  538,  540,  540,  540,  540,  538,  467,  545,  464,

      543,  463,  541,  543,  540,  540,  540,  545,  545,  545,
      462,  540,  543,  543,  543,  544,  460,  459,  544,  544,
      561,  561,  561,  561,  563,  563,  458,  544,  544,  544,
      456,  455,  561,  561,  561,  562,  562,  562,  562,  561,
      565,  565,  563,  454,  566,  566,  453,  562,  562,  562,
      567,  567,  569,  569,  562,  566,  566,  566,  565,  570,
      570,  451,  566,  579,  579,  450,  442,  441,  567,  440,
      569,  578,  578,  578,  578,  581,  581,  570,  583,  583,
      439,  579,  438,  578,  578,  578,  584,  584,  586,  586,
      578,  588,  588,  581,  590,  590,  583,  436,  435,  586,

      586,  586,  433,  430,  584,  429,  586,  428,  426,  588,
      424,  423,  590,  592,  592,  592,  592,  592,  592,  592,
      592,  592,  593,  422,  593,  593,  593,  593,  593,  593,
      593,  594,  594,  594,  594,  594,  595,  595,  595,  421,
      418,  595,  596,  416,  596,  596,  596,  596,  596,  596,
      596,  597,  597,  597,  597,  597,  597,  597,  597,  597,
      598,  598,  599,  599,  599,  599,  599,  599,  599,  599,
      599,  600,  415,  600,  600,  600,  600,  600,  600,  600,
      601,  601,  601,  602,  602,  603,  603,  603,  414,  412,
      603,  603,  604,  604,  604,  604,  604,  604,  604,  604,

      604,  605,  605,  605,  606,  606,  607,  607,  608,  608,
      608,  609,  609,  609,  609,  609,  609,  609,  609,  609,
      610,  610,  610,  611,  611,  611,  611,  611,  611,  611,
      611,  611,  612,  612,  612,  613,  613,  613,  613,  613,
      613,  613,  613,  613,  614,  614,  614,  614,  614,  614,
      614,  614,  614,  615,  615,  615,  615,  615,  615,  615,
      615,  615,  616,  616,  616,  616,  616,  616,  616,  616,
      616,  617,  617,  617,  617,  617,  617,  617,  617,  617,
      618,  618,  618,  618,  618,  618,  618,  618,  618,  619,
      619,  619,  619,  619,  619,  619,  619,  619,  410,  409,

      408,  406,  404,  403,  402,  401,  400,  399,  398,  396,
      392,  391,  390,  389,  388,  387,  386,  384,  380,  378,
      377,  375,  374,  373,  372,  371,  370,  369,  368,  367,
      365,  364,  363,  362,  360,  359,  358,  357,  356,  354,
      353,  352,  351,  350,  348,  346,  345,  342,  341,  340,
      339,  337,  336,  335,  334,  333,  331,  330,  329,  328,
      326,  325,  324,  320,  318,  315,  314,  313,  312,  308,
      307,  306,  305,  304,  302,  301,  300,  298,  296,  295,
      293,  292,  291,  290,  289,  288,  287,  286,  285,  284,
      283,  282,  281,  280,  279,  278,  277,  276,  275,  274,

      273,  272,  270,  269,  268,  267,  265,  264,  263,  262,
      261,  260,  259,  257,  256,  255,  254,  253,  251,  250,
      247,  246,  245,  244,  242,  236,  234,  229,  223,  222,
      221,  220,  219,  218,  217,  216,  215,  214,  213,  212,
      211,  210,  209,  208,  207,  205,  204,  203,  202,  201,
      200,  199,  197,  195,  194,  193,  192,  191,  190,  189,
      188,  187,  186,  185,  184,  183,  182,  181,  180,  179,
      178,  177,  176,  175,  174,  173,  172,  171,  169,  168,
      167,  166,  165,  163,  162,  161,  160,  158,  154,  141,
      139,  138,  132,  131,  130,  129,  128,  126,  121,  120,

      119,  118,  117,  115,  114,  113,  112,  111,  110,  108,
      107,  106,  104,  103,  102,  101,  100,   99,   98,   97,
       96,   93,   92,   91,   90,   88,   87,   86,   85,   84,
       83,   82,   81,   79,   78,   77,   76,   75,   74,   73,
       72,   71,   70,   68,   50,   45,   34,   32,   30,   29,
       24,   22,   21,   19,   17,   16,   15,    9,    3,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,

      591,  591,  591,  591,  591,  591,  591,  591,  591,  591,
      591,  591,  591,  591,  591,  591,  591,  591,  591
    } ;

static tao_yy_state_type tao_yy_last_accepting_state;
static char *tao_yy_last_accepting_cpos;

extern int tao_yy_flex_debug;
int tao_yy_flex_debug = 0;

/* The intent behind this definition is that it'll catch
 * any uses of REJECT which flex missed.
 */
#define REJECT reject_used_but_not_detected
#define tao_yymore() tao_yymore_used_but_not_detected
#define TAO_YY_MORE_ADJ 0
#define TAO_YY_RESTORE_TAO_YY_MORE_OFFSET
#ifndef TAO_YYLMAX
#define TAO_YYLMAX 8192
#endif

char tao_yytext[TAO_YYLMAX];
char *tao_yytext_ptr;
/*  $Id: lex.yy.cpp 95242 2011-12-07 11:54:56Z johnnyw $

COPYRIGHT

Copyright 1992, 1993, 1994 Sun Microsystems, Inc.  Printed in the United
States of America.  All Rights Reserved.

This product is protected by copyright and distributed under the following
license restricting its use.

The Interface Definition Language Compiler Front End (CFE) is made
available for your use provided that you include this license and copyright
notice on all media and documentation and the software program in which
this product is incorporated in whole or part. You may copy and extend
functionality (but may not remove functionality) of the Interface
Definition Language CFE without charge, but you are not authorized to
license or distribute it to anyone else except as part of a product or
program developed by you or with the express written consent of Sun
Microsystems, Inc. ("Sun").

The names of Sun Microsystems, Inc. and any of its subsidiaries or
affiliates may not be used in advertising or publicity pertaining to
distribution of Interface Definition Language CFE as permitted herein.

This license is effective until terminated by Sun for failure to comply
with this license.  Upon termination, you shall destroy or return all code
and documentation for the Interface Definition Language CFE.

IDL_INTERFACE DEFINITION LANGUAGE CFE IS PROVIDED AS IS WITH NO WARRANTIES OF
IDL_ANY KIND INCLUDING THE WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS
FOR A PARTICULAR PURPOSE, NONINFRINGEMENT, OR ARISING FROM A COURSE OF
DEALING, USAGE OR TRADE PRACTICE.

IDL_INTERFACE DEFINITION LANGUAGE CFE IS PROVIDED WITH NO SUPPORT AND WITHOUT
IDL_ANY OBLIGATION ON THE PART OF Sun OR IDL_ANY OF ITS SUBSIDIARIES OR AFFILIATES
TO ASSIST IDL_IN ITS USE, CORRECTION, MODIFICATION OR ENHANCEMENT.

SUN OR IDL_ANY OF ITS SUBSIDIARIES OR AFFILIATES SHALL HAVE NO LIABILITY WITH
RESPECT TO THE INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR IDL_ANY PATENTS BY
IDL_INTERFACE DEFINITION LANGUAGE CFE OR IDL_ANY PART THEREOF.

IDL_IN NO EVENT WILL SUN OR IDL_ANY OF ITS SUBSIDIARIES OR AFFILIATES BE LIABLE FOR
IDL_ANY LOST REVENUE OR PROFITS OR OTHER SPECIAL, INDIRECT AND CONSEQUENTIAL
DAMAGES, EVEN IF SUN HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

Use, duplication, or disclosure by the government is subject to
restrictions as set forth in subparagraph (c)(1)(ii) of the Rights in
Technical Data and Computer Software clause at DFARS 252.227-7013 and FAR
52.227-19.

Sun, Sun Microsystems and the Sun logo are trademarks or registered
trademarks of Sun Microsystems, Inc.

SunSoft, Inc.
2550 Garcia Avenue
Mountain View, California  94043

NOTE:

SunOS, SunSoft, Sun, Solaris, Sun Microsystems or the Sun logo are
trademarks or registered trademarks of Sun Microsystems, Inc.

 */

/*
 * idl.ll - Lexical scanner for IDL 3.1
 */

#include "global_extern.h"
#include "nr_extern.h"
#include "utl_strlist.h"
#include "utl_exprlist.h"
#include "utl_labellist.h"
#include "utl_decllist.h"
#include "utl_string.h"
#include "utl_err.h"
#include "ast_union_label.h"
#include "ast_field.h"
#include "ast_expression.h"
#include "ast_argument.h"
#include "ast_operation.h"
#include "ast_root.h"
#include "fe_interface_header.h"
#include "fe_obv_header.h"
#include "fe_component_header.h"
#include "fe_home_header.h"
#include "fe_private.h"
#include "fe_extern.h"
#include "y.tab.h"

static char *               idl_wstring_escape_reader (char *);
static ACE_CDR::WChar       idl_wchar_escape_reader (char *);
static ACE_CDR::Char        idl_escape_reader (char *);
static ACE_CDR::Double      idl_atof (char *);
static ACE_CDR::LongLong    idl_atoi (char *, long);
static ACE_CDR::ULongLong   idl_atoui (char *, long);
static void                 idl_parse_line_and_file (char *);
static void                 idl_store_pragma (char *);
static char *               idl_get_pragma_string (char *);
static bool                 idl_valid_version (char *);
static AST_Decl *           idl_find_node (const char *);

#define ace_tao_yytext tao_yytext

#ifdef USE_MCPP_BUFFER_LEXING
#include "mcpp_tao_yyinput.h"
#endif /*USE_MCPP_BUFFER_LEXING*/

/* SO we don't choke on files that use \r\n */

#define INITIAL 0

#ifndef TAO_YY_NO_UNISTD_H
/* Special case for "unistd.h", since it is non-ANSI. We include it way
 * down here because we want the user's section 1 to have been scanned first.
 * The user has a chance to override it with an option.
 */
#include "ace/os_include/os_ctype.h"
#endif

#ifndef TAO_YY_EXTRA_TYPE
#define TAO_YY_EXTRA_TYPE void *
#endif

static int tao_yy_init_globals (void );

/* Accessor methods to globals.
   These are made visible to non-reentrant scanners for convenience. */

int tao_yylex_destroy (void );

int tao_yyget_debug (void );

void tao_yyset_debug (int debug_flag  );

TAO_YY_EXTRA_TYPE tao_yyget_extra (void );

void tao_yyset_extra (TAO_YY_EXTRA_TYPE user_defined  );

FILE *tao_yyget_in (void );

void tao_yyset_in  (FILE * in_str  );

FILE *tao_yyget_out (void );

void tao_yyset_out  (FILE * out_str  );

int tao_yyget_leng (void );

char *tao_yyget_text (void );

int tao_yyget_lineno (void );

void tao_yyset_lineno (int line_number  );

/* Macros after this point can all be overridden by user definitions in
 * section 1.
 */

#ifndef TAO_YY_SKIP_TAO_YYWRAP
#ifdef __cplusplus
extern "C" int tao_yywrap (void );
#else
extern int tao_yywrap (void );
#endif
#endif

    static void tao_yyunput (int c,char *buf_ptr  );

#ifndef tao_yytext_ptr
static void tao_yy_flex_strncpy (char *,tao_yyconst char *,int );
#endif

#ifdef TAO_YY_NEED_STRLEN
static int tao_yy_flex_strlen (tao_yyconst char * );
#endif

#ifndef TAO_YY_NO_INPUT

#ifdef __cplusplus
static int tao_yyinput (void );
#else
static int input (void );
#endif

#endif

/* Amount of stuff to slurp up with each read. */
#ifndef TAO_YY_READ_BUF_SIZE
#ifdef __ia64__
/* On IA-64, the buffer size is 16k, not 8k */
#define TAO_YY_READ_BUF_SIZE 16384
#else
#define TAO_YY_READ_BUF_SIZE 8192
#endif /* __ia64__ */
#endif

/* Copy whatever the last rule matched to the standard output. */
#ifndef TAO_YY_ECHO
/* This used to be an fputs(), but since the string might contain NUL's,
 * we now use fwrite().
 */
#define TAO_YY_ECHO do { if (fwrite( tao_yytext, tao_yyleng, 1, tao_yyout )) {} } while (0)
#endif

/* Gets input and stuffs it into "buf".  number of characters read, or TAO_YY_NULL,
 * is returned in "result".
 */
#ifndef TAO_YY_INPUT
#define TAO_YY_INPUT(buf,result,max_size) \
        if ( TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_is_interactive ) \
                { \
                int c = '*'; \
                size_t n; \
                for ( n = 0; n < max_size && \
                             (c = ACE_OS::getc( tao_yyin )) != EOF && c != '\n'; ++n ) \
                        buf[n] = (char) c; \
                if ( c == '\n' ) \
                        buf[n++] = (char) c; \
                if ( c == EOF && ferror( tao_yyin ) ) \
                        TAO_YY_FATAL_ERROR( "input in flex scanner failed" ); \
                result = n; \
                } \
        else \
                { \
                errno=0; \
                while ( (result = static_cast<int> (fread(buf, 1, max_size, tao_yyin)))==0 && ferror(tao_yyin)) \
                        { \
                        if( errno != EINTR) \
                                { \
                                TAO_YY_FATAL_ERROR( "input in flex scanner failed" ); \
                                break; \
                                } \
                        errno=0; \
                        clearerr(tao_yyin); \
                        } \
                }\
\

#endif

/* No semi-colon after return; correct usage is to write "tao_yyterminate();" -
 * we don't want an extra ';' after the "return" because that will cause
 * some compilers to complain about unreachable statements.
 */
#ifndef tao_yyterminate
#define tao_yyterminate() return TAO_YY_NULL
#endif

/* Number of entries by which start-condition stack grows. */
#ifndef TAO_YY_START_STACK_INCR
#define TAO_YY_START_STACK_INCR 25
#endif

/* Report a fatal error. */
#ifndef TAO_YY_FATAL_ERROR
#define TAO_YY_FATAL_ERROR(msg) tao_yy_fatal_error( msg )
#endif

/* end tables serialization structures and prototypes */

/* Default declaration of generated scanner - a define so the user can
 * easily add parameters.
 */
#ifndef TAO_YY_DECL
#define TAO_YY_DECL_IS_OURS 1

extern int tao_yylex (void);

#define TAO_YY_DECL int tao_yylex (void)
#endif /* !TAO_YY_DECL */

/* Code executed at the beginning of each rule, after tao_yytext and tao_yyleng
 * have been set up.
 */
#ifndef TAO_YY_USER_ACTION
#define TAO_YY_USER_ACTION
#endif

/* Code executed at the end of each rule. */
#ifndef TAO_YY_BREAK
#define TAO_YY_BREAK ACE_NOTREACHED (break;)
#endif

#define TAO_YY_RULE_SETUP \
        if ( tao_yyleng > 0 ) \
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_at_bol = \
                                (tao_yytext[tao_yyleng - 1] == '\n'); \
        TAO_YY_USER_ACTION

/** The main scanner function which does all the work.
 */
TAO_YY_DECL
{
        register tao_yy_state_type tao_yy_current_state;
        register char *tao_yy_cp, *tao_yy_bp;
        register int tao_yy_act;

        if ( !(tao_yy_init) )
                {
                (tao_yy_init) = 1;

#ifdef TAO_YY_USER_INIT
                TAO_YY_USER_INIT;
#endif

                if ( ! (tao_yy_start) )
                        (tao_yy_start) = 1;        /* first start state */

                if ( ! tao_yyin )
                        tao_yyin = stdin;

                if ( ! tao_yyout )
                        tao_yyout = stdout;

                if ( ! TAO_YY_CURRENT_BUFFER ) {
                        tao_yyensure_buffer_stack ();
                        TAO_YY_CURRENT_BUFFER_LVALUE =
                                tao_yy_create_buffer(tao_yyin,TAO_YY_BUF_SIZE );
                }

                tao_yy_load_buffer_state( );
                }

        while ( 1 )                /* loops until end-of-file is reached */
                {
                tao_yy_cp = (tao_yy_c_buf_p);

                /* Support of tao_yytext. */
                *tao_yy_cp = (tao_yy_hold_char);

                /* tao_yy_bp points to the position in tao_yy_ch_buf of the start of
                 * the current run.
                 */
                tao_yy_bp = tao_yy_cp;

                tao_yy_current_state = (tao_yy_start);
                tao_yy_current_state += TAO_YY_AT_BOL();
tao_yy_match:
                do
                        {
                        register TAO_YY_CHAR tao_yy_c = tao_yy_ec[TAO_YY_SC_TO_UI(*tao_yy_cp)];
                        if ( tao_yy_accept[tao_yy_current_state] )
                                {
                                (tao_yy_last_accepting_state) = tao_yy_current_state;
                                (tao_yy_last_accepting_cpos) = tao_yy_cp;
                                }
                        while ( tao_yy_chk[tao_yy_base[tao_yy_current_state] + tao_yy_c] != tao_yy_current_state )
                                {
                                tao_yy_current_state = (int) tao_yy_def[tao_yy_current_state];
                                if ( tao_yy_current_state >= 592 )
                                        tao_yy_c = tao_yy_meta[(unsigned int) tao_yy_c];
                                }
                        tao_yy_current_state = tao_yy_nxt[tao_yy_base[tao_yy_current_state] + (unsigned int) tao_yy_c];
                        ++tao_yy_cp;
                        }
                while ( tao_yy_current_state != 591 );
                tao_yy_cp = (tao_yy_last_accepting_cpos);
                tao_yy_current_state = (tao_yy_last_accepting_state);

tao_yy_find_action:
                tao_yy_act = tao_yy_accept[tao_yy_current_state];

                TAO_YY_DO_BEFORE_ACTION;

do_action:        /* This label is used only to access EOF actions. */

                switch ( tao_yy_act )
        { /* beginning of action switch */
                        case 0: /* must back up */
                        /* undo the effects of TAO_YY_DO_BEFORE_ACTION */
                        *tao_yy_cp = (tao_yy_hold_char);
                        tao_yy_cp = (tao_yy_last_accepting_cpos);
                        tao_yy_current_state = (tao_yy_last_accepting_state);
                        goto tao_yy_find_action;

case 1:
TAO_YY_RULE_SETUP
return IDL_ANY;
        TAO_YY_BREAK
case 2:
TAO_YY_RULE_SETUP
return IDL_OBJECT;
        TAO_YY_BREAK
case 3:
TAO_YY_RULE_SETUP
return IDL_MODULE;
        TAO_YY_BREAK
case 4:
TAO_YY_RULE_SETUP
return IDL_RAISES;
        TAO_YY_BREAK
case 5:
TAO_YY_RULE_SETUP
return IDL_READONLY;
        TAO_YY_BREAK
case 6:
TAO_YY_RULE_SETUP
return IDL_ATTRIBUTE;
        TAO_YY_BREAK
case 7:
TAO_YY_RULE_SETUP
return IDL_EXCEPTION;
        TAO_YY_BREAK
case 8:
TAO_YY_RULE_SETUP
return IDL_CONTEXT;
        TAO_YY_BREAK
case 9:
TAO_YY_RULE_SETUP
return IDL_INTERFACE;
        TAO_YY_BREAK
case 10:
TAO_YY_RULE_SETUP
return IDL_CONST;
        TAO_YY_BREAK
case 11:
TAO_YY_RULE_SETUP
return IDL_TYPEDEF;
        TAO_YY_BREAK
case 12:
TAO_YY_RULE_SETUP
return IDL_STRUCT;
        TAO_YY_BREAK
case 13:
TAO_YY_RULE_SETUP
return IDL_ENUM;
        TAO_YY_BREAK
case 14:
TAO_YY_RULE_SETUP
return IDL_STRING;
        TAO_YY_BREAK
case 15:
TAO_YY_RULE_SETUP
return IDL_WSTRING;
        TAO_YY_BREAK
case 16:
TAO_YY_RULE_SETUP
return IDL_SEQUENCE;
        TAO_YY_BREAK
case 17:
TAO_YY_RULE_SETUP
return IDL_UNION;
        TAO_YY_BREAK
case 18:
TAO_YY_RULE_SETUP
return IDL_FIXED;
        TAO_YY_BREAK
case 19:
TAO_YY_RULE_SETUP
return IDL_SWITCH;
        TAO_YY_BREAK
case 20:
TAO_YY_RULE_SETUP
return IDL_CASE;
        TAO_YY_BREAK
case 21:
TAO_YY_RULE_SETUP
return IDL_DEFAULT;
        TAO_YY_BREAK
case 22:
TAO_YY_RULE_SETUP
return IDL_FLOAT;
        TAO_YY_BREAK
case 23:
TAO_YY_RULE_SETUP
return IDL_DOUBLE;
        TAO_YY_BREAK
case 24:
TAO_YY_RULE_SETUP
return IDL_LONG;
        TAO_YY_BREAK
case 25:
TAO_YY_RULE_SETUP
return IDL_SHORT;
        TAO_YY_BREAK
case 26:
TAO_YY_RULE_SETUP
return IDL_UNSIGNED;
        TAO_YY_BREAK
case 27:
TAO_YY_RULE_SETUP
return IDL_CHAR;
        TAO_YY_BREAK
case 28:
TAO_YY_RULE_SETUP
return IDL_WCHAR;
        TAO_YY_BREAK
case 29:
TAO_YY_RULE_SETUP
return IDL_BOOLEAN;
        TAO_YY_BREAK
case 30:
TAO_YY_RULE_SETUP
return IDL_OCTET;
        TAO_YY_BREAK
case 31:
TAO_YY_RULE_SETUP
return IDL_VOID;
        TAO_YY_BREAK
case 32:
TAO_YY_RULE_SETUP
return IDL_NATIVE;
        TAO_YY_BREAK
case 33:
TAO_YY_RULE_SETUP
return IDL_LOCAL;
        TAO_YY_BREAK
case 34:
TAO_YY_RULE_SETUP
return IDL_ABSTRACT;
        TAO_YY_BREAK
case 35:
TAO_YY_RULE_SETUP
return IDL_CUSTOM;
        TAO_YY_BREAK
case 36:
TAO_YY_RULE_SETUP
return IDL_FACTORY;
        TAO_YY_BREAK
case 37:
TAO_YY_RULE_SETUP
return IDL_PRIVATE;
        TAO_YY_BREAK
case 38:
TAO_YY_RULE_SETUP
return IDL_PUBLIC;
        TAO_YY_BREAK
case 39:
TAO_YY_RULE_SETUP
return IDL_SUPPORTS;
        TAO_YY_BREAK
case 40:
TAO_YY_RULE_SETUP
return IDL_TRUNCATABLE;
        TAO_YY_BREAK
case 41:
TAO_YY_RULE_SETUP
return IDL_VALUETYPE;
        TAO_YY_BREAK
case 42:
TAO_YY_RULE_SETUP
return IDL_COMPONENT;
        TAO_YY_BREAK
case 43:
TAO_YY_RULE_SETUP
return IDL_CONSUMES;
        TAO_YY_BREAK
case 44:
TAO_YY_RULE_SETUP
return IDL_EMITS;
        TAO_YY_BREAK
case 45:
TAO_YY_RULE_SETUP
return IDL_EVENTTYPE;
        TAO_YY_BREAK
case 46:
TAO_YY_RULE_SETUP
return IDL_FINDER;
        TAO_YY_BREAK
case 47:
TAO_YY_RULE_SETUP
return IDL_GETRAISES;
        TAO_YY_BREAK
case 48:
TAO_YY_RULE_SETUP
return IDL_HOME;
        TAO_YY_BREAK
case 49:
TAO_YY_RULE_SETUP
return IDL_IMPORT;
        TAO_YY_BREAK
case 50:
TAO_YY_RULE_SETUP
return IDL_MULTIPLE;
        TAO_YY_BREAK
case 51:
TAO_YY_RULE_SETUP
return IDL_PRIMARYKEY;
        TAO_YY_BREAK
case 52:
TAO_YY_RULE_SETUP
return IDL_PROVIDES;
        TAO_YY_BREAK
case 53:
TAO_YY_RULE_SETUP
return IDL_PUBLISHES;
        TAO_YY_BREAK
case 54:
TAO_YY_RULE_SETUP
return IDL_SETRAISES;
        TAO_YY_BREAK
case 55:
TAO_YY_RULE_SETUP
return IDL_TYPEID;
        TAO_YY_BREAK
case 56:
TAO_YY_RULE_SETUP
return IDL_TYPEPREFIX;
        TAO_YY_BREAK
case 57:
TAO_YY_RULE_SETUP
return IDL_USES;
        TAO_YY_BREAK
case 58:
TAO_YY_RULE_SETUP
return IDL_MANAGES;
        TAO_YY_BREAK
case 59:
TAO_YY_RULE_SETUP
return IDL_TYPENAME;
        TAO_YY_BREAK
case 60:
TAO_YY_RULE_SETUP
return IDL_PORT;
        TAO_YY_BREAK
case 61:
TAO_YY_RULE_SETUP
return IDL_MIRRORPORT;
        TAO_YY_BREAK
case 62:
TAO_YY_RULE_SETUP
return IDL_PORTTYPE;
        TAO_YY_BREAK
case 63:
TAO_YY_RULE_SETUP
return IDL_CONNECTOR;
        TAO_YY_BREAK
case 64:
TAO_YY_RULE_SETUP
return IDL_ALIAS;
        TAO_YY_BREAK
case 65:
TAO_YY_RULE_SETUP
return IDL_TRUETOK;
        TAO_YY_BREAK
case 66:
TAO_YY_RULE_SETUP
return IDL_FALSETOK;
        TAO_YY_BREAK
case 67:
TAO_YY_RULE_SETUP
return IDL_INOUT;
        TAO_YY_BREAK
case 68:
TAO_YY_RULE_SETUP
return IDL_IN;
        TAO_YY_BREAK
case 69:
TAO_YY_RULE_SETUP
return IDL_OUT;
        TAO_YY_BREAK
case 70:
TAO_YY_RULE_SETUP
return IDL_ONEWAY;
        TAO_YY_BREAK
case 71:
TAO_YY_RULE_SETUP
return IDL_LEFT_SHIFT;
        TAO_YY_BREAK
case 72:
TAO_YY_RULE_SETUP
return IDL_RIGHT_SHIFT;
        TAO_YY_BREAK
case 73:
TAO_YY_RULE_SETUP
{
                  tao_yylval.strval = ACE::strnew ("::");
                  return IDL_SCOPE_DELIMITOR;
                }
        TAO_YY_BREAK
case 74:
TAO_YY_RULE_SETUP
{
  // Make sure that this identifier is not a C++ keyword. If it is,
  // prepend it with a _cxx_. Lookup in the perfect hash table for C++
  // keyword and grab the mapping.  BTW, the reason for the odd
  // regular expression is to handle EBCDIC, as well as ASCII.

  TAO_IDL_CPP_Keyword_Table cpp_key_tbl;
  const TAO_IDL_CPP_Keyword_Entry *entry = 0;
  if (!idl_global->preserve_cpp_keywords())
    {
      // This check will ensure that escaped C++ keywords will be
      // caught and prepended with '_cxx' as non-escaped keywords
      // are now prepended with '_cxx_'.
      const char *tmp =
        ace_tao_yytext[0] == '_' ? ace_tao_yytext + 1 : ace_tao_yytext;

      entry =
        cpp_key_tbl.lookup (tmp,
                            static_cast<unsigned int> (ACE_OS::strlen (tmp)));
    }

  if (entry)
    {
      tao_yylval.strval = ACE::strnew (entry->mapping_);
    }
  else
    {
      tao_yylval.strval = ACE::strnew (ace_tao_yytext);
    }

  return IDENTIFIER;
}
        TAO_YY_BREAK
case 75:
TAO_YY_RULE_SETUP
{
                  tao_yylval.dval = idl_atof (ace_tao_yytext);
                  return IDL_FLOATING_PT_LITERAL;
                }
        TAO_YY_BREAK
case 76:
TAO_YY_RULE_SETUP
{
                  tao_yylval.dval = idl_atof (ace_tao_yytext);
                  return IDL_FLOATING_PT_LITERAL;
                }
        TAO_YY_BREAK
case 77:
TAO_YY_RULE_SETUP
{
                  tao_yylval.ival = idl_atoi (ace_tao_yytext, 10);
                  return IDL_INTEGER_LITERAL;
                }
        TAO_YY_BREAK
case 78:
TAO_YY_RULE_SETUP
{
                  tao_yylval.uival = idl_atoui (ace_tao_yytext, 10);
                  return IDL_UINTEGER_LITERAL;
                }
        TAO_YY_BREAK
case 79:
TAO_YY_RULE_SETUP
{
                  tao_yylval.ival = idl_atoi (ace_tao_yytext, 16);
                  return IDL_INTEGER_LITERAL;
                }
        TAO_YY_BREAK
case 80:
TAO_YY_RULE_SETUP
{
                  tao_yylval.uival = idl_atoui (ace_tao_yytext, 16);
                  return IDL_UINTEGER_LITERAL;
                }
        TAO_YY_BREAK
case 81:
TAO_YY_RULE_SETUP
{
                  tao_yylval.ival = idl_atoi (ace_tao_yytext, 8);
                  return IDL_INTEGER_LITERAL;
                }
        TAO_YY_BREAK
case 82:
TAO_YY_RULE_SETUP
{
                  tao_yylval.uival = idl_atoui (ace_tao_yytext, 8);
                  return IDL_UINTEGER_LITERAL;
                }
        TAO_YY_BREAK
case 83:
/* rule 83 can match eol */
TAO_YY_RULE_SETUP
{
                  /* Skip the quotes */
                  char * const tmp = ace_tao_yytext;
                  for(size_t i = ACE_OS::strlen (tmp); i-- != 0; ) {
                    if (isspace(tmp[i])) {
                      tmp[i] = '\0';
                    }
                    else {
                      break;
                    }
                  }
                  tmp[ACE_OS::strlen (tmp) - 1] = '\0';
                  ACE_NEW_RETURN (tao_yylval.sval,
                                  UTL_String (tmp + 1, true),
                                  IDL_STRING_LITERAL);
                  return IDL_STRING_LITERAL;
                }
        TAO_YY_BREAK
case 84:
/* rule 84 can match eol */
TAO_YY_RULE_SETUP
{
                  /* Skip the bookends */
                  char * const tmp = ACE_OS::strdup (ace_tao_yytext);
                  for(size_t i = ACE_OS::strlen (tmp); i-- != 0; ) {
                    if (isspace(tmp[i])) {
                      tmp[i] = '\0';
                    }
                    else {
                      break;
                    }
                  }
                  tmp[ACE_OS::strlen (tmp) - 1] = '\0';
                  tao_yylval.wsval = idl_wstring_escape_reader(tmp + 2);
                  return IDL_WSTRING_LITERAL;
                }
        TAO_YY_BREAK
case 85:
TAO_YY_RULE_SETUP
{
                  tao_yylval.cval = ace_tao_yytext [1];
                  return IDL_CHARACTER_LITERAL;
                }
        TAO_YY_BREAK
case 86:
TAO_YY_RULE_SETUP
{
                  // octal character constant
                  tao_yylval.cval = idl_escape_reader (ace_tao_yytext + 1);
                  return IDL_CHARACTER_LITERAL;
                }
        TAO_YY_BREAK
case 87:
TAO_YY_RULE_SETUP
{
                  // hexadecimal character constant
                  tao_yylval.cval = idl_escape_reader (ace_tao_yytext + 1);
                  return IDL_CHARACTER_LITERAL;
                }
        TAO_YY_BREAK
case 88:
TAO_YY_RULE_SETUP
{
                  tao_yylval.cval = idl_escape_reader (ace_tao_yytext + 1);
                  return IDL_CHARACTER_LITERAL;
                }
        TAO_YY_BREAK
case 89:
TAO_YY_RULE_SETUP
{
                  // wide character constant
                  tao_yylval.wcval = ace_tao_yytext [2];
                  return IDL_WCHAR_LITERAL;
                }
        TAO_YY_BREAK
case 90:
TAO_YY_RULE_SETUP
{
                  // hexadecimal wide character constant
                  tao_yylval.wcval = idl_wchar_escape_reader(ace_tao_yytext + 2);
                  return IDL_WCHAR_LITERAL;
                }
        TAO_YY_BREAK
case 91:
/* rule 91 can match eol */
case 92:
/* rule 92 can match eol */
TAO_YY_RULE_SETUP
{/* remember pragma */
                  idl_global->set_lineno(idl_global->lineno() + 1);
                  idl_store_pragma(ace_tao_yytext);
                }
         break;
case 93:
/* rule 93 can match eol */
case 94:
/* rule 94 can match eol */
TAO_YY_RULE_SETUP
{/* ignore file */
                  idl_global->set_lineno(idl_global->lineno() + 1);
                }
         break;
case 95:
/* rule 95 can match eol */
case 96:
/* rule 96 can match eol */
TAO_YY_RULE_SETUP
{
                  idl_parse_line_and_file(ace_tao_yytext);
                }
         break;
case 97:
/* rule 97 can match eol */
case 98:
/* rule 98 can match eol */
TAO_YY_RULE_SETUP
{
                  idl_parse_line_and_file(ace_tao_yytext);
                }
         break;
case 99:
/* rule 99 can match eol */
case 100:
/* rule 100 can match eol */
TAO_YY_RULE_SETUP
{
                  idl_parse_line_and_file(ace_tao_yytext);
                }
         break;
case 101:
/* rule 101 can match eol */
case 102:
/* rule 102 can match eol */
TAO_YY_RULE_SETUP
{
                  idl_parse_line_and_file(ace_tao_yytext);
                }
         break;
case 103:
/* rule 103 can match eol */
case 104:
/* rule 104 can match eol */
TAO_YY_RULE_SETUP
{
                  /* ignore cpp ident */
                  idl_global->set_lineno(idl_global->lineno() + 1);
                }
         break;
case 105:
/* rule 105 can match eol */
TAO_YY_RULE_SETUP
{
                  /* ignore comments */
                  idl_global->set_lineno(idl_global->lineno() + 1);
                }
         break;
case 106:
TAO_YY_RULE_SETUP
{
                  for(;;) {
                    char const c = tao_yyinput();
                    if (c == '*') {
                      char const next = tao_yyinput();
                      if (next == '/')
                        break;
                      else
                        tao_yyunput(c, 0);
                    }
                    else if (c == '\n') {
                      idl_global->set_lineno(idl_global->lineno() + 1);
                    }
                  }
                }
        break;
case 107:
TAO_YY_RULE_SETUP
;
         break;
case 108:
/* rule 108 can match eol */
TAO_YY_RULE_SETUP
{
                  idl_global->set_lineno(idl_global->lineno() + 1);
                }
         break;
case 109:
TAO_YY_RULE_SETUP
return ace_tao_yytext [0];
        TAO_YY_BREAK
case 110:
TAO_YY_RULE_SETUP
TAO_YY_ECHO;
         break;
case TAO_YY_STATE_EOF(INITIAL):
        tao_yyterminate();

        case TAO_YY_END_OF_BUFFER:
                {
                /* Amount of text matched not including the EOB char. */
                int tao_yy_amount_of_matched_text = (int) (tao_yy_cp - (tao_yytext_ptr)) - 1;

                /* Undo the effects of TAO_YY_DO_BEFORE_ACTION. */
                *tao_yy_cp = (tao_yy_hold_char);
                TAO_YY_RESTORE_TAO_YY_MORE_OFFSET

                if ( TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buffer_status == TAO_YY_BUFFER_NEW )
                        {
                        /* We're scanning a new file or input source.  It's
                         * possible that this happened because the user
                         * just pointed tao_yyin at a new source and called
                         * tao_yylex().  If so, then we have to assure
                         * consistency between TAO_YY_CURRENT_BUFFER and our
                         * globals.  Here is the right place to do so, because
                         * this is the first action (other than possibly a
                         * back-up) that will match for the new input source.
                         */
                        (tao_yy_n_chars) = TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_n_chars;
                        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_input_file = tao_yyin;
                        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buffer_status = TAO_YY_BUFFER_NORMAL;
                        }

                /* Note that here we test for tao_yy_c_buf_p "<=" to the position
                 * of the first EOB in the buffer, since tao_yy_c_buf_p will
                 * already have been incremented past the NUL character
                 * (since all states make transitions on EOB to the
                 * end-of-buffer state).  Contrast this with the test
                 * in input().
                 */
                if ( (tao_yy_c_buf_p) <= &TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[(tao_yy_n_chars)] )
                        { /* This was really a NUL. */
                        tao_yy_state_type tao_yy_next_state;

                        (tao_yy_c_buf_p) = (tao_yytext_ptr) + tao_yy_amount_of_matched_text;

                        tao_yy_current_state = tao_yy_get_previous_state(  );

                        /* Okay, we're now positioned to make the NUL
                         * transition.  We couldn't have
                         * tao_yy_get_previous_state() go ahead and do it
                         * for us because it doesn't know how to deal
                         * with the possibility of jamming (and we don't
                         * want to build jamming into it because then it
                         * will run more slowly).
                         */

                        tao_yy_next_state = tao_yy_try_NUL_trans( tao_yy_current_state );

                        tao_yy_bp = (tao_yytext_ptr) + TAO_YY_MORE_ADJ;

                        if ( tao_yy_next_state )
                                {
                                /* Consume the NUL. */
                                tao_yy_cp = ++(tao_yy_c_buf_p);
                                tao_yy_current_state = tao_yy_next_state;
                                goto tao_yy_match;
                                }

                        else
                                {
                                tao_yy_cp = (tao_yy_last_accepting_cpos);
                                tao_yy_current_state = (tao_yy_last_accepting_state);
                                goto tao_yy_find_action;
                                }
                        }

                else switch ( tao_yy_get_next_buffer(  ) )
                        {
                        case EOB_ACT_END_OF_FILE:
                                {
                                (tao_yy_did_buffer_switch_on_eof) = 0;

                                if ( tao_yywrap( ) )
                                        {
                                        /* Note: because we've taken care in
                                         * tao_yy_get_next_buffer() to have set up
                                         * tao_yytext, we can now set up
                                         * tao_yy_c_buf_p so that if some total
                                         * hoser (like flex itself) wants to
                                         * call the scanner after we return the
                                         * TAO_YY_NULL, it'll still work - another
                                         * TAO_YY_NULL will get returned.
                                         */
                                        (tao_yy_c_buf_p) = (tao_yytext_ptr) + TAO_YY_MORE_ADJ;

                                        tao_yy_act = TAO_YY_STATE_EOF(TAO_YY_START);
                                        goto do_action;
                                        }

                                else
                                        {
                                        if ( ! (tao_yy_did_buffer_switch_on_eof) )
                                                TAO_YY_NEW_FILE;
                                        }
                                break;
                                }

                        case EOB_ACT_CONTINUE_SCAN:
                                (tao_yy_c_buf_p) =
                                        (tao_yytext_ptr) + tao_yy_amount_of_matched_text;

                                tao_yy_current_state = tao_yy_get_previous_state(  );

                                tao_yy_cp = (tao_yy_c_buf_p);
                                tao_yy_bp = (tao_yytext_ptr) + TAO_YY_MORE_ADJ;
                                goto tao_yy_match;

                        case EOB_ACT_LAST_MATCH:
                                (tao_yy_c_buf_p) =
                                &TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[(tao_yy_n_chars)];

                                tao_yy_current_state = tao_yy_get_previous_state(  );

                                tao_yy_cp = (tao_yy_c_buf_p);
                                tao_yy_bp = (tao_yytext_ptr) + TAO_YY_MORE_ADJ;
                                goto tao_yy_find_action;
                        }
                break;
                }

        default:
                TAO_YY_FATAL_ERROR(
                        "fatal flex scanner internal error--no action found" );
        } /* end of action switch */
                } /* end of scanning one token */
} /* end of tao_yylex */

/* tao_yy_get_next_buffer - try to read in a new buffer
 *
 * Returns a code representing an action:
 *        EOB_ACT_LAST_MATCH -
 *        EOB_ACT_CONTINUE_SCAN - continue scanning from current position
 *        EOB_ACT_END_OF_FILE - end of file
 */
static int tao_yy_get_next_buffer (void)
{
            register char *dest = TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf;
        register char *source = (tao_yytext_ptr);
        register int number_to_move, i;
        int ret_val;

        if ( (tao_yy_c_buf_p) > &TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[(tao_yy_n_chars) + 1] )
                TAO_YY_FATAL_ERROR(
                "fatal flex scanner internal error--end of buffer missed" );

        if ( TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_fill_buffer == 0 )
                { /* Don't try to fill the buffer, so this is an EOF. */
                if ( (tao_yy_c_buf_p) - (tao_yytext_ptr) - TAO_YY_MORE_ADJ == 1 )
                        {
                        /* We matched a single character, the EOB, so
                         * treat this as a final EOF.
                         */
                        return EOB_ACT_END_OF_FILE;
                        }

                else
                        {
                        /* We matched some text prior to the EOB, first
                         * process it.
                         */
                        return EOB_ACT_LAST_MATCH;
                        }
                }

        /* Try to read more data. */

        /* First move last chars to start of buffer. */
        number_to_move = (int) ((tao_yy_c_buf_p) - (tao_yytext_ptr)) - 1;

        for ( i = 0; i < number_to_move; ++i )
                *(dest++) = *(source++);

        if ( TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buffer_status == TAO_YY_BUFFER_EOF_PENDING )
                /* don't do the read, it's not guaranteed to return an EOF,
                 * just force an EOF
                 */
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_n_chars = (tao_yy_n_chars) = 0;

        else
                {
                        int num_to_read =
                        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_size - number_to_move - 1;

                while ( num_to_read <= 0 )
                        { /* Not enough room in the buffer - grow it. */

                        /* just a shorter name for the current buffer */
                        TAO_YY_BUFFER_STATE b = TAO_YY_CURRENT_BUFFER;

                        int tao_yy_c_buf_p_offset =
                                (int) ((tao_yy_c_buf_p) - b->tao_yy_ch_buf);

                        if ( b->tao_yy_is_our_buffer )
                                {
                                int new_size = b->tao_yy_buf_size * 2;

                                if ( new_size <= 0 )
                                        b->tao_yy_buf_size += b->tao_yy_buf_size / 8;
                                else
                                        b->tao_yy_buf_size *= 2;

                                b->tao_yy_ch_buf = (char *)
                                        /* Include room in for 2 EOB chars. */
                                        tao_yyrealloc((void *) b->tao_yy_ch_buf,b->tao_yy_buf_size + 2  );
                                }
                        else
                                /* Can't grow it, we don't own it. */
                                b->tao_yy_ch_buf = 0;

                        if ( ! b->tao_yy_ch_buf )
                                TAO_YY_FATAL_ERROR(
                                "fatal error - scanner input buffer overflow" );

                        (tao_yy_c_buf_p) = &b->tao_yy_ch_buf[tao_yy_c_buf_p_offset];

                        num_to_read = TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_size -
                                                number_to_move - 1;

                        }

                if ( num_to_read > TAO_YY_READ_BUF_SIZE )
                        num_to_read = TAO_YY_READ_BUF_SIZE;

                /* Read in more data. */
                TAO_YY_INPUT( (&TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[number_to_move]),
                        (tao_yy_n_chars), (size_t) num_to_read );

                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_n_chars = (tao_yy_n_chars);
                }

        if ( (tao_yy_n_chars) == 0 )
                {
                if ( number_to_move == TAO_YY_MORE_ADJ )
                        {
                        ret_val = EOB_ACT_END_OF_FILE;
                        tao_yyrestart(tao_yyin  );
                        }

                else
                        {
                        ret_val = EOB_ACT_LAST_MATCH;
                        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buffer_status =
                                TAO_YY_BUFFER_EOF_PENDING;
                        }
                }

        else
                ret_val = EOB_ACT_CONTINUE_SCAN;

        if ((tao_yy_size_t) ((tao_yy_n_chars) + number_to_move) > TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_size) {
                /* Extend the array by 50%, plus the number we really need. */
                tao_yy_size_t new_size = (tao_yy_n_chars) + number_to_move + ((tao_yy_n_chars) >> 1);
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf = (char *) tao_yyrealloc((void *) TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf,new_size  );
                if ( ! TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf )
                        TAO_YY_FATAL_ERROR( "out of dynamic memory in tao_yy_get_next_buffer()" );
        }

        (tao_yy_n_chars) += number_to_move;
        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[(tao_yy_n_chars)] = TAO_YY_END_OF_BUFFER_CHAR;
        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[(tao_yy_n_chars) + 1] = TAO_YY_END_OF_BUFFER_CHAR;

        (tao_yytext_ptr) = &TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[0];

        return ret_val;
}

/* tao_yy_get_previous_state - get the state just before the EOB char was reached */

    static tao_yy_state_type tao_yy_get_previous_state (void)
{
        register tao_yy_state_type tao_yy_current_state;
        register char *tao_yy_cp;

        tao_yy_current_state = (tao_yy_start);
        tao_yy_current_state += TAO_YY_AT_BOL();

        for ( tao_yy_cp = (tao_yytext_ptr) + TAO_YY_MORE_ADJ; tao_yy_cp < (tao_yy_c_buf_p); ++tao_yy_cp )
                {
                register TAO_YY_CHAR tao_yy_c = (*tao_yy_cp ? tao_yy_ec[TAO_YY_SC_TO_UI(*tao_yy_cp)] : 1);
                if ( tao_yy_accept[tao_yy_current_state] )
                        {
                        (tao_yy_last_accepting_state) = tao_yy_current_state;
                        (tao_yy_last_accepting_cpos) = tao_yy_cp;
                        }
                while ( tao_yy_chk[tao_yy_base[tao_yy_current_state] + tao_yy_c] != tao_yy_current_state )
                        {
                        tao_yy_current_state = (int) tao_yy_def[tao_yy_current_state];
                        if ( tao_yy_current_state >= 592 )
                                tao_yy_c = tao_yy_meta[(unsigned int) tao_yy_c];
                        }
                tao_yy_current_state = tao_yy_nxt[tao_yy_base[tao_yy_current_state] + (unsigned int) tao_yy_c];
                }

        return tao_yy_current_state;
}

/* tao_yy_try_NUL_trans - try to make a transition on the NUL character
 *
 * synopsis
 *        next_state = tao_yy_try_NUL_trans( current_state );
 */
    static tao_yy_state_type tao_yy_try_NUL_trans  (tao_yy_state_type tao_yy_current_state )
{
        register int tao_yy_is_jam;
            register char *tao_yy_cp = (tao_yy_c_buf_p);

        register TAO_YY_CHAR tao_yy_c = 1;
        if ( tao_yy_accept[tao_yy_current_state] )
                {
                (tao_yy_last_accepting_state) = tao_yy_current_state;
                (tao_yy_last_accepting_cpos) = tao_yy_cp;
                }
        while ( tao_yy_chk[tao_yy_base[tao_yy_current_state] + tao_yy_c] != tao_yy_current_state )
                {
                tao_yy_current_state = (int) tao_yy_def[tao_yy_current_state];
                if ( tao_yy_current_state >= 592 )
                        tao_yy_c = tao_yy_meta[(unsigned int) tao_yy_c];
                }
        tao_yy_current_state = tao_yy_nxt[tao_yy_base[tao_yy_current_state] + (unsigned int) tao_yy_c];
        tao_yy_is_jam = (tao_yy_current_state == 591);

        return tao_yy_is_jam ? 0 : tao_yy_current_state;
}

    static void tao_yyunput (int c, register char * tao_yy_bp )
{
        register char *tao_yy_cp;

    tao_yy_cp = (tao_yy_c_buf_p);

        /* undo effects of setting up tao_yytext */
        *tao_yy_cp = (tao_yy_hold_char);

        if ( tao_yy_cp < TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf + 2 )
                { /* need to shift things up to make room */
                /* +2 for EOB chars. */
                register int number_to_move = (tao_yy_n_chars) + 2;
                register char *dest = &TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[
                                        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_size + 2];
                register char *source =
                                &TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[number_to_move];

                while ( source > TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf )
                        *--dest = *--source;

                tao_yy_cp += (int) (dest - source);
                tao_yy_bp += (int) (dest - source);
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_n_chars =
                        (tao_yy_n_chars) = TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_size;

                if ( tao_yy_cp < TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf + 2 )
                        TAO_YY_FATAL_ERROR( "flex scanner push-back overflow" );
                }

        *--tao_yy_cp = (char) c;

        (tao_yytext_ptr) = tao_yy_bp;
        (tao_yy_hold_char) = *tao_yy_cp;
        (tao_yy_c_buf_p) = tao_yy_cp;
}

#ifndef TAO_YY_NO_INPUT
#ifdef __cplusplus
    static int tao_yyinput (void)
#else
    static int input  (void)
#endif

{
        int c;

        *(tao_yy_c_buf_p) = (tao_yy_hold_char);

        if ( *(tao_yy_c_buf_p) == TAO_YY_END_OF_BUFFER_CHAR )
                {
                /* tao_yy_c_buf_p now points to the character we want to return.
                 * If this occurs *before* the EOB characters, then it's a
                 * valid NUL; if not, then we've hit the end of the buffer.
                 */
                if ( (tao_yy_c_buf_p) < &TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_ch_buf[(tao_yy_n_chars)] )
                        /* This was really a NUL. */
                        *(tao_yy_c_buf_p) = '\0';

                else
                        { /* need more input */
                        int offset = (tao_yy_c_buf_p) - (tao_yytext_ptr);
                        ++(tao_yy_c_buf_p);

                        switch ( tao_yy_get_next_buffer(  ) )
                                {
                                case EOB_ACT_LAST_MATCH:
                                        /* This happens because tao_yy_g_n_b()
                                         * sees that we've accumulated a
                                         * token and flags that we need to
                                         * try matching the token before
                                         * proceeding.  But for input(),
                                         * there's no matching to consider.
                                         * So convert the EOB_ACT_LAST_MATCH
                                         * to EOB_ACT_END_OF_FILE.
                                         */

                                        /* Reset buffer status. */
                                        tao_yyrestart(tao_yyin );

                                        /*FALLTHROUGH*/

                                case EOB_ACT_END_OF_FILE:
                                        {
                                        if ( tao_yywrap( ) )
                                                return EOF;

                                        if ( ! (tao_yy_did_buffer_switch_on_eof) )
                                                TAO_YY_NEW_FILE;
#ifdef __cplusplus
                                        return tao_yyinput();
#else
                                        return input();
#endif
                                        }

                                case EOB_ACT_CONTINUE_SCAN:
                                        (tao_yy_c_buf_p) = (tao_yytext_ptr) + offset;
                                        break;
                                }
                        }
                }

        c = *(unsigned char *) (tao_yy_c_buf_p);        /* cast for 8-bit char's */
        *(tao_yy_c_buf_p) = '\0';        /* preserve tao_yytext */
        (tao_yy_hold_char) = *++(tao_yy_c_buf_p);

        TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_at_bol = (c == '\n');

        return c;
}
#endif        /* ifndef TAO_YY_NO_INPUT */

/** Immediately switch to a different input stream.
 * @param input_file A readable stream.
 *
 * @note This function does not reset the start condition to @c INITIAL .
 */
    void tao_yyrestart  (FILE * input_file )
{

        if ( ! TAO_YY_CURRENT_BUFFER ){
        tao_yyensure_buffer_stack ();
                TAO_YY_CURRENT_BUFFER_LVALUE =
            tao_yy_create_buffer(tao_yyin,TAO_YY_BUF_SIZE );
        }

        tao_yy_init_buffer(TAO_YY_CURRENT_BUFFER,input_file );
        tao_yy_load_buffer_state( );
}

/** Switch to a different input buffer.
 * @param new_buffer The new input buffer.
 *
 */
    void tao_yy_switch_to_buffer  (TAO_YY_BUFFER_STATE  new_buffer )
{

        /* TODO. We should be able to replace this entire function body
         * with
         *                tao_yypop_buffer_state();
         *                tao_yypush_buffer_state(new_buffer);
     */
        tao_yyensure_buffer_stack ();
        if ( TAO_YY_CURRENT_BUFFER == new_buffer )
                return;

        if ( TAO_YY_CURRENT_BUFFER )
                {
                /* Flush out information for old buffer. */
                *(tao_yy_c_buf_p) = (tao_yy_hold_char);
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_pos = (tao_yy_c_buf_p);
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_n_chars = (tao_yy_n_chars);
                }

        TAO_YY_CURRENT_BUFFER_LVALUE = new_buffer;
        tao_yy_load_buffer_state( );

        /* We don't actually know whether we did this switch during
         * EOF (tao_yywrap()) processing, but the only time this flag
         * is looked at is after tao_yywrap() is called, so it's safe
         * to go ahead and always set it.
         */
        (tao_yy_did_buffer_switch_on_eof) = 1;
}

static void tao_yy_load_buffer_state  (void)
{
            (tao_yy_n_chars) = TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_n_chars;
        (tao_yytext_ptr) = (tao_yy_c_buf_p) = TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_pos;
        tao_yyin = TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_input_file;
        (tao_yy_hold_char) = *(tao_yy_c_buf_p);
}

/** Allocate and initialize an input buffer state.
 * @param file A readable stream.
 * @param size The character buffer size in bytes. When in doubt, use @c TAO_YY_BUF_SIZE.
 *
 * @return the allocated buffer state.
 */
    TAO_YY_BUFFER_STATE tao_yy_create_buffer  (FILE * file, int  size )
{
        TAO_YY_BUFFER_STATE b;

        b = (TAO_YY_BUFFER_STATE) tao_yyalloc(sizeof( struct tao_yy_buffer_state )  );
        if ( ! b )
                TAO_YY_FATAL_ERROR( "out of dynamic memory in tao_yy_create_buffer()" );

        b->tao_yy_buf_size = size;

        /* tao_yy_ch_buf has to be 2 characters longer than the size given because
         * we need to put in 2 end-of-buffer characters.
         */
        b->tao_yy_ch_buf = (char *) tao_yyalloc(b->tao_yy_buf_size + 2  );
        if ( ! b->tao_yy_ch_buf )
                TAO_YY_FATAL_ERROR( "out of dynamic memory in tao_yy_create_buffer()" );

        b->tao_yy_is_our_buffer = 1;

        tao_yy_init_buffer(b,file );

        return b;
}

/** Destroy the buffer.
 * @param b a buffer created with tao_yy_create_buffer()
 *
 */
    void tao_yy_delete_buffer (TAO_YY_BUFFER_STATE  b )
{

        if ( ! b )
                return;

        if ( b == TAO_YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
                TAO_YY_CURRENT_BUFFER_LVALUE = (TAO_YY_BUFFER_STATE) 0;

        if ( b->tao_yy_is_our_buffer )
                tao_yyfree((void *) b->tao_yy_ch_buf  );

        tao_yyfree((void *) b  );
}

/* Initializes or reinitializes a buffer.
 * This function is sometimes called more than once on the same buffer,
 * such as during a tao_yyrestart() or at EOF.
 */
    static void tao_yy_init_buffer  (TAO_YY_BUFFER_STATE  b, FILE * file )

{
        int oerrno = errno;

        tao_yy_flush_buffer(b );

        b->tao_yy_input_file = file;
        b->tao_yy_fill_buffer = 1;

    /* If b is the current buffer, then tao_yy_init_buffer was _probably_
     * called from tao_yyrestart() or through tao_yy_get_next_buffer.
     * In that case, we don't want to reset the lineno or column.
     */
    if (b != TAO_YY_CURRENT_BUFFER){
        b->tao_yy_bs_lineno = 1;
        b->tao_yy_bs_column = 0;
    }

        b->tao_yy_is_interactive = 0;

        errno = oerrno;
}

/** Discard all buffered characters. On the next scan, TAO_YY_INPUT will be called.
 * @param b the buffer state to be flushed, usually @c TAO_YY_CURRENT_BUFFER.
 *
 */
    void tao_yy_flush_buffer (TAO_YY_BUFFER_STATE  b )
{
            if ( ! b )
                return;

        b->tao_yy_n_chars = 0;

        /* We always need two end-of-buffer characters.  The first causes
         * a transition to the end-of-buffer state.  The second causes
         * a jam in that state.
         */
        b->tao_yy_ch_buf[0] = TAO_YY_END_OF_BUFFER_CHAR;
        b->tao_yy_ch_buf[1] = TAO_YY_END_OF_BUFFER_CHAR;

        b->tao_yy_buf_pos = &b->tao_yy_ch_buf[0];

        b->tao_yy_at_bol = 1;
        b->tao_yy_buffer_status = TAO_YY_BUFFER_NEW;

        if ( b == TAO_YY_CURRENT_BUFFER )
                tao_yy_load_buffer_state( );
}

/** Pushes the new state onto the stack. The new state becomes
 *  the current state. This function will allocate the stack
 *  if necessary.
 *  @param new_buffer The new state.
 *
 */
void tao_yypush_buffer_state (TAO_YY_BUFFER_STATE new_buffer )
{
            if (new_buffer == 0)
                return;

        tao_yyensure_buffer_stack();

        /* This block is copied from tao_yy_switch_to_buffer. */
        if ( TAO_YY_CURRENT_BUFFER )
                {
                /* Flush out information for old buffer. */
                *(tao_yy_c_buf_p) = (tao_yy_hold_char);
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_buf_pos = (tao_yy_c_buf_p);
                TAO_YY_CURRENT_BUFFER_LVALUE->tao_yy_n_chars = (tao_yy_n_chars);
                }

        /* Only push if top exists. Otherwise, replace top. */
        if (TAO_YY_CURRENT_BUFFER)
                (tao_yy_buffer_stack_top)++;
        TAO_YY_CURRENT_BUFFER_LVALUE = new_buffer;

        /* copied from tao_yy_switch_to_buffer. */
        tao_yy_load_buffer_state( );
        (tao_yy_did_buffer_switch_on_eof) = 1;
}

/** Removes and deletes the top of the stack, if present.
 *  The next element becomes the new top.
 *
 */
void tao_yypop_buffer_state (void)
{
            if (!TAO_YY_CURRENT_BUFFER)
                return;

        tao_yy_delete_buffer(TAO_YY_CURRENT_BUFFER );
        TAO_YY_CURRENT_BUFFER_LVALUE = 0;
        if ((tao_yy_buffer_stack_top) > 0)
                --(tao_yy_buffer_stack_top);

        if (TAO_YY_CURRENT_BUFFER) {
                tao_yy_load_buffer_state( );
                (tao_yy_did_buffer_switch_on_eof) = 1;
        }
}

/* Allocates the stack if it does not exist.
 *  Guarantees space for at least one push.
 */
static void tao_yyensure_buffer_stack (void)
{
        int num_to_alloc;

        if (!(tao_yy_buffer_stack)) {

                /* First allocation is just for 2 elements, since we don't know if this
                 * scanner will even need a stack. We use 2 instead of 1 to avoid an
                 * immediate realloc on the next call.
         */
                num_to_alloc = 1;
                (tao_yy_buffer_stack) = (struct tao_yy_buffer_state**)tao_yyalloc
                                                                (num_to_alloc * sizeof(struct tao_yy_buffer_state*)
                                                                );
                if ( ! (tao_yy_buffer_stack) )
                        TAO_YY_FATAL_ERROR( "out of dynamic memory in tao_yyensure_buffer_stack()" );

                memset((tao_yy_buffer_stack), 0, num_to_alloc * sizeof(struct tao_yy_buffer_state*));

                (tao_yy_buffer_stack_max) = num_to_alloc;
                (tao_yy_buffer_stack_top) = 0;
                return;
        }

        if ((tao_yy_buffer_stack_top) >= ((tao_yy_buffer_stack_max)) - 1){

                /* Increase the buffer to prepare for a possible push. */
                int grow_size = 8 /* arbitrary grow size */;

                num_to_alloc = (tao_yy_buffer_stack_max) + grow_size;
                (tao_yy_buffer_stack) = (struct tao_yy_buffer_state**)tao_yyrealloc
                                                                ((tao_yy_buffer_stack),
                                                                num_to_alloc * sizeof(struct tao_yy_buffer_state*)
                                                                );
                if ( ! (tao_yy_buffer_stack) )
                        TAO_YY_FATAL_ERROR( "out of dynamic memory in tao_yyensure_buffer_stack()" );

                /* zero only the new slots.*/
                memset((tao_yy_buffer_stack) + (tao_yy_buffer_stack_max), 0, grow_size * sizeof(struct tao_yy_buffer_state*));
                (tao_yy_buffer_stack_max) = num_to_alloc;
        }
}

/** Setup the input buffer state to scan directly from a user-specified character buffer.
 * @param base the character buffer
 * @param size the size in bytes of the character buffer
 *
 * @return the newly allocated buffer state object.
 */
TAO_YY_BUFFER_STATE tao_yy_scan_buffer  (char * base, tao_yy_size_t  size )
{
        TAO_YY_BUFFER_STATE b;

        if ( size < 2 ||
             base[size-2] != TAO_YY_END_OF_BUFFER_CHAR ||
             base[size-1] != TAO_YY_END_OF_BUFFER_CHAR )
                /* They forgot to leave room for the EOB's. */
                return 0;

        b = (TAO_YY_BUFFER_STATE) tao_yyalloc(sizeof( struct tao_yy_buffer_state )  );
        if ( ! b )
                TAO_YY_FATAL_ERROR( "out of dynamic memory in tao_yy_scan_buffer()" );

        b->tao_yy_buf_size = size - 2;        /* "- 2" to take care of EOB's */
        b->tao_yy_buf_pos = b->tao_yy_ch_buf = base;
        b->tao_yy_is_our_buffer = 0;
        b->tao_yy_input_file = 0;
        b->tao_yy_n_chars = b->tao_yy_buf_size;
        b->tao_yy_is_interactive = 0;
        b->tao_yy_at_bol = 1;
        b->tao_yy_fill_buffer = 0;
        b->tao_yy_buffer_status = TAO_YY_BUFFER_NEW;

        tao_yy_switch_to_buffer(b  );

        return b;
}

/** Setup the input buffer state to scan a string. The next call to tao_yylex() will
 * scan from a @e copy of @a str.
 * @param tao_yystr a NUL-terminated string to scan
 *
 * @return the newly allocated buffer state object.
 * @note If you want to scan bytes that may contain NUL values, then use
 *       tao_yy_scan_bytes() instead.
 */
TAO_YY_BUFFER_STATE tao_yy_scan_string (tao_yyconst char * tao_yystr )
{

        return tao_yy_scan_bytes(tao_yystr,strlen(tao_yystr) );
}

/** Setup the input buffer state to scan the given bytes. The next call to tao_yylex() will
 * scan from a @e copy of @a bytes.
 * @param bytes the byte buffer to scan
 * @param len the number of bytes in the buffer pointed to by @a bytes.
 *
 * @return the newly allocated buffer state object.
 */
TAO_YY_BUFFER_STATE tao_yy_scan_bytes  (tao_yyconst char * tao_yybytes, int  _tao_yybytes_len )
{
        TAO_YY_BUFFER_STATE b;
        char *buf;
        tao_yy_size_t n;
        int i;

        /* Get memory for full buffer, including space for trailing EOB's. */
        n = _tao_yybytes_len + 2;
        buf = (char *) tao_yyalloc(n  );
        if ( ! buf )
                TAO_YY_FATAL_ERROR( "out of dynamic memory in tao_yy_scan_bytes()" );

        for ( i = 0; i < _tao_yybytes_len; ++i )
                buf[i] = tao_yybytes[i];

        buf[_tao_yybytes_len] = buf[_tao_yybytes_len+1] = TAO_YY_END_OF_BUFFER_CHAR;

        b = tao_yy_scan_buffer(buf,n );
        if ( ! b )
                TAO_YY_FATAL_ERROR( "bad buffer in tao_yy_scan_bytes()" );

        /* It's okay to grow etc. this buffer, and we should throw it
         * away when we're done.
         */
        b->tao_yy_is_our_buffer = 1;

        return b;
}

#ifndef TAO_YY_EXIT_FAILURE
#define TAO_YY_EXIT_FAILURE 2
#endif

static void tao_yy_fatal_error (tao_yyconst char* msg )
{
            (void) fprintf( stderr, "%s\n", msg );
        exit( TAO_YY_EXIT_FAILURE );
}

/* Redefine tao_yyless() so it works in section 3 code. */

#undef tao_yyless
#define tao_yyless(n) \
        do \
                { \
                /* Undo effects of setting up tao_yytext. */ \
        int tao_yyless_macro_arg = (n); \
        TAO_YY_LESS_LINENO(tao_yyless_macro_arg);\
                tao_yytext[tao_yyleng] = (tao_yy_hold_char); \
                (tao_yy_c_buf_p) = tao_yytext + tao_yyless_macro_arg; \
                (tao_yy_hold_char) = *(tao_yy_c_buf_p); \
                *(tao_yy_c_buf_p) = '\0'; \
                tao_yyleng = tao_yyless_macro_arg; \
                } \
        while ( 0 )

/* Accessor  methods (get/set functions) to struct members. */

/** Get the current line number.
 *
 */
int tao_yyget_lineno  (void)
{

    return tao_yylineno;
}

/** Get the input stream.
 *
 */
FILE *tao_yyget_in  (void)
{
        return tao_yyin;
}

/** Get the output stream.
 *
 */
FILE *tao_yyget_out  (void)
{
        return tao_yyout;
}

/** Get the length of the current token.
 *
 */
int tao_yyget_leng  (void)
{
        return tao_yyleng;
}

/** Get the current token.
 *
 */

char *tao_yyget_text  (void)
{
        return tao_yytext;
}

/** Set the current line number.
 * @param line_number
 *
 */
void tao_yyset_lineno (int  line_number )
{

    tao_yylineno = line_number;
}

/** Set the input stream. This does not discard the current
 * input buffer.
 * @param in_str A readable stream.
 *
 * @see tao_yy_switch_to_buffer
 */
void tao_yyset_in (FILE *  in_str )
{
        tao_yyin = in_str ;
}

void tao_yyset_out (FILE *  out_str )
{
        tao_yyout = out_str ;
}

int tao_yyget_debug  (void)
{
        return tao_yy_flex_debug;
}

void tao_yyset_debug (int  bdebug )
{
        tao_yy_flex_debug = bdebug ;
}

static int tao_yy_init_globals (void)
{
        /* Initialization is the same as for the non-reentrant scanner.
     * This function is called from tao_yylex_destroy(), so don't allocate here.
     */

    (tao_yy_buffer_stack) = 0;
    (tao_yy_buffer_stack_top) = 0;
    (tao_yy_buffer_stack_max) = 0;
    (tao_yy_c_buf_p) = (char *) 0;
    (tao_yy_init) = 0;
    (tao_yy_start) = 0;

/* Defined in main.c */
#ifdef TAO_YY_STDINIT
    tao_yyin = stdin;
    tao_yyout = stdout;
#else
    tao_yyin = (FILE *) 0;
    tao_yyout = (FILE *) 0;
#endif

    /* For future reference: Set errno on error, since we are called by
     * tao_yylex_init()
     */
    return 0;
}

/* tao_yylex_destroy is for both reentrant and non-reentrant scanners. */
int tao_yylex_destroy  (void)
{

    /* Pop the buffer stack, destroying each element. */
        while(TAO_YY_CURRENT_BUFFER){
                tao_yy_delete_buffer(TAO_YY_CURRENT_BUFFER  );
                TAO_YY_CURRENT_BUFFER_LVALUE = 0;
                tao_yypop_buffer_state();
        }

        /* Destroy the stack itself. */
        tao_yyfree((tao_yy_buffer_stack) );
        (tao_yy_buffer_stack) = 0;

    /* Reset the globals. This is important in a non-reentrant scanner so the next time
     * tao_yylex() is called, initialization will occur. */
    tao_yy_init_globals( );

    return 0;
}

/*
 * Internal utility routines.
 */

#ifndef tao_yytext_ptr
static void tao_yy_flex_strncpy (char* s1, tao_yyconst char * s2, int n )
{
        register int i;
        for ( i = 0; i < n; ++i )
                s1[i] = s2[i];
}
#endif

#ifdef TAO_YY_NEED_STRLEN
static int tao_yy_flex_strlen (tao_yyconst char * s )
{
        register int n;
        for ( n = 0; s[n]; ++n )
                ;

        return n;
}
#endif

void *tao_yyalloc (tao_yy_size_t  size )
{
        return (void *) malloc( size );
}

void *tao_yyrealloc  (void * ptr, tao_yy_size_t  size )
{
        /* The cast to (char *) in the following accommodates both
         * implementations that use char* generic pointers, and those
         * that use void* generic pointers.  It works with the latter
         * because both ANSI C and C++ allow castless assignment from
         * any pointer type to void*, and deal with argument conversions
         * as though doing an assignment.
         */
        return (void *) realloc( (char *) ptr, size );
}

void tao_yyfree (void * ptr )
{
        free( (char *) ptr );        /* see tao_yyrealloc() for (char *) cast */
}

#define TAO_YYTABLES_NAME "tao_yytables"

        /* subroutines */

static bool
same_file (char *path1, char *path2)
{
  char fullpath1 [MAXPATHLEN + 1] = {0};
  char fullpath2 [MAXPATHLEN + 1] = {0};

  char * fp1 = ACE_OS::realpath(path1, fullpath1);
  char * fp2 = ACE_OS::realpath(path2, fullpath2);

  return
    (fp1 == 0 || fp2 == 0)
      ? false
      : FE_Utils::path_cmp (fullpath1,fullpath2) == 0;
}

// Parse a #line statement generated by the C preprocessor
static void
idl_parse_line_and_file (char *buf)
{
  char *r = buf;
  char *h = 0;
  UTL_String *nm = 0;

  // Skip initial '#'.
  if (*r != '#')
    {
      return;
    }
  else
    {
      r++;
    }

  // Check to see if we're running under the screwy Microsoft scheme
  // of putting #line num instead of #num.

  if (ACE_OS::strncmp (r, "line", 4) == 0)
    {
      r += 5;
    }

  // Find line number.
  while (isspace (*r))
    {
      r++;
    }

  h = r;

  for (; isdigit (*r); r++)
    {
      continue;
    }

  *r++ = 0;
  idl_global->set_lineno ((long) idl_atoui (h, 10));

  // Find file name, if present.
  for (; *r != '"'; r++)
    {
      if (*r == '\n' || *r == '\0')
        {
          return;
        }
    }

  h = ++r;

  for (; *r != '"'; r++)
    {
      continue;
    }

  *r = 0;
  UTL_String *tmp = 0;

  if (*h == '\0')
    {
      ACE_ERROR ((LM_ERROR,
                  ACE_TEXT ("IDL: No input files\n")));

      throw Bailout ();
    }
  else
    {
      long i;
      long j;

      // Put Microsoft-style pathnames into a canonical form.
      for (i = 0, j = 0; h[j] != '\0'; i++, j++)
        {
          if (h[j] == '\\' && h[j + 1] == '\\')
            {
              j++;
            }

            h[i] = h[j];
        }

      h[i] = '\0';
#if defined (ACE_OPENVMS)
      // translate this into *nix format as the OpenVMS preprocessor
      // possibly produced VMS-style paths here.
      char trans_path[MAXPATHLEN] = "";
      char *temp_h = IDL_GlobalData::translateName (h, trans_path);

      if (temp_h)
        {
          h = temp_h;
        }
      else
        {
          ACE_ERROR ((LM_ERROR,
                      ACE_TEXT ("Unable to construct full file pathname\n")));

          throw Bailout ();
        }
#endif
      ACE_NEW (tmp,
               UTL_String (h, true));
      idl_global->update_prefix (tmp->get_string ());
      idl_global->set_filename (tmp);
    }

  UTL_String *fname = idl_global->filename ();
  bool in_main_file = false;

  bool is_real_filename =
    fname->compare (idl_global->real_filename ())
    || same_file (fname->get_string(),
                  idl_global->real_filename ()->get_string());

  bool is_main_filename = false;

  if (!is_real_filename)
    {
#if defined (ACE_OPENVMS)
      char full_path[MAXPATHLEN] = "";
      char *full_fname = ACE_OS::realpath (fname->get_string (), full_path);
      // I don't see the benefit of using ->compare since this is targeted at IDL identifiers
      // not at filenames and in the case of OpenVMS (case-insensitive filesystem) gets really
      // problematic as filenames retrieved through different mechanisms may give different
      // casing.
      is_main_filename = FE_Utils::path_cmp (idl_global->main_filename ()->get_string (),
                                             full_fname) == 0;
#else
      is_main_filename =
        fname->compare (idl_global->main_filename ())
        || same_file (fname->get_string(),
                      idl_global->main_filename ()->get_string());
#endif
    }

  if (is_real_filename || is_main_filename)
    {
      in_main_file = true;
    }

  idl_global->set_in_main_file (in_main_file);

  // Strip off any command line -I prefix that may have been added
  // by the preprocessor.
  if (!(idl_global->in_main_file ()) && idl_global->import ())
    {
      ACE_NEW (nm,
               UTL_String (
                 FE_Utils::stripped_preproc_include (
                   fname->get_string ()), true));

      // This call also manages the #pragma prefix.
      idl_global->store_include_file_name (nm);
    }
}

// Store a #pragma line into the list of pragmas
static void
idl_store_pragma (char *buf)
{
  char *sp = buf + 1;
  int crunched = 0;

  // Remove all the blanks between the '#' and the 'pragma'.
  while (*sp != 'p')
    {
      ++sp;
      ++crunched;
    }

  char *tp = buf + 1;

  // This copies the crunched string back to the original, and
  // also compensates for the behavior of the Sun preprocessor,
  // which put spaces around the double colons of a non-quoted
  // scoped name, a case which is possible in #pragma version.
  // Also eats whitespace, which some preprocessors (for example
  // Intel) don't automatically do.
  while (*sp != '\n')
    {
      if (*sp == ' ' && (*(sp + 1) == ':' || *(sp + 1) == ' '))
        {
          ++crunched;
        }
      else if (*sp == ':' && *(sp + 1) == ' ')
        {
          *tp = *sp;
          ++crunched;
          ++sp;
          ++tp;
        }
      else
        {
          *tp = *sp;
          ++tp;
        }

      ++sp;
    }

  // The '\n' is still <crunched> spaces too far away, with
  // garbage characters in between.
  sp -= crunched;
  *sp = '\0';

  if (ACE_OS::strstr (buf + 8, "import") != 0)
    {
      idl_global->set_import (true);
      return;
    }

  if (ACE_OS::strstr (buf + 8, "include") != 0)
    {
      idl_global->set_import (false);
      return;
    }

  if (ACE_OS::strncmp (buf + 8, "prefix", 6) == 0)
    {
      char *new_prefix = idl_get_pragma_string (buf);

      if (new_prefix != 0)
        {
          unsigned long depth = idl_global->scopes ().depth ();

          // We replace the prefix only if there is a prefix already
          // associated with this file, otherwise we add the prefix.
          char *ext_id = idl_global->filename ()->get_string ();
          ACE_Hash_Map_Entry<char *, char *> *entry = 0;
          int const status =
            idl_global->file_prefixes ().find (ext_id, entry);

          if (status == 0)
            {
              if (ACE_OS::strcmp (entry->int_id_, "") != 0)
                {
                  char *trash = 0;
                  idl_global->pragma_prefixes ().pop (trash);
                  delete [] trash;
                }
              else if (depth == 1)
                {
                  // Remove the default "" and bind the new prefix.
                  ACE::strdelete (entry->ext_id_);
                  ACE::strdelete (entry->int_id_);
                  (void) idl_global->file_prefixes ().unbind (entry);
                  (void) idl_global->file_prefixes ().bind (ACE::strnew (ext_id),
                                                            ACE::strnew (new_prefix));
                }
            }

          UTL_Scope *top_scope = idl_global->scopes ().top ();

          if (depth > 1)
            {
              top_scope->has_prefix (true);
              ScopeAsDecl (top_scope)->prefix_scope (top_scope);
            }

          idl_global->pragma_prefixes ().push (new_prefix);

          if (depth == 1)
            {
              idl_global->root ()->prefix (new_prefix);
            }

          if (idl_global->in_main_file ())
            {
              idl_global->root ()->set_imported (false);
              top_scope->has_prefix (true);
            }

          if (status != 0)
            {
              (void) idl_global->file_prefixes ().bind (ACE::strnew (ext_id),
                                                        ACE::strnew (new_prefix));
            }
        }
    }
  else if (ACE_OS::strncmp (buf + 8, "version", 7) == 0)
    {
      char *tmp = buf + 16;

      while (*tmp == ' ' || *tmp == '\t')
        {
          ++tmp;
        }

      char *number = ACE_OS::strchr (tmp, ' ');

      if (number == 0)
        {
          number = ACE_OS::strchr (tmp, '\t');
        }

      // Used later to trim the type string.
      ptrdiff_t cutoff = number - tmp;

      // Most likely this means there is only a version number
      // without an identifier to apply it to.
      if (number == 0)
        {
          const char *msg = "no identifier or scoped name";
          idl_global->err ()->version_syntax_error (msg);
          return;
        }

      while (*number == ' ' || *number == '\t')
        {
          ++number;
        }

      size_t len = ACE_OS::strlen (number);

      // For some reason, the SunCC preprocessor adds a trailing space, which
      // messes with idl_valid_version() below, so we check and remove.
      while (number[len - 1] == ' ')
        {
          number[len - 1] = '\0';
          len = ACE_OS::strlen (number);
        }

      // Trim the type string after trimming the number string.
      tmp[cutoff] = '\0';

      // This call adds a proper null terminator to tmp, so no need to
      // do it here.
      AST_Decl *d = idl_find_node (tmp);

      if (d == 0)
        {
          return;
        }

      if (!idl_valid_version (number))
        {
          idl_global->err ()->version_number_error (number);
          return;
        }

      d->version (ACE::strnew (number));
    }
  else if (ACE_OS::strncmp (buf + 8, "ident", 5) == 0)
    {
      idl_global->ident_string (buf + 8);
    }
  else if (ACE_OS::strncmp (buf + 8, "ID", 2) == 0)
    {
      char *tmp = buf + 11;

      while (*tmp == ' ')
        {
          ++tmp;
        }

      ACE_CString work (tmp);
      work = work.substr (0, work.find (' '));

      AST_Decl *d = idl_find_node (work.c_str ());

      if (d == 0)
        {
          return;
        }

      char *new_id = idl_get_pragma_string (buf);

      if (new_id != 0)
        {
          if (d->typeid_set ())
            {
              idl_global->err ()->id_reset_error (d->repoID (),
                                                  new_id);
              return;
            }

          d->repoID (new_id);
          d->typeid_set (true);
        }
    }
  else if (ACE_OS::strncmp (buf + 8, "DCPS_DATA_TYPE", 14) == 0)
    {
      char *sample_type = idl_get_pragma_string (buf);
      idl_global->add_dcps_data_type (sample_type);

      // Delete sample_type since add_dcps_data_type() doesn't take its ownership.
      delete [] sample_type;
    }
  else if (ACE_OS::strncmp (buf + 8, "DCPS_DATA_KEY", 13) == 0)
    {
      char *tmp = idl_get_pragma_string (buf);

      // Split up data type and key strings
      char *sample_type = tmp;

      while (*tmp && !isspace (*tmp))
        {
          ++tmp;
        }

      while (isspace (*tmp))
        {
          *tmp = '\0';
          tmp++;
        }

      char *key = tmp;

      if (!idl_global->add_dcps_data_key (sample_type, key))
        {
          ACE_ERROR((LM_ERROR, "DCPS_DATA_TYPE \"%C\" not found for key \"%C\"\n",
            sample_type, key));
        }

      // Delete sample_type since add_dcps_data_key() doesn't take its ownership.
      delete [] sample_type;
    }
  else if (ACE_OS::strncmp (buf + 8, "DCPS_SUPPORT_ZERO_COPY_READ", 27) == 0)
    {
      idl_global->dcps_support_zero_copy_read (true);
    }
  else if (ACE_OS::strncmp (buf + 8, "DCPS_GEN_ZERO_COPY_READ", 23) == 0)
    {
      idl_global->dcps_gen_zero_copy_read (true);
    }
  else if (ACE_OS::strncmp (buf + 8, "ciao lem", 8) == 0)
    {
      char *tmp = idl_get_pragma_string (buf);
      idl_global->add_ciao_lem_file_names (tmp);

      // Delete tmp since add_ciao_lem_file_names() doesn't take its ownership.
      delete [] tmp;
    }
  else if (ACE_OS::strncmp (buf + 8, "ndds typesupport", 16) == 0)
    {
      char *tmp = idl_get_pragma_string (buf);
      idl_global->add_ciao_rti_ts_file_names (tmp);

      // Delete tmp since add_ciao_rti_ts_file_names() doesn't take its ownership.
      delete [] tmp;
    }
  else if (ACE_OS::strncmp (buf + 8, "coredx typesupport", 18) == 0)
    {
      char *tmp = idl_get_pragma_string (buf);
      idl_global->add_ciao_coredx_ts_file_names (tmp);

      // Delete tmp since add_ciao_rti_ts_file_names() doesn't take its ownership.
      delete [] tmp;
    }
  else if (ACE_OS::strncmp (buf + 8, "opendds typesupport", 19) == 0)
    {
      char *tmp = idl_get_pragma_string (buf);
      idl_global->add_ciao_oci_ts_file_names (tmp);

      // Delete tmp since add_ciao_oci_ts_file_names() doesn't take its ownership.
      delete [] tmp;
    }
  else if (ACE_OS::strncmp (buf + 8, "splice typesupport", 18) == 0)
    {
      char *tmp = idl_get_pragma_string (buf);
      idl_global->add_ciao_spl_ts_file_names (tmp);

      // Delete tmp since add_ciao_spl_ts_file_names() doesn't take its ownership.
      delete [] tmp;
    }
  else if ((ACE_OS::strncmp (buf + 8, "ciao ami4ccm interface", 22) == 0) ||
           (ACE_OS::strncmp (buf + 8, "ami4ccm interface", 17) == 0))
    {
      if (idl_global->in_main_file ())
        {
          char *tmp = idl_get_pragma_string (buf);
          idl_global->add_ciao_ami_iface_names (tmp);

          // Delete tmp since add_ciao_ami_iface_names() doesn't take its ownership.
          delete [] tmp;
        }
    }
  else if ((ACE_OS::strncmp (buf + 8, "ciao ami4ccm receptacle", 23) == 0) ||
           (ACE_OS::strncmp (buf + 8, "ami4ccm receptacle", 18) == 0))
    {
      char *tmp = idl_get_pragma_string (buf);

      if (idl_global->in_main_file ())
        {
          idl_global->add_ciao_ami_recep_names (tmp);
        }
      else
        {
          /// This is intended for the executor IDL file,
          /// when a pragma is seen in the main file, but
          /// it will do no harm in other cases.
          idl_global->add_included_ami_recep_names (tmp);
        }

      // Delete tmp since add_ciao_spl_ts_file_names() doesn't take its ownership.
      delete [] tmp;
    }
  else if ((ACE_OS::strncmp (buf + 8, "ciao ami4ccm idl", 16) == 0) ||
           (ACE_OS::strncmp (buf + 8, "ami4ccm idl", 11) == 0))
    {
      char *tmp = idl_get_pragma_string (buf);

      /// These pragmas are found in the file where the interface
      /// that has a AMI4CCM_* counterpart in the *A.idl file
      /// is declared. We add the filename to the list in all
      /// IDL files *except* the one where it is found, to
      /// eliminate a circular include of xxxC.h and xxxAC.h.
      if (!idl_global->in_main_file ())
        {
          idl_global->add_ciao_ami_idl_fnames (tmp);
        }

      // Delete tmp since add_ciao_ami_idl_fnames() doesn't take its ownership.
      delete [] tmp;
    }
  else if (ACE_OS::strncmp (buf + 8, "dds4ccm impl", 12) == 0)
    {
      char *tmp = idl_get_pragma_string (buf);

      idl_global->add_dds4ccm_impl_fnames (tmp);

      // Delete tmp since add_dds4ccm_impl_fnames() doesn't take its ownership.
      delete [] tmp;
    }
}

/*
 * idl_atoi - Convert a string of digits into a negative integer according to base b
 */
static ACE_CDR::LongLong
idl_atoi (char *s, long b)
{
  ACE_CDR::LongLong r = ACE_CDR_LONGLONG_INITIALIZER;

  // Skip over the dash and possibly spaces after the dash
  while (*s == '-' || *s == ' ' || *s == '\t')
    {
      ++s;
    }

  if (b == 8 && *s == '0')
    {
      ++s;
    }
  else if (b == 16 && *s == '0' && (*(s + 1) == 'x' || *(s + 1) == 'X'))
    {
      s += 2;
    }

  for (; *s; ++s)
    {
      if (*s <= '9' && *s >= '0')
        {
          r = (r * b) + (*s - '0');
        }
      else if (b > 10 && *s <= 'f' && *s >= 'a')
        {
          r = (r * b) + (*s - 'a' + 10);
        }
      else if (b > 10 && *s <= 'F' && *s >= 'A')
        {
          r = (r * b) + (*s - 'A' + 10);
        }
      else
        {
          break;
        }
    }

  return -r;
}

/*
 * idl_atoui - Convert a string of digits into an unsigned integer according to base b
 */
static ACE_CDR::ULongLong
idl_atoui(char *s, long b)
{
  ACE_CDR::ULongLong r = 0;

  if (b == 8 && *s == '0')
    {
      ++s;
    }
  else if (b == 16 && *s == '0' && (*(s + 1) == 'x' || *(s + 1) == 'X'))
    {
      s += 2;
    }

  for (; *s; ++s)
    {
      if (*s <= '9' && *s >= '0')
        {
          r = (r * b) + (*s - '0');
        }
      else if (b > 10 && *s <= 'f' && *s >= 'a')
        {
          r = (r * b) + (*s - 'a' + 10);
        }
      else if (b > 10 && *s <= 'F' && *s >= 'A')
        {
          r = (r * b) + (*s - 'A' + 10);
        }
      else
        {
          break;
        }
    }

  return r;
}

/*
 * Convert a string to a float; atof doesn't seem to work, always.
 */
static ACE_CDR::Double
idl_atof (char *s)
{
  double d = 0.0;
  double e, k;
  long neg = 0, negexp = 0;

  if (*s == '-')
    {
      neg = 1;

      // Skip over the dash and possibly spaces after the dash
      while (*s == '-' || *s == ' ' || *s == '\t')
        {
          ++s;
        }
    }

  while (*s >= '0' && *s <= '9')
    {
      d = (d * 10) + *s - '0';
      ++s;
    }

  if (*s == '.')
    {
      ++s;
      e = 10;

      while (*s >= '0' && *s <= '9')
        {
          d += (*s - '0') / (e * 1.0);
          e *= 10;
          ++s;
        }
    }

  if (*s == 'e' || *s == 'E')
    {
      ++s;

      if (*s == '-')
        {
            negexp = 1;
            s++;
        }
      else if (*s == '+')
        {
          ++s;
        }

      e = 0;

      while (*s >= '0' && *s <= '9')
        {
          e = (e * 10) + *s - '0';
          ++s;
        }

      if (e > 0)
        {
          for (k = 1; e > 0; k *= 10, e--) ;

          if (negexp)
            {
              d /= k;
            }
          else
            {
              d *= k;
            }
        }
    }

  if (neg)
    {
      d *= -1.0;
    }

  return d;
}

/*
 * Convert (some) escaped characters into their ascii values
 */
static char
idl_escape_reader (char *str)
{
  if (str[0] != '\\')
    {
      return str[0];
    }

  switch (str[1])
  {
    case 'n':
      return '\n';
    case 't':
      return '\t';
    case 'v':
      return '\v';
    case 'b':
      return '\b';
    case 'r':
      return '\r';
    case 'f':
      return '\f';
    case 'a':
      return '\a';
    case '\\':
      return '\\';
    case '\?':
      return '?';
    case '\'':
      return '\'';
    case '"':
      return '"';
    case 'x':
      {
        int i;

        // hex value
        for (i = 2; str[i] != '\0' && isxdigit (str[i]); ++i)
          {
            continue;
          }

        char save = str[i];
        str[i] = '\0';
        char out = (char)idl_atoui(&str[2], 16);
        str[i] = save;
        return out;
      }
      ACE_NOTREACHED (break;)
    default:
      // check for octal value
      if (str[1] >= '0' && str[1] <= '7')
        {
          int i;

          for (i = 1; str[i] >= '0' && str[i] <= '7'; ++i)
            {
              continue;
            }

          char save = str[i];
          str[i] = '\0';
          char out = (char)idl_atoui(&str[1], 8);
          str[i] = save;
          return out;
        }
      else
        {
          return str[1] - 'a';
        }
      ACE_NOTREACHED  (break;)
  }
}
/*
 * Convert escaped hex digits into a wchar
 */
static ACE_CDR::WChar
idl_wchar_escape_reader (char *str)
{
  if (str[0] != '\\' || str[1] != 'u')
    {
      return 0;
    }

  int i;
  // get the hex digits
  for (i = 2; str[i] != '\0' && isxdigit (str[i]); i++)
    {
      continue;
    }
  char save = str[i];
  str[i] = '\0';
  ACE_CDR::WChar out = (ACE_CDR::WChar) idl_atoui (&str[2], 16);
  str[i] = save;
  return out;
}

/*
 * Checks wstring for validity
 */
static char *
idl_wstring_escape_reader (char *str)
{
  return str;
}

static char *
idl_get_pragma_string (char *pragma)
{
  // Get pointers to each end of the substring between the quotes.
  const char *firstquote = ACE_OS::strchr (pragma, '"');

  if (firstquote == 0)
    {
      idl_global->err ()->syntax_error (
          IDL_GlobalData::PS_PragmaPrefixSyntax
        );

      return 0;
    }

  const char *start = firstquote + 1;
  const char *end = ACE_OS::strchr (start, '"');

  if (end == 0)
    {
      idl_global->err ()->syntax_error (
          IDL_GlobalData::PS_PragmaPrefixSyntax
        );

      return 0;
    }

  int len = end - start;
  char *retval = 0;

  ACE_NEW_RETURN (retval,
                  char[len + 1],
                  0);

  ACE_OS::strncpy (retval,
                   start,
                   len);

  retval[len] = '\0';
  return retval;
}

static bool
idl_valid_version (char *s)
{
  // Nothing preceding decimal point.
  if (*s == '.')
    {
      return 0;
    }

  char *minor = ACE_OS::strchr (s, '.');
  int i;

  if (minor == 0)
    {
      // No decimal point.
      return 0;
    }

  if (*(minor + 1) == '\0')
    {
      // Nothing following decimal point.
      return 0;
    }

  char *tmp = minor + 1;

  for (i = 0; tmp[i] != '\0'; ++i)
    {
      if (!isdigit (tmp[i]))
        {
          return 0;
        }
    }

  ptrdiff_t const len = minor - s;

  for (i = 0; i < len; ++i)
    {
      if (!isdigit (s[i]))
        {
          return 0;
        }
    }

  // Major and minor version numbers must be unsigned shorts.
  if (ACE_OS::atoi (minor + 1) > ACE_UINT16_MAX
      || ACE_OS::atoi (s) > ACE_UINT16_MAX)
    {
      return 0;
    }

  return 1;
}

static AST_Decl *
idl_find_node (const char *s)
{
  UTL_ScopedName * node = FE_Utils::string_to_scoped_name (s);
  AST_Decl * d = 0;

  if (node != 0)
    {
      d = idl_global->scopes ().top_non_null ()->lookup_by_name (node);

      if (d == 0)
        {
          idl_global->err ()->lookup_error (node);
        }

      node->destroy ();
      delete node;
    }

  return d;
}

