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