Changeset 3434

Show
Ignore:
Timestamp:
05/19/05 09:22:52 (4 years ago)
Author:
autrijus
svk:copy_cache_prev:
5016
Message:

* Upgrade to Syck 0.55 from «why the lucky stiff».

Files:
5 modified

Legend:

Unmodified
Added
Removed
  • README

    r3336 r3434  
    2020under a BSD-style license.  See src/pcre/LICENCE. 
    2121 
    22 The "Syck" subsystem is derived from Syck 0.54 by "why the lucky stiff", 
     22The "Syck" subsystem is derived from Syck 0.55 by "why the lucky stiff", 
    2323under a BSD-style license.  See src/syck/COPYING. 
    2424 
  • src/syck/emitter.c

    r2786 r3434  
    33 * 
    44 * $Author: why $ 
    5  * $Date: 2005/04/13 06:27:54 $ 
     5 * $Date: 2005/05/19 06:07:42 $ 
    66 * 
    77 * Copyright (C) 2003 why the lucky stiff 
     
    492492    int i; 
    493493    SyckLevel *lvl = syck_emitter_current_level( e ); 
    494     char *spcs = S_ALLOC_N( char, lvl->spaces + 2 ); 
    495  
    496     spcs[0] = '\n'; spcs[lvl->spaces + 1] = '\0'; 
    497     for ( i = 0; i < lvl->spaces; i++ ) spcs[i+1] = ' '; 
    498     syck_emitter_write( e, spcs, lvl->spaces + 1 ); 
    499     free( spcs ); 
     494    if ( lvl->spaces >= 0 ) { 
     495        char *spcs = S_ALLOC_N( char, lvl->spaces + 2 ); 
     496 
     497        spcs[0] = '\n'; spcs[lvl->spaces + 1] = '\0'; 
     498        for ( i = 0; i < lvl->spaces; i++ ) spcs[i+1] = ' '; 
     499        syck_emitter_write( e, spcs, lvl->spaces + 1 ); 
     500        free( spcs ); 
     501    } 
    500502} 
    501503 
     
    528530/* Contains flow seq indicators */ 
    529531#define SCAN_FLOWSEQ    4096 
     532/* Contains a valid doc separator */ 
     533#define SCAN_DOCSEP     8192 
    530534 
    531535/* 
     
    564568    } 
    565569 
     570    /* opening doc sep */ 
     571    if ( len >= 3 && strncmp( cursor, "---", 3 ) == 0 ) 
     572        flags |= SCAN_DOCSEP; 
     573 
    566574    /* scan string */ 
    567575    for ( i = 0; i < len; i++ ) { 
     
    576584        else if ( cursor[i] == '\n' ) { 
    577585            flags |= SCAN_NEWLINE; 
     586            if ( len - i >= 3 && strncmp( &cursor[i+1], "---", 3 ) == 0 ) 
     587                flags |= SCAN_DOCSEP; 
    578588            if ( cursor[i+1] == ' ' || cursor[i+1] == '\t' )  
    579589                flags |= SCAN_INDENTED; 
     
    643653    } 
    644654 
    645     scan = syck_scan_scalar( force_indent, str, len ); 
     655    scan = syck_scan_scalar( force_width, str, len ); 
    646656    implicit = syck_match_implicit( str, len ); 
    647657 
     
    691701    } 
    692702 
    693     if ( force_indent == 0 ) { 
    694         force_indent = e->indent; 
     703    if ( force_indent > 0 ) { 
     704        lvl->spaces = parent->spaces + force_indent; 
     705    } else if ( scan & SCAN_DOCSEP ) { 
     706        lvl->spaces = parent->spaces + e->indent; 
    695707    } 
    696708 
     
    10101022                    syck_emitter_write( e, "?", 1 ); 
    10111023                    parent->status = syck_lvl_mapx; 
    1012                 } else { 
     1024                /* shortcut -- the lvl->anctag check should be unneccesary but 
     1025                 * there is a nasty shift/reduce in the parser on this point and 
     1026                 * i'm not ready to tickle it. */ 
     1027                } else if ( lvl->anctag == 0 ) {  
    10131028                    lvl->spaces = parent->spaces; 
    10141029                } 
  • src/syck/gram.c

    r2786 r3434  
    1 /* A Bison parser, made from gram.y, by GNU bison 1.75.  */ 
     1/* A Bison parser, made by GNU Bison 1.875d.  */ 
    22 
    33/* Skeleton parser for Yacc-like parsing with Bison, 
    4    Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software Foundation, Inc. 
     4   Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. 
    55 
    66   This program is free software; you can redistribute it and/or modify 
     
    3535 
    3636/* Identify Bison output.  */ 
    37 #define YYBISON 1 
     37#define YYBISON 1 
     38 
     39/* Skeleton name.  */ 
     40#define YYSKELETON_NAME "yacc.c" 
    3841 
    3942/* Pure parsers.  */ 
    40 #define YYPURE  1 
     43#define YYPURE 1 
    4144 
    4245/* Using locations.  */ 
     
    126129#endif 
    127130 
    128 #ifndef YYSTYPE 
     131#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED) 
    129132#line 35 "gram.y" 
    130 typedef union { 
     133typedef union YYSTYPE { 
    131134    SYMID nodeId; 
    132135    SyckNode *nodeData; 
    133136    char *name; 
    134 } yystype; 
    135 /* Line 193 of /usr/local/share/bison/yacc.c.  */ 
    136 #line 137 "gram.c" 
    137 # define YYSTYPE yystype 
     137} YYSTYPE; 
     138/* Line 191 of yacc.c.  */ 
     139#line 140 "gram.c" 
     140# define yystype YYSTYPE /* obsolescent; will be withdrawn */ 
     141# define YYSTYPE_IS_DECLARED 1 
    138142# define YYSTYPE_IS_TRIVIAL 1 
    139143#endif 
    140144 
    141 #ifndef YYLTYPE 
    142 typedef struct yyltype 
    143 { 
    144   int first_line; 
    145   int first_column; 
    146   int last_line; 
    147   int last_column; 
    148 } yyltype; 
    149 # define YYLTYPE yyltype 
    150 # define YYLTYPE_IS_TRIVIAL 1 
    151 #endif 
     145 
    152146 
    153147/* Copy the second part of user declarations.  */ 
    154148 
    155149 
    156 /* Line 213 of /usr/local/share/bison/yacc.c.  */ 
    157 #line 158 "gram.c" 
     150/* Line 214 of yacc.c.  */ 
     151#line 152 "gram.c" 
    158152 
    159153#if ! defined (yyoverflow) || YYERROR_VERBOSE 
    160154 
     155# ifndef YYFREE 
     156#  define YYFREE free 
     157# endif 
     158# ifndef YYMALLOC 
     159#  define YYMALLOC malloc 
     160# endif 
     161 
    161162/* The parser invokes alloca or malloc; define the necessary symbols.  */ 
    162163 
    163 # if YYSTACK_USE_ALLOCA 
    164 #  define YYSTACK_ALLOC alloca 
     164# ifdef YYSTACK_USE_ALLOCA 
     165#  if YYSTACK_USE_ALLOCA 
     166#   define YYSTACK_ALLOC alloca 
     167#  endif 
    165168# else 
    166 #  ifndef YYSTACK_USE_ALLOCA 
    167 #   if defined (alloca) || defined (_ALLOCA_H) 
    168 #    define YYSTACK_ALLOC alloca 
    169 #   else 
    170 #    ifdef __GNUC__ 
    171 #     define YYSTACK_ALLOC __builtin_alloca 
    172 #    endif 
     169#  if defined (alloca) || defined (_ALLOCA_H) 
     170#   define YYSTACK_ALLOC alloca 
     171#  else 
     172#   ifdef __GNUC__ 
     173#    define YYSTACK_ALLOC __builtin_alloca 
    173174#   endif 
    174175#  endif 
     
    183184#   define YYSIZE_T size_t 
    184185#  endif 
    185 #  define YYSTACK_ALLOC malloc 
    186 #  define YYSTACK_FREE free 
     186#  define YYSTACK_ALLOC YYMALLOC 
     187#  define YYSTACK_FREE YYFREE 
    187188# endif 
    188189#endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */ 
     
    191192#if (! defined (yyoverflow) \ 
    192193     && (! defined (__cplusplus) \ 
    193          || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) 
     194         || (defined (YYSTYPE_IS_TRIVIAL) && YYSTYPE_IS_TRIVIAL))) 
    194195 
    195196/* A type that is properly aligned for any stack member.  */ 
    196197union yyalloc 
    197198{ 
    198   short yyss; 
     199  short int yyss; 
    199200  YYSTYPE yyvs; 
    200201  }; 
    201202 
    202203/* The size of the maximum gap between one aligned stack and the next.  */ 
    203 # define YYSTACK_GAP_MAX (sizeof (union yyalloc) - 1) 
     204# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) 
    204205 
    205206/* The size of an array large to enough to hold all stacks, each with 
    206207   N elements.  */ 
    207208# define YYSTACK_BYTES(N) \ 
    208      ((N) * (sizeof (short) + sizeof (YYSTYPE))                         \ 
    209       + YYSTACK_GAP_MAX) 
     209     ((N) * (sizeof (short int) + sizeof (YYSTYPE))                     \ 
     210      + YYSTACK_GAP_MAXIMUM) 
    210211 
    211212/* Copy COUNT objects from FROM to TO.  The source and destination do 
    212213   not overlap.  */ 
    213214# ifndef YYCOPY 
    214 #  if 1 < __GNUC__ 
     215#  if defined (__GNUC__) && 1 < __GNUC__ 
    215216#   define YYCOPY(To, From, Count) \ 
    216217      __builtin_memcpy (To, From, (Count) * sizeof (*(From))) 
     
    221222          register YYSIZE_T yyi;                \ 
    222223          for (yyi = 0; yyi < (Count); yyi++)   \ 
    223             (To)[yyi] = (From)[yyi];    \ 
     224            (To)[yyi] = (From)[yyi];            \ 
    224225        }                                       \ 
    225226      while (0) 
     
    238239        YYCOPY (&yyptr->Stack, Stack, yysize);                          \ 
    239240        Stack = &yyptr->Stack;                                          \ 
    240         yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX;   \ 
     241        yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ 
    241242        yyptr += yynewbytes / sizeof (*yyptr);                          \ 
    242243      }                                                                 \ 
     
    248249   typedef signed char yysigned_char; 
    249250#else 
    250    typedef short yysigned_char; 
     251   typedef short int yysigned_char; 
    251252#endif 
    252253 
    253254/* YYFINAL -- State number of the termination state. */ 
    254255#define YYFINAL  52 
     256/* YYLAST -- Last index in YYTABLE.  */ 
    255257#define YYLAST   396 
    256258 
     
    268270#define YYMAXUTOK   269 
    269271 
    270 #define YYTRANSLATE(X) \ 
    271   ((unsigned)(X) <= YYMAXUTOK ? yytranslate[X] : YYUNDEFTOK) 
     272#define YYTRANSLATE(YYX)                                                \ 
     273  ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) 
    272274 
    273275/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */ 
     
    347349 
    348350/* YYRLINE[YYN] -- source line where rule number YYN was defined.  */ 
    349 static const unsigned short yyrline[] = 
    350 { 
    351        0,    56,    56,    60,    64,    70,    71,    74,    75,    80, 
    352       85,    94,   100,   101,   104,   108,   113,   121,   126,   131, 
     351static const unsigned short int yyrline[] = 
     352{ 
     353       0,    56,    56,    60,    65,    70,    71,    74,    75,    80, 
     354      85,    94,   100,   101,   104,   109,   113,   121,   126,   131, 
    353355     145,   146,   149,   152,   155,   156,   164,   169,   174,   182, 
    354356     186,   194,   207,   208,   218,   219,   220,   221,   222,   228, 
     
    365367static const char *const yytname[] = 
    366368{ 
    367   "$end", "error", "$undefined", "YAML_ANCHOR", "YAML_ALIAS",  
    368   "YAML_TRANSFER", "YAML_TAGURI", "YAML_ITRANSFER", "YAML_WORD",  
    369   "YAML_PLAIN", "YAML_BLOCK", "YAML_DOCSEP", "YAML_IOPEN", "YAML_INDENT",  
    370   "YAML_IEND", "'-'", "':'", "'['", "']'", "'{'", "'}'", "','", "'?'",  
    371   "$accept", "doc", "atom", "ind_rep", "atom_or_empty", "empty",  
    372   "indent_open", "indent_end", "indent_sep", "indent_flex_end",  
    373   "word_rep", "struct_rep", "implicit_seq", "basic_seq", "top_imp_seq",  
    374   "in_implicit_seq", "inline_seq", "in_inline_seq", "inline_seq_atom",  
    375   "implicit_map", "top_imp_map", "complex_key", "complex_value",  
    376   "complex_mapping", "in_implicit_map", "basic_mapping", "inline_map",  
     369  "$end", "error", "$undefined", "YAML_ANCHOR", "YAML_ALIAS", 
     370  "YAML_TRANSFER", "YAML_TAGURI", "YAML_ITRANSFER", "YAML_WORD", 
     371  "YAML_PLAIN", "YAML_BLOCK", "YAML_DOCSEP", "YAML_IOPEN", "YAML_INDENT", 
     372  "YAML_IEND", "'-'", "':'", "'['", "']'", "'{'", "'}'", "','", "'?'", 
     373  "$accept", "doc", "atom", "ind_rep", "atom_or_empty", "empty", 
     374  "indent_open", "indent_end", "indent_sep", "indent_flex_end", "word_rep", 
     375  "struct_rep", "implicit_seq", "basic_seq", "top_imp_seq", 
     376  "in_implicit_seq", "inline_seq", "in_inline_seq", "inline_seq_atom", 
     377  "implicit_map", "top_imp_map", "complex_key", "complex_value", 
     378  "complex_mapping", "in_implicit_map", "basic_mapping", "inline_map", 
    377379  "in_inline_map", "inline_map_atom", 0 
    378380}; 
     
    382384/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to 
    383385   token YYLEX-NUM.  */ 
    384 static const unsigned short yytoknum[] = 
     386static const unsigned short int yytoknum[] = 
    385387{ 
    386388       0,   256,   257,   258,   259,   260,   261,   262,   263,   264, 
     
    447449   STATE-NUM.  */ 
    448450#define YYPACT_NINF -97 
    449 static const short yypact[] = 
     451static const short int yypact[] = 
    450452{ 
    451453     250,   318,   -97,   318,   318,   374,   -97,   -97,   -97,   335, 
     
    475477   positive, shift that token.  If negative, reduce the rule which 
    476478   number is the opposite.  If zero, do what YYDEFACT says. 
    477    If YYTABLE_NINF, parse error.  */ 
     479   If YYTABLE_NINF, syntax error.  */ 
    478480#define YYTABLE_NINF -1 
    479481static const unsigned char yytable[] = 
     
    602604#define yyerrok         (yyerrstatus = 0) 
    603605#define yyclearin       (yychar = YYEMPTY) 
    604 #define YYEMPTY         -2 
     606#define YYEMPTY         (-2) 
    605607#define YYEOF           0 
    606608 
    607609#define YYACCEPT        goto yyacceptlab 
    608610#define YYABORT         goto yyabortlab 
    609 #define YYERROR         goto yyerrlab1 
     611#define YYERROR         goto yyerrorlab 
     612 
    610613 
    611614/* Like YYERROR except do call yyerror.  This remains here temporarily 
     
    623626      yychar = (Token);                                         \ 
    624627      yylval = (Value);                                         \ 
    625       yychar1 = YYTRANSLATE (yychar);                           \ 
     628      yytoken = YYTRANSLATE (yychar);                           \ 
    626629      YYPOPSTACK;                                               \ 
    627630      goto yybackup;                                            \ 
     
    629632  else                                                          \ 
    630633    {                                                           \ 
    631       yyerror ("syntax error: cannot back up");                 \ 
     634      yyerror ("syntax error: cannot back up");\ 
    632635      YYERROR;                                                  \ 
    633636    }                                                           \ 
     
    641644 
    642645#ifndef YYLLOC_DEFAULT 
    643 # define YYLLOC_DEFAULT(Current, Rhs, N)           \ 
    644   Current.first_line   = Rhs[1].first_line;      \ 
    645   Current.first_column = Rhs[1].first_column;    \ 
    646   Current.last_line    = Rhs[N].last_line;       \ 
    647   Current.last_column  = Rhs[N].last_column; 
     646# define YYLLOC_DEFAULT(Current, Rhs, N)                \ 
     647   ((Current).first_line   = (Rhs)[1].first_line,       \ 
     648    (Current).first_column = (Rhs)[1].first_column,     \ 
     649    (Current).last_line    = (Rhs)[N].last_line,        \ 
     650    (Current).last_column  = (Rhs)[N].last_column) 
    648651#endif 
    649652 
     
    651654 
    652655#ifdef YYLEX_PARAM 
    653 # define YYLEX  yylex (&yylval, YYLEX_PARAM) 
     656# define YYLEX yylex (&yylval, YYLEX_PARAM) 
    654657#else 
    655 # define YYLEX  yylex (&yylval) 
     658# define YYLEX yylex (&yylval) 
    656659#endif 
    657660 
     
    669672    YYFPRINTF Args;                             \ 
    670673} while (0) 
     674 
    671675# define YYDSYMPRINT(Args)                      \ 
    672676do {                                            \ 
     
    674678    yysymprint Args;                            \ 
    675679} while (0) 
     680 
     681# define YYDSYMPRINTF(Title, Token, Value, Location)            \ 
     682do {                                                            \ 
     683  if (yydebug)                                                  \ 
     684    {                                                           \ 
     685      YYFPRINTF (stderr, "%s ", Title);                         \ 
     686      yysymprint (stderr,                                       \ 
     687                  Token, Value);        \ 
     688      YYFPRINTF (stderr, "\n");                                 \ 
     689    }                                                           \ 
     690} while (0) 
     691 
     692/*------------------------------------------------------------------. 
     693| yy_stack_print -- Print the state stack from its BOTTOM up to its | 
     694| TOP (included).                                                   | 
     695`------------------------------------------------------------------*/ 
     696 
     697#if defined (__STDC__) || defined (__cplusplus) 
     698static void 
     699yy_stack_print (short int *bottom, short int *top) 
     700#else 
     701static void 
     702yy_stack_print (bottom, top) 
     703    short int *bottom; 
     704    short int *top; 
     705#endif 
     706{ 
     707  YYFPRINTF (stderr, "Stack now"); 
     708  for (/* Nothing. */; bottom <= top; ++bottom) 
     709    YYFPRINTF (stderr, " %d", *bottom); 
     710  YYFPRINTF (stderr, "\n"); 
     711} 
     712 
     713# define YY_STACK_PRINT(Bottom, Top)                            \ 
     714do {                                                            \ 
     715  if (yydebug)                                                  \ 
     716    yy_stack_print ((Bottom), (Top));                           \ 
     717} while (0) 
     718 
     719 
     720/*------------------------------------------------. 
     721| Report that the YYRULE is going to be reduced.  | 
     722`------------------------------------------------*/ 
     723 
     724#if defined (__STDC__) || defined (__cplusplus) 
     725static void 
     726yy_reduce_print (int yyrule) 
     727#else 
     728static void 
     729yy_reduce_print (yyrule) 
     730    int yyrule; 
     731#endif 
     732{ 
     733  int yyi; 
     734  unsigned int yylno = yyrline[yyrule]; 
     735  YYFPRINTF (stderr, "Reducing stack by rule %d (line %u), ", 
     736             yyrule - 1, yylno); 
     737  /* Print the symbols being reduced, and their result.  */ 
     738  for (yyi = yyprhs[yyrule]; 0 <= yyrhs[yyi]; yyi++) 
     739    YYFPRINTF (stderr, "%s ", yytname [yyrhs[yyi]]); 
     740  YYFPRINTF (stderr, "-> %s\n", yytname [yyr1[yyrule]]); 
     741} 
     742 
     743# define YY_REDUCE_PRINT(Rule)          \ 
     744do {                                    \ 
     745  if (yydebug)                          \ 
     746    yy_reduce_print (Rule);             \ 
     747} while (0) 
     748 
    676749/* Nonzero means print parse trace.  It is left uninitialized so that 
    677750   multiple parsers can coexist.  */ 
     
    680753# define YYDPRINTF(Args) 
    681754# define YYDSYMPRINT(Args) 
     755# define YYDSYMPRINTF(Title, Token, Value, Location) 
     756# define YY_STACK_PRINT(Bottom, Top) 
     757# define YY_REDUCE_PRINT(Rule) 
    682758#endif /* !YYDEBUG */ 
     759 
    683760 
    684761/* YYINITDEPTH -- initial size of the parser's stacks.  */ 
     
    694771   evaluated with infinite-precision integer arithmetic.  */ 
    695772 
    696 #if YYMAXDEPTH == 0 
     773#if defined (YYMAXDEPTH) && YYMAXDEPTH == 0 
    697774# undef YYMAXDEPTH 
    698775#endif 
     
    760837 
    761838#if YYDEBUG 
    762 /*-----------------------------. 
    763 | Print this symbol on YYOUT.  | 
    764 `-----------------------------*/ 
    765  
     839/*--------------------------------. 
     840| Print this symbol on YYOUTPUT.  | 
     841`--------------------------------*/ 
     842 
     843#if defined (__STDC__) || defined (__cplusplus) 
    766844static void 
    767 #if defined (__STDC__) || defined (__cplusplus) 
    768 yysymprint (FILE* yyout, int yytype, YYSTYPE yyvalue) 
     845yysymprint (FILE *yyoutput, int yytype, YYSTYPE *yyvaluep) 
    769846#else 
    770 yysymprint (yyout, yytype, yyvalue) 
    771     FILE* yyout; 
     847static void 
     848yysymprint (yyoutput, yytype, yyvaluep) 
     849    FILE *yyoutput; 
    772850    int yytype; 
    773     YYSTYPE yyvalue; 
     851    YYSTYPE *yyvaluep; 
    774852#endif 
    775853{ 
    776854  /* Pacify ``unused variable'' warnings.  */ 
    777   (void) yyvalue; 
     855  (void) yyvaluep; 
    778856 
    779857  if (yytype < YYNTOKENS) 
    780858    { 
    781       YYFPRINTF (yyout, "token %s (", yytname[yytype]); 
     859      YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); 
    782860# ifdef YYPRINT 
    783       YYPRINT (yyout, yytoknum[yytype], yyvalue); 
     861      YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); 
    784862# endif 
    785863    } 
    786864  else 
    787     YYFPRINTF (yyout, "nterm %s (", yytname[yytype]); 
     865    YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); 
    788866 
    789867  switch (yytype) 
     
    792870        break; 
    793871    } 
    794   YYFPRINTF (yyout, ")"); 
     872  YYFPRINTF (yyoutput, ")"); 
    795873} 
    796 #endif /* YYDEBUG. */ 
    797  
    798  
     874 
     875#endif /* ! YYDEBUG */ 
    799876/*-----------------------------------------------. 
    800877| Release the memory associated to this symbol.  | 
    801878`-----------------------------------------------*/ 
    802879 
     880#if defined (__STDC__) || defined (__cplusplus) 
    803881static void 
    804 #if defined (__STDC__) || defined (__cplusplus) 
    805 yydestruct (int yytype, YYSTYPE yyvalue) 
     882yydestruct (int yytype, YYSTYPE *yyvaluep) 
    806883#else 
    807 yydestruct (yytype, yyvalue) 
     884static void 
     885yydestruct (yytype, yyvaluep) 
    808886    int yytype; 
    809     YYSTYPE yyvalue; 
     887    YYSTYPE *yyvaluep; 
    810888#endif 
    811889{ 
    812890  /* Pacify ``unused variable'' warnings.  */ 
    813   (void) yyvalue; 
     891  (void) yyvaluep; 
    814892 
    815893  switch (yytype) 
    816894    { 
     895 
    817896      default: 
    818897        break; 
    819898    } 
    820899} 
    821  
    822900  
    823901 
    824 /* The user can define YYPARSE_PARAM as the name of an argument to be passed 
    825    into yyparse.  The argument should have type void *. 
    826    It should actually point to an object. 
    827    Grammar actions can access the variable by casting it 
    828    to the proper pointer type.  */ 
     902/* Prevent warnings from -Wmissing-prototypes.  */ 
    829903 
    830904#ifdef YYPARSE_PARAM 
    831905# if defined (__STDC__) || defined (__cplusplus) 
    832 #  define YYPARSE_PARAM_ARG void *YYPARSE_PARAM 
    833 #  define YYPARSE_PARAM_DECL 
     906int yyparse (void *YYPARSE_PARAM); 
    834907# else 
    835 #  define YYPARSE_PARAM_ARG YYPARSE_PARAM 
    836 #  define YYPARSE_PARAM_DECL void *YYPARSE_PARAM; 
     908int yyparse (); 
    837909# endif 
    838 #else /* !YYPARSE_PARAM */ 
    839 # define YYPARSE_PARAM_ARG 
    840 # define YYPARSE_PARAM_DECL 
    841 #endif /* !YYPARSE_PARAM */ 
    842  
    843 /* Prevent warning if -Wstrict-prototypes.  */ 
    844 #ifdef __GNUC__ 
    845 # ifdef YYPARSE_PARAM 
    846 int yyparse (void *); 
     910#else /* ! YYPARSE_PARAM */ 
     911#if defined (__STDC__) || defined (__cplusplus) 
     912int yyparse (void); 
     913#else 
     914int yyparse (); 
     915#endif 
     916#endif /* ! YYPARSE_PARAM */ 
     917 
     918 
     919 
     920 
     921 
     922 
     923/*----------. 
     924| yyparse.  | 
     925`----------*/ 
     926 
     927#ifdef YYPARSE_PARAM 
     928# if defined (__STDC__) || defined (__cplusplus) 
     929int yyparse (void *YYPARSE_PARAM) 
    847930# else 
    848 int yyparse (void); 
     931int yyparse (YYPARSE_PARAM) 
     932  void *YYPARSE_PARAM; 
    849933# endif 
    850 #endif 
    851  
    852  
    853  
    854  
     934#else /* ! YYPARSE_PARAM */ 
     935#if defined (__STDC__) || defined (__cplusplus) 
    855936int 
    856 yyparse (YYPARSE_PARAM_ARG) 
    857      YYPARSE_PARAM_DECL 
     937yyparse (void) 
     938#else 
     939int 
     940yyparse () 
     941 
     942#endif 
     943#endif 
    858944{ 
    859945  /* The lookahead symbol.  */ 
     
    863949YYSTYPE yylval; 
    864950 
    865 /* Number of parse errors so far.  */ 
     951/* Number of syntax errors so far.  */ 
    866952int yynerrs; 
    867953