LTP GCOV extension - code coverage report
Current view: directory - home/mike/build/php-5.2-gcov/lcov_data/Zend - zend_ini_parser.c
Test: PHP Code Coverage
Date: 2007-04-10 Instrumented lines: 132
Code covered: 51.5 % Executed lines: 68
Legend: not executed executed

       1                 : /* A Bison parser, made by GNU Bison 2.3.  */
       2                 : 
       3                 : /* Skeleton implementation for Bison's Yacc-like parsers in C
       4                 : 
       5                 :    Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
       6                 :    Free Software Foundation, Inc.
       7                 : 
       8                 :    This program is free software; you can redistribute it and/or modify
       9                 :    it under the terms of the GNU General Public License as published by
      10                 :    the Free Software Foundation; either version 2, or (at your option)
      11                 :    any later version.
      12                 : 
      13                 :    This program is distributed in the hope that it will be useful,
      14                 :    but WITHOUT ANY WARRANTY; without even the implied warranty of
      15                 :    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      16                 :    GNU General Public License for more details.
      17                 : 
      18                 :    You should have received a copy of the GNU General Public License
      19                 :    along with this program; if not, write to the Free Software
      20                 :    Foundation, Inc., 51 Franklin Street, Fifth Floor,
      21                 :    Boston, MA 02110-1301, USA.  */
      22                 : 
      23                 : /* As a special exception, you may create a larger work that contains
      24                 :    part or all of the Bison parser skeleton and distribute that work
      25                 :    under terms of your choice, so long as that work isn't itself a
      26                 :    parser generator using the skeleton or a modified version thereof
      27                 :    as a parser skeleton.  Alternatively, if you modify or redistribute
      28                 :    the parser skeleton itself, you may (at your option) remove this
      29                 :    special exception, which will cause the skeleton and the resulting
      30                 :    Bison output files to be licensed under the GNU General Public
      31                 :    License without this special exception.
      32                 : 
      33                 :    This special exception was added by the Free Software Foundation in
      34                 :    version 2.2 of Bison.  */
      35                 : 
      36                 : /* C LALR(1) parser skeleton written by Richard Stallman, by
      37                 :    simplifying the original so-called "semantic" parser.  */
      38                 : 
      39                 : /* All symbols defined below should begin with yy or YY, to avoid
      40                 :    infringing on user name space.  This should be done even for local
      41                 :    variables, as they might otherwise be expanded by user macros.
      42                 :    There are some unavoidable exceptions within include files to
      43                 :    define necessary library symbols; they are noted "INFRINGES ON
      44                 :    USER NAME SPACE" below.  */
      45                 : 
      46                 : /* Identify Bison output.  */
      47                 : #define YYBISON 1
      48                 : 
      49                 : /* Bison version.  */
      50                 : #define YYBISON_VERSION "2.3"
      51                 : 
      52                 : /* Skeleton name.  */
      53                 : #define YYSKELETON_NAME "yacc.c"
      54                 : 
      55                 : /* Pure parsers.  */
      56                 : #define YYPURE 1
      57                 : 
      58                 : /* Using locations.  */
      59                 : #define YYLSP_NEEDED 0
      60                 : 
      61                 : /* Substitute the variable and function names.  */
      62                 : #define yyparse ini_parse
      63                 : #define yylex   ini_lex
      64                 : #define yyerror ini_error
      65                 : #define yylval  ini_lval
      66                 : #define yychar  ini_char
      67                 : #define yydebug ini_debug
      68                 : #define yynerrs ini_nerrs
      69                 : 
      70                 : 
      71                 : /* Tokens.  */
      72                 : #ifndef YYTOKENTYPE
      73                 : # define YYTOKENTYPE
      74                 :    /* Put the tokens into the symbol table, so that GDB and other debuggers
      75                 :       know about them.  */
      76                 :    enum yytokentype {
      77                 :      TC_STRING = 258,
      78                 :      TC_ENCAPSULATED_STRING = 259,
      79                 :      BRACK = 260,
      80                 :      SECTION = 261,
      81                 :      CFG_TRUE = 262,
      82                 :      CFG_FALSE = 263,
      83                 :      TC_DOLLAR_CURLY = 264
      84                 :    };
      85                 : #endif
      86                 : /* Tokens.  */
      87                 : #define TC_STRING 258
      88                 : #define TC_ENCAPSULATED_STRING 259
      89                 : #define BRACK 260
      90                 : #define SECTION 261
      91                 : #define CFG_TRUE 262
      92                 : #define CFG_FALSE 263
      93                 : #define TC_DOLLAR_CURLY 264
      94                 : 
      95                 : 
      96                 : 
      97                 : 
      98                 : /* Copy the first part of user declarations.  */
      99                 : #line 1 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
     100                 : 
     101                 : /*
     102                 :    +----------------------------------------------------------------------+
     103                 :    | Zend Engine                                                          |
     104                 :    +----------------------------------------------------------------------+
     105                 :    | Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
     106                 :    +----------------------------------------------------------------------+
     107                 :    | This source file is subject to version 2.00 of the Zend license,     |
     108                 :    | that is bundled with this package in the file LICENSE, and is        |
     109                 :    | available through the world-wide-web at the following url:           |
     110                 :    | http://www.zend.com/license/2_00.txt.                                |
     111                 :    | If you did not receive a copy of the Zend license and are unable to  |
     112                 :    | obtain it through the world-wide-web, please send a note to          |
     113                 :    | license@zend.com so we can mail you a copy immediately.              |
     114                 :    +----------------------------------------------------------------------+
     115                 :    | Author: Zeev Suraski <zeev@zend.com>                                 |
     116                 :    +----------------------------------------------------------------------+
     117                 : */
     118                 : 
     119                 : /* $Id: zend_ini_parser.y,v 1.41.2.2.2.1 2006/09/19 20:33:12 dmitry Exp $ */
     120                 : 
     121                 : #define DEBUG_CFG_PARSER 0
     122                 : #include "zend.h"
     123                 : #include "zend_API.h"
     124                 : #include "zend_ini.h"
     125                 : #include "zend_constants.h"
     126                 : #include "zend_ini_scanner.h"
     127                 : #include "zend_extensions.h"
     128                 : 
     129                 : #define YYSTYPE zval
     130                 : 
     131                 : #ifdef ZTS
     132                 : #define YYPARSE_PARAM tsrm_ls
     133                 : #define YYLEX_PARAM tsrm_ls
     134                 : #endif
     135                 : 
     136                 : #define ZEND_INI_PARSER_CB      (CG(ini_parser_param))->ini_parser_cb
     137                 : #define ZEND_INI_PARSER_ARG     (CG(ini_parser_param))->arg
     138                 : 
     139                 : int ini_lex(zval *ini_lval TSRMLS_DC);
     140                 : #ifdef ZTS
     141                 : int ini_parse(void *arg);
     142                 : #else
     143                 : int ini_parse(void);
     144                 : #endif
     145                 : 
     146                 : zval yylval;
     147                 : 
     148                 : #ifndef ZTS
     149                 : extern int ini_lex(zval *ini_lval TSRMLS_DC);
     150                 : extern FILE *ini_in;
     151                 : extern void init_cfg_scanner(void);
     152                 : #endif
     153                 : 
     154                 : void zend_ini_do_op(char type, zval *result, zval *op1, zval *op2)
     155                 : {
     156                 :         int i_result;
     157                 :         int i_op1, i_op2;
     158                 :         char str_result[MAX_LENGTH_OF_LONG];
     159                 : 
     160                 :         i_op1 = atoi(op1->value.str.val);
     161                 :         free(op1->value.str.val);
     162                 :         if (op2) {
     163                 :                 i_op2 = atoi(op2->value.str.val);
     164                 :                 free(op2->value.str.val);
     165                 :         } else {
     166                 :                 i_op2 = 0;
     167                 :         }
     168                 : 
     169                 :         switch (type) {
     170                 :                 case '|':
     171                 :                         i_result = i_op1 | i_op2;
     172                 :                         break;
     173                 :                 case '&':
     174                 :                         i_result = i_op1 & i_op2;
     175                 :                         break;
     176                 :                 case '~':
     177                 :                         i_result = ~i_op1;
     178                 :                         break;
     179                 :                 case '!':
     180                 :                         i_result = !i_op1;
     181                 :                         break;
     182                 :                 default:
     183                 :                         i_result = 0;
     184                 :                         break;
     185                 :         }
     186                 : 
     187                 :         result->value.str.len = zend_sprintf(str_result, "%d", i_result);
     188                 :         result->value.str.val = (char *) malloc(result->value.str.len+1);
     189                 :         memcpy(result->value.str.val, str_result, result->value.str.len);
     190                 :         result->value.str.val[result->value.str.len] = 0;
     191                 :         result->type = IS_STRING;
     192                 : }
     193                 : 
     194                 : void zend_ini_init_string(zval *result)
     195                 : {
     196                 :         result->value.str.val = malloc(1);
     197                 :         result->value.str.val[0] = 0;
     198                 :         result->value.str.len = 0;
     199                 :         result->type = IS_STRING;
     200                 : }
     201                 : 
     202                 : void zend_ini_add_string(zval *result, zval *op1, zval *op2)
     203                 : {           
     204                 :     int length = op1->value.str.len + op2->value.str.len;
     205                 : 
     206                 :         result->value.str.val = (char *) realloc(op1->value.str.val, length+1);
     207                 :     memcpy(result->value.str.val+op1->value.str.len, op2->value.str.val, op2->value.str.len);
     208                 :     result->value.str.val[length] = 0;
     209                 :     result->value.str.len = length;
     210                 :     result->type = IS_STRING;
     211                 : }
     212                 : 
     213                 : void zend_ini_get_constant(zval *result, zval *name)
     214                 : {
     215                 :         zval z_constant;
     216                 :         TSRMLS_FETCH();
     217                 : 
     218                 :         if (!memchr(name->value.str.val, ':', name->value.str.len)
     219                 :                         && zend_get_constant(name->value.str.val, name->value.str.len, &z_constant TSRMLS_CC)) {
     220                 :                 /* z_constant is emalloc()'d */
     221                 :                 convert_to_string(&z_constant);
     222                 :                 result->value.str.val = zend_strndup(z_constant.value.str.val, z_constant.value.str.len);
     223                 :                 result->value.str.len = z_constant.value.str.len;
     224                 :                 result->type = z_constant.type;
     225                 :                 zval_dtor(&z_constant);
     226                 :                 free(name->value.str.val);   
     227                 :         } else {
     228                 :                 *result = *name;
     229                 :         }
     230                 : }
     231                 : 
     232                 : void zend_ini_get_var(zval *result, zval *name)
     233                 : {
     234                 :         zval curval;
     235                 :         char *envvar;
     236                 :         TSRMLS_FETCH();
     237                 : 
     238                 :         if (zend_get_configuration_directive(name->value.str.val, name->value.str.len+1, &curval) == SUCCESS) {
     239                 :                 result->value.str.val = zend_strndup(curval.value.str.val, curval.value.str.len);
     240                 :                 result->value.str.len = curval.value.str.len;
     241                 :         } else if ((envvar = zend_getenv(name->value.str.val, name->value.str.len TSRMLS_CC)) != NULL ||
     242                 :                            (envvar = getenv(name->value.str.val)) != NULL) {
     243                 :                 result->value.str.val = strdup(envvar);
     244                 :                 result->value.str.len = strlen(envvar);
     245                 :         } else {
     246                 :                 zend_ini_init_string(result);
     247                 :         }
     248                 : }
     249                 : 
     250                 : 
     251                 : static void ini_error(char *str)
     252                 : {
     253                 :         char *error_buf;
     254                 :         int error_buf_len;
     255                 :         char *currently_parsed_filename;
     256                 :         TSRMLS_FETCH();
     257                 : 
     258                 :         currently_parsed_filename = zend_ini_scanner_get_filename(TSRMLS_C);
     259                 :         if (currently_parsed_filename) {
     260                 :                 error_buf_len = 128+strlen(currently_parsed_filename); /* should be more than enough */
     261                 :                 error_buf = (char *) emalloc(error_buf_len);
     262                 : 
     263                 :                 sprintf(error_buf, "Error parsing %s on line %d\n", currently_parsed_filename, zend_ini_scanner_get_lineno(TSRMLS_C));
     264                 :         } else {
     265                 :                 error_buf = estrdup("Invalid configuration directive\n");
     266                 :         }
     267                 : 
     268                 :         if (CG(ini_parser_unbuffered_errors)) {
     269                 : #ifdef PHP_WIN32
     270                 :                 MessageBox(NULL, error_buf, "PHP Error", MB_OK|MB_TOPMOST|0x00200000L);
     271                 : #else
     272                 :                 fprintf(stderr, "PHP:  %s", error_buf);
     273                 : #endif
     274                 :         } else {
     275                 :                 zend_error(E_WARNING, "%s", error_buf);
     276                 :         }
     277                 :         efree(error_buf);
     278                 : }
     279                 : 
     280                 : 
     281                 : ZEND_API int zend_parse_ini_file(zend_file_handle *fh, zend_bool unbuffered_errors, zend_ini_parser_cb_t ini_parser_cb, void *arg)
     282                 : {
     283                 :         int retval;
     284                 :         zend_ini_parser_param ini_parser_param;
     285                 :         TSRMLS_FETCH();
     286                 : 
     287                 :         ini_parser_param.ini_parser_cb = ini_parser_cb;
     288                 :         ini_parser_param.arg = arg;
     289                 : 
     290                 :         CG(ini_parser_param) = &ini_parser_param;
     291                 :         if (zend_ini_open_file_for_scanning(fh TSRMLS_CC)==FAILURE) {
     292                 :                 return FAILURE;
     293                 :         }
     294                 : 
     295                 :         CG(ini_parser_unbuffered_errors) = unbuffered_errors;
     296                 :         retval = ini_parse(TSRMLS_C);
     297                 : 
     298                 :         zend_ini_close_file(fh TSRMLS_CC);
     299                 : 
     300                 :         if (retval==0) {
     301                 :                 return SUCCESS;
     302                 :         } else {
     303                 :                 return FAILURE;
     304                 :         }
     305                 : }
     306                 : 
     307                 : 
     308                 : ZEND_API int zend_parse_ini_string(char *str, zend_bool unbuffered_errors, zend_ini_parser_cb_t ini_parser_cb, void *arg)
     309                 : {
     310                 :         zend_ini_parser_param ini_parser_param;
     311                 :         TSRMLS_FETCH();
     312                 : 
     313                 :         ini_parser_param.ini_parser_cb = ini_parser_cb;
     314                 :         ini_parser_param.arg = arg;
     315                 : 
     316                 :         CG(ini_parser_param) = &ini_parser_param;
     317                 :         if (zend_ini_prepare_string_for_scanning(str TSRMLS_CC)==FAILURE) {
     318                 :                 return FAILURE;
     319                 :         }
     320                 : 
     321                 :         CG(ini_parser_unbuffered_errors) = unbuffered_errors;
     322                 : 
     323                 :         if (ini_parse(TSRMLS_C)) {
     324                 :                 return SUCCESS;
     325                 :         } else {
     326                 :                 return FAILURE;
     327                 :         }
     328                 : }
     329                 : 
     330                 : 
     331                 : 
     332                 : 
     333                 : /* Enabling traces.  */
     334                 : #ifndef YYDEBUG
     335                 : # define YYDEBUG 0
     336                 : #endif
     337                 : 
     338                 : /* Enabling verbose error messages.  */
     339                 : #ifdef YYERROR_VERBOSE
     340                 : # undef YYERROR_VERBOSE
     341                 : # define YYERROR_VERBOSE 1
     342                 : #else
     343                 : # define YYERROR_VERBOSE 0
     344                 : #endif
     345                 : 
     346                 : /* Enabling the token table.  */
     347                 : #ifndef YYTOKEN_TABLE
     348                 : # define YYTOKEN_TABLE 0
     349                 : #endif
     350                 : 
     351                 : #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
     352                 : typedef int YYSTYPE;
     353                 : # define yystype YYSTYPE /* obsolescent; will be withdrawn */
     354                 : # define YYSTYPE_IS_DECLARED 1
     355                 : # define YYSTYPE_IS_TRIVIAL 1
     356                 : #endif
     357                 : 
     358                 : 
     359                 : 
     360                 : /* Copy the second part of user declarations.  */
     361                 : 
     362                 : 
     363                 : /* Line 216 of yacc.c.  */
     364                 : #line 365 "Zend/zend_ini_parser.c"
     365                 : 
     366                 : #ifdef short
     367                 : # undef short
     368                 : #endif
     369                 : 
     370                 : #ifdef YYTYPE_UINT8
     371                 : typedef YYTYPE_UINT8 yytype_uint8;
     372                 : #else
     373                 : typedef unsigned char yytype_uint8;
     374                 : #endif
     375                 : 
     376                 : #ifdef YYTYPE_INT8
     377                 : typedef YYTYPE_INT8 yytype_int8;
     378                 : #elif (defined __STDC__ || defined __C99__FUNC__ \
     379                 :      || defined __cplusplus || defined _MSC_VER)
     380                 : typedef signed char yytype_int8;
     381                 : #else
     382                 : typedef short int yytype_int8;
     383                 : #endif
     384                 : 
     385                 : #ifdef YYTYPE_UINT16
     386                 : typedef YYTYPE_UINT16 yytype_uint16;
     387                 : #else
     388                 : typedef unsigned short int yytype_uint16;
     389                 : #endif
     390                 : 
     391                 : #ifdef YYTYPE_INT16
     392                 : typedef YYTYPE_INT16 yytype_int16;
     393                 : #else
     394                 : typedef short int yytype_int16;
     395                 : #endif
     396                 : 
     397                 : #ifndef YYSIZE_T
     398                 : # ifdef __SIZE_TYPE__
     399                 : #  define YYSIZE_T __SIZE_TYPE__
     400                 : # elif defined size_t
     401                 : #  define YYSIZE_T size_t
     402                 : # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
     403                 :      || defined __cplusplus || defined _MSC_VER)
     404                 : #  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
     405                 : #  define YYSIZE_T size_t
     406                 : # else
     407                 : #  define YYSIZE_T unsigned int
     408                 : # endif
     409                 : #endif
     410                 : 
     411                 : #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
     412                 : 
     413                 : #ifndef YY_
     414                 : # if YYENABLE_NLS
     415                 : #  if ENABLE_NLS
     416                 : #   include <libintl.h> /* INFRINGES ON USER NAME SPACE */
     417                 : #   define YY_(msgid) dgettext ("bison-runtime", msgid)
     418                 : #  endif
     419                 : # endif
     420                 : # ifndef YY_
     421                 : #  define YY_(msgid) msgid
     422                 : # endif
     423                 : #endif
     424                 : 
     425                 : /* Suppress unused-variable warnings by "using" E.  */
     426                 : #if ! defined lint || defined __GNUC__
     427                 : # define YYUSE(e) ((void) (e))
     428                 : #else
     429                 : # define YYUSE(e) /* empty */
     430                 : #endif
     431                 : 
     432                 : /* Identity function, used to suppress warnings about constant conditions.  */
     433                 : #ifndef lint
     434                 : # define YYID(n) (n)
     435                 : #else
     436                 : #if (defined __STDC__ || defined __C99__FUNC__ \
     437                 :      || defined __cplusplus || defined _MSC_VER)
     438                 : static int
     439                 : YYID (int i)
     440                 : #else
     441                 : static int
     442                 : YYID (i)
     443                 :     int i;
     444                 : #endif
     445                 : {
     446                 :   return i;
     447                 : }
     448                 : #endif
     449                 : 
     450                 : #if ! defined yyoverflow || YYERROR_VERBOSE
     451                 : 
     452                 : /* The parser invokes alloca or malloc; define the necessary symbols.  */
     453                 : 
     454                 : # ifdef YYSTACK_USE_ALLOCA
     455                 : #  if YYSTACK_USE_ALLOCA
     456                 : #   ifdef __GNUC__
     457                 : #    define YYSTACK_ALLOC __builtin_alloca
     458                 : #   elif defined __BUILTIN_VA_ARG_INCR
     459                 : #    include <alloca.h> /* INFRINGES ON USER NAME SPACE */
     460                 : #   elif defined _AIX
     461                 : #    define YYSTACK_ALLOC __alloca
     462                 : #   elif defined _MSC_VER
     463                 : #    include <malloc.h> /* INFRINGES ON USER NAME SPACE */
     464                 : #    define alloca _alloca
     465                 : #   else
     466                 : #    define YYSTACK_ALLOC alloca
     467                 : #    if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
     468                 :      || defined __cplusplus || defined _MSC_VER)
     469                 : #     include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
     470                 : #     ifndef _STDLIB_H
     471                 : #      define _STDLIB_H 1
     472                 : #     endif
     473                 : #    endif
     474                 : #   endif
     475                 : #  endif
     476                 : # endif
     477                 : 
     478                 : # ifdef YYSTACK_ALLOC
     479                 :    /* Pacify GCC's `empty if-body' warning.  */
     480                 : #  define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
     481                 : #  ifndef YYSTACK_ALLOC_MAXIMUM
     482                 :     /* The OS might guarantee only one guard page at the bottom of the stack,
     483                 :        and a page size can be as small as 4096 bytes.  So we cannot safely
     484                 :        invoke alloca (N) if N exceeds 4096.  Use a slightly smaller number
     485                 :        to allow for a few compiler-allocated temporary stack slots.  */
     486                 : #   define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
     487                 : #  endif
     488                 : # else
     489                 : #  define YYSTACK_ALLOC YYMALLOC
     490                 : #  define YYSTACK_FREE YYFREE
     491                 : #  ifndef YYSTACK_ALLOC_MAXIMUM
     492                 : #   define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
     493                 : #  endif
     494                 : #  if (defined __cplusplus && ! defined _STDLIB_H \
     495                 :        && ! ((defined YYMALLOC || defined malloc) \
     496                 :              && (defined YYFREE || defined free)))
     497                 : #   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
     498                 : #   ifndef _STDLIB_H
     499                 : #    define _STDLIB_H 1
     500                 : #   endif
     501                 : #  endif
     502                 : #  ifndef YYMALLOC
     503                 : #   define YYMALLOC malloc
     504                 : #   if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
     505                 :      || defined __cplusplus || defined _MSC_VER)
     506                 : void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
     507                 : #   endif
     508                 : #  endif
     509                 : #  ifndef YYFREE
     510                 : #   define YYFREE free
     511                 : #   if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
     512                 :      || defined __cplusplus || defined _MSC_VER)
     513                 : void free (void *); /* INFRINGES ON USER NAME SPACE */
     514                 : #   endif
     515                 : #  endif
     516                 : # endif
     517                 : #endif /* ! defined yyoverflow || YYERROR_VERBOSE */
     518                 : 
     519                 : 
     520                 : #if (! defined yyoverflow \
     521                 :      && (! defined __cplusplus \
     522                 :          || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
     523                 : 
     524                 : /* A type that is properly aligned for any stack member.  */
     525                 : union yyalloc
     526                 : {
     527                 :   yytype_int16 yyss;
     528                 :   YYSTYPE yyvs;
     529                 :   };
     530                 : 
     531                 : /* The size of the maximum gap between one aligned stack and the next.  */
     532                 : # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
     533                 : 
     534                 : /* The size of an array large to enough to hold all stacks, each with
     535                 :    N elements.  */
     536                 : # define YYSTACK_BYTES(N) \
     537                 :      ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
     538                 :       + YYSTACK_GAP_MAXIMUM)
     539                 : 
     540                 : /* Copy COUNT objects from FROM to TO.  The source and destination do
     541                 :    not overlap.  */
     542                 : # ifndef YYCOPY
     543                 : #  if defined __GNUC__ && 1 < __GNUC__
     544                 : #   define YYCOPY(To, From, Count) \
     545                 :       __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
     546                 : #  else
     547                 : #   define YYCOPY(To, From, Count)              \
     548                 :       do                                        \
     549                 :         {                                       \
     550                 :           YYSIZE_T yyi;                         \
     551                 :           for (yyi = 0; yyi < (Count); yyi++)        \
     552                 :             (To)[yyi] = (From)[yyi];            \
     553                 :         }                                       \
     554                 :       while (YYID (0))
     555                 : #  endif
     556                 : # endif
     557                 : 
     558                 : /* Relocate STACK from its old location to the new one.  The
     559                 :    local variables YYSIZE and YYSTACKSIZE give the old and new number of
     560                 :    elements in the stack, and YYPTR gives the new location of the
     561                 :    stack.  Advance YYPTR to a properly aligned location for the next
     562                 :    stack.  */
     563                 : # define YYSTACK_RELOCATE(Stack)                                        \
     564                 :     do                                                                  \
     565                 :       {                                                                 \
     566                 :         YYSIZE_T yynewbytes;                                            \
     567                 :         YYCOPY (&yyptr->Stack, Stack, yysize);                           \
     568                 :         Stack = &yyptr->Stack;                                           \
     569                 :         yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
     570                 :         yyptr += yynewbytes / sizeof (*yyptr);                          \
     571                 :       }                                                                 \
     572                 :     while (YYID (0))
     573                 : 
     574                 : #endif
     575                 : 
     576                 : /* YYFINAL -- State number of the termination state.  */
     577                 : #define YYFINAL  2
     578                 : /* YYLAST -- Last index in YYTABLE.  */
     579                 : #define YYLAST   41
     580                 : 
     581                 : /* YYNTOKENS -- Number of terminals.  */
     582                 : #define YYNTOKENS  19
     583                 : /* YYNNTS -- Number of nonterminals.  */
     584                 : #define YYNNTS  8
     585                 : /* YYNRULES -- Number of rules.  */
     586                 : #define YYNRULES  27
     587                 : /* YYNRULES -- Number of states.  */
     588                 : #define YYNSTATES  38
     589                 : 
     590                 : /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
     591                 : #define YYUNDEFTOK  2
     592                 : #define YYMAXUTOK   264
     593                 : 
     594                 : #define YYTRANSLATE(YYX)                                                \
     595                 :   ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
     596                 : 
     597                 : /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
     598                 : static const yytype_uint8 yytranslate[] =
     599                 : {
     600                 :        0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     601                 :       15,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     602                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     603                 :        2,     2,     2,    13,     2,     2,     2,     2,    11,     2,
     604                 :       17,    18,     2,     2,     2,     2,     2,     2,     2,     2,
     605                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     606                 :        2,    14,     2,     2,     2,     2,     2,     2,     2,     2,
     607                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     608                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     609                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     610                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     611                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     612                 :        2,     2,     2,     2,    10,    16,    12,     2,     2,     2,
     613                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     614                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     615                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     616                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     617                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     618                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     619                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     620                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     621                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     622                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     623                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     624                 :        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     625                 :        2,     2,     2,     2,     2,     2,     1,     2,     3,     4,
     626                 :        5,     6,     7,     8,     9
     627                 : };
     628                 : 
     629                 : #if YYDEBUG
     630                 : /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
     631                 :    YYRHS.  */
     632                 : static const yytype_uint8 yyprhs[] =
     633                 : {
     634                 :        0,     0,     3,     6,     7,    11,    16,    18,    20,    22,
     635                 :       24,    26,    28,    30,    31,    33,    35,    37,    40,    43,
     636                 :       46,    50,    52,    56,    60,    63,    66,    70
     637                 : };
     638                 : 
     639                 : /* YYRHS -- A `-1'-separated list of the rules' RHS.  */
     640                 : static const yytype_int8 yyrhs[] =
     641                 : {
     642                 :       20,     0,    -1,    20,    21,    -1,    -1,     3,    14,    22,
     643                 :       -1,     3,     5,    14,    22,    -1,     3,    -1,     6,    -1,
     644                 :       15,    -1,    25,    -1,     7,    -1,     8,    -1,    15,    -1,
     645                 :       -1,    24,    -1,     4,    -1,    26,    -1,    23,    24,    -1,
     646                 :       23,     4,    -1,    23,    26,    -1,     9,     3,    16,    -1,
     647                 :       23,    -1,    25,    10,    25,    -1,    25,    11,    25,    -1,
     648                 :       12,    25,    -1,    13,    25,    -1,    17,    25,    18,    -1,
     649                 :        3,    -1
     650                 : };
     651                 : 
     652                 : /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
     653                 : static const yytype_uint16 yyrline[] =
     654                 : {
     655                 :        0,   248,   248,   249,   253,   261,   269,   270,   271,   276,
     656                 :      277,   278,   279,   280,   285,   286,   287,   288,   289,   290,
     657                 :      294,   298,   299,   300,   301,   302,   303,   307
     658                 : };
     659                 : #endif
     660                 : 
     661                 : #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
     662                 : /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
     663                 :    First, the terminals, then, starting at YYNTOKENS, nonterminals.  */
     664                 : static const char *const yytname[] =
     665                 : {
     666                 :   "$end", "error", "$undefined", "TC_STRING", "TC_ENCAPSULATED_STRING",
     667                 :   "BRACK", "SECTION", "CFG_TRUE", "CFG_FALSE", "TC_DOLLAR_CURLY", "'|'",
     668                 :   "'&'", "'~'", "'!'", "'='", "'\\n'", "'}'", "'('", "')'", "$accept",
     669                 :   "statement_list", "statement", "string_or_value", "var_string_list",
     670                 :   "cfg_var_ref", "expr", "constant_string", 0
     671                 : };
     672                 : #endif
     673                 : 
     674                 : # ifdef YYPRINT
     675                 : /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
     676                 :    token YYLEX-NUM.  */
     677                 : static const yytype_uint16 yytoknum[] =
     678                 : {
     679                 :        0,   256,   257,   258,   259,   260,   261,   262,   263,   264,
     680                 :      124,    38,   126,    33,    61,    10,   125,    40,    41
     681                 : };
     682                 : # endif
     683                 : 
     684                 : /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
     685                 : static const yytype_uint8 yyr1[] =
     686                 : {
     687                 :        0,    19,    20,    20,    21,    21,    21,    21,    21,    22,
     688                 :       22,    22,    22,    22,    23,    23,    23,    23,    23,    23,
     689                 :       24,    25,    25,    25,    25,    25,    25,    26
     690                 : };
     691                 : 
     692                 : /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
     693                 : static const yytype_uint8 yyr2[] =
     694                 : {
     695                 :        0,     2,     2,     0,     3,     4,     1,     1,     1,     1,
     696                 :        1,     1,     1,     0,     1,     1,     1,     2,     2,     2,
     697                 :        3,     1,     3,     3,     2,     2,     3,     1
     698                 : };
     699                 : 
     700                 : /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
     701                 :    STATE-NUM when YYTABLE doesn't specify something else to do.  Zero
     702                 :    means the default is an error.  */
     703                 : static const yytype_uint8 yydefact[] =
     704                 : {
     705                 :        3,     0,     1,     6,     7,     8,     2,     0,    13,    13,
     706                 :       27,    15,    10,    11,     0,     0,     0,    12,     0,     4,
     707                 :       21,    14,     9,    16,     5,     0,    24,    25,     0,    18,
     708                 :       17,    19,     0,     0,    20,    26,    22,    23
     709                 : };
     710                 : 
     711                 : /* YYDEFGOTO[NTERM-NUM].  */
     712                 : static const yytype_int8 yydefgoto[] =
     713                 : {
     714                 :       -1,     1,     6,    19,    20,    21,    22,    23
     715                 : };
     716                 : 
     717                 : /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
     718                 :    STATE-NUM.  */
     719                 : #define YYPACT_NINF -16
     720                 : static const yytype_int8 yypact[] =
     721                 : {
     722                 :      -16,     4,   -16,    -3,   -16,   -16,   -16,    -2,    17,    17,
     723                 :      -16,   -16,   -16,   -16,    13,    24,    24,   -16,    24,   -16,
     724                 :        5,   -16,    12,   -16,   -16,    -1,   -16,   -16,    -5,   -16,
     725                 :      -16,   -16,    24,    24,   -16,   -16,   -16,   -16
     726                 : };
     727                 : 
     728                 : /* YYPGOTO[NTERM-NUM].  */
     729                 : static const yytype_int8 yypgoto[] =
     730                 : {
     731                 :      -16,   -16,   -16,    22,   -16,    15,   -15,    18
     732                 : };
     733                 : 
     734                 : /* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
     735                 :    positive, shift that token.  If negative, reduce the rule which
     736                 :    number is the opposite.  If zero, do what YYDEFACT says.
     737                 :    If YYTABLE_NINF, syntax error.  */
     738                 : #define YYTABLE_NINF -1
     739                 : static const yytype_uint8 yytable[] =
     740                 : {
     741                 :       26,    27,     7,    28,     2,    32,    33,     3,    10,    29,
     742                 :        4,     8,     9,    35,    14,    34,    25,    36,    37,     5,
     743                 :       10,    11,    32,    33,    12,    13,    14,    10,    11,    15,
     744                 :       16,    24,    17,    14,    18,    30,    15,    16,    31,     0,
     745                 :        0,    18
     746                 : };
     747                 : 
     748                 : static const yytype_int8 yycheck[] =
     749                 : {
     750                 :       15,    16,     5,    18,     0,    10,    11,     3,     3,     4,
     751                 :        6,    14,    14,    18,     9,    16,     3,    32,    33,    15,
     752                 :        3,     4,    10,    11,     7,     8,     9,     3,     4,    12,
     753                 :       13,     9,    15,     9,    17,    20,    12,    13,    20,    -1,
     754                 :       -1,    17
     755                 : };
     756                 : 
     757                 : /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
     758                 :    symbol of state STATE-NUM.  */
     759                 : static const yytype_uint8 yystos[] =
     760                 : {
     761                 :        0,    20,     0,     3,     6,    15,    21,     5,    14,    14,
     762                 :        3,     4,     7,     8,     9,    12,    13,    15,    17,    22,
     763                 :       23,    24,    25,    26,    22,     3,    25,    25,    25,     4,
     764                 :       24,    26,    10,    11,    16,    18,    25,    25
     765                 : };
     766                 : 
     767                 : #define yyerrok         (yyerrstatus = 0)
     768                 : #define yyclearin       (yychar = YYEMPTY)
     769                 : #define YYEMPTY         (-2)
     770                 : #define YYEOF           0
     771                 : 
     772                 : #define YYACCEPT        goto yyacceptlab
     773                 : #define YYABORT         goto yyabortlab
     774                 : #define YYERROR         goto yyerrorlab
     775                 : 
     776                 : 
     777                 : /* Like YYERROR except do call yyerror.  This remains here temporarily
     778                 :    to ease the transition to the new meaning of YYERROR, for GCC.
     779                 :    Once GCC version 2 has supplanted version 1, this can go.  */
     780                 : 
     781                 : #define YYFAIL          goto yyerrlab
     782                 : 
     783                 : #define YYRECOVERING()  (!!yyerrstatus)
     784                 : 
     785                 : #define YYBACKUP(Token, Value)                                  \
     786                 : do                                                              \
     787                 :   if (yychar == YYEMPTY && yylen == 1)                          \
     788                 :     {                                                           \
     789                 :       yychar = (Token);                                         \
     790                 :       yylval = (Value);                                         \
     791                 :       yytoken = YYTRANSLATE (yychar);                           \
     792                 :       YYPOPSTACK (1);                                           \
     793                 :       goto yybackup;                                            \
     794                 :     }                                                           \
     795                 :   else                                                          \
     796                 :     {                                                           \
     797                 :       yyerror (YY_("syntax error: cannot back up")); \
     798                 :       YYERROR;                                                  \
     799                 :     }                                                           \
     800                 : while (YYID (0))
     801                 : 
     802                 : 
     803                 : #define YYTERROR        1
     804                 : #define YYERRCODE       256
     805                 : 
     806                 : 
     807                 : /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
     808                 :    If N is 0, then set CURRENT to the empty location which ends
     809                 :    the previous symbol: RHS[0] (always defined).  */
     810                 : 
     811                 : #define YYRHSLOC(Rhs, K) ((Rhs)[K])
     812                 : #ifndef YYLLOC_DEFAULT
     813                 : # define YYLLOC_DEFAULT(Current, Rhs, N)                                \
     814                 :     do                                                                  \
     815                 :       if (YYID (N))                                                    \
     816                 :         {                                                               \
     817                 :           (Current).first_line   = YYRHSLOC (Rhs, 1).first_line;        \
     818                 :           (Current).first_column = YYRHSLOC (Rhs, 1).first_column;      \
     819                 :           (Current).last_line    = YYRHSLOC (Rhs, N).last_line;         \
     820                 :           (Current).last_column  = YYRHSLOC (Rhs, N).last_column;       \
     821                 :         }                                                               \
     822                 :       else                                                              \
     823                 :         {                                                               \
     824                 :           (Current).first_line   = (Current).last_line   =              \
     825                 :             YYRHSLOC (Rhs, 0).last_line;                                \
     826                 :           (Current).first_column = (Current).last_column =              \
     827                 :             YYRHSLOC (Rhs, 0).last_column;                              \
     828                 :         }                                                               \
     829                 :     while (YYID (0))
     830                 : #endif
     831                 : 
     832                 : 
     833                 : /* YY_LOCATION_PRINT -- Print the location on the stream.
     834                 :    This macro was not mandated originally: define only if we know
     835                 :    we won't break user code: when these are the locations we know.  */
     836                 : 
     837                 : #ifndef YY_LOCATION_PRINT
     838                 : # if YYLTYPE_IS_TRIVIAL
     839                 : #  define YY_LOCATION_PRINT(File, Loc)                  \
     840                 :      fprintf (File, "%d.%d-%d.%d",                    \
     841                 :               (Loc).first_line, (Loc).first_column,     \
     842                 :               (Loc).last_line,  (Loc).last_column)
     843                 : # else
     844                 : #  define YY_LOCATION_PRINT(File, Loc) ((void) 0)
     845                 : # endif
     846                 : #endif
     847                 : 
     848                 : 
     849                 : /* YYLEX -- calling `yylex' with the right arguments.  */
     850                 : 
     851                 : #ifdef YYLEX_PARAM
     852                 : # define YYLEX yylex (&yylval, YYLEX_PARAM)
     853                 : #else
     854                 : # define YYLEX yylex (&yylval)
     855                 : #endif
     856                 : 
     857                 : /* Enable debugging if requested.  */
     858                 : #if YYDEBUG
     859                 : 
     860                 : # ifndef YYFPRINTF
     861                 : #  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
     862                 : #  define YYFPRINTF fprintf
     863                 : # endif
     864                 : 
     865                 : # define YYDPRINTF(Args)                        \
     866                 : do {                                            \
     867                 :   if (yydebug)                                  \
     868                 :     YYFPRINTF Args;                             \
     869                 : } while (YYID (0))
     870                 : 
     871                 : # define YY_SYMBOL_PRINT(Title, Type, Value, Location)                    \
     872                 : do {                                                                      \
     873                 :   if (yydebug)                                                            \
     874                 :     {                                                                     \
     875                 :       YYFPRINTF (stderr, "%s ", Title);                                         \
     876                 :       yy_symbol_print (stderr,                                            \
     877                 :                   Type, Value); \
     878                 :       YYFPRINTF (stderr, "\n");                                                 \
     879                 :     }                                                                     \
     880                 : } while (YYID (0))
     881                 : 
     882                 : 
     883                 : /*--------------------------------.
     884                 : | Print this symbol on YYOUTPUT.  |
     885                 : `--------------------------------*/
     886                 : 
     887                 : /*ARGSUSED*/
     888                 : #if (defined __STDC__ || defined __C99__FUNC__ \
     889                 :      || defined __cplusplus || defined _MSC_VER)
     890                 : static void
     891                 : yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
     892                 : #else
     893                 : static void
     894                 : yy_symbol_value_print (yyoutput, yytype, yyvaluep)
     895                 :     FILE *yyoutput;
     896                 :     int yytype;
     897                 :     YYSTYPE const * const yyvaluep;
     898                 : #endif
     899                 : {
     900                 :   if (!yyvaluep)
     901                 :     return;
     902                 : # ifdef YYPRINT
     903                 :   if (yytype < YYNTOKENS)
     904                 :     YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
     905                 : # else
     906                 :   YYUSE (yyoutput);
     907                 : # endif
     908                 :   switch (yytype)
     909                 :     {
     910                 :       default:
     911                 :         break;
     912                 :     }
     913                 : }
     914                 : 
     915                 : 
     916                 : /*--------------------------------.
     917                 : | Print this symbol on YYOUTPUT.  |
     918                 : `--------------------------------*/
     919                 : 
     920                 : #if (defined __STDC__ || defined __C99__FUNC__ \
     921                 :      || defined __cplusplus || defined _MSC_VER)
     922                 : static void
     923                 : yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
     924                 : #else
     925                 : static void
     926                 : yy_symbol_print (yyoutput, yytype, yyvaluep)
     927                 :     FILE *yyoutput;
     928                 :     int yytype;
     929                 :     YYSTYPE const * const yyvaluep;
     930                 : #endif
     931                 : {
     932                 :   if (yytype < YYNTOKENS)
     933                 :     YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
     934                 :   else
     935                 :     YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
     936                 : 
     937                 :   yy_symbol_value_print (yyoutput, yytype, yyvaluep);
     938                 :   YYFPRINTF (yyoutput, ")");
     939                 : }
     940                 : 
     941                 : /*------------------------------------------------------------------.
     942                 : | yy_stack_print -- Print the state stack from its BOTTOM up to its |
     943                 : | TOP (included).                                                   |
     944                 : `------------------------------------------------------------------*/
     945                 : 
     946                 : #if (defined __STDC__ || defined __C99__FUNC__ \
     947                 :      || defined __cplusplus || defined _MSC_VER)
     948                 : static void
     949                 : yy_stack_print (yytype_int16 *bottom, yytype_int16 *top)
     950                 : #else
     951                 : static void
     952                 : yy_stack_print (bottom, top)
     953                 :     yytype_int16 *bottom;
     954                 :     yytype_int16 *top;
     955                 : #endif
     956                 : {
     957                 :   YYFPRINTF (stderr, "Stack now");
     958                 :   for (; bottom <= top; ++bottom)
     959                 :     YYFPRINTF (stderr, " %d", *bottom);
     960                 :   YYFPRINTF (stderr, "\n");
     961                 : }
     962                 : 
     963                 : # define YY_STACK_PRINT(Bottom, Top)                            \
     964                 : do {                                                            \
     965                 :   if (yydebug)                                                  \
     966                 :     yy_stack_print ((Bottom), (Top));                           \
     967                 : } while (YYID (0))
     968                 : 
     969                 : 
     970                 : /*------------------------------------------------.
     971                 : | Report that the YYRULE is going to be reduced.  |
     972                 : `------------------------------------------------*/
     973                 : 
     974                 : #if (defined __STDC__ || defined __C99__FUNC__ \
     975                 :      || defined __cplusplus || defined _MSC_VER)
     976                 : static void
     977                 : yy_reduce_print (YYSTYPE *yyvsp, int yyrule)
     978                 : #else
     979                 : static void
     980                 : yy_reduce_print (yyvsp, yyrule)
     981                 :     YYSTYPE *yyvsp;
     982                 :     int yyrule;
     983                 : #endif
     984                 : {
     985                 :   int yynrhs = yyr2[yyrule];
     986                 :   int yyi;
     987                 :   unsigned long int yylno = yyrline[yyrule];
     988                 :   YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
     989                 :              yyrule - 1, yylno);
     990                 :   /* The symbols being reduced.  */
     991                 :   for (yyi = 0; yyi < yynrhs; yyi++)
     992                 :     {
     993                 :       fprintf (stderr, "   $%d = ", yyi + 1);
     994                 :       yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
     995                 :                        &(yyvsp[(yyi + 1) - (yynrhs)])
     996                 :                                        );
     997                 :       fprintf (stderr, "\n");
     998                 :     }
     999                 : }
    1000                 : 
    1001                 : # define YY_REDUCE_PRINT(Rule)          \
    1002                 : do {                                    \
    1003                 :   if (yydebug)                          \
    1004                 :     yy_reduce_print (yyvsp, Rule); \
    1005                 : } while (YYID (0))
    1006                 : 
    1007                 : /* Nonzero means print parse trace.  It is left uninitialized so that
    1008                 :    multiple parsers can coexist.  */
    1009                 : int yydebug;
    1010                 : #else /* !YYDEBUG */
    1011                 : # define YYDPRINTF(Args)
    1012                 : # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
    1013                 : # define YY_STACK_PRINT(Bottom, Top)
    1014                 : # define YY_REDUCE_PRINT(Rule)
    1015                 : #endif /* !YYDEBUG */
    1016                 : 
    1017                 : 
    1018                 : /* YYINITDEPTH -- initial size of the parser's stacks.  */
    1019                 : #ifndef YYINITDEPTH
    1020                 : # define YYINITDEPTH 200
    1021                 : #endif
    1022                 : 
    1023                 : /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
    1024                 :    if the built-in stack extension method is used).
    1025                 : 
    1026                 :    Do not make this value too large; the results are undefined if
    1027                 :    YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
    1028                 :    evaluated with infinite-precision integer arithmetic.  */
    1029                 : 
    1030                 : #ifndef YYMAXDEPTH
    1031                 : # define YYMAXDEPTH 10000
    1032                 : #endif
    1033                 : 
    1034                 : 
    1035                 : 
    1036                 : #if YYERROR_VERBOSE
    1037                 : 
    1038                 : # ifndef yystrlen
    1039                 : #  if defined __GLIBC__ && defined _STRING_H
    1040                 : #   define yystrlen strlen
    1041                 : #  else
    1042                 : /* Return the length of YYSTR.  */
    1043                 : #if (defined __STDC__ || defined __C99__FUNC__ \
    1044                 :      || defined __cplusplus || defined _MSC_VER)
    1045                 : static YYSIZE_T
    1046                 : yystrlen (const char *yystr)
    1047                 : #else
    1048                 : static YYSIZE_T
    1049                 : yystrlen (yystr)
    1050                 :     const char *yystr;
    1051                 : #endif
    1052                 : {
    1053                 :   YYSIZE_T yylen;
    1054                 :   for (yylen = 0; yystr[yylen]; yylen++)
    1055                 :     continue;
    1056                 :   return yylen;
    1057                 : }
    1058                 : #  endif
    1059                 : # endif
    1060                 : 
    1061                 : # ifndef yystpcpy
    1062                 : #  if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
    1063                 : #   define yystpcpy stpcpy
    1064                 : #  else
    1065                 : /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
    1066                 :    YYDEST.  */
    1067                 : #if (defined __STDC__ || defined __C99__FUNC__ \
    1068                 :      || defined __cplusplus || defined _MSC_VER)
    1069                 : static char *
    1070                 : yystpcpy (char *yydest, const char *yysrc)
    1071                 : #else
    1072                 : static char *
    1073                 : yystpcpy (yydest, yysrc)
    1074                 :     char *yydest;
    1075                 :     const char *yysrc;
    1076                 : #endif
    1077                 : {
    1078                 :   char *yyd = yydest;
    1079                 :   const char *yys = yysrc;
    1080                 : 
    1081                 :   while ((*yyd++ = *yys++) != '\0')
    1082                 :     continue;
    1083                 : 
    1084                 :   return yyd - 1;
    1085                 : }
    1086                 : #  endif
    1087                 : # endif
    1088                 : 
    1089                 : # ifndef yytnamerr
    1090                 : /* Copy to YYRES the contents of YYSTR after stripping away unnecessary
    1091                 :    quotes and backslashes, so that it's suitable for yyerror.  The
    1092                 :    heuristic is that double-quoting is unnecessary unless the string
    1093                 :    contains an apostrophe, a comma, or backslash (other than
    1094                 :    backslash-backslash).  YYSTR is taken from yytname.  If YYRES is
    1095                 :    null, do not copy; instead, return the length of what the result
    1096                 :    would have been.  */
    1097                 : static YYSIZE_T
    1098                 : yytnamerr (char *yyres, const char *yystr)
    1099                 : {
    1100                 :   if (*yystr == '"')
    1101                 :     {
    1102                 :       YYSIZE_T yyn = 0;
    1103                 :       char const *yyp = yystr;
    1104                 : 
    1105                 :       for (;;)
    1106                 :         switch (*++yyp)
    1107                 :           {
    1108                 :           case '\'':
    1109                 :           case ',':
    1110                 :             goto do_not_strip_quotes;
    1111                 : 
    1112                 :           case '\\':
    1113                 :             if (*++yyp != '\\')
    1114                 :               goto do_not_strip_quotes;
    1115                 :             /* Fall through.  */
    1116                 :           default:
    1117                 :             if (yyres)
    1118                 :               yyres[yyn] = *yyp;
    1119                 :             yyn++;
    1120                 :             break;
    1121                 : 
    1122                 :           case '"':
    1123                 :             if (yyres)
    1124                 :               yyres[yyn] = '\0';
    1125                 :             return yyn;
    1126                 :           }
    1127                 :     do_not_strip_quotes: ;
    1128                 :     }
    1129                 : 
    1130                 :   if (! yyres)
    1131                 :     return yystrlen (yystr);
    1132                 : 
    1133                 :   return yystpcpy (yyres, yystr) - yyres;
    1134                 : }
    1135                 : # endif
    1136                 : 
    1137                 : /* Copy into YYRESULT an error message about the unexpected token
    1138                 :    YYCHAR while in state YYSTATE.  Return the number of bytes copied,
    1139                 :    including the terminating null byte.  If YYRESULT is null, do not
    1140                 :    copy anything; just return the number of bytes that would be
    1141                 :    copied.  As a special case, return 0 if an ordinary "syntax error"
    1142                 :    message will do.  Return YYSIZE_MAXIMUM if overflow occurs during
    1143                 :    size calculation.  */
    1144                 : static YYSIZE_T
    1145                 : yysyntax_error (char *yyresult, int yystate, int yychar)
    1146                 : {
    1147                 :   int yyn = yypact[yystate];
    1148                 : 
    1149                 :   if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
    1150                 :     return 0;
    1151                 :   else
    1152                 :     {
    1153                 :       int yytype = YYTRANSLATE (yychar);
    1154                 :       YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]);
    1155                 :       YYSIZE_T yysize = yysize0;
    1156                 :       YYSIZE_T yysize1;
    1157                 :       int yysize_overflow = 0;
    1158                 :       enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
    1159                 :       char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
    1160                 :       int yyx;
    1161                 : 
    1162                 : # if 0
    1163                 :       /* This is so xgettext sees the translatable formats that are
    1164                 :          constructed on the fly.  */
    1165                 :       YY_("syntax error, unexpected %s");
    1166                 :       YY_("syntax error, unexpected %s, expecting %s");
    1167                 :       YY_("syntax error, unexpected %s, expecting %s or %s");
    1168                 :       YY_("syntax error, unexpected %s, expecting %s or %s or %s");
    1169                 :       YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
    1170                 : # endif
    1171                 :       char *yyfmt;
    1172                 :       char const *yyf;
    1173                 :       static char const yyunexpected[] = "syntax error, unexpected %s";
    1174                 :       static char const yyexpecting[] = ", expecting %s";
    1175                 :       static char const yyor[] = " or %s";
    1176                 :       char yyformat[sizeof yyunexpected
    1177                 :                     + sizeof yyexpecting - 1
    1178                 :                     + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2)
    1179                 :                        * (sizeof yyor - 1))];
    1180                 :       char const *yyprefix = yyexpecting;
    1181                 : 
    1182                 :       /* Start YYX at -YYN if negative to avoid negative indexes in
    1183                 :          YYCHECK.  */
    1184                 :       int yyxbegin = yyn < 0 ? -yyn : 0;
    1185                 : 
    1186                 :       /* Stay within bounds of both yycheck and yytname.  */
    1187                 :       int yychecklim = YYLAST - yyn + 1;
    1188                 :       int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
    1189                 :       int yycount = 1;
    1190                 : 
    1191                 :       yyarg[0] = yytname[yytype];
    1192                 :       yyfmt = yystpcpy (yyformat, yyunexpected);
    1193                 : 
    1194                 :       for (yyx = yyxbegin; yyx < yyxend; ++yyx)
    1195                 :         if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
    1196                 :           {
    1197                 :             if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
    1198                 :               {
    1199                 :                 yycount = 1;
    1200                 :                 yysize = yysize0;
    1201                 :                 yyformat[sizeof yyunexpected - 1] = '\0';
    1202                 :                 break;
    1203                 :               }
    1204                 :             yyarg[yycount++] = yytname[yyx];
    1205                 :             yysize1 = yysize + yytnamerr (0, yytname[yyx]);
    1206                 :             yysize_overflow |= (yysize1 < yysize);
    1207                 :             yysize = yysize1;
    1208                 :             yyfmt = yystpcpy (yyfmt, yyprefix);
    1209                 :             yyprefix = yyor;
    1210                 :           }
    1211                 : 
    1212                 :       yyf = YY_(yyformat);
    1213                 :       yysize1 = yysize + yystrlen (yyf);
    1214                 :       yysize_overflow |= (yysize1 < yysize);
    1215                 :       yysize = yysize1;
    1216                 : 
    1217                 :       if (yysize_overflow)
    1218                 :         return YYSIZE_MAXIMUM;
    1219                 : 
    1220                 :       if (yyresult)
    1221                 :         {
    1222                 :           /* Avoid sprintf, as that infringes on the user's name space.
    1223                 :              Don't have undefined behavior even if the translation
    1224                 :              produced a string with the wrong number of "%s"s.  */
    1225                 :           char *yyp = yyresult;
    1226                 :           int yyi = 0;
    1227                 :           while ((*yyp = *yyf) != '\0')
    1228                 :             {
    1229                 :               if (*yyp == '%' && yyf[1] == 's' && yyi < yycount)
    1230                 :                 {
    1231                 :                   yyp += yytnamerr (yyp, yyarg[yyi++]);
    1232                 :                   yyf += 2;
    1233                 :                 }
    1234                 :               else
    1235                 :                 {
    1236                 :                   yyp++;
    1237                 :                   yyf++;
    1238                 :                 }
    1239                 :             }
    1240                 :         }
    1241                 :       return yysize;
    1242                 :     }
    1243                 : }
    1244                 : #endif /* YYERROR_VERBOSE */
    1245                 : 
    1246                 : 
    1247                 : /*-----------------------------------------------.
    1248                 : | Release the memory associated to this symbol.  |
    1249                 : `-----------------------------------------------*/
    1250                 : 
    1251                 : /*ARGSUSED*/
    1252                 : #if (defined __STDC__ || defined __C99__FUNC__ \
    1253                 :      || defined __cplusplus || defined _MSC_VER)
    1254                 : static void
    1255                 : yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep)
    1256                 : #else
    1257                 : static void
    1258                 : yydestruct (yymsg, yytype, yyvaluep)
    1259                 :     const char *yymsg;
    1260                 :     int yytype;
    1261                 :     YYSTYPE *yyvaluep;
    1262                 : #endif
    1263             219 : {
    1264                 :   YYUSE (yyvaluep);
    1265                 : 
    1266             219 :   if (!yymsg)
    1267               0 :     yymsg = "Deleting";
    1268                 :   YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
    1269                 : 
    1270                 :   switch (yytype)
    1271                 :     {
    1272                 : 
    1273                 :       default:
    1274                 :         break;
    1275                 :     }
    1276             219 : }
    1277                 : 
    1278                 : 
    1279                 : /* Prevent warnings from -Wmissing-prototypes.  */
    1280                 : 
    1281                 : #ifdef YYPARSE_PARAM
    1282                 : #if defined __STDC__ || defined __cplusplus
    1283                 : int yyparse (void *YYPARSE_PARAM);
    1284                 : #else
    1285                 : int yyparse ();
    1286                 : #endif
    1287                 : #else /* ! YYPARSE_PARAM */
    1288                 : #if defined __STDC__ || defined __cplusplus
    1289                 : int yyparse (void);
    1290                 : #else
    1291                 : int yyparse ();
    1292                 : #endif
    1293                 : #endif /* ! YYPARSE_PARAM */
    1294                 : 
    1295                 : 
    1296                 : 
    1297                 : 
    1298                 : 
    1299                 : 
    1300                 : /*----------.
    1301                 : | yyparse.  |
    1302                 : `----------*/
    1303                 : 
    1304                 : #ifdef YYPARSE_PARAM
    1305                 : #if (defined __STDC__ || defined __C99__FUNC__ \
    1306                 :      || defined __cplusplus || defined _MSC_VER)
    1307                 : int
    1308                 : yyparse (void *YYPARSE_PARAM)
    1309                 : #else
    1310                 : int
    1311                 : yyparse (YYPARSE_PARAM)
    1312                 :     void *YYPARSE_PARAM;
    1313                 : #endif
    1314                 : #else /* ! YYPARSE_PARAM */
    1315                 : #if (defined __STDC__ || defined __C99__FUNC__ \
    1316                 :      || defined __cplusplus || defined _MSC_VER)
    1317                 : int
    1318                 : yyparse (void)
    1319                 : #else
    1320                 : int
    1321                 : yyparse ()
    1322                 : 
    1323                 : #endif
    1324                 : #endif
    1325             219 : {
    1326                 :   /* The look-ahead symbol.  */
    1327                 : int yychar;
    1328                 : 
    1329                 : /* The semantic value of the look-ahead symbol.  */
    1330                 : YYSTYPE yylval;
    1331                 : 
    1332                 : /* Number of syntax errors so far.  */
    1333                 : int yynerrs;
    1334                 : 
    1335                 :   int yystate;
    1336                 :   int yyn;
    1337                 :   int yyresult;
    1338                 :   /* Number of tokens to shift before error messages enabled.  */
    1339                 :   int yyerrstatus;
    1340                 :   /* Look-ahead token as an internal (translated) token number.  */
    1341             219 :   int yytoken = 0;
    1342                 : #if YYERROR_VERBOSE
    1343                 :   /* Buffer for error messages, and its allocated size.  */
    1344                 :   char yymsgbuf[128];
    1345                 :   char *yymsg = yymsgbuf;
    1346                 :   YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
    1347                 : #endif
    1348                 : 
    1349                 :   /* Three stacks and their tools:
    1350                 :      `yyss': related to states,
    1351                 :      `yyvs': related to semantic values,
    1352                 :      `yyls': related to locations.
    1353                 : 
    1354                 :      Refer to the stacks thru separate pointers, to allow yyoverflow
    1355                 :      to reallocate them elsewhere.  */
    1356                 : 
    1357                 :   /* The state stack.  */
    1358                 :   yytype_int16 yyssa[YYINITDEPTH];
    1359             219 :   yytype_int16 *yyss = yyssa;
    1360                 :   yytype_int16 *yyssp;
    1361                 : 
    1362                 :   /* The semantic value stack.  */
    1363                 :   YYSTYPE yyvsa[YYINITDEPTH];
    1364             219 :   YYSTYPE *yyvs = yyvsa;
    1365                 :   YYSTYPE *yyvsp;
    1366                 : 
    1367                 : 
    1368                 : 
    1369                 : #define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N))
    1370                 : 
    1371             219 :   YYSIZE_T yystacksize = YYINITDEPTH;
    1372                 : 
    1373                 :   /* The variables used to return semantic value and location from the
    1374                 :      action routines.  */
    1375                 :   YYSTYPE yyval;
    1376                 : 
    1377                 : 
    1378                 :   /* The number of symbols on the RHS of the reduced rule.
    1379                 :      Keep to zero when no symbol should be popped.  */
    1380             219 :   int yylen = 0;
    1381                 : 
    1382                 :   YYDPRINTF ((stderr, "Starting parse\n"));
    1383                 : 
    1384             219 :   yystate = 0;
    1385             219 :   yyerrstatus = 0;
    1386             219 :   yynerrs = 0;
    1387             219 :   yychar = YYEMPTY;             /* Cause a token to be read.  */
    1388                 : 
    1389                 :   /* Initialize stack pointers.
    1390                 :      Waste one element of value and location stack
    1391                 :      so that they stay on the same level as the state stack.
    1392                 :      The wasted elements are never initialized.  */
    1393                 : 
    1394             219 :   yyssp = yyss;
    1395             219 :   yyvsp = yyvs;
    1396                 : 
    1397             219 :   goto yysetstate;
    1398                 : 
    1399                 : /*------------------------------------------------------------.
    1400                 : | yynewstate -- Push a new state, which is found in yystate.  |
    1401                 : `------------------------------------------------------------*/
    1402           41338 :  yynewstate:
    1403                 :   /* In all cases, when you get here, the value and location stacks
    1404                 :      have just been pushed.  So pushing a state here evens the stacks.  */
    1405           41338 :   yyssp++;
    1406                 : 
    1407           41557 :  yysetstate:
    1408           41557 :   *yyssp = yystate;
    1409                 : 
    1410           41557 :   if (yyss + yystacksize - 1 <= yyssp)
    1411                 :     {
    1412                 :       /* Get the current used size of the three stacks, in elements.  */
    1413               0 :       YYSIZE_T yysize = yyssp - yyss + 1;
    1414                 : 
    1415                 : #ifdef yyoverflow
    1416                 :       {
    1417                 :         /* Give user a chance to reallocate the stack.  Use copies of
    1418                 :            these so that the &'s don't force the real ones into
    1419                 :            memory.  */
    1420                 :         YYSTYPE *yyvs1 = yyvs;
    1421                 :         yytype_int16 *yyss1 = yyss;
    1422                 : 
    1423                 : 
    1424                 :         /* Each stack pointer address is followed by the size of the
    1425                 :            data in use in that stack, in bytes.  This used to be a
    1426                 :            conditional around just the two extra args, but that might
    1427                 :            be undefined if yyoverflow is a macro.  */
    1428                 :         yyoverflow (YY_("memory exhausted"),
    1429                 :                     &yyss1, yysize * sizeof (*yyssp),
    1430                 :                     &yyvs1, yysize * sizeof (*yyvsp),
    1431                 : 
    1432                 :                     &yystacksize);
    1433                 : 
    1434                 :         yyss = yyss1;
    1435                 :         yyvs = yyvs1;
    1436                 :       }
    1437                 : #else /* no yyoverflow */
    1438                 : # ifndef YYSTACK_RELOCATE
    1439                 :       goto yyexhaustedlab;
    1440                 : # else
    1441                 :       /* Extend the stack our own way.  */
    1442               0 :       if (YYMAXDEPTH <= yystacksize)
    1443               0 :         goto yyexhaustedlab;
    1444               0 :       yystacksize *= 2;
    1445               0 :       if (YYMAXDEPTH < yystacksize)
    1446               0 :         yystacksize = YYMAXDEPTH;
    1447                 : 
    1448                 :       {
    1449               0 :         yytype_int16 *yyss1 = yyss;
    1450                 :         union yyalloc *yyptr =
    1451               0 :           (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
    1452               0 :         if (! yyptr)
    1453               0 :           goto yyexhaustedlab;
    1454               0 :         YYSTACK_RELOCATE (yyss);
    1455               0 :         YYSTACK_RELOCATE (yyvs);
    1456                 : 
    1457                 : #  undef YYSTACK_RELOCATE
    1458               0 :         if (yyss1 != yyssa)
    1459               0 :           YYSTACK_FREE (yyss1);
    1460                 :       }
    1461                 : # endif
    1462                 : #endif /* no yyoverflow */
    1463                 : 
    1464               0 :       yyssp = yyss + yysize - 1;
    1465               0 :       yyvsp = yyvs + yysize - 1;
    1466                 : 
    1467                 : 
    1468                 :       YYDPRINTF ((stderr, "Stack size increased to %lu\n",
    1469                 :                   (unsigned long int) yystacksize));
    1470                 : 
    1471               0 :       if (yyss + yystacksize - 1 <= yyssp)
    1472               0 :         YYABORT;
    1473                 :     }
    1474                 : 
    1475                 :   YYDPRINTF ((stderr, "Entering state %d\n", yystate));
    1476                 : 
    1477                 :   goto yybackup;
    1478                 : 
    1479                 : /*-----------.
    1480                 : | yybackup.  |
    1481                 : `-----------*/
    1482           41557 : yybackup:
    1483                 : 
    1484                 :   /* Do appropriate processing given the current state.  Read a
    1485                 :      look-ahead token if we need one and don't already have one.  */
    1486                 : 
    1487                 :   /* First try to decide what to do without reference to look-ahead token.  */
    1488           41557 :   yyn = yypact[yystate];
    1489           41557 :   if (yyn == YYPACT_NINF)
    1490           20777 :     goto yydefault;
    1491                 : 
    1492                 :   /* Not known => get a look-ahead token if don't already have one.  */
    1493                 : 
    1494                 :   /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol.  */
    1495           20780 :   if (yychar == YYEMPTY)
    1496                 :     {
    1497                 :       YYDPRINTF ((stderr, "Reading a token: "));
    1498           15962 :       yychar = YYLEX;
    1499                 :     }
    1500                 : 
    1501           20780 :   if (yychar <= YYEOF)
    1502                 :     {
    1503             219 :       yychar = yytoken = YYEOF;
    1504                 :       YYDPRINTF ((stderr, "Now at end of input.\n"));
    1505                 :     }
    1506                 :   else
    1507                 :     {
    1508           20561 :       yytoken = YYTRANSLATE (yychar);
    1509                 :       YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
    1510                 :     }
    1511                 : 
    1512                 :   /* If the proper action on seeing token YYTOKEN is to reduce or to
    1513                 :      detect an error, take that action.  */
    1514           20780 :   yyn += yytoken;
    1515           20780 :   if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
    1516                 :     goto yydefault;
    1517           15962 :   yyn = yytable[yyn];
    1518           15962 :   if (yyn <= 0)
    1519                 :     {
    1520               0 :       if (yyn == 0 || yyn == YYTABLE_NINF)
    1521                 :         goto yyerrlab;
    1522               0 :       yyn = -yyn;
    1523               0 :       goto yyreduce;
    1524                 :     }
    1525                 : 
    1526           15962 :   if (yyn == YYFINAL)
    1527             219 :     YYACCEPT;
    1528                 : 
    1529                 :   /* Count tokens shifted since error; after three, turn off error
    1530                 :      status.  */
    1531           15743 :   if (yyerrstatus)
    1532               0 :     yyerrstatus--;
    1533                 : 
    1534                 :   /* Shift the look-ahead token.  */
    1535                 :   YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
    1536                 : 
    1537                 :   /* Discard the shifted token unless it is eof.  */
    1538           15743 :   if (yychar != YYEOF)
    1539           15743 :     yychar = YYEMPTY;
    1540                 : 
    1541           15743 :   yystate = yyn;
    1542           15743 :   *++yyvsp = yylval;
    1543                 : 
    1544           15743 :   goto yynewstate;
    1545                 : 
    1546                 : 
    1547                 : /*-----------------------------------------------------------.
    1548                 : | yydefault -- do the default action for the current state.  |
    1549                 : `-----------------------------------------------------------*/
    1550           25595 : yydefault:
    1551           25595 :   yyn = yydefact[yystate];
    1552           25595 :   if (yyn == 0)
    1553               0 :     goto yyerrlab;
    1554                 :   goto yyreduce;
    1555                 : 
    1556                 : 
    1557                 : /*-----------------------------.
    1558                 : | yyreduce -- Do a reduction.  |
    1559                 : `-----------------------------*/
    1560           25595 : yyreduce:
    1561                 :   /* yyn is the number of a rule to reduce with.  */
    1562           25595 :   yylen = yyr2[yyn];
    1563                 : 
    1564                 :   /* If YYLEN is nonzero, implement the default value of the action:
    1565                 :      `$$ = $1'.
    1566                 : 
    1567                 :      Otherwise, the following line sets YYVAL to garbage.
    1568                 :      This behavior is undocumented and Bison
    1569                 :      users should not rely upon it.  Assigning to YYVAL
    1570                 :      unconditionally makes the parser a bit smaller, and it avoids a
    1571                 :      GCC warning that YYVAL may be used uninitialized.  */
    1572           25595 :   yyval = yyvsp[1-yylen];
    1573                 : 
    1574                 : 
    1575                 :   YY_REDUCE_PRINT (yyn);
    1576           25595 :   switch (yyn)
    1577                 :     {
    1578                 :         case 4:
    1579                 : #line 253 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1580                 :     {
    1581                 : #if DEBUG_CFG_PARSER
    1582                 :                         printf("'%s' = '%s'\n", (yyvsp[(1) - (3)]).value.str.val, (yyvsp[(3) - (3)]).value.str.val);
    1583                 : #endif
    1584                 :                         ZEND_INI_PARSER_CB(&(yyvsp[(1) - (3)]), &(yyvsp[(3) - (3)]), ZEND_INI_PARSER_ENTRY, ZEND_INI_PARSER_ARG);
    1585                 :                         free((yyvsp[(1) - (3)]).value.str.val);
    1586                 :                         free((yyvsp[(3) - (3)]).value.str.val);
    1587                 :                 }
    1588                 :     break;
    1589                 : 
    1590                 :   case 5:
    1591                 : #line 261 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1592                 :     {
    1593                 : #if DEBUG_CFG_PARSER
    1594                 :                         printf("'%s'[ ] = '%s'\n", (yyvsp[(1) - (4)]).value.str.val, (yyvsp[(4) - (4)]).value.str.val);
    1595                 : #endif
    1596                 :                         ZEND_INI_PARSER_CB(&(yyvsp[(1) - (4)]), &(yyvsp[(4) - (4)]), ZEND_INI_PARSER_POP_ENTRY, ZEND_INI_PARSER_ARG);
    1597                 :                         free((yyvsp[(1) - (4)]).value.str.val);
    1598                 :                         free((yyvsp[(4) - (4)]).value.str.val);
    1599                 :                 }
    1600                 :     break;
    1601                 : 
    1602                 :   case 6:
    1603                 : #line 269 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1604                 :     { ZEND_INI_PARSER_CB(&(yyvsp[(1) - (1)]), NULL, ZEND_INI_PARSER_ENTRY, ZEND_INI_PARSER_ARG); free((yyvsp[(1) - (1)]).value.str.val); }
    1605                 :     break;
    1606                 : 
    1607                 :   case 7:
    1608                 : #line 270 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1609                 :     { ZEND_INI_PARSER_CB(&(yyvsp[(1) - (1)]), NULL, ZEND_INI_PARSER_SECTION, ZEND_INI_PARSER_ARG); free((yyvsp[(1) - (1)]).value.str.val); }
    1610                 :     break;
    1611                 : 
    1612                 :   case 9:
    1613                 : #line 276 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1614                 :     { (yyval) = (yyvsp[(1) - (1)]); }
    1615                 :     break;
    1616                 : 
    1617                 :   case 10:
    1618                 : #line 277 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1619                 :     { (yyval) = (yyvsp[(1) - (1)]); }
    1620                 :     break;
    1621                 : 
    1622                 :   case 11:
    1623                 : #line 278 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1624                 :     { (yyval) = (yyvsp[(1) - (1)]); }
    1625                 :     break;
    1626                 : 
    1627                 :   case 12:
    1628                 : #line 279 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1629                 :     { zend_ini_init_string(&(yyval)); }
    1630                 :     break;
    1631                 : 
    1632                 :   case 13:
    1633                 : #line 280 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1634                 :     { zend_ini_init_string(&(yyval)); }
    1635                 :     break;
    1636                 : 
    1637                 :   case 14:
    1638                 : #line 285 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1639                 :     { (yyval) = (yyvsp[(1) - (1)]); }
    1640                 :     break;
    1641                 : 
    1642                 :   case 15:
    1643                 : #line 286 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1644                 :     { (yyval) = (yyvsp[(1) - (1)]); }
    1645                 :     break;
    1646                 : 
    1647                 :   case 16:
    1648                 : #line 287 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1649                 :     { (yyval) = (yyvsp[(1) - (1)]); }
    1650                 :     break;
    1651                 : 
    1652                 :   case 17:
    1653                 : #line 288 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1654                 :     { zend_ini_add_string(&(yyval), &(yyvsp[(1) - (2)]), &(yyvsp[(2) - (2)])); free((yyvsp[(2) - (2)]).value.str.val); }
    1655                 :     break;
    1656                 : 
    1657                 :   case 18:
    1658                 : #line 289 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1659                 :     { zend_ini_add_string(&(yyval), &(yyvsp[(1) - (2)]), &(yyvsp[(2) - (2)])); free((yyvsp[(2) - (2)]).value.str.val); }
    1660                 :     break;
    1661                 : 
    1662                 :   case 19:
    1663                 : #line 290 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1664                 :     { zend_ini_add_string(&(yyval), &(yyvsp[(1) - (2)]), &(yyvsp[(2) - (2)])); free((yyvsp[(2) - (2)]).value.str.val); }
    1665                 :     break;
    1666                 : 
    1667                 :   case 20:
    1668                 : #line 294 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1669                 :     { zend_ini_get_var(&(yyval), &(yyvsp[(2) - (3)])); free((yyvsp[(2) - (3)]).value.str.val); }
    1670                 :     break;
    1671                 : 
    1672                 :   case 21:
    1673                 : #line 298 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1674                 :     { (yyval) = (yyvsp[(1) - (1)]); }
    1675                 :     break;
    1676                 : 
    1677                 :   case 22:
    1678                 : #line 299 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1679                 :     { zend_ini_do_op('|', &(yyval), &(yyvsp[(1) - (3)]), &(yyvsp[(3) - (3)])); }
    1680                 :     break;
    1681                 : 
    1682                 :   case 23:
    1683                 : #line 300 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1684                 :     { zend_ini_do_op('&', &(yyval), &(yyvsp[(1) - (3)]), &(yyvsp[(3) - (3)])); }
    1685                 :     break;
    1686                 : 
    1687                 :   case 24:
    1688                 : #line 301 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1689                 :     { zend_ini_do_op('~', &(yyval), &(yyvsp[(2) - (2)]), NULL); }
    1690                 :     break;
    1691                 : 
    1692                 :   case 25:
    1693                 : #line 302 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1694                 :     { zend_ini_do_op('!', &(yyval), &(yyvsp[(2) - (2)]), NULL); }
    1695                 :     break;
    1696                 : 
    1697                 :   case 26:
    1698                 : #line 303 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1699                 :     { (yyval) = (yyvsp[(2) - (3)]); }
    1700                 :     break;
    1701                 : 
    1702                 :   case 27:
    1703                 : #line 307 "/home/mike/cvs/php-5.2/Zend/zend_ini_parser.y"
    1704                 :     { zend_ini_get_constant(&(yyval), &(yyvsp[(1) - (1)])); }
    1705                 :     break;
    1706                 : 
    1707                 : 
    1708                 : /* Line 1267 of yacc.c.  */
    1709                 : #line 1710 "Zend/zend_ini_parser.c"
    1710                 :       default: break;
    1711                 :     }
    1712                 :   YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
    1713                 : 
    1714           25595 :   YYPOPSTACK (yylen);
    1715           25595 :   yylen = 0;
    1716                 :   YY_STACK_PRINT (yyss, yyssp);
    1717                 : 
    1718           25595 :   *++yyvsp = yyval;
    1719                 : 
    1720                 : 
    1721                 :   /* Now `shift' the result of the reduction.  Determine what state
    1722                 :      that goes to, based on the state we popped back to and the rule
    1723                 :      number reduced by.  */
    1724                 : 
    1725           25595 :   yyn = yyr1[yyn];
    1726                 : 
    1727           25595 :   yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
    1728           25595 :   if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
    1729               0 :     yystate = yytable[yystate];
    1730                 :   else
    1731           25595 :     yystate = yydefgoto[yyn - YYNTOKENS];
    1732                 : 
    1733           25595 :   goto yynewstate;
    1734                 : 
    1735                 : 
    1736                 : /*------------------------------------.
    1737                 : | yyerrlab -- here on detecting error |
    1738                 : `------------------------------------*/
    1739               0 : yyerrlab:
    1740                 :   /* If not already recovering from an error, report this error.  */
    1741               0 :   if (!yyerrstatus)
    1742                 :     {
    1743               0 :       ++yynerrs;
    1744                 : #if ! YYERROR_VERBOSE
    1745               0 :       yyerror (YY_("syntax error"));
    1746                 : #else
    1747                 :       {
    1748                 :         YYSIZE_T yysize = yysyntax_error (0, yystate, yychar);
    1749                 :         if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM)
    1750                 :           {
    1751                 :             YYSIZE_T yyalloc = 2 * yysize;
    1752                 :             if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM))
    1753                 :               yyalloc = YYSTACK_ALLOC_MAXIMUM;
    1754                 :             if (yymsg != yymsgbuf)
    1755                 :               YYSTACK_FREE (yymsg);
    1756                 :             yymsg = (char *) YYSTACK_ALLOC (yyalloc);
    1757                 :             if (yymsg)
    1758                 :               yymsg_alloc = yyalloc;
    1759                 :             else
    1760                 :               {
    1761                 :                 yymsg = yymsgbuf;
    1762                 :                 yymsg_alloc = sizeof yymsgbuf;
    1763                 :               }
    1764                 :           }
    1765                 : 
    1766                 :         if (0 < yysize && yysize <= yymsg_alloc)
    1767                 :           {
    1768                 :             (void) yysyntax_error (yymsg, yystate, yychar);
    1769                 :             yyerror (yymsg);
    1770                 :           }
    1771                 :         else
    1772                 :           {
    1773                 :             yyerror (YY_("syntax error"));
    1774                 :             if (yysize != 0)
    1775                 :               goto yyexhaustedlab;
    1776                 :           }
    1777                 :       }
    1778                 : #endif
    1779                 :     }
    1780                 : 
    1781                 : 
    1782                 : 
    1783               0 :   if (yyerrstatus == 3)
    1784                 :     {
    1785                 :       /* If just tried and failed to reuse look-ahead token after an
    1786                 :          error, discard it.  */
    1787                 : 
    1788               0 :       if (yychar <= YYEOF)
    1789                 :         {
    1790                 :           /* Return failure if at end of input.  */
    1791               0 :           if (yychar == YYEOF)
    1792               0 :             YYABORT;
    1793                 :         }
    1794                 :       else
    1795                 :         {
    1796               0 :           yydestruct ("Error: discarding",
    1797                 :                       yytoken, &yylval);
    1798               0 :           yychar = YYEMPTY;
    1799                 :         }
    1800                 :     }
    1801                 : 
    1802                 :   /* Else will try to reuse look-ahead token after shifting the error
    1803                 :      token.  */
    1804               0 :   goto yyerrlab1;
    1805                 : 
    1806                 : 
    1807                 : /*---------------------------------------------------.
    1808                 : | yyerrorlab -- error raised explicitly by YYERROR.  |
    1809                 : `---------------------------------------------------*/
    1810                 : yyerrorlab:
    1811                 : 
    1812                 :   /* Pacify compilers like GCC when the user code never invokes
    1813                 :      YYERROR and the label yyerrorlab therefore never appears in user
    1814                 :      code.  */
    1815                 :   if (/*CONSTCOND*/ 0)
    1816                 :      goto yyerrorlab;
    1817                 : 
    1818                 :   /* Do not reclaim the symbols of the rule which action triggered
    1819                 :      this YYERROR.  */
    1820                 :   YYPOPSTACK (yylen);
    1821                 :   yylen = 0;
    1822                 :   YY_STACK_PRINT (yyss, yyssp);
    1823                 :   yystate = *yyssp;
    1824                 :   goto yyerrlab1;
    1825                 : 
    1826                 : 
    1827                 : /*-------------------------------------------------------------.
    1828                 : | yyerrlab1 -- common code for both syntax error and YYERROR.  |
    1829                 : `-------------------------------------------------------------*/
    1830               0 : yyerrlab1:
    1831               0 :   yyerrstatus = 3;      /* Each real token shifted decrements this.  */
    1832                 : 
    1833                 :   for (;;)
    1834                 :     {
    1835               0 :       yyn = yypact[yystate];
    1836               0 :       if (yyn != YYPACT_NINF)
    1837                 :         {
    1838               0 :           yyn += YYTERROR;
    1839               0 :           if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
    1840                 :             {
    1841               0 :               yyn = yytable[yyn];
    1842               0 :               if (0 < yyn)
    1843               0 :                 break;
    1844                 :             }
    1845                 :         }
    1846                 : 
    1847                 :       /* Pop the current state because it cannot handle the error token.  */
    1848               0 :       if (yyssp == yyss)
    1849               0 :         YYABORT;
    1850                 : 
    1851                 : 
    1852               0 :       yydestruct ("Error: popping",
    1853                 :                   yystos[yystate], yyvsp);
    1854               0 :       YYPOPSTACK (1);
    1855               0 :       yystate = *yyssp;
    1856                 :       YY_STACK_PRINT (yyss, yyssp);
    1857               0 :     }
    1858                 : 
    1859               0 :   if (yyn == YYFINAL)
    1860               0 :     YYACCEPT;
    1861                 : 
    1862               0 :   *++yyvsp = yylval;
    1863                 : 
    1864                 : 
    1865                 :   /* Shift the error token.  */
    1866                 :   YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
    1867                 : 
    1868               0 :   yystate = yyn;
    1869               0 :   goto yynewstate;
    1870                 : 
    1871                 : 
    1872                 : /*-------------------------------------.
    1873                 : | yyacceptlab -- YYACCEPT comes here.  |
    1874                 : `-------------------------------------*/
    1875             219 : yyacceptlab:
    1876             219 :   yyresult = 0;
    1877             219 :   goto yyreturn;
    1878                 : 
    1879                 : /*-----------------------------------.
    1880                 : | yyabortlab -- YYABORT comes here.  |
    1881                 : `-----------------------------------*/
    1882               0 : yyabortlab:
    1883               0 :   yyresult = 1;
    1884               0 :   goto yyreturn;
    1885                 : 
    1886                 : #ifndef yyoverflow
    1887                 : /*-------------------------------------------------.
    1888                 : | yyexhaustedlab -- memory exhaustion comes here.  |
    1889                 : `-------------------------------------------------*/
    1890               0 : yyexhaustedlab:
    1891               0 :   yyerror (YY_("memory exhausted"));
    1892               0 :   yyresult = 2;
    1893                 :   /* Fall through.  */
    1894                 : #endif
    1895                 : 
    1896             219 : yyreturn:
    1897             219 :   if (yychar != YYEOF && yychar != YYEMPTY)
    1898               0 :      yydestruct ("Cleanup: discarding lookahead",
    1899                 :                  yytoken, &yylval);
    1900                 :   /* Do not reclaim the symbols of the rule which action triggered
    1901                 :      this YYABORT or YYACCEPT.  */
    1902             219 :   YYPOPSTACK (yylen);
    1903                 :   YY_STACK_PRINT (yyss, yyssp);
    1904             657 :   while (yyssp != yyss)
    1905                 :     {
    1906             219 :       yydestruct ("Cleanup: popping",
    1907                 :                   yystos[*yyssp], yyvsp);
    1908             219 :       YYPOPSTACK (1);
    1909                 :     }
    1910                 : #ifndef yyoverflow
    1911             219 :   if (yyss != yyssa)
    1912               0 :     YYSTACK_FREE (yyss);
    1913                 : #endif
    1914                 : #if YYERROR_VERBOSE
    1915                 :   if (yymsg != yymsgbuf)
    1916                 :     YYSTACK_FREE (yymsg);
    1917                 : #endif
    1918                 :   /* Make sure YYID is used.  */
    1919             219 :   return YYID (yyresult);
    1920                 : }
    1921                 : 
    1922                 : 
    1923                 : 

Generated by: LTP GCOV extension version 1.5