Sourcecode and documentation for libtasn1-2 version 0.2.10-3sarge1
show bar | Show file versions
Search packages:
| Sourcecode archive home

ASN1.c

00001 /* A Bison parser, made by GNU Bison 1.875a.  */
00002 
00003 /* Skeleton parser for Yacc-like parsing with Bison,
00004    Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
00005 
00006    This program is free software; you can redistribute it and/or modify
00007    it under the terms of the GNU General Public License as published by
00008    the Free Software Foundation; either version 2, or (at your option)
00009    any later version.
00010 
00011    This program is distributed in the hope that it will be useful,
00012    but WITHOUT ANY WARRANTY; without even the implied warranty of
00013    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014    GNU General Public License for more details.
00015 
00016    You should have received a copy of the GNU General Public License
00017    along with this program; if not, write to the Free Software
00018    Foundation, Inc., 59 Temple Place - Suite 330,
00019    Boston, MA 02111-1307, USA.  */
00020 
00021 /* As a special exception, when this file is copied by Bison into a
00022    Bison output file, you may use that output file without restriction.
00023    This special exception was added by the Free Software Foundation
00024    in version 1.24 of Bison.  */
00025 
00026 /* Written by Richard Stallman by simplifying the original so called
00027    ``semantic'' parser.  */
00028 
00029 /* All symbols defined below should begin with yy or YY, to avoid
00030    infringing on user name space.  This should be done even for local
00031    variables, as they might otherwise be expanded by user macros.
00032    There are some unavoidable exceptions within include files to
00033    define necessary library symbols; they are noted "INFRINGES ON
00034    USER NAME SPACE" below.  */
00035 
00036 /* Identify Bison output.  */
00037 #define YYBISON 1
00038 
00039 /* Skeleton name.  */
00040 #define YYSKELETON_NAME "yacc.c"
00041 
00042 /* Pure parsers.  */
00043 #define YYPURE 0
00044 
00045 /* Using locations.  */
00046 #define YYLSP_NEEDED 0
00047 
00048 /* If NAME_PREFIX is specified substitute the variables and functions
00049    names.  */
00050 #define yyparse _asn1_yyparse
00051 #define yylex   _asn1_yylex
00052 #define yyerror _asn1_yyerror
00053 #define yylval  _asn1_yylval
00054 #define yychar  _asn1_yychar
00055 #define yydebug _asn1_yydebug
00056 #define yynerrs _asn1_yynerrs
00057 
00058 
00059 /* Tokens.  */
00060 #ifndef YYTOKENTYPE
00061 # define YYTOKENTYPE
00062    /* Put the tokens into the symbol table, so that GDB and other debuggers
00063       know about them.  */
00064    enum yytokentype {
00065      ASSIG = 258,
00066      NUM = 259,
00067      IDENTIFIER = 260,
00068      OPTIONAL = 261,
00069      INTEGER = 262,
00070      SIZE = 263,
00071      OCTET = 264,
00072      STRING = 265,
00073      SEQUENCE = 266,
00074      BIT = 267,
00075      UNIVERSAL = 268,
00076      PRIVATE = 269,
00077      APPLICATION = 270,
00078      DEFAULT = 271,
00079      CHOICE = 272,
00080      OF = 273,
00081      OBJECT = 274,
00082      STR_IDENTIFIER = 275,
00083      BOOLEAN = 276,
00084      TRUE = 277,
00085      FALSE = 278,
00086      TOKEN_NULL = 279,
00087      ANY = 280,
00088      DEFINED = 281,
00089      BY = 282,
00090      SET = 283,
00091      EXPLICIT = 284,
00092      IMPLICIT = 285,
00093      DEFINITIONS = 286,
00094      TAGS = 287,
00095      BEGIN = 288,
00096      END = 289,
00097      UTCTime = 290,
00098      GeneralizedTime = 291,
00099      GeneralString = 292,
00100      FROM = 293,
00101      IMPORTS = 294,
00102      ENUMERATED = 295
00103    };
00104 #endif
00105 #define ASSIG 258
00106 #define NUM 259
00107 #define IDENTIFIER 260
00108 #define OPTIONAL 261
00109 #define INTEGER 262
00110 #define SIZE 263
00111 #define OCTET 264
00112 #define STRING 265
00113 #define SEQUENCE 266
00114 #define BIT 267
00115 #define UNIVERSAL 268
00116 #define PRIVATE 269
00117 #define APPLICATION 270
00118 #define DEFAULT 271
00119 #define CHOICE 272
00120 #define OF 273
00121 #define OBJECT 274
00122 #define STR_IDENTIFIER 275
00123 #define BOOLEAN 276
00124 #define TRUE 277
00125 #define FALSE 278
00126 #define TOKEN_NULL 279
00127 #define ANY 280
00128 #define DEFINED 281
00129 #define BY 282
00130 #define SET 283
00131 #define EXPLICIT 284
00132 #define IMPLICIT 285
00133 #define DEFINITIONS 286
00134 #define TAGS 287
00135 #define BEGIN 288
00136 #define END 289
00137 #define UTCTime 290
00138 #define GeneralizedTime 291
00139 #define GeneralString 292
00140 #define FROM 293
00141 #define IMPORTS 294
00142 #define ENUMERATED 295
00143 
00144 
00145 
00146 
00147 /* Copy the first part of user declarations.  */
00148 #line 29 "ASN1.y"
00149  
00150 #include <int.h> 
00151 #include <errors.h>
00152 #include <parser_aux.h>
00153 #include <structure.h>
00154 
00155 
00156 static FILE *file_asn1;            /* Pointer to file to parse */
00157 static asn1_retCode result_parse;  /* result of the parser algorithm */
00158 static node_asn *p_tree;        /* pointer to the root of the structure 
00159                             created by the parser*/     
00160 static unsigned long lineNumber; /* line number describing the parser position 
00161                              inside the file */
00162 static char lastToken[MAX_NAME_SIZE+1];  /* last token find in the file to 
00163                                   parse before the 'parse error' */ 
00164 extern char _asn1_identifierMissing[];
00165 static const char *fileName;           /* file to parse */
00166 
00167 int _asn1_yyerror (char *);
00168 int _asn1_yylex(void);
00169 
00170 
00171 
00172 /* Enabling traces.  */
00173 #ifndef YYDEBUG
00174 # define YYDEBUG 0
00175 #endif
00176 
00177 /* Enabling verbose error messages.  */
00178 #ifdef YYERROR_VERBOSE
00179 # undef YYERROR_VERBOSE
00180 # define YYERROR_VERBOSE 1
00181 #else
00182 # define YYERROR_VERBOSE 0
00183 #endif
00184 
00185 #if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
00186 #line 55 "ASN1.y"
00187 typedef union YYSTYPE {
00188   unsigned int constant;
00189   char str[MAX_NAME_SIZE+1];
00190   node_asn* node;
00191 } YYSTYPE;
00192 /* Line 191 of yacc.c.  */
00193 #line 194 "ASN1.c"
00194 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
00195 # define YYSTYPE_IS_DECLARED 1
00196 # define YYSTYPE_IS_TRIVIAL 1
00197 #endif
00198 
00199 
00200 
00201 /* Copy the second part of user declarations.  */
00202 
00203 
00204 /* Line 214 of yacc.c.  */
00205 #line 206 "ASN1.c"
00206 
00207 #if ! defined (yyoverflow) || YYERROR_VERBOSE
00208 
00209 /* The parser invokes alloca or malloc; define the necessary symbols.  */
00210 
00211 # if YYSTACK_USE_ALLOCA
00212 #  define YYSTACK_ALLOC alloca
00213 # else
00214 #  ifndef YYSTACK_USE_ALLOCA
00215 #   if defined (alloca) || defined (_ALLOCA_H)
00216 #    define YYSTACK_ALLOC alloca
00217 #   else
00218 #    ifdef __GNUC__
00219 #     define YYSTACK_ALLOC __builtin_alloca
00220 #    endif
00221 #   endif
00222 #  endif
00223 # endif
00224 
00225 # ifdef YYSTACK_ALLOC
00226    /* Pacify GCC's `empty if-body' warning. */
00227 #  define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
00228 # else
00229 #  if defined (__STDC__) || defined (__cplusplus)
00230 #   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
00231 #   define YYSIZE_T size_t
00232 #  endif
00233 #  define YYSTACK_ALLOC malloc
00234 #  define YYSTACK_FREE free
00235 # endif
00236 #endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */
00237 
00238 
00239 #if (! defined (yyoverflow) \
00240      && (! defined (__cplusplus) \
00241        || (YYSTYPE_IS_TRIVIAL)))
00242 
00243 /* A type that is properly aligned for any stack member.  */
00244 union yyalloc
00245 {
00246   short yyss;
00247   YYSTYPE yyvs;
00248   };
00249 
00250 /* The size of the maximum gap between one aligned stack and the next.  */
00251 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
00252 
00253 /* The size of an array large to enough to hold all stacks, each with
00254    N elements.  */
00255 # define YYSTACK_BYTES(N) \
00256      ((N) * (sizeof (short) + sizeof (YYSTYPE))                   \
00257       + YYSTACK_GAP_MAXIMUM)
00258 
00259 /* Copy COUNT objects from FROM to TO.  The source and destination do
00260    not overlap.  */
00261 # ifndef YYCOPY
00262 #  if 1 < __GNUC__
00263 #   define YYCOPY(To, From, Count) \
00264       __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
00265 #  else
00266 #   define YYCOPY(To, From, Count)        \
00267       do                            \
00268       {                             \
00269         register YYSIZE_T yyi;            \
00270         for (yyi = 0; yyi < (Count); yyi++)     \
00271           (To)[yyi] = (From)[yyi];        \
00272       }                             \
00273       while (0)
00274 #  endif
00275 # endif
00276 
00277 /* Relocate STACK from its old location to the new one.  The
00278    local variables YYSIZE and YYSTACKSIZE give the old and new number of
00279    elements in the stack, and YYPTR gives the new location of the
00280    stack.  Advance YYPTR to a properly aligned location for the next
00281    stack.  */
00282 # define YYSTACK_RELOCATE(Stack)                            \
00283     do                                                      \
00284       {                                                     \
00285       YYSIZE_T yynewbytes;                                  \
00286       YYCOPY (&yyptr->Stack, Stack, yysize);                      \
00287       Stack = &yyptr->Stack;                                \
00288       yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
00289       yyptr += yynewbytes / sizeof (*yyptr);                      \
00290       }                                                     \
00291     while (0)
00292 
00293 #endif
00294 
00295 #if defined (__STDC__) || defined (__cplusplus)
00296    typedef signed char yysigned_char;
00297 #else
00298    typedef short yysigned_char;
00299 #endif
00300 
00301 /* YYFINAL -- State number of the termination state. */
00302 #define YYFINAL  5
00303 /* YYLAST -- Last index in YYTABLE.  */
00304 #define YYLAST   189
00305 
00306 /* YYNTOKENS -- Number of terminals. */
00307 #define YYNTOKENS  52
00308 /* YYNNTS -- Number of nonterminals. */
00309 #define YYNNTS  43
00310 /* YYNRULES -- Number of rules. */
00311 #define YYNRULES  98
00312 /* YYNRULES -- Number of states. */
00313 #define YYNSTATES  189
00314 
00315 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
00316 #define YYUNDEFTOK  2
00317 #define YYMAXUTOK   295
00318 
00319 #define YYTRANSLATE(YYX)                                    \
00320   ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
00321 
00322 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
00323 static const unsigned char yytranslate[] =
00324 {
00325        0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00326        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00327        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00328        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00329       43,    44,     2,    41,    45,    42,    51,     2,     2,     2,
00330        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00331        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00332        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00333        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00334        2,    46,     2,    47,     2,     2,     2,     2,     2,     2,
00335        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00336        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00337        2,     2,     2,    49,    48,    50,     2,     2,     2,     2,
00338        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00339        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00340        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00341        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00342        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00343        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00344        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00345        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00346        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00347        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00348        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00349        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00350        2,     2,     2,     2,     2,     2,     1,     2,     3,     4,
00351        5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
00352       15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
00353       25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
00354       35,    36,    37,    38,    39,    40
00355 };
00356 
00357 #if YYDEBUG
00358 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
00359    YYRHS.  */
00360 static const unsigned short yyprhs[] =
00361 {
00362        0,     0,     3,    12,    14,    17,    20,    22,    24,    26,
00363       28,    30,    32,    36,    41,    43,    47,    49,    54,    56,
00364       59,    61,    63,    65,    69,    74,    76,    79,    82,    85,
00365       88,    91,    93,    97,    99,   104,   109,   117,   119,   121,
00366      123,   128,   136,   138,   142,   144,   147,   150,   154,   159,
00367      161,   165,   168,   174,   179,   182,   184,   187,   189,   191,
00368      193,   195,   197,   199,   201,   203,   205,   207,   209,   211,
00369      213,   215,   218,   220,   223,   226,   229,   231,   235,   240,
00370      244,   249,   254,   258,   263,   268,   270,   275,   279,   287,
00371      294,   299,   301,   303,   305,   308,   313,   317,   319
00372 };
00373 
00374 /* YYRHS -- A `-1'-separated list of the rules' RHS. */
00375 static const yysigned_char yyrhs[] =
00376 {
00377       53,     0,    -1,    93,    31,    94,    32,     3,    33,    92,
00378       34,    -1,     4,    -1,    41,     4,    -1,    42,     4,    -1,
00379       54,    -1,    55,    -1,     4,    -1,     5,    -1,    56,    -1,
00380        5,    -1,    43,    56,    44,    -1,     5,    43,    56,    44,
00381       -1,    59,    -1,    60,    45,    59,    -1,    57,    -1,     5,
00382       43,     4,    44,    -1,    61,    -1,    62,    61,    -1,    13,
00383       -1,    14,    -1,    15,    -1,    46,     4,    47,    -1,    46,
00384       63,     4,    47,    -1,    64,    -1,    64,    29,    -1,    64,
00385       30,    -1,    16,    58,    -1,    16,    22,    -1,    16,    23,
00386       -1,    56,    -1,    67,    48,    56,    -1,     7,    -1,     7,
00387       49,    60,    50,    -1,     7,    43,    67,    44,    -1,     7,
00388       43,    57,    51,    51,    57,    44,    -1,    21,    -1,    35,
00389       -1,    36,    -1,     8,    43,    57,    44,    -1,     8,    43,
00390       57,    51,    51,    57,    44,    -1,    71,    -1,    43,    71,
00391       44,    -1,    37,    -1,    37,    72,    -1,     9,    10,    -1,
00392        9,    10,    72,    -1,     5,    43,     4,    44,    -1,    75,
00393       -1,    76,    45,    75,    -1,    12,    10,    -1,    12,    10,
00394       49,    76,    50,    -1,    40,    49,    76,    50,    -1,    19,
00395       20,    -1,     5,    -1,     5,    72,    -1,    68,    -1,    78,
00396       -1,    69,    -1,    70,    -1,    74,    -1,    77,    -1,    73,
00397       -1,    85,    -1,    79,    -1,    87,    -1,    88,    -1,    86,
00398       -1,    24,    -1,    80,    -1,    65,    80,    -1,    81,    -1,
00399       81,    66,    -1,    81,     6,    -1,     5,    82,    -1,    83,
00400       -1,    84,    45,    83,    -1,    11,    49,    84,    50,    -1,
00401       11,    18,    80,    -1,    11,    72,    18,    80,    -1,    28,
00402       49,    84,    50,    -1,    28,    18,    80,    -1,    28,    72,
00403       18,    80,    -1,    17,    49,    84,    50,    -1,    25,    -1,
00404       25,    26,    27,     5,    -1,     5,     3,    81,    -1,     5,
00405       19,    20,     3,    49,    62,    50,    -1,     5,     5,     3,
00406       49,    62,    50,    -1,     5,     7,     3,    56,    -1,    89,
00407       -1,    90,    -1,    91,    -1,    92,    91,    -1,     5,    49,
00408       62,    50,    -1,     5,    49,    50,    -1,    29,    -1,    30,
00409       -1
00410 };
00411 
00412 /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
00413 static const unsigned short yyrline[] =
00414 {
00415        0,   117,   117,   130,   131,   134,   138,   139,   142,   143,
00416      146,   147,   150,   152,   157,   158,   162,   164,   169,   170,
00417      174,   175,   176,   179,   181,   185,   186,   187,   190,   192,
00418      193,   197,   198,   202,   203,   205,   206,   213,   216,   217,
00419      220,   222,   228,   229,   232,   233,   237,   238,   242,   247,
00420      248,   252,   253,   258,   264,   267,   269,   272,   273,   274,
00421      275,   276,   277,   278,   279,   280,   281,   282,   283,   284,
00422      287,   288,   293,   294,   297,   300,   303,   304,   308,   310,
00423      312,   317,   319,   321,   326,   330,   331,   336,   339,   343,
00424      348,   354,   355,   358,   359,   363,   366,   390,   391
00425 };
00426 #endif
00427 
00428 #if YYDEBUG || YYERROR_VERBOSE
00429 /* YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
00430    First, the terminals, then, starting at YYNTOKENS, nonterminals. */
00431 static const char *const yytname[] =
00432 {
00433   "$end", "error", "$undefined", "\"::=\"", "NUM", "IDENTIFIER", "OPTIONAL", 
00434   "INTEGER", "SIZE", "OCTET", "STRING", "SEQUENCE", "BIT", "UNIVERSAL", 
00435   "PRIVATE", "APPLICATION", "DEFAULT", "CHOICE", "OF", "OBJECT", 
00436   "STR_IDENTIFIER", "BOOLEAN", "TRUE", "FALSE", "TOKEN_NULL", "ANY", 
00437   "DEFINED", "BY", "SET", "EXPLICIT", "IMPLICIT", "DEFINITIONS", "TAGS", 
00438   "BEGIN", "END", "UTCTime", "GeneralizedTime", "GeneralString", "FROM", 
00439   "IMPORTS", "ENUMERATED", "'+'", "'-'", "'('", "')'", "','", "'['", 
00440   "']'", "'|'", "'{'", "'}'", "'.'", "$accept", "definitions", "pos_num", 
00441   "neg_num", "pos_neg_num", "num_identifier", "pos_neg_identifier", 
00442   "constant", "constant_list", "obj_constant", "obj_constant_list", 
00443   "class", "tag_type", "tag", "default", "pos_neg_list", "integer_def", 
00444   "boolean_def", "Time", "size_def2", "size_def", "generalstring_def", 
00445   "octet_string_def", "bit_element", "bit_element_list", "bit_string_def", 
00446   "enumerated_def", "object_def", "type_assig_right", 
00447   "type_assig_right_tag", "type_assig_right_tag_default", "type_assig", 
00448   "type_assig_list", "sequence_def", "set_def", "choise_def", "any_def", 
00449   "type_def", "constant_def", "type_constant", "type_constant_list", 
00450   "definitions_id", "explicit_implicit", 0
00451 };
00452 #endif
00453 
00454 # ifdef YYPRINT
00455 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
00456    token YYLEX-NUM.  */
00457 static const unsigned short yytoknum[] =
00458 {
00459        0,   256,   257,   258,   259,   260,   261,   262,   263,   264,
00460      265,   266,   267,   268,   269,   270,   271,   272,   273,   274,
00461      275,   276,   277,   278,   279,   280,   281,   282,   283,   284,
00462      285,   286,   287,   288,   289,   290,   291,   292,   293,   294,
00463      295,    43,    45,    40,    41,    44,    91,    93,   124,   123,
00464      125,    46
00465 };
00466 # endif
00467 
00468 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
00469 static const unsigned char yyr1[] =
00470 {
00471        0,    52,    53,    54,    54,    55,    56,    56,    57,    57,
00472       58,    58,    59,    59,    60,    60,    61,    61,    62,    62,
00473       63,    63,    63,    64,    64,    65,    65,    65,    66,    66,
00474       66,    67,    67,    68,    68,    68,    68,    69,    70,    70,
00475       71,    71,    72,    72,    73,    73,    74,    74,    75,    76,
00476       76,    77,    77,    78,    79,    80,    80,    80,    80,    80,
00477       80,    80,    80,    80,    80,    80,    80,    80,    80,    80,
00478       81,    81,    82,    82,    82,    83,    84,    84,    85,    85,
00479       85,    86,    86,    86,    87,    88,    88,    89,    90,    90,
00480       90,    91,    91,    92,    92,    93,    93,    94,    94
00481 };
00482 
00483 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
00484 static const unsigned char yyr2[] =
00485 {
00486        0,     2,     8,     1,     2,     2,     1,     1,     1,     1,
00487        1,     1,     3,     4,     1,     3,     1,     4,     1,     2,
00488        1,     1,     1,     3,     4,     1,     2,     2,     2,     2,
00489        2,     1,     3,     1,     4,     4,     7,     1,     1,     1,
00490        4,     7,     1,     3,     1,     2,     2,     3,     4,     1,
00491        3,     2,     5,     4,     2,     1,     2,     1,     1,     1,
00492        1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00493        1,     2,     1,     2,     2,     2,     1,     3,     4,     3,
00494        4,     4,     3,     4,     4,     1,     4,     3,     7,     6,
00495        4,     1,     1,     1,     2,     4,     3,     1,     1
00496 };
00497 
00498 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
00499    STATE-NUM when YYTABLE doesn't specify something else to do.  Zero
00500    means the default is an error.  */
00501 static const unsigned char yydefact[] =
00502 {
00503        0,     0,     0,     0,     0,     1,     0,     8,     9,    96,
00504       16,    18,     0,    97,    98,     0,     0,    95,    19,     0,
00505        0,     0,    17,     0,     0,    91,    92,    93,     0,     0,
00506        0,     0,     0,     2,    94,    55,    33,     0,     0,     0,
00507        0,     0,    37,    69,    85,     0,    38,    39,    44,     0,
00508        0,    25,     0,    57,    59,    60,    63,    61,    62,    58,
00509       65,    70,    87,    64,    68,    66,    67,     0,     0,     0,
00510        0,     0,    42,    56,     0,     0,    46,     0,     0,     0,
00511       51,     0,    54,     0,     0,     0,     0,    45,     0,     0,
00512       20,    21,    22,     0,    26,    27,    71,     0,     3,     0,
00513        0,     6,     7,    90,     0,     0,     0,     3,     9,    31,
00514        0,     0,     0,     0,    14,     0,    47,    79,     0,    76,
00515        0,     0,     0,     0,     0,    82,     0,     0,     0,    49,
00516        0,    23,     0,     0,     4,     5,     0,     0,    43,     0,
00517       35,     0,     0,     0,     0,    34,    72,    75,     0,    78,
00518       80,     0,    84,    86,    81,    83,     0,     0,    53,    24,
00519       89,     0,    40,     0,     0,    32,     0,    12,    15,    74,
00520        0,    73,    77,    52,     0,    50,    88,     0,     0,    13,
00521       11,    29,    30,    10,    28,    48,     0,    36,    41
00522 };
00523 
00524 /* YYDEFGOTO[NTERM-NUM]. */
00525 static const short yydefgoto[] =
00526 {
00527       -1,     2,   101,   102,   103,    10,   184,   114,   115,    11,
00528       12,    93,    51,    52,   171,   111,    53,    54,    55,    72,
00529       73,    56,    57,   129,   130,    58,    59,    60,    61,    62,
00530      147,   119,   120,    63,    64,    65,    66,    25,    26,    27,
00531       28,     3,    15
00532 };
00533 
00534 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
00535    STATE-NUM.  */
00536 #define YYPACT_NINF -84
00537 static const short yypact[] =
00538 {
00539       18,   -32,    33,    15,     0,   -84,    90,   -84,    49,   -84,
00540      -84,   -84,     2,   -84,   -84,    11,    45,   -84,   -84,    57,
00541       50,    43,   -84,   100,    74,   -84,   -84,   -84,    10,    78,
00542      105,   113,   106,   -84,   -84,     5,   -31,   126,     8,   128,
00543       79,   120,   -84,   -84,   115,    12,   -84,   -84,     5,    95,
00544       96,   102,   118,   -84,   -84,   -84,   -84,   -84,   -84,   -84,
00545      -84,   -84,   -84,   -84,   -84,   -84,   -84,    98,    23,   142,
00546      107,   140,   -84,   -84,    32,    20,     5,   118,   146,   134,
00547      108,   146,   -84,   132,   118,   146,   138,   -84,   155,   114,
00548      -84,   -84,   -84,   158,   -84,   -84,   -84,    63,   -84,   159,
00549      160,   -84,   -84,   -84,   116,   129,   122,   117,   -84,   -84,
00550      119,    38,   124,    23,   -84,    -3,   -84,   -84,    78,   -84,
00551       21,   118,   155,    30,   164,   -84,    51,   118,   130,   -84,
00552       62,   -84,   125,     4,   -84,   -84,    63,    -6,   -84,   123,
00553      -84,    23,    23,   127,    20,   -84,    13,   -84,   146,   -84,
00554      -84,    72,   -84,   -84,   -84,   -84,   171,   155,   -84,   -84,
00555      -84,     6,   -84,   131,   129,   -84,   133,   -84,   -84,   -84,
00556       17,   -84,   -84,   -84,   135,   -84,   -84,   129,   136,   -84,
00557      -84,   -84,   -84,   -84,   -84,   -84,   137,   -84,   -84
00558 };
00559 
00560 /* YYPGOTO[NTERM-NUM].  */
00561 static const short yypgoto[] =
00562 {
00563      -84,   -84,   -84,   -84,   -72,   -73,   -84,    34,   -84,   -12,
00564      -83,   -84,   -84,   -84,   -84,   -84,   -84,   -84,   -84,   112,
00565      -14,   -84,   -84,    19,    64,   -84,   -84,   -84,   -49,    66,
00566      -84,    37,     3,   -84,   -84,   -84,   -84,   -84,   -84,   161,
00567      -84,   -84,   -84
00568 };
00569 
00570 /* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
00571    positive, shift that token.  If negative, reduce the rule which
00572    number is the opposite.  If zero, do what YYDEFACT says.
00573    If YYTABLE_NINF, syntax error.  */
00574 #define YYTABLE_NINF -9
00575 static const short yytable[] =
00576 {
00577       18,   110,   109,    96,     7,     8,     7,     8,     7,     8,
00578        7,     8,    74,    70,   133,    24,    70,     4,    75,   169,
00579       70,    98,   180,     1,    79,   112,    77,    98,   117,   170,
00580       84,    86,   137,     5,    87,   125,   107,   108,   162,   181,
00581      182,   143,   144,    19,    33,   163,     6,   145,    71,    20,
00582        9,    71,    17,   161,   160,    71,   176,    78,    99,   100,
00583       21,    85,   116,   113,    99,   100,   148,     7,     8,   165,
00584      166,   149,   150,    99,   100,   148,    23,    29,   155,    30,
00585      152,    31,   140,    35,   123,    36,   141,    37,   126,    38,
00586       39,   178,    16,    32,    22,    40,   148,    41,   183,    42,
00587       89,   154,    43,    44,   186,    24,    45,   157,    67,    90,
00588       91,    92,   158,    46,    47,    48,    68,   157,    49,    13,
00589       14,    18,   173,    35,    50,    36,    69,    37,    81,    38,
00590       39,    94,    95,     7,   108,    40,    76,    41,    80,    42,
00591       82,    83,    43,    44,    88,   104,    45,    97,    70,    18,
00592      105,   118,   121,    46,    47,    48,   127,   122,    49,   124,
00593      128,   131,   132,   134,   135,   136,   138,   142,    -8,   153,
00594      139,   167,   159,   156,   164,   174,   175,   179,   168,   185,
00595      187,   188,   177,   106,   146,   172,   151,     0,     0,    34
00596 };
00597 
00598 static const short yycheck[] =
00599 {
00600       12,    74,    74,    52,     4,     5,     4,     5,     4,     5,
00601        4,     5,    43,     8,    97,     5,     8,    49,    49,     6,
00602        8,     4,     5,     5,    38,     5,    18,     4,    77,    16,
00603       18,    45,   105,     0,    48,    84,     4,     5,    44,    22,
00604       23,   113,    45,    32,    34,    51,    31,    50,    43,     4,
00605       50,    43,    50,   136,    50,    43,    50,    49,    41,    42,
00606        3,    49,    76,    43,    41,    42,    45,     4,     5,   141,
00607      142,    50,   121,    41,    42,    45,    33,     3,   127,     5,
00608       50,     7,    44,     5,    81,     7,    48,     9,    85,    11,
00609       12,   164,    43,    19,    44,    17,    45,    19,   170,    21,
00610        4,    50,    24,    25,   177,     5,    28,    45,     3,    13,
00611       14,    15,    50,    35,    36,    37,     3,    45,    40,    29,
00612       30,   133,    50,     5,    46,     7,    20,     9,    49,    11,
00613       12,    29,    30,     4,     5,    17,    10,    19,    10,    21,
00614       20,    26,    24,    25,    49,     3,    28,    49,     8,   161,
00615       43,     5,    18,    35,    36,    37,    18,    49,    40,    27,
00616        5,    47,     4,     4,     4,    49,    44,    43,    51,     5,
00617       51,    44,    47,    43,    51,     4,   157,    44,   144,    44,
00618       44,    44,    51,    71,   118,   148,   122,    -1,    -1,    28
00619 };
00620 
00621 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
00622    symbol of state STATE-NUM.  */
00623 static const unsigned char yystos[] =
00624 {
00625        0,     5,    53,    93,    49,     0,    31,     4,     5,    50,
00626       57,    61,    62,    29,    30,    94,    43,    50,    61,    32,
00627        4,     3,    44,    33,     5,    89,    90,    91,    92,     3,
00628        5,     7,    19,    34,    91,     5,     7,     9,    11,    12,
00629       17,    19,    21,    24,    25,    28,    35,    36,    37,    40,
00630       46,    64,    65,    68,    69,    70,    73,    74,    77,    78,
00631       79,    80,    81,    85,    86,    87,    88,     3,     3,    20,
00632        8,    43,    71,    72,    43,    49,    10,    18,    49,    72,
00633       10,    49,    20,    26,    18,    49,    72,    72,    49,     4,
00634       13,    14,    15,    63,    29,    30,    80,    49,     4,    41,
00635       42,    54,    55,    56,     3,    43,    71,     4,     5,    56,
00636       57,    67,     5,    43,    59,    60,    72,    80,     5,    83,
00637       84,    18,    49,    84,    27,    80,    84,    18,     5,    75,
00638       76,    47,     4,    62,     4,     4,    49,    57,    44,    51,
00639       44,    48,    43,    56,    45,    50,    81,    82,    45,    50,
00640       80,    76,    50,     5,    50,    80,    43,    45,    50,    47,
00641       50,    62,    44,    51,    51,    56,    56,    44,    59,     6,
00642       16,    66,    83,    50,     4,    75,    50,    51,    57,    44,
00643        5,    22,    23,    56,    58,    44,    57,    44,    44
00644 };
00645 
00646 #if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
00647 # define YYSIZE_T __SIZE_TYPE__
00648 #endif
00649 #if ! defined (YYSIZE_T) && defined (size_t)
00650 # define YYSIZE_T size_t
00651 #endif
00652 #if ! defined (YYSIZE_T)
00653 # if defined (__STDC__) || defined (__cplusplus)
00654 #  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
00655 #  define YYSIZE_T size_t
00656 # endif
00657 #endif
00658 #if ! defined (YYSIZE_T)
00659 # define YYSIZE_T unsigned int
00660 #endif
00661 
00662 #define yyerrok         (yyerrstatus = 0)
00663 #define yyclearin (yychar = YYEMPTY)
00664 #define YYEMPTY         (-2)
00665 #define YYEOF           0
00666 
00667 #define YYACCEPT  goto yyacceptlab
00668 #define YYABORT         goto yyabortlab
00669 #define YYERROR         goto yyerrlab1
00670 
00671 
00672 /* Like YYERROR except do call yyerror.  This remains here temporarily
00673    to ease the transition to the new meaning of YYERROR, for GCC.
00674    Once GCC version 2 has supplanted version 1, this can go.  */
00675 
00676 #define YYFAIL          goto yyerrlab
00677 
00678 #define YYRECOVERING()  (!!yyerrstatus)
00679 
00680 #define YYBACKUP(Token, Value)                              \
00681 do                                              \
00682   if (yychar == YYEMPTY && yylen == 1)                      \
00683     {                                           \
00684       yychar = (Token);                               \
00685       yylval = (Value);                               \
00686       yytoken = YYTRANSLATE (yychar);                       \
00687       YYPOPSTACK;                               \
00688       goto yybackup;                                  \
00689     }                                           \
00690   else                                                \
00691     {                                                 \
00692       yyerror ("syntax error: cannot back up");\
00693       YYERROR;                                        \
00694     }                                           \
00695 while (0)
00696 
00697 #define YYTERROR  1
00698 #define YYERRCODE 256
00699 
00700 /* YYLLOC_DEFAULT -- Compute the default location (before the actions
00701    are run).  */
00702 
00703 #ifndef YYLLOC_DEFAULT
00704 # define YYLLOC_DEFAULT(Current, Rhs, N)         \
00705   Current.first_line   = Rhs[1].first_line;      \
00706   Current.first_column = Rhs[1].first_column;    \
00707   Current.last_line    = Rhs[N].last_line;       \
00708   Current.last_column  = Rhs[N].last_column;
00709 #endif
00710 
00711 /* YYLEX -- calling `yylex' with the right arguments.  */
00712 
00713 #ifdef YYLEX_PARAM
00714 # define YYLEX yylex (YYLEX_PARAM)
00715 #else
00716 # define YYLEX yylex ()
00717 #endif
00718 
00719 /* Enable debugging if requested.  */
00720 #if YYDEBUG
00721 
00722 # ifndef YYFPRINTF
00723 #  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
00724 #  define YYFPRINTF fprintf
00725 # endif
00726 
00727 # define YYDPRINTF(Args)                  \
00728 do {                                \
00729   if (yydebug)                            \
00730     YYFPRINTF Args;                       \
00731 } while (0)
00732 
00733 # define YYDSYMPRINT(Args)                \
00734 do {                                \
00735   if (yydebug)                            \
00736     yysymprint Args;                      \
00737 } while (0)
00738 
00739 # define YYDSYMPRINTF(Title, Token, Value, Location)        \
00740 do {                                            \
00741   if (yydebug)                                        \
00742     {                                           \
00743       YYFPRINTF (stderr, "%s ", Title);                     \
00744       yysymprint (stderr,                             \
00745                   Token, Value);    \
00746       YYFPRINTF (stderr, "\n");                             \
00747     }                                           \
00748 } while (0)
00749 
00750 /*------------------------------------------------------------------.
00751 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
00752 | TOP (cinluded).                                                   |
00753 `------------------------------------------------------------------*/
00754 
00755 #if defined (__STDC__) || defined (__cplusplus)
00756 static void
00757 yy_stack_print (short *bottom, short *top)
00758 #else
00759 static void
00760 yy_stack_print (bottom, top)
00761     short *bottom;
00762     short *top;
00763 #endif
00764 {
00765   YYFPRINTF (stderr, "Stack now");
00766   for (/* Nothing. */; bottom <= top; ++bottom)
00767     YYFPRINTF (stderr, " %d", *bottom);
00768   YYFPRINTF (stderr, "\n");
00769 }
00770 
00771 # define YY_STACK_PRINT(Bottom, Top)                        \
00772 do {                                            \
00773   if (yydebug)                                        \
00774     yy_stack_print ((Bottom), (Top));                       \
00775 } while (0)
00776 
00777 
00778 /*------------------------------------------------.
00779 | Report that the YYRULE is going to be reduced.  |
00780 `------------------------------------------------*/
00781 
00782 #if defined (__STDC__) || defined (__cplusplus)
00783 static void
00784 yy_reduce_print (int yyrule)
00785 #else
00786 static void
00787 yy_reduce_print (yyrule)
00788     int yyrule;
00789 #endif
00790 {
00791   int yyi;
00792   unsigned int yylineno = yyrline[yyrule];
00793   YYFPRINTF (stderr, "Reducing stack by rule %d (line %u), ",
00794              yyrule - 1, yylineno);
00795   /* Print the symbols being reduced, and their result.  */
00796   for (yyi = yyprhs[yyrule]; 0 <= yyrhs[yyi]; yyi++)
00797     YYFPRINTF (stderr, "%s ", yytname [yyrhs[yyi]]);
00798   YYFPRINTF (stderr, "-> %s\n", yytname [yyr1[yyrule]]);
00799 }
00800 
00801 # define YY_REDUCE_PRINT(Rule)            \
00802 do {                          \
00803   if (yydebug)                      \
00804     yy_reduce_print (Rule);         \
00805 } while (0)
00806 
00807 /* Nonzero means print parse trace.  It is left uninitialized so that
00808    multiple parsers can coexist.  */
00809 int yydebug;
00810 #else /* !YYDEBUG */
00811 # define YYDPRINTF(Args)
00812 # define YYDSYMPRINT(Args)
00813 # define YYDSYMPRINTF(Title, Token, Value, Location)
00814 # define YY_STACK_PRINT(Bottom, Top)
00815 # define YY_REDUCE_PRINT(Rule)
00816 #endif /* !YYDEBUG */
00817 
00818 
00819 /* YYINITDEPTH -- initial size of the parser's stacks.  */
00820 #ifndef     YYINITDEPTH
00821 # define YYINITDEPTH 200
00822 #endif
00823 
00824 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
00825    if the built-in stack extension method is used).
00826 
00827    Do not make this value too large; the results are undefined if
00828    SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH)
00829    evaluated with infinite-precision integer arithmetic.  */
00830 
00831 #if YYMAXDEPTH == 0
00832 # undef YYMAXDEPTH
00833 #endif
00834 
00835 #ifndef YYMAXDEPTH
00836 # define YYMAXDEPTH 10000
00837 #endif
00838 
00839 
00840 
00841 #if YYERROR_VERBOSE
00842 
00843 # ifndef yystrlen
00844 #  if defined (__GLIBC__) && defined (_STRING_H)
00845 #   define yystrlen strlen
00846 #  else
00847 /* Return the length of YYSTR.  */
00848 static YYSIZE_T
00849 #   if defined (__STDC__) || defined (__cplusplus)
00850 yystrlen (const char *yystr)
00851 #   else
00852 yystrlen (yystr)
00853      const char *yystr;
00854 #   endif
00855 {
00856   register const char *yys = yystr;
00857 
00858   while (*yys++ != '\0')
00859     continue;
00860 
00861   return yys - yystr - 1;
00862 }
00863 #  endif
00864 # endif
00865 
00866 # ifndef yystpcpy
00867 #  if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE)
00868 #   define yystpcpy stpcpy
00869 #  else
00870 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
00871    YYDEST.  */
00872 static char *
00873 #   if defined (__STDC__) || defined (__cplusplus)
00874 yystpcpy (char *yydest, const char *yysrc)
00875 #   else
00876 yystpcpy (yydest, yysrc)
00877      char *yydest;
00878      const char *yysrc;
00879 #   endif
00880 {
00881   register char *yyd = yydest;
00882   register const char *yys = yysrc;
00883 
00884   while ((*yyd++ = *yys++) != '\0')
00885     continue;
00886 
00887   return yyd - 1;
00888 }
00889 #  endif
00890 # endif
00891 
00892 #endif /* !YYERROR_VERBOSE */
00893 
00894 
00895 
00896 #if YYDEBUG
00897 /*--------------------------------.
00898 | Print this symbol on YYOUTPUT.  |
00899 `--------------------------------*/
00900 
00901 #if defined (__STDC__) || defined (__cplusplus)
00902 static void
00903 yysymprint (FILE *yyoutput, int yytype, YYSTYPE *yyvaluep)
00904 #else
00905 static void
00906 yysymprint (yyoutput, yytype, yyvaluep)
00907     FILE *yyoutput;
00908     int yytype;
00909     YYSTYPE *yyvaluep;
00910 #endif
00911 {
00912   /* Pacify ``unused variable'' warnings.  */
00913   (void) yyvaluep;
00914 
00915   if (yytype < YYNTOKENS)
00916     {
00917       YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
00918 # ifdef YYPRINT
00919       YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
00920 # endif
00921     }
00922   else
00923     YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
00924 
00925   switch (yytype)
00926     {
00927       default:
00928         break;
00929     }
00930   YYFPRINTF (yyoutput, ")");
00931 }
00932 
00933 #endif /* ! YYDEBUG */
00934 /*-----------------------------------------------.
00935 | Release the memory associated to this symbol.  |
00936 `-----------------------------------------------*/
00937 
00938 #if defined (__STDC__) || defined (__cplusplus)
00939 static void
00940 yydestruct (int yytype, YYSTYPE *yyvaluep)
00941 #else
00942 static void
00943 yydestruct (yytype, yyvaluep)
00944     int yytype;
00945     YYSTYPE *yyvaluep;
00946 #endif
00947 {
00948   /* Pacify ``unused variable'' warnings.  */
00949   (void) yyvaluep;
00950 
00951   switch (yytype)
00952     {
00953 
00954       default:
00955         break;
00956     }
00957 }
00958 
00959 
00960 /* Prevent warnings from -Wmissing-prototypes.  */
00961 
00962 #ifdef YYPARSE_PARAM
00963 # if defined (__STDC__) || defined (__cplusplus)
00964 int yyparse (void *YYPARSE_PARAM);
00965 # else
00966 int yyparse ();
00967 # endif
00968 #else /* ! YYPARSE_PARAM */
00969 #if defined (__STDC__) || defined (__cplusplus)
00970 int yyparse (void);
00971 #else
00972 int yyparse ();
00973 #endif
00974 #endif /* ! YYPARSE_PARAM */
00975 
00976 
00977 
00978 /* The lookahead symbol.  */
00979 int yychar;
00980 
00981 /* The semantic value of the lookahead symbol.  */
00982 YYSTYPE yylval;
00983 
00984 /* Number of syntax errors so far.  */
00985 int yynerrs;
00986 
00987 
00988 
00989 /*----------.
00990 | yyparse.  |
00991 `----------*/
00992 
00993 #ifdef YYPARSE_PARAM
00994 # if defined (__STDC__) || defined (__cplusplus)
00995 int yyparse (void *YYPARSE_PARAM)
00996 # else
00997 int yyparse (YYPARSE_PARAM)
00998   void *YYPARSE_PARAM;
00999 # endif
01000 #else /* ! YYPARSE_PARAM */
01001 #if defined (__STDC__) || defined (__cplusplus)
01002 int
01003 yyparse (void)
01004 #else
01005 int
01006 yyparse ()
01007 
01008 #endif
01009 #endif
01010 {
01011   
01012   register int yystate;
01013   register int yyn;
01014   int yyresult;
01015   /* Number of tokens to shift before error messages enabled.  */
01016   int yyerrstatus;
01017   /* Lookahead token as an internal (translated) token number.  */
01018   int yytoken = 0;
01019 
01020   /* Three stacks and their tools:
01021      `yyss': related to states,
01022      `yyvs': related to semantic values,
01023      `yyls': related to locations.
01024 
01025      Refer to the stacks thru separate pointers, to allow yyoverflow
01026      to reallocate them elsewhere.  */
01027 
01028   /* The state stack.  */
01029   short     yyssa[YYINITDEPTH];
01030   short *yyss = yyssa;
01031   register short *yyssp;
01032 
01033   /* The semantic value stack.  */
01034   YYSTYPE yyvsa[YYINITDEPTH];
01035   YYSTYPE *yyvs = yyvsa;
01036   register YYSTYPE *yyvsp;
01037 
01038 
01039 
01040 #define YYPOPSTACK   (yyvsp--, yyssp--)
01041 
01042   YYSIZE_T yystacksize = YYINITDEPTH;
01043 
01044   /* The variables used to return semantic value and location from the
01045      action routines.  */
01046   YYSTYPE yyval;
01047 
01048 
01049   /* When reducing, the number of symbols on the RHS of the reduced
01050      rule.  */
01051   int yylen;
01052 
01053   YYDPRINTF ((stderr, "Starting parse\n"));
01054 
01055   yystate = 0;
01056   yyerrstatus = 0;
01057   yynerrs = 0;
01058   yychar = YYEMPTY;           /* Cause a token to be read.  */
01059 
01060   /* Initialize stack pointers.
01061      Waste one element of value and location stack
01062      so that they stay on the same level as the state stack.
01063      The wasted elements are never initialized.  */
01064 
01065   yyssp = yyss;
01066   yyvsp = yyvs;
01067 
01068   goto yysetstate;
01069 
01070 /*------------------------------------------------------------.
01071 | yynewstate -- Push a new state, which is found in yystate.  |
01072 `------------------------------------------------------------*/
01073  yynewstate:
01074   /* In all cases, when you get here, the value and location stacks
01075      have just been pushed. so pushing a state here evens the stacks.
01076      */
01077   yyssp++;
01078 
01079  yysetstate:
01080   *yyssp = yystate;
01081 
01082   if (yyss + yystacksize - 1 <= yyssp)
01083     {
01084       /* Get the current used size of the three stacks, in elements.  */
01085       YYSIZE_T yysize = yyssp - yyss + 1;
01086 
01087 #ifdef yyoverflow
01088       {
01089       /* Give user a chance to reallocate the stack. Use copies of
01090          these so that the &'s don't force the real ones into
01091          memory.  */
01092       YYSTYPE *yyvs1 = yyvs;
01093       short *yyss1 = yyss;
01094 
01095 
01096       /* Each stack pointer address is followed by the size of the
01097          data in use in that stack, in bytes.  This used to be a
01098          conditional around just the two extra args, but that might
01099          be undefined if yyoverflow is a macro.  */
01100       yyoverflow ("parser stack overflow",
01101                 &yyss1, yysize * sizeof (*yyssp),
01102                 &yyvs1, yysize * sizeof (*yyvsp),
01103 
01104                 &yystacksize);
01105 
01106       yyss = yyss1;
01107       yyvs = yyvs1;
01108       }
01109 #else /* no yyoverflow */
01110 # ifndef YYSTACK_RELOCATE
01111       goto yyoverflowlab;
01112 # else
01113       /* Extend the stack our own way.  */
01114       if (YYMAXDEPTH <= yystacksize)
01115       goto yyoverflowlab;
01116       yystacksize *= 2;
01117       if (YYMAXDEPTH < yystacksize)
01118       yystacksize = YYMAXDEPTH;
01119 
01120       {
01121       short *yyss1 = yyss;
01122       union yyalloc *yyptr =
01123         (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
01124       if (! yyptr)
01125         goto yyoverflowlab;
01126       YYSTACK_RELOCATE (yyss);
01127       YYSTACK_RELOCATE (yyvs);
01128 
01129 #  undef YYSTACK_RELOCATE
01130       if (yyss1 != yyssa)
01131         YYSTACK_FREE (yyss1);
01132       }
01133 # endif
01134 #endif /* no yyoverflow */
01135 
01136       yyssp = yyss + yysize - 1;
01137       yyvsp = yyvs + yysize - 1;
01138 
01139 
01140       YYDPRINTF ((stderr, "Stack size increased to %lu\n",
01141               (unsigned long int) yystacksize));
01142 
01143       if (yyss + yystacksize - 1 <= yyssp)
01144       YYABORT;
01145     }
01146 
01147   YYDPRINTF ((stderr, "Entering state %d\n", yystate));
01148 
01149   goto yybackup;
01150 
01151 /*-----------.
01152 | yybackup.  |
01153 `-----------*/
01154 yybackup:
01155 
01156 /* Do appropriate processing given the current state.  */
01157 /* Read a lookahead token if we need one and don't already have one.  */
01158 /* yyresume: */
01159 
01160   /* First try to decide what to do without reference to lookahead token.  */
01161 
01162   yyn = yypact[yystate];
01163   if (yyn == YYPACT_NINF)
01164     goto yydefault;
01165 
01166   /* Not known => get a lookahead token if don't already have one.  */
01167 
01168   /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol.  */
01169   if (yychar == YYEMPTY)
01170     {
01171       YYDPRINTF ((stderr, "Reading a token: "));
01172       yychar = YYLEX;
01173     }
01174 
01175   if (yychar <= YYEOF)
01176     {
01177       yychar = yytoken = YYEOF;
01178       YYDPRINTF ((stderr, "Now at end of input.\n"));
01179     }
01180   else
01181     {
01182       yytoken = YYTRANSLATE (yychar);
01183       YYDSYMPRINTF ("Next token is", yytoken, &yylval, &yylloc);
01184     }
01185 
01186   /* If the proper action on seeing token YYTOKEN is to reduce or to
01187      detect an error, take that action.  */
01188   yyn += yytoken;
01189   if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
01190     goto yydefault;
01191   yyn = yytable[yyn];
01192   if (yyn <= 0)
01193     {
01194       if (yyn == 0 || yyn == YYTABLE_NINF)
01195       goto yyerrlab;
01196       yyn = -yyn;
01197       goto yyreduce;
01198     }
01199 
01200   if (yyn == YYFINAL)
01201     YYACCEPT;
01202 
01203   /* Shift the lookahead token.  */
01204   YYDPRINTF ((stderr, "Shifting token %s, ", yytname[yytoken]));
01205 
01206   /* Discard the token being shifted unless it is eof.  */
01207   if (yychar != YYEOF)
01208     yychar = YYEMPTY;
01209 
01210   *++yyvsp = yylval;
01211 
01212 
01213   /* Count tokens shifted since error; after three, turn off error
01214      status.  */
01215   if (yyerrstatus)
01216     yyerrstatus--;
01217 
01218   yystate = yyn;
01219   goto yynewstate;
01220 
01221 
01222 /*-----------------------------------------------------------.
01223 | yydefault -- do the default action for the current state.  |
01224 `-----------------------------------------------------------*/
01225 yydefault:
01226   yyn = yydefact[yystate];
01227   if (yyn == 0)
01228     goto yyerrlab;
01229   goto yyreduce;
01230 
01231 
01232 /*-----------------------------.
01233 | yyreduce -- Do a reduction.  |
01234 `-----------------------------*/
01235 yyreduce:
01236   /* yyn is the number of a rule to reduce with.  */
01237   yylen = yyr2[yyn];
01238 
01239   /* If YYLEN is nonzero, implement the default value of the action:
01240      `$$ = $1'.
01241 
01242      Otherwise, the following line sets YYVAL to garbage.
01243      This behavior is undocumented and Bison
01244      users should not rely upon it.  Assigning to YYVAL
01245      unconditionally makes the parser a bit smaller, and it avoids a
01246      GCC warning that YYVAL may be used uninitialized.  */
01247   yyval = yyvsp[1-yylen];
01248 
01249 
01250   YY_REDUCE_PRINT (yyn);
01251   switch (yyn)
01252     {
01253         case 2:
01254 #line 120 "ASN1.y"
01255     {yyval.node=_asn1_add_node(TYPE_DEFINITIONS|yyvsp[-5].constant);
01256                     _asn1_set_name(yyval.node,_asn1_get_name(yyvsp[-7].node));
01257                     _asn1_set_name(yyvsp[-7].node,"");
01258                     _asn1_set_right(yyvsp[-7].node,yyvsp[-1].node);
01259                     _asn1_set_down(yyval.node,yyvsp[-7].node);
01260                
01261                 p_tree=yyval.node;
01262                 }
01263     break;
01264 
01265   case 3:
01266 #line 130 "ASN1.y"
01267     {strcpy(yyval.str,yyvsp[0].str);}
01268     break;
01269 
01270   case 4:
01271 #line 131 "ASN1.y"
01272     {strcpy(yyval.str,yyvsp[0].str);}
01273     break;
01274 
01275   case 5:
01276 #line 134 "ASN1.y"
01277     {strcpy(yyval.str,"-");
01278                        strcat(yyval.str,yyvsp[0].str);}
01279     break;
01280 
01281   case 6:
01282 #line 138 "ASN1.y"
01283     {strcpy(yyval.str,yyvsp[0].str);}
01284     break;
01285 
01286   case 7:
01287 #line 139 "ASN1.y"
01288     {strcpy(yyval.str,yyvsp[0].str);}
01289     break;
01290 
01291   case 8:
01292 #line 142 "ASN1.y"
01293     {strcpy(yyval.str,yyvsp[0].str);}
01294     break;
01295 
01296   case 9:
01297 #line 143 "ASN1.y"
01298     {strcpy(yyval.str,yyvsp[0].str);}
01299     break;
01300 
01301   case 10:
01302 #line 146 "ASN1.y"
01303     {strcpy(yyval.str,yyvsp[0].str);}
01304     break;
01305 
01306   case 11:
01307 #line 147 "ASN1.y"
01308     {strcpy(yyval.str,yyvsp[0].str);}
01309     break;
01310 
01311   case 12:
01312 #line 150 "ASN1.y"
01313     {yyval.node=_asn1_add_node(TYPE_CONSTANT); 
01314                                        _asn1_set_value(yyval.node,yyvsp[-1].str,strlen(yyvsp[-1].str)+1);}
01315     break;
01316 
01317   case 13:
01318 #line 152 "ASN1.y"
01319     {yyval.node=_asn1_add_node(TYPE_CONSTANT);
01320                                      _asn1_set_name(yyval.node,yyvsp[-3].str); 
01321                                        _asn1_set_value(yyval.node,yyvsp[-1].str,strlen(yyvsp[-1].str)+1);}
01322     break;
01323 
01324   case 14:
01325 #line 157 "ASN1.y"
01326     {yyval.node=yyvsp[0].node;}
01327     break;
01328 
01329   case 15:
01330 #line 158 "ASN1.y"
01331     {yyval.node=yyvsp[-2].node;
01332                                             _asn1_set_right(_asn1_get_last_right(yyvsp[-2].node),yyvsp[0].node);}
01333     break;
01334 
01335   case 16:
01336 #line 162 "ASN1.y"
01337     {yyval.node=_asn1_add_node(TYPE_CONSTANT); 
01338                                    _asn1_set_value(yyval.node,yyvsp[0].str,strlen(yyvsp[0].str)+1);}
01339     break;
01340 
01341   case 17:
01342 #line 164 "ASN1.y"
01343     {yyval.node=_asn1_add_node(TYPE_CONSTANT);
01344                                   _asn1_set_name(yyval.node,yyvsp[-3].str); 
01345                                     _asn1_set_value(yyval.node,yyvsp[-1].str,strlen(yyvsp[-1].str)+1);}
01346     break;
01347 
01348   case 18:
01349 #line 169 "ASN1.y"
01350     {yyval.node=yyvsp[0].node;}
01351     break;
01352 
01353   case 19:
01354 #line 170 "ASN1.y"
01355     {yyval.node=yyvsp[-1].node;
01356                                                     _asn1_set_right(_asn1_get_last_right(yyvsp[-1].node),yyvsp[0].node);}
01357     break;
01358 
01359   case 20:
01360 #line 174 "ASN1.y"
01361     {yyval.constant=CONST_UNIVERSAL;}
01362     break;
01363 
01364   case 21:
01365 #line 175 "ASN1.y"
01366     {yyval.constant=CONST_PRIVATE;}
01367     break;
01368 
01369   case 22:
01370 #line 176 "ASN1.y"
01371     {yyval.constant=CONST_APPLICATION;}
01372     break;
01373 
01374   case 23:
01375 #line 179 "ASN1.y"
01376     {yyval.node=_asn1_add_node(TYPE_TAG); 
01377                             _asn1_set_value(yyval.node,yyvsp[-1].str,strlen(yyvsp[-1].str)+1);}
01378     break;
01379 
01380   case 24:
01381 #line 181 "ASN1.y"
01382     {yyval.node=_asn1_add_node(TYPE_TAG | yyvsp[-2].constant); 
01383                                 _asn1_set_value(yyval.node,yyvsp[-1].str,strlen(yyvsp[-1].str)+1);}
01384     break;
01385 
01386   case 25:
01387 #line 185 "ASN1.y"
01388     {yyval.node=yyvsp[0].node;}
01389     break;
01390 
01391   case 26:
01392 #line 186 "ASN1.y"
01393     {yyval.node=_asn1_mod_type(yyvsp[-1].node,CONST_EXPLICIT);}
01394     break;
01395 
01396   case 27:
01397 #line 187 "ASN1.y"
01398     {yyval.node=_asn1_mod_type(yyvsp[-1].node,CONST_IMPLICIT);}
01399     break;
01400 
01401   case 28:
01402 #line 190 "ASN1.y"
01403     {yyval.node=_asn1_add_node(TYPE_DEFAULT); 
01404                                        _asn1_set_value(yyval.node,yyvsp[0].str,strlen(yyvsp[0].str)+1);}
01405     break;
01406 
01407   case 29:
01408 #line 192 "ASN1.y"
01409     {yyval.node=_asn1_add_node(TYPE_DEFAULT|CONST_TRUE);}
01410     break;
01411 
01412   case 30:
01413 #line 193 "ASN1.y"
01414     {yyval.node=_asn1_add_node(TYPE_DEFAULT|CONST_FALSE);}
01415     break;
01416 
01417   case 33:
01418 #line 202 "ASN1.y"
01419     {yyval.node=_asn1_add_node(TYPE_INTEGER);}
01420     break;
01421 
01422   case 34:
01423 #line 203 "ASN1.y"
01424     {yyval.node=_asn1_add_node(TYPE_INTEGER|CONST_LIST);
01425                                        _asn1_set_down(yyval.node,yyvsp[-1].node);}
01426     break;
01427 
01428   case 35:
01429 #line 205 "ASN1.y"
01430     {yyval.node=_asn1_add_node(TYPE_INTEGER);}
01431     break;
01432 
01433   case 36:
01434 #line 207 "ASN1.y"
01435     {yyval.node=_asn1_add_node(TYPE_INTEGER|CONST_MIN_MAX);
01436                                          _asn1_set_down(yyval.node,_asn1_add_node(TYPE_SIZE)); 
01437                                          _asn1_set_value(_asn1_get_down(yyval.node),yyvsp[-1].str,strlen(yyvsp[-1].str)+1); 
01438                                          _asn1_set_name(_asn1_get_down(yyval.node),yyvsp[-4].str);}
01439     break;
01440 
01441   case 37:
01442 #line 213 "ASN1.y"
01443     {yyval.node=_asn1_add_node(TYPE_BOOLEAN);}
01444     break;
01445 
01446   case 38:
01447 #line 216 "ASN1.y"
01448     {yyval.node=_asn1_add_node(TYPE_TIME|CONST_UTC);}
01449     break;
01450 
01451   case 39:
01452 #line 217 "ASN1.y"
01453     {yyval.node=_asn1_add_node(TYPE_TIME|CONST_GENERALIZED);}
01454     break;
01455 
01456   case 40:
01457