| 1 |
|
| /* A Bison parser, made by GNU Bison 3.7.4. */ |
| 2 |
|
| |
| 3 |
|
| /* Bison implementation for Yacc-like parsers in C |
| 4 |
|
| |
| 5 |
|
| Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2020 Free Software Foundation, |
| 6 |
|
| Inc. |
| 7 |
|
| |
| 8 |
|
| This program is free software: you can redistribute it and/or modify |
| 9 |
|
| it under the terms of the GNU General Public License as published by |
| 10 |
|
| the Free Software Foundation, either version 3 of the License, or |
| 11 |
|
| (at your option) any later version. |
| 12 |
|
| |
| 13 |
|
| This program is distributed in the hope that it will be useful, |
| 14 |
|
| but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 |
|
| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 16 |
|
| GNU General Public License for more details. |
| 17 |
|
| |
| 18 |
|
| You should have received a copy of the GNU General Public License |
| 19 |
|
| along with this program. If not, see <http://www.gnu.org/licenses/>. */ |
| 20 |
|
| |
| 21 |
|
| /* As a special exception, you may create a larger work that contains |
| 22 |
|
| part or all of the Bison parser skeleton and distribute that work |
| 23 |
|
| under terms of your choice, so long as that work isn't itself a |
| 24 |
|
| parser generator using the skeleton or a modified version thereof |
| 25 |
|
| as a parser skeleton. Alternatively, if you modify or redistribute |
| 26 |
|
| the parser skeleton itself, you may (at your option) remove this |
| 27 |
|
| special exception, which will cause the skeleton and the resulting |
| 28 |
|
| Bison output files to be licensed under the GNU General Public |
| 29 |
|
| License without this special exception. |
| 30 |
|
| |
| 31 |
|
| This special exception was added by the Free Software Foundation in |
| 32 |
|
| version 2.2 of Bison. */ |
| 33 |
|
| |
| 34 |
|
| /* C LALR(1) parser skeleton written by Richard Stallman, by |
| 35 |
|
| simplifying the original so-called "semantic" parser. */ |
| 36 |
|
| |
| 37 |
|
| /* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual, |
| 38 |
|
| especially those whose name start with YY_ or yy_. They are |
| 39 |
|
| private implementation details that can be changed or removed. */ |
| 40 |
|
| |
| 41 |
|
| /* All symbols defined below should begin with yy or YY, to avoid |
| 42 |
|
| infringing on user name space. This should be done even for local |
| 43 |
|
| variables, as they might otherwise be expanded by user macros. |
| 44 |
|
| There are some unavoidable exceptions within include files to |
| 45 |
|
| define necessary library symbols; they are noted "INFRINGES ON |
| 46 |
|
| USER NAME SPACE" below. */ |
| 47 |
|
| |
| 48 |
|
| /* Identify Bison output, and Bison version. */ |
| 49 |
|
| #define YYBISON 30704 |
| 50 |
|
| |
| 51 |
|
| /* Bison version string. */ |
| 52 |
|
| #define YYBISON_VERSION "3.7.4" |
| 53 |
|
| |
| 54 |
|
| /* Skeleton name. */ |
| 55 |
|
| #define YYSKELETON_NAME "yacc.c" |
| 56 |
|
| |
| 57 |
|
| /* Pure parsers. */ |
| 58 |
|
| #define YYPURE 2 |
| 59 |
|
| |
| 60 |
|
| /* Push parsers. */ |
| 61 |
|
| #define YYPUSH 0 |
| 62 |
|
| |
| 63 |
|
| /* Pull parsers. */ |
| 64 |
|
| #define YYPULL 1 |
| 65 |
|
| |
| 66 |
|
| /* Substitute the type names. */ |
| 67 |
|
| #define YYSTYPE SYCKSTYPE |
| 68 |
|
| /* Substitute the variable and function names. */ |
| 69 |
|
| #define yyparse syckparse |
| 70 |
|
| #define yylex sycklex |
| 71 |
|
| #define yyerror syckerror |
| 72 |
|
| #define yydebug syckdebug |
| 73 |
|
| #define yynerrs sycknerrs |
| 74 |
|
| |
| 75 |
|
| /* First part of user prologue. */ |
| 76 |
|
| #line 1 "gram.y" |
| 77 |
|
| |
| 78 |
|
| |
| 79 |
|
| #include "syck.h" |
| 80 |
|
| |
| 81 |
|
| void apply_seq_in_map( SyckParser *parser, SyckNode *n ); |
| 82 |
|
| |
| 83 |
|
| /* Bison 3.x calls yyerror(parser, msg) with 2 args due to %parse-param. |
| 84 |
|
| * Redirect to a wrapper that drops the parser arg and calls the real function. */ |
| 85 |
|
| static void syck_gram_error(void *parser_arg, const char *msg) { |
| 86 |
|
| void syckerror(char *); |
| 87 |
|
| (void)parser_arg; |
| 88 |
|
| syckerror((char *)msg); |
| 89 |
|
| } |
| 90 |
|
| #undef yyerror |
| 91 |
|
| #define yyerror syck_gram_error |
| 92 |
|
| |
| 93 |
|
| /* sycklex declared after YYSTYPE is defined, via %code provides below */ |
| 94 |
|
| |
| 95 |
|
| #define NULL_NODE(parser, node) \ |
| 96 |
|
| SyckNode *node = syck_new_str( "", scalar_plain ); \ |
| 97 |
|
| if ( ((SyckParser *)parser)->taguri_expansion == 1 ) \ |
| 98 |
|
| { \ |
| 99 |
|
| node->type_id = syck_taguri( YAML_DOMAIN, "null", 4 ); \ |
| 100 |
|
| } \ |
| 101 |
|
| else \ |
| 102 |
|
| { \ |
| 103 |
|
| node->type_id = syck_strndup( "null", 4 ); \ |
| 104 |
|
| } |
| 105 |
|
| |
| 106 |
|
| |
| 107 |
|
| #line 108 "gram.c" |
| 108 |
|
| |
| 109 |
|
| # ifndef YY_CAST |
| 110 |
|
| # ifdef __cplusplus |
| 111 |
|
| # define YY_CAST(Type, Val) static_cast<Type> (Val) |
| 112 |
|
| # define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast<Type> (Val) |
| 113 |
|
| # else |
| 114 |
|
| # define YY_CAST(Type, Val) ((Type) (Val)) |
| 115 |
|
| # define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val)) |
| 116 |
|
| # endif |
| 117 |
|
| # endif |
| 118 |
|
| # ifndef YY_NULLPTR |
| 119 |
|
| # if defined __cplusplus |
| 120 |
|
| # if 201103L <= __cplusplus |
| 121 |
|
| # define YY_NULLPTR nullptr |
| 122 |
|
| # else |
| 123 |
|
| # define YY_NULLPTR 0 |
| 124 |
|
| # endif |
| 125 |
|
| # else |
| 126 |
|
| # define YY_NULLPTR ((void*)0) |
| 127 |
|
| # endif |
| 128 |
|
| # endif |
| 129 |
|
| |
| 130 |
|
| #include "gram.h" |
| 131 |
|
| /* Symbol kind. */ |
| 132 |
|
| enum yysymbol_kind_t |
| 133 |
|
| { |
| 134 |
|
| YYSYMBOL_YYEMPTY = -2, |
| 135 |
|
| YYSYMBOL_YYEOF = 0, /* "end of file" */ |
| 136 |
|
| YYSYMBOL_YYerror = 1, /* error */ |
| 137 |
|
| YYSYMBOL_YYUNDEF = 2, /* "invalid token" */ |
| 138 |
|
| YYSYMBOL_YAML_ANCHOR = 3, /* YAML_ANCHOR */ |
| 139 |
|
| YYSYMBOL_YAML_ALIAS = 4, /* YAML_ALIAS */ |
| 140 |
|
| YYSYMBOL_YAML_TRANSFER = 5, /* YAML_TRANSFER */ |
| 141 |
|
| YYSYMBOL_YAML_TAGURI = 6, /* YAML_TAGURI */ |
| 142 |
|
| YYSYMBOL_YAML_ITRANSFER = 7, /* YAML_ITRANSFER */ |
| 143 |
|
| YYSYMBOL_YAML_WORD = 8, /* YAML_WORD */ |
| 144 |
|
| YYSYMBOL_YAML_PLAIN = 9, /* YAML_PLAIN */ |
| 145 |
|
| YYSYMBOL_YAML_BLOCK = 10, /* YAML_BLOCK */ |
| 146 |
|
| YYSYMBOL_YAML_DOCSEP = 11, /* YAML_DOCSEP */ |
| 147 |
|
| YYSYMBOL_YAML_IOPEN = 12, /* YAML_IOPEN */ |
| 148 |
|
| YYSYMBOL_YAML_INDENT = 13, /* YAML_INDENT */ |
| 149 |
|
| YYSYMBOL_YAML_IEND = 14, /* YAML_IEND */ |
| 150 |
|
| YYSYMBOL_15_ = 15, /* '-' */ |
| 151 |
|
| YYSYMBOL_16_ = 16, /* '[' */ |
| 152 |
|
| YYSYMBOL_17_ = 17, /* ']' */ |
| 153 |
|
| YYSYMBOL_18_ = 18, /* ',' */ |
| 154 |
|
| YYSYMBOL_19_ = 19, /* '?' */ |
| 155 |
|
| YYSYMBOL_20_ = 20, /* ':' */ |
| 156 |
|
| YYSYMBOL_21_ = 21, /* '{' */ |
| 157 |
|
| YYSYMBOL_22_ = 22, /* '}' */ |
| 158 |
|
| YYSYMBOL_YYACCEPT = 23, /* $accept */ |
| 159 |
|
| YYSYMBOL_doc = 24, /* doc */ |
| 160 |
|
| YYSYMBOL_atom = 25, /* atom */ |
| 161 |
|
| YYSYMBOL_ind_rep = 26, /* ind_rep */ |
| 162 |
|
| YYSYMBOL_atom_or_empty = 27, /* atom_or_empty */ |
| 163 |
|
| YYSYMBOL_empty = 28, /* empty */ |
| 164 |
|
| YYSYMBOL_indent_open = 29, /* indent_open */ |
| 165 |
|
| YYSYMBOL_indent_end = 30, /* indent_end */ |
| 166 |
|
| YYSYMBOL_indent_sep = 31, /* indent_sep */ |
| 167 |
|
| YYSYMBOL_indent_flex_end = 32, /* indent_flex_end */ |
| 168 |
|
| YYSYMBOL_word_rep = 33, /* word_rep */ |
| 169 |
|
| YYSYMBOL_struct_rep = 34, /* struct_rep */ |
| 170 |
|
| YYSYMBOL_implicit_seq = 35, /* implicit_seq */ |
| 171 |
|
| YYSYMBOL_basic_seq = 36, /* basic_seq */ |
| 172 |
|
| YYSYMBOL_top_imp_seq = 37, /* top_imp_seq */ |
| 173 |
|
| YYSYMBOL_in_implicit_seq = 38, /* in_implicit_seq */ |
| 174 |
|
| YYSYMBOL_inline_seq = 39, /* inline_seq */ |
| 175 |
|
| YYSYMBOL_in_inline_seq = 40, /* in_inline_seq */ |
| 176 |
|
| YYSYMBOL_inline_seq_atom = 41, /* inline_seq_atom */ |
| 177 |
|
| YYSYMBOL_implicit_map = 42, /* implicit_map */ |
| 178 |
|
| YYSYMBOL_top_imp_map = 43, /* top_imp_map */ |
| 179 |
|
| YYSYMBOL_complex_key = 44, /* complex_key */ |
| 180 |
|
| YYSYMBOL_complex_value = 45, /* complex_value */ |
| 181 |
|
| YYSYMBOL_complex_mapping = 46, /* complex_mapping */ |
| 182 |
|
| YYSYMBOL_in_implicit_map = 47, /* in_implicit_map */ |
| 183 |
|
| YYSYMBOL_basic_mapping = 48, /* basic_mapping */ |
| 184 |
|
| YYSYMBOL_inline_map = 49, /* inline_map */ |
| 185 |
|
| YYSYMBOL_in_inline_map = 50, /* in_inline_map */ |
| 186 |
|
| YYSYMBOL_inline_map_atom = 51 /* inline_map_atom */ |
| 187 |
|
| }; |
| 188 |
|
| typedef enum yysymbol_kind_t yysymbol_kind_t; |
| 189 |
|
| |
| 190 |
|
| |
| 191 |
|
| |
| 192 |
|
| |
| 193 |
|
| #ifdef short |
| 194 |
|
| # undef short |
| 195 |
|
| #endif |
| 196 |
|
| |
| 197 |
|
| /* On compilers that do not define __PTRDIFF_MAX__ etc., make sure |
| 198 |
|
| <limits.h> and (if available) <stdint.h> are included |
| 199 |
|
| so that the code can choose integer types of a good width. */ |
| 200 |
|
| |
| 201 |
|
| #ifndef __PTRDIFF_MAX__ |
| 202 |
|
| # include <limits.h> /* INFRINGES ON USER NAME SPACE */ |
| 203 |
|
| # if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__ |
| 204 |
|
| # include <stdint.h> /* INFRINGES ON USER NAME SPACE */ |
| 205 |
|
| # define YY_STDINT_H |
| 206 |
|
| # endif |
| 207 |
|
| #endif |
| 208 |
|
| |
| 209 |
|
| /* Narrow types that promote to a signed type and that can represent a |
| 210 |
|
| signed or unsigned integer of at least N bits. In tables they can |
| 211 |
|
| save space and decrease cache pressure. Promoting to a signed type |
| 212 |
|
| helps avoid bugs in integer arithmetic. */ |
| 213 |
|
| |
| 214 |
|
| #ifdef __INT_LEAST8_MAX__ |
| 215 |
|
| typedef __INT_LEAST8_TYPE__ yytype_int8; |
| 216 |
|
| #elif defined YY_STDINT_H |
| 217 |
|
| typedef int_least8_t yytype_int8; |
| 218 |
|
| #else |
| 219 |
|
| typedef signed char yytype_int8; |
| 220 |
|
| #endif |
| 221 |
|
| |
| 222 |
|
| #ifdef __INT_LEAST16_MAX__ |
| 223 |
|
| typedef __INT_LEAST16_TYPE__ yytype_int16; |
| 224 |
|
| #elif defined YY_STDINT_H |
| 225 |
|
| typedef int_least16_t yytype_int16; |
| 226 |
|
| #else |
| 227 |
|
| typedef short yytype_int16; |
| 228 |
|
| #endif |
| 229 |
|
| |
| 230 |
|
| #if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__ |
| 231 |
|
| typedef __UINT_LEAST8_TYPE__ yytype_uint8; |
| 232 |
|
| #elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \ |
| 233 |
|
| && UINT_LEAST8_MAX <= INT_MAX) |
| 234 |
|
| typedef uint_least8_t yytype_uint8; |
| 235 |
|
| #elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX |
| 236 |
|
| typedef unsigned char yytype_uint8; |
| 237 |
|
| #else |
| 238 |
|
| typedef short yytype_uint8; |
| 239 |
|
| #endif |
| 240 |
|
| |
| 241 |
|
| #if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__ |
| 242 |
|
| typedef __UINT_LEAST16_TYPE__ yytype_uint16; |
| 243 |
|
| #elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \ |
| 244 |
|
| && UINT_LEAST16_MAX <= INT_MAX) |
| 245 |
|
| typedef uint_least16_t yytype_uint16; |
| 246 |
|
| #elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX |
| 247 |
|
| typedef unsigned short yytype_uint16; |
| 248 |
|
| #else |
| 249 |
|
| typedef int yytype_uint16; |
| 250 |
|
| #endif |
| 251 |
|
| |
| 252 |
|
| #ifndef YYPTRDIFF_T |
| 253 |
|
| # if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__ |
| 254 |
|
| # define YYPTRDIFF_T __PTRDIFF_TYPE__ |
| 255 |
|
| # define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__ |
| 256 |
|
| # elif defined PTRDIFF_MAX |
| 257 |
|
| # ifndef ptrdiff_t |
| 258 |
|
| # include <stddef.h> /* INFRINGES ON USER NAME SPACE */ |
| 259 |
|
| # endif |
| 260 |
|
| # define YYPTRDIFF_T ptrdiff_t |
| 261 |
|
| # define YYPTRDIFF_MAXIMUM PTRDIFF_MAX |
| 262 |
|
| # else |
| 263 |
|
| # define YYPTRDIFF_T long |
| 264 |
|
| # define YYPTRDIFF_MAXIMUM LONG_MAX |
| 265 |
|
| # endif |
| 266 |
|
| #endif |
| 267 |
|
| |
| 268 |
|
| #ifndef YYSIZE_T |
| 269 |
|
| # ifdef __SIZE_TYPE__ |
| 270 |
|
| # define YYSIZE_T __SIZE_TYPE__ |
| 271 |
|
| # elif defined size_t |
| 272 |
|
| # define YYSIZE_T size_t |
| 273 |
|
| # elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__ |
| 274 |
|
| # include <stddef.h> /* INFRINGES ON USER NAME SPACE */ |
| 275 |
|
| # define YYSIZE_T size_t |
| 276 |
|
| # else |
| 277 |
|
| # define YYSIZE_T unsigned |
| 278 |
|
| # endif |
| 279 |
|
| #endif |
| 280 |
|
| |
| 281 |
|
| #define YYSIZE_MAXIMUM \ |
| 282 |
|
| YY_CAST (YYPTRDIFF_T, \ |
| 283 |
|
| (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1) \ |
| 284 |
|
| ? YYPTRDIFF_MAXIMUM \ |
| 285 |
|
| : YY_CAST (YYSIZE_T, -1))) |
| 286 |
|
| |
| 287 |
|
| #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) |
| 288 |
|
| |
| 289 |
|
| |
| 290 |
|
| /* Stored state numbers (used for stacks). */ |
| 291 |
|
| typedef yytype_int8 yy_state_t; |
| 292 |
|
| |
| 293 |
|
| /* State numbers in computations. */ |
| 294 |
|
| typedef int yy_state_fast_t; |
| 295 |
|
| |
| 296 |
|
| #ifndef YY_ |
| 297 |
|
| # if defined YYENABLE_NLS && YYENABLE_NLS |
| 298 |
|
| # if ENABLE_NLS |
| 299 |
|
| # include <libintl.h> /* INFRINGES ON USER NAME SPACE */ |
| 300 |
|
| # define YY_(Msgid) dgettext ("bison-runtime", Msgid) |
| 301 |
|
| # endif |
| 302 |
|
| # endif |
| 303 |
|
| # ifndef YY_ |
| 304 |
|
| # define YY_(Msgid) Msgid |
| 305 |
|
| # endif |
| 306 |
|
| #endif |
| 307 |
|
| |
| 308 |
|
| |
| 309 |
|
| #ifndef YY_ATTRIBUTE_PURE |
| 310 |
|
| # if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__) |
| 311 |
|
| # define YY_ATTRIBUTE_PURE __attribute__ ((__pure__)) |
| 312 |
|
| # else |
| 313 |
|
| # define YY_ATTRIBUTE_PURE |
| 314 |
|
| # endif |
| 315 |
|
| #endif |
| 316 |
|
| |
| 317 |
|
| #ifndef YY_ATTRIBUTE_UNUSED |
| 318 |
|
| # if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__) |
| 319 |
|
| # define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__)) |
| 320 |
|
| # else |
| 321 |
|
| # define YY_ATTRIBUTE_UNUSED |
| 322 |
|
| # endif |
| 323 |
|
| #endif |
| 324 |
|
| |
| 325 |
|
| /* Suppress unused-variable warnings by "using" E. */ |
| 326 |
|
| #if ! defined lint || defined __GNUC__ |
| 327 |
|
| # define YYUSE(E) ((void) (E)) |
| 328 |
|
| #else |
| 329 |
|
| # define YYUSE(E) /* empty */ |
| 330 |
|
| #endif |
| 331 |
|
| |
| 332 |
|
| #if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ |
| 333 |
|
| /* Suppress an incorrect diagnostic about yylval being uninitialized. */ |
| 334 |
|
| # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ |
| 335 |
|
| _Pragma ("GCC diagnostic push") \ |
| 336 |
|
| _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ |
| 337 |
|
| _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") |
| 338 |
|
| # define YY_IGNORE_MAYBE_UNINITIALIZED_END \ |
| 339 |
|
| _Pragma ("GCC diagnostic pop") |
| 340 |
|
| #else |
| 341 |
|
| # define YY_INITIAL_VALUE(Value) Value |
| 342 |
|
| #endif |
| 343 |
|
| #ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 344 |
|
| # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 345 |
|
| # define YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 346 |
|
| #endif |
| 347 |
|
| #ifndef YY_INITIAL_VALUE |
| 348 |
|
| # define YY_INITIAL_VALUE(Value) /* Nothing. */ |
| 349 |
|
| #endif |
| 350 |
|
| |
| 351 |
|
| #if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__ |
| 352 |
|
| # define YY_IGNORE_USELESS_CAST_BEGIN \ |
| 353 |
|
| _Pragma ("GCC diagnostic push") \ |
| 354 |
|
| _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"") |
| 355 |
|
| # define YY_IGNORE_USELESS_CAST_END \ |
| 356 |
|
| _Pragma ("GCC diagnostic pop") |
| 357 |
|
| #endif |
| 358 |
|
| #ifndef YY_IGNORE_USELESS_CAST_BEGIN |
| 359 |
|
| # define YY_IGNORE_USELESS_CAST_BEGIN |
| 360 |
|
| # define YY_IGNORE_USELESS_CAST_END |
| 361 |
|
| #endif |
| 362 |
|
| |
| 363 |
|
| |
| 364 |
|
| #define YY_ASSERT(E) ((void) (0 && (E))) |
| 365 |
|
| |
| 366 |
|
| #if !defined yyoverflow |
| 367 |
|
| |
| 368 |
|
| /* The parser invokes alloca or malloc; define the necessary symbols. */ |
| 369 |
|
| |
| 370 |
|
| # ifdef YYSTACK_USE_ALLOCA |
| 371 |
|
| # if YYSTACK_USE_ALLOCA |
| 372 |
|
| # ifdef __GNUC__ |
| 373 |
|
| # define YYSTACK_ALLOC __builtin_alloca |
| 374 |
|
| # elif defined __BUILTIN_VA_ARG_INCR |
| 375 |
|
| # include <alloca.h> /* INFRINGES ON USER NAME SPACE */ |
| 376 |
|
| # elif defined _AIX |
| 377 |
|
| # define YYSTACK_ALLOC __alloca |
| 378 |
|
| # elif defined _MSC_VER |
| 379 |
|
| # include <malloc.h> /* INFRINGES ON USER NAME SPACE */ |
| 380 |
|
| # define alloca _alloca |
| 381 |
|
| # else |
| 382 |
|
| # define YYSTACK_ALLOC alloca |
| 383 |
|
| # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS |
| 384 |
|
| # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ |
| 385 |
|
| /* Use EXIT_SUCCESS as a witness for stdlib.h. */ |
| 386 |
|
| # ifndef EXIT_SUCCESS |
| 387 |
|
| # define EXIT_SUCCESS 0 |
| 388 |
|
| # endif |
| 389 |
|
| # endif |
| 390 |
|
| # endif |
| 391 |
|
| # endif |
| 392 |
|
| # endif |
| 393 |
|
| |
| 394 |
|
| # ifdef YYSTACK_ALLOC |
| 395 |
|
| /* Pacify GCC's 'empty if-body' warning. */ |
| 396 |
|
| # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) |
| 397 |
|
| # ifndef YYSTACK_ALLOC_MAXIMUM |
| 398 |
|
| /* The OS might guarantee only one guard page at the bottom of the stack, |
| 399 |
|
| and a page size can be as small as 4096 bytes. So we cannot safely |
| 400 |
|
| invoke alloca (N) if N exceeds 4096. Use a slightly smaller number |
| 401 |
|
| to allow for a few compiler-allocated temporary stack slots. */ |
| 402 |
|
| # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ |
| 403 |
|
| # endif |
| 404 |
|
| # else |
| 405 |
|
| # define YYSTACK_ALLOC YYMALLOC |
| 406 |
|
| # define YYSTACK_FREE YYFREE |
| 407 |
|
| # ifndef YYSTACK_ALLOC_MAXIMUM |
| 408 |
|
| # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM |
| 409 |
|
| # endif |
| 410 |
|
| # if (defined __cplusplus && ! defined EXIT_SUCCESS \ |
| 411 |
|
| && ! ((defined YYMALLOC || defined malloc) \ |
| 412 |
|
| && (defined YYFREE || defined free))) |
| 413 |
|
| # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ |
| 414 |
|
| # ifndef EXIT_SUCCESS |
| 415 |
|
| # define EXIT_SUCCESS 0 |
| 416 |
|
| # endif |
| 417 |
|
| # endif |
| 418 |
|
| # ifndef YYMALLOC |
| 419 |
|
| # define YYMALLOC malloc |
| 420 |
|
| # if ! defined malloc && ! defined EXIT_SUCCESS |
| 421 |
|
| void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ |
| 422 |
|
| # endif |
| 423 |
|
| # endif |
| 424 |
|
| # ifndef YYFREE |
| 425 |
|
| # define YYFREE free |
| 426 |
|
| # if ! defined free && ! defined EXIT_SUCCESS |
| 427 |
|
| void free (void *); /* INFRINGES ON USER NAME SPACE */ |
| 428 |
|
| # endif |
| 429 |
|
| # endif |
| 430 |
|
| # endif |
| 431 |
|
| #endif /* !defined yyoverflow */ |
| 432 |
|
| |
| 433 |
|
| #if (! defined yyoverflow \ |
| 434 |
|
| && (! defined __cplusplus \ |
| 435 |
|
| || (defined SYCKSTYPE_IS_TRIVIAL && SYCKSTYPE_IS_TRIVIAL))) |
| 436 |
|
| |
| 437 |
|
| /* A type that is properly aligned for any stack member. */ |
| 438 |
|
| union yyalloc |
| 439 |
|
| { |
| 440 |
|
| yy_state_t yyss_alloc; |
| 441 |
|
| YYSTYPE yyvs_alloc; |
| 442 |
|
| }; |
| 443 |
|
| |
| 444 |
|
| /* The size of the maximum gap between one aligned stack and the next. */ |
| 445 |
|
| # define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1) |
| 446 |
|
| |
| 447 |
|
| /* The size of an array large to enough to hold all stacks, each with |
| 448 |
|
| N elements. */ |
| 449 |
|
| # define YYSTACK_BYTES(N) \ |
| 450 |
|
| ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ |
| 451 |
|
| + YYSTACK_GAP_MAXIMUM) |
| 452 |
|
| |
| 453 |
|
| # define YYCOPY_NEEDED 1 |
| 454 |
|
| |
| 455 |
|
| /* Relocate STACK from its old location to the new one. The |
| 456 |
|
| local variables YYSIZE and YYSTACKSIZE give the old and new number of |
| 457 |
|
| elements in the stack, and YYPTR gives the new location of the |
| 458 |
|
| stack. Advance YYPTR to a properly aligned location for the next |
| 459 |
|
| stack. */ |
| 460 |
|
| # define YYSTACK_RELOCATE(Stack_alloc, Stack) \ |
| 461 |
|
| do \ |
| 462 |
|
| { \ |
| 463 |
|
| YYPTRDIFF_T yynewbytes; \ |
| 464 |
|
| YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ |
| 465 |
|
| Stack = &yyptr->Stack_alloc; \ |
| 466 |
|
| yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \ |
| 467 |
|
| yyptr += yynewbytes / YYSIZEOF (*yyptr); \ |
| 468 |
|
| } \ |
| 469 |
|
| while (0) |
| 470 |
|
| |
| 471 |
|
| #endif |
| 472 |
|
| |
| 473 |
|
| #if defined YYCOPY_NEEDED && YYCOPY_NEEDED |
| 474 |
|
| /* Copy COUNT objects from SRC to DST. The source and destination do |
| 475 |
|
| not overlap. */ |
| 476 |
|
| # ifndef YYCOPY |
| 477 |
|
| # if defined __GNUC__ && 1 < __GNUC__ |
| 478 |
|
| # define YYCOPY(Dst, Src, Count) \ |
| 479 |
|
| __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src))) |
| 480 |
|
| # else |
| 481 |
|
| # define YYCOPY(Dst, Src, Count) \ |
| 482 |
|
| do \ |
| 483 |
|
| { \ |
| 484 |
|
| YYPTRDIFF_T yyi; \ |
| 485 |
|
| for (yyi = 0; yyi < (Count); yyi++) \ |
| 486 |
|
| (Dst)[yyi] = (Src)[yyi]; \ |
| 487 |
|
| } \ |
| 488 |
|
| while (0) |
| 489 |
|
| # endif |
| 490 |
|
| # endif |
| 491 |
|
| #endif /* !YYCOPY_NEEDED */ |
| 492 |
|
| |
| 493 |
|
| /* YYFINAL -- State number of the termination state. */ |
| 494 |
|
| #define YYFINAL 49 |
| 495 |
|
| /* YYLAST -- Last index in YYTABLE. */ |
| 496 |
|
| #define YYLAST 388 |
| 497 |
|
| |
| 498 |
|
| /* YYNTOKENS -- Number of terminals. */ |
| 499 |
|
| #define YYNTOKENS 23 |
| 500 |
|
| /* YYNNTS -- Number of nonterminals. */ |
| 501 |
|
| #define YYNNTS 29 |
| 502 |
|
| /* YYNRULES -- Number of rules. */ |
| 503 |
|
| #define YYNRULES 82 |
| 504 |
|
| /* YYNSTATES -- Number of states. */ |
| 505 |
|
| #define YYNSTATES 126 |
| 506 |
|
| |
| 507 |
|
| /* YYMAXUTOK -- Last valid token kind. */ |
| 508 |
|
| #define YYMAXUTOK 269 |
| 509 |
|
| |
| 510 |
|
| |
| 511 |
|
| /* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM |
| 512 |
|
| as returned by yylex, with out-of-bounds checking. */ |
| 513 |
|
| #define YYTRANSLATE(YYX) \ |
| 514 |
|
| (0 <= (YYX) && (YYX) <= YYMAXUTOK \ |
| 515 |
|
| ? YY_CAST (yysymbol_kind_t, yytranslate[YYX]) \ |
| 516 |
|
| : YYSYMBOL_YYUNDEF) |
| 517 |
|
| |
| 518 |
|
| /* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM |
| 519 |
|
| as returned by yylex. */ |
| 520 |
|
| static const yytype_int8 yytranslate[] = |
| 521 |
|
| { |
| 522 |
|
| 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 523 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 524 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 525 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 526 |
|
| 2, 2, 2, 2, 18, 15, 2, 2, 2, 2, |
| 527 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 20, 2, |
| 528 |
|
| 2, 2, 2, 19, 2, 2, 2, 2, 2, 2, |
| 529 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 530 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 531 |
|
| 2, 16, 2, 17, 2, 2, 2, 2, 2, 2, |
| 532 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 533 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 534 |
|
| 2, 2, 2, 21, 2, 22, 2, 2, 2, 2, |
| 535 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 536 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 537 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 538 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 539 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 540 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 541 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 542 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 543 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 544 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 545 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 546 |
|
| 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 547 |
|
| 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, |
| 548 |
|
| 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 |
| 549 |
|
| }; |
| 550 |
|
| |
| 551 |
|
| #if SYCKDEBUG |
| 552 |
|
| /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ |
| 553 |
|
| static const yytype_int16 yyrline[] = |
| 554 |
|
| { |
| 555 |
|
| 0, 62, 62, 66, 71, 76, 77, 80, 81, 86, |
| 556 |
|
| 91, 100, 108, 115, 116, 119, 124, 128, 136, 141, |
| 557 |
|
| 146, 158, 159, 163, 167, 171, 172, 176, 181, 186, |
| 558 |
|
| 194, 198, 206, 219, 220, 227, 228, 229, 230, 231, |
| 559 |
|
| 235, 239, 246, 253, 258, 263, 268, 273, 277, 284, |
| 560 |
|
| 288, 293, 300, 304, 311, 315, 320, 327, 328, 332, |
| 561 |
|
| 337, 345, 350, 355, 360, 365, 369, 376, 377, 384, |
| 562 |
|
| 388, 397, 398, 410, 418, 425, 434, 438, 445, 446, |
| 563 |
|
| 453, 460, 467 |
| 564 |
|
| }; |
| 565 |
|
| #endif |
| 566 |
|
| |
| 567 |
|
| /** Accessing symbol of state STATE. */ |
| 568 |
|
| #define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State]) |
| 569 |
|
| |
| 570 |
|
| #if SYCKDEBUG || 0 |
| 571 |
|
| /* The user-facing name of the symbol whose (internal) number is |
| 572 |
|
| YYSYMBOL. No bounds checking. */ |
| 573 |
|
| static const char *yysymbol_name (yysymbol_kind_t yysymbol) YY_ATTRIBUTE_UNUSED; |
| 574 |
|
| |
| 575 |
|
| /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. |
| 576 |
|
| First, the terminals, then, starting at YYNTOKENS, nonterminals. */ |
| 577 |
|
| static const char *const yytname[] = |
| 578 |
|
| { |
| 579 |
|
| "\"end of file\"", "error", "\"invalid token\"", "YAML_ANCHOR", |
| 580 |
|
| "YAML_ALIAS", "YAML_TRANSFER", "YAML_TAGURI", "YAML_ITRANSFER", |
| 581 |
|
| "YAML_WORD", "YAML_PLAIN", "YAML_BLOCK", "YAML_DOCSEP", "YAML_IOPEN", |
| 582 |
|
| "YAML_INDENT", "YAML_IEND", "'-'", "'['", "']'", "','", "'?'", "':'", |
| 583 |
|
| "'{'", "'}'", "$accept", "doc", "atom", "ind_rep", "atom_or_empty", |
| 584 |
|
| "empty", "indent_open", "indent_end", "indent_sep", "indent_flex_end", |
| 585 |
|
| "word_rep", "struct_rep", "implicit_seq", "basic_seq", "top_imp_seq", |
| 586 |
|
| "in_implicit_seq", "inline_seq", "in_inline_seq", "inline_seq_atom", |
| 587 |
|
| "implicit_map", "top_imp_map", "complex_key", "complex_value", |
| 588 |
|
| "complex_mapping", "in_implicit_map", "basic_mapping", "inline_map", |
| 589 |
|
| "in_inline_map", "inline_map_atom", YY_NULLPTR |
| 590 |
|
| }; |
| 591 |
|
| |
| 592 |
|
| static const char * |
| 593 |
|
| yysymbol_name (yysymbol_kind_t yysymbol) |
| 594 |
|
| { |
| 595 |
|
| return yytname[yysymbol]; |
| 596 |
|
| } |
| 597 |
|
| #endif |
| 598 |
|
| |
| 599 |
|
| #ifdef YYPRINT |
| 600 |
|
| /* YYTOKNUM[NUM] -- (External) token number corresponding to the |
| 601 |
|
| (internal) symbol number NUM (which must be that of a token). */ |
| 602 |
|
| static const yytype_int16 yytoknum[] = |
| 603 |
|
| { |
| 604 |
|
| 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, |
| 605 |
|
| 265, 266, 267, 268, 269, 45, 91, 93, 44, 63, |
| 606 |
|
| 58, 123, 125 |
| 607 |
|
| }; |
| 608 |
|
| #endif |
| 609 |
|
| |
| 610 |
|
| #define YYPACT_NINF (-92) |
| 611 |
|
| |
| 612 |
|
| #define yypact_value_is_default(Yyn) \ |
| 613 |
|
| ((Yyn) == YYPACT_NINF) |
| 614 |
|
| |
| 615 |
|
| #define YYTABLE_NINF (-1) |
| 616 |
|
| |
| 617 |
|
| #define yytable_value_is_error(Yyn) \ |
| 618 |
|
| 0 |
| 619 |
|
| |
| 620 |
|
| /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing |
| 621 |
|
| STATE-NUM. */ |
| 622 |
|
| static const yytype_int16 yypact[] = |
| 623 |
|
| { |
| 624 |
|
| 255, 331, -92, 331, 331, 331, -92, -92, -92, 350, |
| 625 |
|
| -92, 274, 190, 9, -92, -92, 210, -92, -92, -92, |
| 626 |
|
| -92, -92, -92, -92, -92, -92, -92, -92, -92, -92, |
| 627 |
|
| -92, 350, 350, 350, 350, -92, -92, -92, 236, -92, |
| 628 |
|
| -4, 11, -92, -92, -92, -4, -92, 23, -92, -92, |
| 629 |
|
| 293, 293, 293, -92, 350, 331, 34, 34, -92, 4, |
| 630 |
|
| 41, 4, 16, -92, 41, -92, -92, -92, -92, 312, |
| 631 |
|
| 312, 312, 4, 350, -92, 331, 331, -92, -92, 369, |
| 632 |
|
| -92, -92, 369, -92, -92, 369, -92, -92, -92, 26, |
| 633 |
|
| -92, 34, -92, -92, -92, -92, -92, 37, -92, 350, |
| 634 |
|
| -92, 369, -92, -92, -92, -92, 108, 108, 108, 108, |
| 635 |
|
| 171, -92, 26, 26, 26, 26, 26, 26, -92, -92, |
| 636 |
|
| -92, -92, -92, -92, -92, 34 |
| 637 |
|
| }; |
| 638 |
|
| |
| 639 |
|
| /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. |
| 640 |
|
| Performed when YYTABLE does not specify something else to do. Zero |
| 641 |
|
| means the default is an error. */ |
| 642 |
|
| static const yytype_int8 yydefact[] = |
| 643 |
|
| { |
| 644 |
|
| 4, 0, 31, 0, 0, 0, 32, 33, 35, 16, |
| 645 |
|
| 21, 0, 0, 0, 2, 6, 0, 5, 7, 36, |
| 646 |
|
| 37, 38, 39, 10, 30, 8, 27, 9, 28, 11, |
| 647 |
|
| 29, 16, 16, 16, 16, 13, 3, 14, 16, 53, |
| 648 |
|
| 57, 0, 54, 58, 77, 81, 82, 0, 78, 1, |
| 649 |
|
| 0, 0, 0, 22, 16, 0, 0, 67, 49, 0, |
| 650 |
|
| 0, 0, 0, 71, 0, 20, 18, 19, 17, 16, |
| 651 |
|
| 16, 16, 0, 16, 52, 56, 80, 76, 24, 0, |
| 652 |
|
| 48, 66, 0, 44, 62, 0, 46, 64, 42, 0, |
| 653 |
|
| 25, 0, 12, 34, 23, 40, 41, 51, 59, 16, |
| 654 |
|
| 60, 74, 15, 75, 55, 79, 0, 0, 0, 0, |
| 655 |
|
| 0, 67, 47, 65, 43, 61, 45, 63, 68, 26, |
| 656 |
|
| 50, 69, 70, 72, 73, 0 |
| 657 |
|
| }; |
| 658 |
|
| |
| 659 |
|
| /* YYPGOTO[NTERM-NUM]. */ |
| 660 |
|
| static const yytype_int8 yypgoto[] = |
| 661 |
|
| { |
| 662 |
|
| -92, -92, 1, 118, -46, -12, 56, -26, 121, -51, |
| 663 |
|
| -1, -92, -92, -91, -27, -68, -92, -92, -14, -92, |
| 664 |
|
| 22, -92, -92, -39, -19, -5, -92, -92, -9 |
| 665 |
|
| }; |
| 666 |
|
| |
| 667 |
|
| /* YYDEFGOTO[NTERM-NUM]. */ |
| 668 |
|
| static const yytype_int8 yydefgoto[] = |
| 669 |
|
| { |
| 670 |
|
| -1, 13, 35, 15, 36, 37, 16, 95, 91, 93, |
| 671 |
|
| 17, 18, 19, 58, 59, 60, 20, 41, 42, 21, |
| 672 |
|
| 61, 62, 122, 63, 64, 43, 22, 47, 48 |
| 673 |
|
| }; |
| 674 |
|
| |
| 675 |
|
| /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If |
| 676 |
|
| positive, shift that token. If negative, reduce the rule whose |
| 677 |
|
| number is the opposite. If YYTABLE_NINF, syntax error. */ |
| 678 |
|
| static const yytype_int8 yytable[] = |
| 679 |
|
| { |
| 680 |
|
| 24, 14, 26, 28, 30, 92, 120, 46, 88, 49, |
| 681 |
|
| 123, 112, 40, 45, 114, 57, 73, 116, 94, 65, |
| 682 |
|
| 66, 67, 68, 80, 83, 86, 72, 103, 74, 75, |
| 683 |
|
| 24, 26, 28, 30, 96, 98, 99, 57, 100, 78, |
| 684 |
|
| 119, 76, 80, 83, 86, 77, 102, 78, 90, 24, |
| 685 |
|
| 26, 28, 54, 121, 78, 94, 89, 65, 66, 67, |
| 686 |
|
| 113, 104, 124, 115, 0, 38, 117, 105, 24, 26, |
| 687 |
|
| 28, 46, 81, 84, 87, 0, 40, 45, 111, 0, |
| 688 |
|
| 0, 111, 0, 0, 111, 0, 0, 38, 38, 38, |
| 689 |
|
| 38, 81, 84, 87, 38, 0, 0, 0, 0, 0, |
| 690 |
|
| 111, 0, 0, 0, 0, 24, 26, 28, 30, 125, |
| 691 |
|
| 38, 106, 2, 107, 108, 109, 6, 7, 0, 23, |
| 692 |
|
| 10, 25, 27, 29, 0, 38, 38, 38, 0, 38, |
| 693 |
|
| 0, 0, 0, 0, 56, 110, 0, 0, 110, 0, |
| 694 |
|
| 0, 110, 0, 0, 0, 0, 0, 0, 0, 23, |
| 695 |
|
| 25, 27, 29, 0, 0, 38, 56, 110, 0, 0, |
| 696 |
|
| 0, 0, 110, 110, 110, 110, 110, 0, 23, 25, |
| 697 |
|
| 27, 79, 82, 85, 106, 2, 107, 108, 109, 6, |
| 698 |
|
| 7, 97, 0, 10, 53, 101, 0, 23, 25, 27, |
| 699 |
|
| 79, 82, 85, 1, 2, 3, 4, 5, 6, 7, |
| 700 |
|
| 8, 0, 10, 0, 0, 0, 11, 0, 0, 0, |
| 701 |
|
| 118, 12, 44, 50, 2, 51, 52, 5, 6, 7, |
| 702 |
|
| 8, 0, 10, 53, 0, 54, 11, 0, 0, 55, |
| 703 |
|
| 0, 12, 0, 97, 101, 97, 101, 97, 101, 69, |
| 704 |
|
| 2, 70, 71, 34, 6, 7, 8, 0, 10, 53, |
| 705 |
|
| 0, 54, 11, 0, 0, 55, 0, 12, 1, 2, |
| 706 |
|
| 3, 4, 5, 6, 7, 8, 9, 10, 0, 0, |
| 707 |
|
| 0, 11, 0, 0, 0, 0, 12, 1, 2, 3, |
| 708 |
|
| 4, 5, 6, 7, 8, 0, 10, 0, 0, 0, |
| 709 |
|
| 11, 39, 0, 0, 0, 12, 50, 2, 51, 52, |
| 710 |
|
| 5, 6, 7, 8, 0, 10, 78, 0, 0, 11, |
| 711 |
|
| 0, 0, 0, 0, 12, 69, 2, 70, 71, 34, |
| 712 |
|
| 6, 7, 8, 0, 10, 78, 0, 0, 11, 0, |
| 713 |
|
| 0, 0, 0, 12, 1, 2, 3, 4, 5, 6, |
| 714 |
|
| 7, 8, 0, 10, 0, 0, 0, 11, 0, 0, |
| 715 |
|
| 0, 0, 12, 31, 2, 32, 33, 34, 6, 7, |
| 716 |
|
| 8, 0, 10, 0, 0, 0, 11, 0, 0, 0, |
| 717 |
|
| 0, 12, 106, 2, 107, 108, 109, 6, 7, 0, |
| 718 |
|
| 0, 10, 0, 0, 54, 0, 0, 0, 55 |
| 719 |
|
| }; |
| 720 |
|
| |
| 721 |
|
| static const yytype_int8 yycheck[] = |
| 722 |
|
| { |
| 723 |
|
| 1, 0, 3, 4, 5, 56, 97, 12, 54, 0, |
| 724 |
|
| 101, 79, 11, 12, 82, 16, 20, 85, 14, 31, |
| 725 |
|
| 32, 33, 34, 50, 51, 52, 38, 73, 17, 18, |
| 726 |
|
| 31, 32, 33, 34, 60, 61, 20, 38, 64, 13, |
| 727 |
|
| 91, 18, 69, 70, 71, 22, 72, 13, 14, 50, |
| 728 |
|
| 51, 52, 15, 99, 13, 14, 55, 69, 70, 71, |
| 729 |
|
| 79, 75, 101, 82, -1, 9, 85, 76, 69, 70, |
| 730 |
|
| 71, 76, 50, 51, 52, -1, 75, 76, 79, -1, |
| 731 |
|
| -1, 82, -1, -1, 85, -1, -1, 31, 32, 33, |
| 732 |
|
| 34, 69, 70, 71, 38, -1, -1, -1, -1, -1, |
| 733 |
|
| 101, -1, -1, -1, -1, 106, 107, 108, 109, 110, |
| 734 |
|
| 54, 3, 4, 5, 6, 7, 8, 9, -1, 1, |
| 735 |
|
| 12, 3, 4, 5, -1, 69, 70, 71, -1, 73, |
| 736 |
|
| -1, -1, -1, -1, 16, 79, -1, -1, 82, -1, |
| 737 |
|
| -1, 85, -1, -1, -1, -1, -1, -1, -1, 31, |
| 738 |
|
| 32, 33, 34, -1, -1, 99, 38, 101, -1, -1, |
| 739 |
|
| -1, -1, 106, 107, 108, 109, 110, -1, 50, 51, |
| 740 |
|
| 52, 50, 51, 52, 3, 4, 5, 6, 7, 8, |
| 741 |
|
| 9, 60, -1, 12, 13, 64, -1, 69, 70, 71, |
| 742 |
|
| 69, 70, 71, 3, 4, 5, 6, 7, 8, 9, |
| 743 |
|
| 10, -1, 12, -1, -1, -1, 16, -1, -1, -1, |
| 744 |
|
| 89, 21, 22, 3, 4, 5, 6, 7, 8, 9, |
| 745 |
|
| 10, -1, 12, 13, -1, 15, 16, -1, -1, 19, |
| 746 |
|
| -1, 21, -1, 112, 113, 114, 115, 116, 117, 3, |
| 747 |
|
| 4, 5, 6, 7, 8, 9, 10, -1, 12, 13, |
| 748 |
|
| -1, 15, 16, -1, -1, 19, -1, 21, 3, 4, |
| 749 |
|
| 5, 6, 7, 8, 9, 10, 11, 12, -1, -1, |
| 750 |
|
| -1, 16, -1, -1, -1, -1, 21, 3, 4, 5, |
| 751 |
|
| 6, 7, 8, 9, 10, -1, 12, -1, -1, -1, |
| 752 |
|
| 16, 17, -1, -1, -1, 21, 3, 4, 5, 6, |
| 753 |
|
| 7, 8, 9, 10, -1, 12, 13, -1, -1, 16, |
| 754 |
|
| -1, -1, -1, -1, 21, 3, 4, 5, 6, 7, |
| 755 |
|
| 8, 9, 10, -1, 12, 13, -1, -1, 16, -1, |
| 756 |
|
| -1, -1, -1, 21, 3, 4, 5, 6, 7, 8, |
| 757 |
|
| 9, 10, -1, 12, -1, -1, -1, 16, -1, -1, |
| 758 |
|
| -1, -1, 21, 3, 4, 5, 6, 7, 8, 9, |
| 759 |
|
| 10, -1, 12, -1, -1, -1, 16, -1, -1, -1, |
| 760 |
|
| -1, 21, 3, 4, 5, 6, 7, 8, 9, -1, |
| 761 |
|
| -1, 12, -1, -1, 15, -1, -1, -1, 19 |
| 762 |
|
| }; |
| 763 |
|
| |
| 764 |
|
| /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing |
| 765 |
|
| symbol of state STATE-NUM. */ |
| 766 |
|
| static const yytype_int8 yystos[] = |
| 767 |
|
| { |
| 768 |
|
| 0, 3, 4, 5, 6, 7, 8, 9, 10, 11, |
| 769 |
|
| 12, 16, 21, 24, 25, 26, 29, 33, 34, 35, |
| 770 |
|
| 39, 42, 49, 26, 33, 26, 33, 26, 33, 26, |
| 771 |
|
| 33, 3, 5, 6, 7, 25, 27, 28, 29, 17, |
| 772 |
|
| 25, 40, 41, 48, 22, 25, 48, 50, 51, 0, |
| 773 |
|
| 3, 5, 6, 13, 15, 19, 26, 33, 36, 37, |
| 774 |
|
| 38, 43, 44, 46, 47, 28, 28, 28, 28, 3, |
| 775 |
|
| 5, 6, 28, 20, 17, 18, 18, 22, 13, 31, |
| 776 |
|
| 37, 43, 31, 37, 43, 31, 37, 43, 27, 25, |
| 777 |
|
| 14, 31, 32, 32, 14, 30, 30, 31, 30, 20, |
| 778 |
|
| 30, 31, 30, 27, 41, 51, 3, 5, 6, 7, |
| 779 |
|
| 29, 33, 38, 47, 38, 47, 38, 47, 31, 32, |
| 780 |
|
| 36, 27, 45, 36, 46, 33 |
| 781 |
|
| }; |
| 782 |
|
| |
| 783 |
|
| /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ |
| 784 |
|
| static const yytype_int8 yyr1[] = |
| 785 |
|
| { |
| 786 |
|
| 0, 23, 24, 24, 24, 25, 25, 26, 26, 26, |
| 787 |
|
| 26, 26, 26, 27, 27, 28, 28, 28, 28, 28, |
| 788 |
|
| 28, 29, 29, 30, 31, 32, 32, 33, 33, 33, |
| 789 |
|
| 33, 33, 33, 33, 33, 34, 34, 34, 34, 34, |
| 790 |
|
| 35, 35, 36, 37, 37, 37, 37, 37, 37, 38, |
| 791 |
|
| 38, 38, 39, 39, 40, 40, 40, 41, 41, 42, |
| 792 |
|
| 42, 43, 43, 43, 43, 43, 43, 44, 44, 45, |
| 793 |
|
| 46, 47, 47, 47, 47, 48, 49, 49, 50, 50, |
| 794 |
|
| 50, 51, 51 |
| 795 |
|
| }; |
| 796 |
|
| |
| 797 |
|
| /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ |
| 798 |
|
| static const yytype_int8 yyr2[] = |
| 799 |
|
| { |
| 800 |
|
| 0, 2, 1, 2, 0, 1, 1, 1, 2, 2, |
| 801 |
|
| 2, 2, 3, 1, 1, 3, 0, 2, 2, 2, |
| 802 |
|
| 2, 1, 2, 1, 1, 1, 2, 2, 2, 2, |
| 803 |
|
| 2, 1, 1, 1, 3, 1, 1, 1, 1, 1, |
| 804 |
|
| 3, 3, 2, 3, 2, 3, 2, 3, 2, 1, |
| 805 |
|
| 3, 2, 3, 2, 1, 3, 2, 1, 1, 3, |
| 806 |
|
| 3, 3, 2, 3, 2, 3, 2, 1, 3, 1, |
| 807 |
|
| 3, 1, 3, 3, 2, 3, 3, 2, 1, 3, |
| 808 |
|
| 2, 1, 1 |
| 809 |
|
| }; |
| 810 |
|
| |
| 811 |
|
| |
| 812 |
|
| enum { YYENOMEM = -2 }; |
| 813 |
|
| |
| 814 |
|
| #define yyerrok (yyerrstatus = 0) |
| 815 |
|
| #define yyclearin (yychar = SYCKEMPTY) |
| 816 |
|
| |
| 817 |
|
| #define YYACCEPT goto yyacceptlab |
| 818 |
|
| #define YYABORT goto yyabortlab |
| 819 |
|
| #define YYERROR goto yyerrorlab |
| 820 |
|
| |
| 821 |
|
| |
| 822 |
|
| #define YYRECOVERING() (!!yyerrstatus) |
| 823 |
|
| |
| 824 |
|
| #define YYBACKUP(Token, Value) \ |
| 825 |
|
| do \ |
| 826 |
|
| if (yychar == SYCKEMPTY) \ |
| 827 |
|
| { \ |
| 828 |
|
| yychar = (Token); \ |
| 829 |
|
| yylval = (Value); \ |
| 830 |
|
| YYPOPSTACK (yylen); \ |
| 831 |
|
| yystate = *yyssp; \ |
| 832 |
|
| goto yybackup; \ |
| 833 |
|
| } \ |
| 834 |
|
| else \ |
| 835 |
|
| { \ |
| 836 |
|
| yyerror (parser, YY_("syntax error: cannot back up")); \ |
| 837 |
|
| YYERROR; \ |
| 838 |
|
| } \ |
| 839 |
|
| while (0) |
| 840 |
|
| |
| 841 |
|
| /* Backward compatibility with an undocumented macro. |
| 842 |
|
| Use SYCKerror or SYCKUNDEF. */ |
| 843 |
|
| #define YYERRCODE SYCKUNDEF |
| 844 |
|
| |
| 845 |
|
| |
| 846 |
|
| /* Enable debugging if requested. */ |
| 847 |
|
| #if SYCKDEBUG |
| 848 |
|
| |
| 849 |
|
| # ifndef YYFPRINTF |
| 850 |
|
| # include <stdio.h> /* INFRINGES ON USER NAME SPACE */ |
| 851 |
|
| # define YYFPRINTF fprintf |
| 852 |
|
| # endif |
| 853 |
|
| |
| 854 |
|
| # define YYDPRINTF(Args) \ |
| 855 |
|
| do { \ |
| 856 |
|
| if (yydebug) \ |
| 857 |
|
| YYFPRINTF Args; \ |
| 858 |
|
| } while (0) |
| 859 |
|
| |
| 860 |
|
| /* This macro is provided for backward compatibility. */ |
| 861 |
|
| # ifndef YY_LOCATION_PRINT |
| 862 |
|
| # define YY_LOCATION_PRINT(File, Loc) ((void) 0) |
| 863 |
|
| # endif |
| 864 |
|
| |
| 865 |
|
| |
| 866 |
|
| # define YY_SYMBOL_PRINT(Title, Kind, Value, Location) \ |
| 867 |
|
| do { \ |
| 868 |
|
| if (yydebug) \ |
| 869 |
|
| { \ |
| 870 |
|
| YYFPRINTF (stderr, "%s ", Title); \ |
| 871 |
|
| yy_symbol_print (stderr, \ |
| 872 |
|
| Kind, Value, parser); \ |
| 873 |
|
| YYFPRINTF (stderr, "\n"); \ |
| 874 |
|
| } \ |
| 875 |
|
| } while (0) |
| 876 |
|
| |
| 877 |
|
| |
| 878 |
|
| /*-----------------------------------. |
| 879 |
|
| | Print this symbol's value on YYO. | |
| 880 |
|
| `-----------------------------------*/ |
| 881 |
|
| |
| 882 |
|
| static void |
| 883 |
|
| yy_symbol_value_print (FILE *yyo, |
| 884 |
|
| yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep, void *parser) |
| 885 |
|
| { |
| 886 |
|
| FILE *yyoutput = yyo; |
| 887 |
|
| YYUSE (yyoutput); |
| 888 |
|
| YYUSE (parser); |
| 889 |
|
| if (!yyvaluep) |
| 890 |
|
| return; |
| 891 |
|
| # ifdef YYPRINT |
| 892 |
|
| if (yykind < YYNTOKENS) |
| 893 |
|
| YYPRINT (yyo, yytoknum[yykind], *yyvaluep); |
| 894 |
|
| # endif |
| 895 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 896 |
|
| YYUSE (yykind); |
| 897 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 898 |
|
| } |
| 899 |
|
| |
| 900 |
|
| |
| 901 |
|
| /*---------------------------. |
| 902 |
|
| | Print this symbol on YYO. | |
| 903 |
|
| `---------------------------*/ |
| 904 |
|
| |
| 905 |
|
| static void |
| 906 |
|
| yy_symbol_print (FILE *yyo, |
| 907 |
|
| yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep, void *parser) |
| 908 |
|
| { |
| 909 |
|
| YYFPRINTF (yyo, "%s %s (", |
| 910 |
|
| yykind < YYNTOKENS ? "token" : "nterm", yysymbol_name (yykind)); |
| 911 |
|
| |
| 912 |
|
| yy_symbol_value_print (yyo, yykind, yyvaluep, parser); |
| 913 |
|
| YYFPRINTF (yyo, ")"); |
| 914 |
|
| } |
| 915 |
|
| |
| 916 |
|
| /*------------------------------------------------------------------. |
| 917 |
|
| | yy_stack_print -- Print the state stack from its BOTTOM up to its | |
| 918 |
|
| | TOP (included). | |
| 919 |
|
| `------------------------------------------------------------------*/ |
| 920 |
|
| |
| 921 |
|
| static void |
| 922 |
|
| yy_stack_print (yy_state_t *yybottom, yy_state_t *yytop) |
| 923 |
|
| { |
| 924 |
|
| YYFPRINTF (stderr, "Stack now"); |
| 925 |
|
| for (; yybottom <= yytop; yybottom++) |
| 926 |
|
| { |
| 927 |
|
| int yybot = *yybottom; |
| 928 |
|
| YYFPRINTF (stderr, " %d", yybot); |
| 929 |
|
| } |
| 930 |
|
| YYFPRINTF (stderr, "\n"); |
| 931 |
|
| } |
| 932 |
|
| |
| 933 |
|
| # define YY_STACK_PRINT(Bottom, Top) \ |
| 934 |
|
| do { \ |
| 935 |
|
| if (yydebug) \ |
| 936 |
|
| yy_stack_print ((Bottom), (Top)); \ |
| 937 |
|
| } while (0) |
| 938 |
|
| |
| 939 |
|
| |
| 940 |
|
| /*------------------------------------------------. |
| 941 |
|
| | Report that the YYRULE is going to be reduced. | |
| 942 |
|
| `------------------------------------------------*/ |
| 943 |
|
| |
| 944 |
|
| static void |
| 945 |
|
| yy_reduce_print (yy_state_t *yyssp, YYSTYPE *yyvsp, |
| 946 |
|
| int yyrule, void *parser) |
| 947 |
|
| { |
| 948 |
|
| int yylno = yyrline[yyrule]; |
| 949 |
|
| int yynrhs = yyr2[yyrule]; |
| 950 |
|
| int yyi; |
| 951 |
|
| YYFPRINTF (stderr, "Reducing stack by rule %d (line %d):\n", |
| 952 |
|
| yyrule - 1, yylno); |
| 953 |
|
| /* The symbols being reduced. */ |
| 954 |
|
| for (yyi = 0; yyi < yynrhs; yyi++) |
| 955 |
|
| { |
| 956 |
|
| YYFPRINTF (stderr, " $%d = ", yyi + 1); |
| 957 |
|
| yy_symbol_print (stderr, |
| 958 |
|
| YY_ACCESSING_SYMBOL (+yyssp[yyi + 1 - yynrhs]), |
| 959 |
|
| &yyvsp[(yyi + 1) - (yynrhs)], parser); |
| 960 |
|
| YYFPRINTF (stderr, "\n"); |
| 961 |
|
| } |
| 962 |
|
| } |
| 963 |
|
| |
| 964 |
|
| # define YY_REDUCE_PRINT(Rule) \ |
| 965 |
|
| do { \ |
| 966 |
|
| if (yydebug) \ |
| 967 |
|
| yy_reduce_print (yyssp, yyvsp, Rule, parser); \ |
| 968 |
|
| } while (0) |
| 969 |
|
| |
| 970 |
|
| /* Nonzero means print parse trace. It is left uninitialized so that |
| 971 |
|
| multiple parsers can coexist. */ |
| 972 |
|
| int yydebug; |
| 973 |
|
| #else /* !SYCKDEBUG */ |
| 974 |
|
| # define YYDPRINTF(Args) ((void) 0) |
| 975 |
|
| # define YY_SYMBOL_PRINT(Title, Kind, Value, Location) |
| 976 |
|
| # define YY_STACK_PRINT(Bottom, Top) |
| 977 |
|
| # define YY_REDUCE_PRINT(Rule) |
| 978 |
|
| #endif /* !SYCKDEBUG */ |
| 979 |
|
| |
| 980 |
|
| |
| 981 |
|
| /* YYINITDEPTH -- initial size of the parser's stacks. */ |
| 982 |
|
| #ifndef YYINITDEPTH |
| 983 |
|
| # define YYINITDEPTH 200 |
| 984 |
|
| #endif |
| 985 |
|
| |
| 986 |
|
| /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only |
| 987 |
|
| if the built-in stack extension method is used). |
| 988 |
|
| |
| 989 |
|
| Do not make this value too large; the results are undefined if |
| 990 |
|
| YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) |
| 991 |
|
| evaluated with infinite-precision integer arithmetic. */ |
| 992 |
|
| |
| 993 |
|
| #ifndef YYMAXDEPTH |
| 994 |
|
| # define YYMAXDEPTH 10000 |
| 995 |
|
| #endif |
| 996 |
|
| |
| 997 |
|
| |
| 998 |
|
| |
| 999 |
|
| |
| 1000 |
|
| |
| 1001 |
|
| |
| 1002 |
|
| /*-----------------------------------------------. |
| 1003 |
|
| | Release the memory associated to this symbol. | |
| 1004 |
|
| `-----------------------------------------------*/ |
| 1005 |
|
| |
| 1006 |
|
| static void |
| 1007 |
4912 |
| yydestruct (const char *yymsg, |
| 1008 |
|
| yysymbol_kind_t yykind, YYSTYPE *yyvaluep, void *parser) |
| 1009 |
|
| { |
| 1010 |
|
| YYUSE (yyvaluep); |
| 1011 |
|
| YYUSE (parser); |
| 1012 |
4912 |
▶ | if (!yymsg) |
Branch: 1 branch
| Branch | True | False | Total |
| if (!yymsg) |
0 |
4912 |
4912 |
|
| 1013 |
0 |
| yymsg = "Deleting"; |
| 1014 |
|
| YY_SYMBOL_PRINT (yymsg, yykind, yyvaluep, yylocationp); |
| 1015 |
|
| |
| 1016 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 1017 |
|
| YYUSE (yykind); |
| 1018 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 1019 |
4912 |
| } |
| 1020 |
|
| |
| 1021 |
|
| |
| 1022 |
|
| |
| 1023 |
|
| |
| 1024 |
|
| |
| 1025 |
|
| |
| 1026 |
|
| /*----------. |
| 1027 |
|
| | yyparse. | |
| 1028 |
|
| `----------*/ |
| 1029 |
|
| |
| 1030 |
|
| int |
| 1031 |
2488 |
| yyparse (void *parser) |
| 1032 |
|
| { |
| 1033 |
|
| /* Lookahead token kind. */ |
| 1034 |
|
| int yychar; |
| 1035 |
|
| |
| 1036 |
|
| |
| 1037 |
|
| /* The semantic value of the lookahead symbol. */ |
| 1038 |
|
| /* Default value used for initialization, for pacifying older GCCs |
| 1039 |
|
| or non-GCC compilers. */ |
| 1040 |
|
| YY_INITIAL_VALUE (static YYSTYPE yyval_default;) |
| 1041 |
|
| YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default); |
| 1042 |
|
| |
| 1043 |
|
| /* Number of syntax errors so far. */ |
| 1044 |
2488 |
| int yynerrs = 0; |
| 1045 |
|
| |
| 1046 |
2488 |
| yy_state_fast_t yystate = 0; |
| 1047 |
|
| /* Number of tokens to shift before error messages enabled. */ |
| 1048 |
2488 |
| int yyerrstatus = 0; |
| 1049 |
|
| |
| 1050 |
|
| /* Refer to the stacks through separate pointers, to allow yyoverflow |
| 1051 |
|
| to reallocate them elsewhere. */ |
| 1052 |
|
| |
| 1053 |
|
| /* Their size. */ |
| 1054 |
2488 |
| YYPTRDIFF_T yystacksize = YYINITDEPTH; |
| 1055 |
|
| |
| 1056 |
|
| /* The state stack: array, bottom, top. */ |
| 1057 |
|
| yy_state_t yyssa[YYINITDEPTH]; |
| 1058 |
2488 |
| yy_state_t *yyss = yyssa; |
| 1059 |
2488 |
| yy_state_t *yyssp = yyss; |
| 1060 |
|
| |
| 1061 |
|
| /* The semantic value stack: array, bottom, top. */ |
| 1062 |
|
| YYSTYPE yyvsa[YYINITDEPTH]; |
| 1063 |
2488 |
| YYSTYPE *yyvs = yyvsa; |
| 1064 |
2488 |
| YYSTYPE *yyvsp = yyvs; |
| 1065 |
|
| |
| 1066 |
|
| int yyn; |
| 1067 |
|
| /* The return value of yyparse. */ |
| 1068 |
|
| int yyresult; |
| 1069 |
|
| /* Lookahead symbol kind. */ |
| 1070 |
2488 |
| yysymbol_kind_t yytoken = YYSYMBOL_YYEMPTY; |
| 1071 |
|
| /* The variables used to return semantic value and location from the |
| 1072 |
|
| action routines. */ |
| 1073 |
|
| YYSTYPE yyval; |
| 1074 |
|
| |
| 1075 |
|
| |
| 1076 |
|
| |
| 1077 |
|
| #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) |
| 1078 |
|
| |
| 1079 |
|
| /* The number of symbols on the RHS of the reduced rule. |
| 1080 |
|
| Keep to zero when no symbol should be popped. */ |
| 1081 |
2488 |
| int yylen = 0; |
| 1082 |
|
| |
| 1083 |
|
| YYDPRINTF ((stderr, "Starting parse\n")); |
| 1084 |
|
| |
| 1085 |
2488 |
| yychar = SYCKEMPTY; /* Cause a token to be read. */ |
| 1086 |
2488 |
| goto yysetstate; |
| 1087 |
|
| |
| 1088 |
|
| |
| 1089 |
|
| /*------------------------------------------------------------. |
| 1090 |
|
| | yynewstate -- push a new state, which is found in yystate. | |
| 1091 |
|
| `------------------------------------------------------------*/ |
| 1092 |
121747004 |
| yynewstate: |
| 1093 |
|
| /* In all cases, when you get here, the value and location stacks |
| 1094 |
|
| have just been pushed. So pushing a state here evens the stacks. */ |
| 1095 |
121747004 |
| yyssp++; |
| 1096 |
|
| |
| 1097 |
|
| |
| 1098 |
|
| /*--------------------------------------------------------------------. |
| 1099 |
|
| | yysetstate -- set current state (the top of the stack) to yystate. | |
| 1100 |
|
| `--------------------------------------------------------------------*/ |
| 1101 |
121749492 |
| yysetstate: |
| 1102 |
|
| YYDPRINTF ((stderr, "Entering state %d\n", yystate)); |
| 1103 |
|
| YY_ASSERT (0 <= yystate && yystate < YYNSTATES); |
| 1104 |
|
| YY_IGNORE_USELESS_CAST_BEGIN |
| 1105 |
121749492 |
| *yyssp = YY_CAST (yy_state_t, yystate); |
| 1106 |
|
| YY_IGNORE_USELESS_CAST_END |
| 1107 |
|
| YY_STACK_PRINT (yyss, yyssp); |
| 1108 |
|
| |
| 1109 |
121749492 |
▶ | if (yyss + yystacksize - 1 <= yyssp) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyss + yystacksize - 1 <= yyssp) |
14 |
121749478 |
121749492 |
|
| 1110 |
|
| #if !defined yyoverflow && !defined YYSTACK_RELOCATE |
| 1111 |
|
| goto yyexhaustedlab; |
| 1112 |
|
| #else |
| 1113 |
|
| { |
| 1114 |
|
| /* Get the current used size of the three stacks, in elements. */ |
| 1115 |
14 |
| YYPTRDIFF_T yysize = yyssp - yyss + 1; |
| 1116 |
|
| |
| 1117 |
|
| # if defined yyoverflow |
| 1118 |
|
| { |
| 1119 |
|
| /* Give user a chance to reallocate the stack. Use copies of |
| 1120 |
|
| these so that the &'s don't force the real ones into |
| 1121 |
|
| memory. */ |
| 1122 |
|
| yy_state_t *yyss1 = yyss; |
| 1123 |
|
| YYSTYPE *yyvs1 = yyvs; |
| 1124 |
|
| |
| 1125 |
|
| /* Each stack pointer address is followed by the size of the |
| 1126 |
|
| data in use in that stack, in bytes. This used to be a |
| 1127 |
|
| conditional around just the two extra args, but that might |
| 1128 |
|
| be undefined if yyoverflow is a macro. */ |
| 1129 |
|
| yyoverflow (YY_("memory exhausted"), |
| 1130 |
|
| &yyss1, yysize * YYSIZEOF (*yyssp), |
| 1131 |
|
| &yyvs1, yysize * YYSIZEOF (*yyvsp), |
| 1132 |
|
| &yystacksize); |
| 1133 |
|
| yyss = yyss1; |
| 1134 |
|
| yyvs = yyvs1; |
| 1135 |
|
| } |
| 1136 |
|
| # else /* defined YYSTACK_RELOCATE */ |
| 1137 |
|
| /* Extend the stack our own way. */ |
| 1138 |
14 |
▶ | if (YYMAXDEPTH <= yystacksize) |
Branch: 1 branch
| Branch | True | False | Total |
| if (YYMAXDEPTH <= yystacksize) |
0 |
14 |
14 |
|
| 1139 |
0 |
| goto yyexhaustedlab; |
| 1140 |
14 |
| yystacksize *= 2; |
| 1141 |
14 |
▶ | if (YYMAXDEPTH < yystacksize) |
Branch: 1 branch
| Branch | True | False | Total |
| if (YYMAXDEPTH < yystacksize) |
0 |
14 |
14 |
|
| 1142 |
0 |
| yystacksize = YYMAXDEPTH; |
| 1143 |
|
| |
| 1144 |
|
| { |
| 1145 |
14 |
| yy_state_t *yyss1 = yyss; |
| 1146 |
|
| union yyalloc *yyptr = |
| 1147 |
14 |
| YY_CAST (union yyalloc *, |
| 1148 |
|
| YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); |
| 1149 |
14 |
▶ | if (! yyptr) |
Branch: 1 branch
| Branch | True | False | Total |
| if (! yyptr) |
0 |
14 |
14 |
|
| 1150 |
0 |
| goto yyexhaustedlab; |
| 1151 |
14 |
| YYSTACK_RELOCATE (yyss_alloc, yyss); |
| 1152 |
14 |
| YYSTACK_RELOCATE (yyvs_alloc, yyvs); |
| 1153 |
|
| # undef YYSTACK_RELOCATE |
| 1154 |
14 |
▶ | if (yyss1 != yyssa) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyss1 != yyssa) |
10 |
4 |
14 |
|
| 1155 |
10 |
| YYSTACK_FREE (yyss1); |
| 1156 |
|
| } |
| 1157 |
|
| # endif |
| 1158 |
|
| |
| 1159 |
14 |
| yyssp = yyss + yysize - 1; |
| 1160 |
14 |
| yyvsp = yyvs + yysize - 1; |
| 1161 |
|
| |
| 1162 |
|
| YY_IGNORE_USELESS_CAST_BEGIN |
| 1163 |
|
| YYDPRINTF ((stderr, "Stack size increased to %ld\n", |
| 1164 |
|
| YY_CAST (long, yystacksize))); |
| 1165 |
|
| YY_IGNORE_USELESS_CAST_END |
| 1166 |
|
| |
| 1167 |
14 |
▶ | if (yyss + yystacksize - 1 <= yyssp) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyss + yystacksize - 1 <= yyssp) |
0 |
14 |
14 |
|
| 1168 |
0 |
| YYABORT; |
| 1169 |
|
| } |
| 1170 |
|
| #endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */ |
| 1171 |
|
| |
| 1172 |
121749492 |
▶ | if (yystate == YYFINAL) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yystate == YYFINAL) |
2456 |
121747036 |
121749492 |
|
| 1173 |
2456 |
| YYACCEPT; |
| 1174 |
|
| |
| 1175 |
121747036 |
| goto yybackup; |
| 1176 |
|
| |
| 1177 |
|
| |
| 1178 |
|
| /*-----------. |
| 1179 |
|
| | yybackup. | |
| 1180 |
|
| `-----------*/ |
| 1181 |
121747036 |
| yybackup: |
| 1182 |
|
| /* Do appropriate processing given the current state. Read a |
| 1183 |
|
| lookahead token if we need one and don't already have one. */ |
| 1184 |
|
| |
| 1185 |
|
| /* First try to decide what to do without reference to lookahead token. */ |
| 1186 |
121747036 |
| yyn = yypact[yystate]; |
| 1187 |
121747036 |
▶ | if (yypact_value_is_default (yyn)) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yypact_value_is_default (yyn)) |
84281431 |
37465605 |
121747036 |
|
| 1188 |
84281431 |
| goto yydefault; |
| 1189 |
|
| |
| 1190 |
|
| /* Not known => get a lookahead token if don't already have one. */ |
| 1191 |
|
| |
| 1192 |
|
| /* YYCHAR is either empty, or end-of-input, or a valid lookahead. */ |
| 1193 |
37465605 |
▶ | if (yychar == SYCKEMPTY) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yychar == SYCKEMPTY) |
37462840 |
2765 |
37465605 |
|
| 1194 |
|
| { |
| 1195 |
|
| YYDPRINTF ((stderr, "Reading a token\n")); |
| 1196 |
37462840 |
| yychar = yylex (&yylval, parser); |
| 1197 |
|
| } |
| 1198 |
|
| |
| 1199 |
37465597 |
▶ | if (yychar <= SYCKEOF) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yychar <= SYCKEOF) |
2672 |
37462925 |
37465597 |
|
| 1200 |
|
| { |
| 1201 |
2672 |
| yychar = SYCKEOF; |
| 1202 |
2672 |
| yytoken = YYSYMBOL_YYEOF; |
| 1203 |
|
| YYDPRINTF ((stderr, "Now at end of input.\n")); |
| 1204 |
|
| } |
| 1205 |
37462925 |
▶ | else if (yychar == SYCKerror) |
Branch: 1 branch
| Branch | True | False | Total |
| else if (yychar == SYCKerror) |
0 |
37462925 |
37462925 |
|
| 1206 |
|
| { |
| 1207 |
|
| /* The scanner already issued an error message, process directly |
| 1208 |
|
| to error recovery. But do not keep the error token as |
| 1209 |
|
| lookahead, it is too special and may lead us to an endless |
| 1210 |
|
| loop in error recovery. */ |
| 1211 |
0 |
| yychar = SYCKUNDEF; |
| 1212 |
0 |
| yytoken = YYSYMBOL_YYerror; |
| 1213 |
0 |
| goto yyerrlab1; |
| 1214 |
|
| } |
| 1215 |
|
| else |
| 1216 |
|
| { |
| 1217 |
37462925 |
▶ | yytoken = YYTRANSLATE (yychar); |
Branch: 2 branches
| Branch | True | False | Total |
| yytoken = YYTRANSLATE (yychar); |
37462925 |
0 |
37462925 |
| yytoken = YYTRANSLATE (yychar); |
37462925 |
0 |
37462925 |
|
| 1218 |
|
| YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); |
| 1219 |
|
| } |
| 1220 |
|
| |
| 1221 |
|
| /* If the proper action on seeing token YYTOKEN is to reduce or to |
| 1222 |
|
| detect an error, take that action. */ |
| 1223 |
37465597 |
| yyn += yytoken; |
| 1224 |
37465597 |
▶ | if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) |
Branch: 3 branches
| Branch | True | False | Total |
| if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) |
37465596 |
1 |
37465597 |
| if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) |
37465596 |
0 |
37465596 |
| if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) |
2777 |
37462819 |
37465596 |
|
| 1225 |
2778 |
| goto yydefault; |
| 1226 |
37462819 |
| yyn = yytable[yyn]; |
| 1227 |
37462819 |
▶ | if (yyn <= 0) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyn <= 0) |
0 |
37462819 |
37462819 |
|
| 1228 |
|
| { |
| 1229 |
|
| if (yytable_value_is_error (yyn)) |
| 1230 |
|
| goto yyerrlab; |
| 1231 |
0 |
| yyn = -yyn; |
| 1232 |
0 |
| goto yyreduce; |
| 1233 |
|
| } |
| 1234 |
|
| |
| 1235 |
|
| /* Count tokens shifted since error; after three, turn off error |
| 1236 |
|
| status. */ |
| 1237 |
37462819 |
▶ | if (yyerrstatus) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyerrstatus) |
0 |
37462819 |
37462819 |
|
| 1238 |
0 |
| yyerrstatus--; |
| 1239 |
|
| |
| 1240 |
|
| /* Shift the lookahead token. */ |
| 1241 |
|
| YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); |
| 1242 |
37462819 |
| yystate = yyn; |
| 1243 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 1244 |
37462819 |
| *++yyvsp = yylval; |
| 1245 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 1246 |
|
| |
| 1247 |
|
| /* Discard the shifted token. */ |
| 1248 |
37462819 |
| yychar = SYCKEMPTY; |
| 1249 |
37462819 |
| goto yynewstate; |
| 1250 |
|
| |
| 1251 |
|
| |
| 1252 |
|
| /*-----------------------------------------------------------. |
| 1253 |
|
| | yydefault -- do the default action for the current state. | |
| 1254 |
|
| `-----------------------------------------------------------*/ |
| 1255 |
84284209 |
| yydefault: |
| 1256 |
84284209 |
| yyn = yydefact[yystate]; |
| 1257 |
84284209 |
▶ | if (yyn == 0) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyn == 0) |
13 |
84284196 |
84284209 |
|
| 1258 |
13 |
| goto yyerrlab; |
| 1259 |
84284196 |
| goto yyreduce; |
| 1260 |
|
| |
| 1261 |
|
| |
| 1262 |
|
| /*-----------------------------. |
| 1263 |
|
| | yyreduce -- do a reduction. | |
| 1264 |
|
| `-----------------------------*/ |
| 1265 |
84284196 |
| yyreduce: |
| 1266 |
|
| /* yyn is the number of a rule to reduce with. */ |
| 1267 |
84284196 |
| yylen = yyr2[yyn]; |
| 1268 |
|
| |
| 1269 |
|
| /* If YYLEN is nonzero, implement the default value of the action: |
| 1270 |
|
| '$$ = $1'. |
| 1271 |
|
| |
| 1272 |
|
| Otherwise, the following line sets YYVAL to garbage. |
| 1273 |
|
| This behavior is undocumented and Bison |
| 1274 |
|
| users should not rely upon it. Assigning to YYVAL |
| 1275 |
|
| unconditionally makes the parser a bit smaller, and it avoids a |
| 1276 |
|
| GCC warning that YYVAL may be used uninitialized. */ |
| 1277 |
84284196 |
| yyval = yyvsp[1-yylen]; |
| 1278 |
|
| |
| 1279 |
|
| |
| 1280 |
|
| YY_REDUCE_PRINT (yyn); |
| 1281 |
84284196 |
| switch (yyn) |
| 1282 |
|
| { |
| 1283 |
176 |
| case 2: /* doc: atom */ |
| 1284 |
|
| #line 63 "gram.y" |
| 1285 |
|
| { |
| 1286 |
|
| ((SyckParser *)parser)->root = syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ); |
| 1287 |
|
| } |
| 1288 |
|
| #line 1289 "gram.c" |
| 1289 |
176 |
| break; |
| 1290 |
|
| |
| 1291 |
2066 |
| case 3: /* doc: YAML_DOCSEP atom_or_empty */ |
| 1292 |
|
| #line 67 "gram.y" |
| 1293 |
|
| { |
| 1294 |
|
| ((SyckParser *)parser)->root = syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ); |
| 1295 |
|
| } |
| 1296 |
|
| #line 1297 "gram.c" |
| 1297 |
2066 |
| break; |
| 1298 |
|
| |
| 1299 |
214 |
| case 4: /* doc: %empty */ |
| 1300 |
|
| #line 71 "gram.y" |
| 1301 |
|
| { |
| 1302 |
|
| ((SyckParser *)parser)->eof = 1; |
| 1303 |
|
| } |
| 1304 |
|
| #line 1305 "gram.c" |
| 1305 |
214 |
| break; |
| 1306 |
|
| |
| 1307 |
43 |
| case 8: /* ind_rep: YAML_TRANSFER ind_rep */ |
| 1308 |
|
| #line 82 "gram.y" |
| 1309 |
|
| { |
| 1310 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1311 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1312 |
|
| } |
| 1313 |
|
| #line 1314 "gram.c" |
| 1314 |
43 |
| break; |
| 1315 |
|
| |
| 1316 |
0 |
| case 9: /* ind_rep: YAML_TAGURI ind_rep */ |
| 1317 |
|
| #line 87 "gram.y" |
| 1318 |
|
| { |
| 1319 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), 0 ); |
| 1320 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1321 |
|
| } |
| 1322 |
|
| #line 1323 "gram.c" |
| 1323 |
0 |
| break; |
| 1324 |
|
| |
| 1325 |
24 |
| case 10: /* ind_rep: YAML_ANCHOR ind_rep */ |
| 1326 |
|
| #line 92 "gram.y" |
| 1327 |
|
| { |
| 1328 |
|
| /* |
| 1329 |
|
| * _Anchors_: The language binding must keep a separate symbol table |
| 1330 |
|
| * for anchors. The actual ID in the symbol table is returned to the |
| 1331 |
|
| * higher nodes, though. |
| 1332 |
|
| */ |
| 1333 |
|
| (yyval.nodeData) = syck_hdlr_add_anchor( (SyckParser *)parser, (yyvsp[-1].name), (yyvsp[0].nodeData) ); |
| 1334 |
|
| } |
| 1335 |
|
| #line 1336 "gram.c" |
| 1336 |
24 |
| break; |
| 1337 |
|
| |
| 1338 |
1 |
▶ | case 11: /* ind_rep: YAML_ITRANSFER ind_rep */ |
Branch: 1 branch
| Branch | True | False | Total |
| case 11: /* ind_rep: YAML_ITRANSFER ind_rep */ |
0 |
1 |
1 |
|
| 1339 |
|
| #line 101 "gram.y" |
| 1340 |
|
| { |
| 1341 |
|
| if ( ((SyckParser *)parser)->implicit_typing == 1 ) |
| 1342 |
|
| { |
| 1343 |
|
| try_tag_implicit( (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1344 |
|
| } |
| 1345 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1346 |
|
| } |
| 1347 |
|
| #line 1348 "gram.c" |
| 1348 |
1 |
| break; |
| 1349 |
|
| |
| 1350 |
106 |
| case 12: /* ind_rep: indent_open ind_rep indent_flex_end */ |
| 1351 |
|
| #line 109 "gram.y" |
| 1352 |
|
| { |
| 1353 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1354 |
|
| } |
| 1355 |
|
| #line 1356 "gram.c" |
| 1356 |
106 |
| break; |
| 1357 |
|
| |
| 1358 |
1 |
| case 15: /* empty: indent_open empty indent_end */ |
| 1359 |
|
| #line 120 "gram.y" |
| 1360 |
|
| { |
| 1361 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1362 |
|
| } |
| 1363 |
|
| #line 1364 "gram.c" |
| 1364 |
1 |
| break; |
| 1365 |
|
| |
| 1366 |
3 |
| case 16: /* empty: %empty */ |
| 1367 |
|
| #line 124 "gram.y" |
| 1368 |
|
| { |
| 1369 |
|
| NULL_NODE( parser, n ); |
| 1370 |
|
| (yyval.nodeData) = n; |
| 1371 |
|
| } |
| 1372 |
|
| #line 1373 "gram.c" |
| 1373 |
3 |
| break; |
| 1374 |
|
| |
| 1375 |
0 |
▶ | case 17: /* empty: YAML_ITRANSFER empty */ |
Branch: 1 branch
| Branch | True | False | Total |
| case 17: /* empty: YAML_ITRANSFER empty */ |
0 |
0 |
0 |
|
| 1376 |
|
| #line 129 "gram.y" |
| 1377 |
|
| { |
| 1378 |
|
| if ( ((SyckParser *)parser)->implicit_typing == 1 ) |
| 1379 |
|
| { |
| 1380 |
|
| try_tag_implicit( (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1381 |
|
| } |
| 1382 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1383 |
|
| } |
| 1384 |
|
| #line 1385 "gram.c" |
| 1385 |
0 |
| break; |
| 1386 |
|
| |
| 1387 |
0 |
| case 18: /* empty: YAML_TRANSFER empty */ |
| 1388 |
|
| #line 137 "gram.y" |
| 1389 |
|
| { |
| 1390 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1391 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1392 |
|
| } |
| 1393 |
|
| #line 1394 "gram.c" |
| 1394 |
0 |
| break; |
| 1395 |
|
| |
| 1396 |
0 |
| case 19: /* empty: YAML_TAGURI empty */ |
| 1397 |
|
| #line 142 "gram.y" |
| 1398 |
|
| { |
| 1399 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), 0 ); |
| 1400 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1401 |
|
| } |
| 1402 |
|
| #line 1403 "gram.c" |
| 1403 |
0 |
| break; |
| 1404 |
|
| |
| 1405 |
2 |
| case 20: /* empty: YAML_ANCHOR empty */ |
| 1406 |
|
| #line 147 "gram.y" |
| 1407 |
|
| { |
| 1408 |
|
| /* |
| 1409 |
|
| * _Anchors_: The language binding must keep a separate symbol table |
| 1410 |
|
| * for anchors. The actual ID in the symbol table is returned to the |
| 1411 |
|
| * higher nodes, though. |
| 1412 |
|
| */ |
| 1413 |
|
| (yyval.nodeData) = syck_hdlr_add_anchor( (SyckParser *)parser, (yyvsp[-1].name), (yyvsp[0].nodeData) ); |
| 1414 |
|
| } |
| 1415 |
|
| #line 1416 "gram.c" |
| 1416 |
2 |
| break; |
| 1417 |
|
| |
| 1418 |
641 |
| case 27: /* word_rep: YAML_TRANSFER word_rep */ |
| 1419 |
|
| #line 177 "gram.y" |
| 1420 |
|
| { |
| 1421 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1422 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1423 |
|
| } |
| 1424 |
|
| #line 1425 "gram.c" |
| 1425 |
641 |
| break; |
| 1426 |
|
| |
| 1427 |
0 |
| case 28: /* word_rep: YAML_TAGURI word_rep */ |
| 1428 |
|
| #line 182 "gram.y" |
| 1429 |
|
| { |
| 1430 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), 0 ); |
| 1431 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1432 |
|
| } |
| 1433 |
|
| #line 1434 "gram.c" |
| 1434 |
0 |
| break; |
| 1435 |
|
| |
| 1436 |
0 |
▶ | case 29: /* word_rep: YAML_ITRANSFER word_rep */ |
Branch: 1 branch
| Branch | True | False | Total |
| case 29: /* word_rep: YAML_ITRANSFER word_rep */ |
0 |
0 |
0 |
|
| 1437 |
|
| #line 187 "gram.y" |
| 1438 |
|
| { |
| 1439 |
|
| if ( ((SyckParser *)parser)->implicit_typing == 1 ) |
| 1440 |
|
| { |
| 1441 |
|
| try_tag_implicit( (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1442 |
|
| } |
| 1443 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1444 |
|
| } |
| 1445 |
|
| #line 1446 "gram.c" |
| 1446 |
0 |
| break; |
| 1447 |
|
| |
| 1448 |
4 |
| case 30: /* word_rep: YAML_ANCHOR word_rep */ |
| 1449 |
|
| #line 195 "gram.y" |
| 1450 |
|
| { |
| 1451 |
|
| (yyval.nodeData) = syck_hdlr_add_anchor( (SyckParser *)parser, (yyvsp[-1].name), (yyvsp[0].nodeData) ); |
| 1452 |
|
| } |
| 1453 |
|
| #line 1454 "gram.c" |
| 1454 |
4 |
| break; |
| 1455 |
|
| |
| 1456 |
63 |
| case 31: /* word_rep: YAML_ALIAS */ |
| 1457 |
|
| #line 199 "gram.y" |
| 1458 |
|
| { |
| 1459 |
|
| /* |
| 1460 |
|
| * _Aliases_: The anchor symbol table is scanned for the anchor name. |
| 1461 |
|
| * The anchor's ID in the language's symbol table is returned. |
| 1462 |
|
| */ |
| 1463 |
|
| (yyval.nodeData) = syck_hdlr_get_anchor( (SyckParser *)parser, (yyvsp[0].name) ); |
| 1464 |
|
| } |
| 1465 |
|
| #line 1466 "gram.c" |
| 1466 |
63 |
| break; |
| 1467 |
|
| |
| 1468 |
0 |
▶ | case 32: /* word_rep: YAML_WORD */ |
Branch: 1 branch
| Branch | True | False | Total |
| case 32: /* word_rep: YAML_WORD */ |
0 |
0 |
0 |
|
| 1469 |
|
| #line 207 "gram.y" |
| 1470 |
|
| { |
| 1471 |
|
| SyckNode *n = (yyvsp[0].nodeData); |
| 1472 |
|
| if ( ((SyckParser *)parser)->taguri_expansion == 1 ) |
| 1473 |
|
| { |
| 1474 |
|
| n->type_id = syck_taguri( YAML_DOMAIN, "str", 3 ); |
| 1475 |
|
| } |
| 1476 |
|
| else |
| 1477 |
|
| { |
| 1478 |
|
| n->type_id = syck_strndup( "str", 3 ); |
| 1479 |
|
| } |
| 1480 |
|
| (yyval.nodeData) = n; |
| 1481 |
|
| } |
| 1482 |
|
| #line 1483 "gram.c" |
| 1483 |
0 |
| break; |
| 1484 |
|
| |
| 1485 |
1093 |
| case 34: /* word_rep: indent_open word_rep indent_flex_end */ |
| 1486 |
|
| #line 221 "gram.y" |
| 1487 |
|
| { |
| 1488 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1489 |
|
| } |
| 1490 |
|
| #line 1491 "gram.c" |
| 1491 |
1093 |
| break; |
| 1492 |
|
| |
| 1493 |
1 |
| case 40: /* implicit_seq: indent_open top_imp_seq indent_end */ |
| 1494 |
|
| #line 236 "gram.y" |
| 1495 |
|
| { |
| 1496 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1497 |
|
| } |
| 1498 |
|
| #line 1499 "gram.c" |
| 1499 |
1 |
| break; |
| 1500 |
|
| |
| 1501 |
54 |
| case 41: /* implicit_seq: indent_open in_implicit_seq indent_end */ |
| 1502 |
|
| #line 240 "gram.y" |
| 1503 |
|
| { |
| 1504 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1505 |
|
| } |
| 1506 |
|
| #line 1507 "gram.c" |
| 1507 |
54 |
| break; |
| 1508 |
|
| |
| 1509 |
147 |
| case 42: /* basic_seq: '-' atom_or_empty */ |
| 1510 |
|
| #line 247 "gram.y" |
| 1511 |
|
| { |
| 1512 |
|
| (yyval.nodeId) = syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ); |
| 1513 |
|
| } |
| 1514 |
|
| #line 1515 "gram.c" |
| 1515 |
147 |
| break; |
| 1516 |
|
| |
| 1517 |
1 |
| case 43: /* top_imp_seq: YAML_TRANSFER indent_sep in_implicit_seq */ |
| 1518 |
|
| #line 254 "gram.y" |
| 1519 |
|
| { |
| 1520 |
|
| syck_add_transfer( (yyvsp[-2].name), (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1521 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1522 |
|
| } |
| 1523 |
|
| #line 1524 "gram.c" |
| 1524 |
1 |
| break; |
| 1525 |
|
| |
| 1526 |
0 |
| case 44: /* top_imp_seq: YAML_TRANSFER top_imp_seq */ |
| 1527 |
|
| #line 259 "gram.y" |
| 1528 |
|
| { |
| 1529 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1530 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1531 |
|
| } |
| 1532 |
|
| #line 1533 "gram.c" |
| 1533 |
0 |
| break; |
| 1534 |
|
| |
| 1535 |
0 |
| case 45: /* top_imp_seq: YAML_TAGURI indent_sep in_implicit_seq */ |
| 1536 |
|
| #line 264 "gram.y" |
| 1537 |
|
| { |
| 1538 |
|
| syck_add_transfer( (yyvsp[-2].name), (yyvsp[0].nodeData), 0 ); |
| 1539 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1540 |
|
| } |
| 1541 |
|
| #line 1542 "gram.c" |
| 1542 |
0 |
| break; |
| 1543 |
|
| |
| 1544 |
0 |
| case 46: /* top_imp_seq: YAML_TAGURI top_imp_seq */ |
| 1545 |
|
| #line 269 "gram.y" |
| 1546 |
|
| { |
| 1547 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), 0 ); |
| 1548 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1549 |
|
| } |
| 1550 |
|
| #line 1551 "gram.c" |
| 1551 |
0 |
| break; |
| 1552 |
|
| |
| 1553 |
0 |
| case 47: /* top_imp_seq: YAML_ANCHOR indent_sep in_implicit_seq */ |
| 1554 |
|
| #line 274 "gram.y" |
| 1555 |
|
| { |
| 1556 |
|
| (yyval.nodeData) = syck_hdlr_add_anchor( (SyckParser *)parser, (yyvsp[-2].name), (yyvsp[0].nodeData) ); |
| 1557 |
|
| } |
| 1558 |
|
| #line 1559 "gram.c" |
| 1559 |
0 |
| break; |
| 1560 |
|
| |
| 1561 |
1 |
| case 48: /* top_imp_seq: YAML_ANCHOR top_imp_seq */ |
| 1562 |
|
| #line 278 "gram.y" |
| 1563 |
|
| { |
| 1564 |
|
| (yyval.nodeData) = syck_hdlr_add_anchor( (SyckParser *)parser, (yyvsp[-1].name), (yyvsp[0].nodeData) ); |
| 1565 |
|
| } |
| 1566 |
|
| #line 1567 "gram.c" |
| 1567 |
1 |
| break; |
| 1568 |
|
| |
| 1569 |
56 |
| case 49: /* in_implicit_seq: basic_seq */ |
| 1570 |
|
| #line 285 "gram.y" |
| 1571 |
|
| { |
| 1572 |
|
| (yyval.nodeData) = syck_new_seq( (yyvsp[0].nodeId) ); |
| 1573 |
|
| } |
| 1574 |
|
| #line 1575 "gram.c" |
| 1575 |
56 |
| break; |
| 1576 |
|
| |
| 1577 |
91 |
| case 50: /* in_implicit_seq: in_implicit_seq indent_sep basic_seq */ |
| 1578 |
|
| #line 289 "gram.y" |
| 1579 |
|
| { |
| 1580 |
|
| syck_seq_add( (yyvsp[-2].nodeData), (yyvsp[0].nodeId) ); |
| 1581 |
|
| (yyval.nodeData) = (yyvsp[-2].nodeData); |
| 1582 |
|
| } |
| 1583 |
|
| #line 1584 "gram.c" |
| 1584 |
91 |
| break; |
| 1585 |
|
| |
| 1586 |
3 |
| case 51: /* in_implicit_seq: in_implicit_seq indent_sep */ |
| 1587 |
|
| #line 294 "gram.y" |
| 1588 |
|
| { |
| 1589 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1590 |
|
| } |
| 1591 |
|
| #line 1592 "gram.c" |
| 1592 |
3 |
| break; |
| 1593 |
|
| |
| 1594 |
57 |
| case 52: /* inline_seq: '[' in_inline_seq ']' */ |
| 1595 |
|
| #line 301 "gram.y" |
| 1596 |
|
| { |
| 1597 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1598 |
|
| } |
| 1599 |
|
| #line 1600 "gram.c" |
| 1600 |
57 |
| break; |
| 1601 |
|
| |
| 1602 |
9 |
| case 53: /* inline_seq: '[' ']' */ |
| 1603 |
|
| #line 305 "gram.y" |
| 1604 |
|
| { |
| 1605 |
|
| (yyval.nodeData) = syck_alloc_seq(); |
| 1606 |
|
| } |
| 1607 |
|
| #line 1608 "gram.c" |
| 1608 |
9 |
| break; |
| 1609 |
|
| |
| 1610 |
58 |
| case 54: /* in_inline_seq: inline_seq_atom */ |
| 1611 |
|
| #line 312 "gram.y" |
| 1612 |
|
| { |
| 1613 |
|
| (yyval.nodeData) = syck_new_seq( syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ) ); |
| 1614 |
|
| } |
| 1615 |
|
| #line 1616 "gram.c" |
| 1616 |
58 |
| break; |
| 1617 |
|
| |
| 1618 |
72 |
| case 55: /* in_inline_seq: in_inline_seq ',' inline_seq_atom */ |
| 1619 |
|
| #line 316 "gram.y" |
| 1620 |
|
| { |
| 1621 |
|
| syck_seq_add( (yyvsp[-2].nodeData), syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ) ); |
| 1622 |
|
| (yyval.nodeData) = (yyvsp[-2].nodeData); |
| 1623 |
|
| } |
| 1624 |
|
| #line 1625 "gram.c" |
| 1625 |
72 |
| break; |
| 1626 |
|
| |
| 1627 |
2 |
| case 56: /* in_inline_seq: in_inline_seq ',' */ |
| 1628 |
|
| #line 321 "gram.y" |
| 1629 |
|
| { |
| 1630 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1631 |
|
| } |
| 1632 |
|
| #line 1633 "gram.c" |
| 1633 |
2 |
| break; |
| 1634 |
|
| |
| 1635 |
5 |
| case 59: /* implicit_map: indent_open top_imp_map indent_end */ |
| 1636 |
|
| #line 333 "gram.y" |
| 1637 |
|
| { |
| 1638 |
|
| apply_seq_in_map( (SyckParser *)parser, (yyvsp[-1].nodeData) ); |
| 1639 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1640 |
|
| } |
| 1641 |
|
| #line 1642 "gram.c" |
| 1642 |
5 |
| break; |
| 1643 |
|
| |
| 1644 |
1851 |
| case 60: /* implicit_map: indent_open in_implicit_map indent_end */ |
| 1645 |
|
| #line 338 "gram.y" |
| 1646 |
|
| { |
| 1647 |
|
| apply_seq_in_map( (SyckParser *)parser, (yyvsp[-1].nodeData) ); |
| 1648 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1649 |
|
| } |
| 1650 |
|
| #line 1651 "gram.c" |
| 1651 |
1851 |
| break; |
| 1652 |
|
| |
| 1653 |
4 |
| case 61: /* top_imp_map: YAML_TRANSFER indent_sep in_implicit_map */ |
| 1654 |
|
| #line 346 "gram.y" |
| 1655 |
|
| { |
| 1656 |
|
| syck_add_transfer( (yyvsp[-2].name), (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1657 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1658 |
|
| } |
| 1659 |
|
| #line 1660 "gram.c" |
| 1660 |
4 |
| break; |
| 1661 |
|
| |
| 1662 |
0 |
| case 62: /* top_imp_map: YAML_TRANSFER top_imp_map */ |
| 1663 |
|
| #line 351 "gram.y" |
| 1664 |
|
| { |
| 1665 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), ((SyckParser *)parser)->taguri_expansion ); |
| 1666 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1667 |
|
| } |
| 1668 |
|
| #line 1669 "gram.c" |
| 1669 |
0 |
| break; |
| 1670 |
|
| |
| 1671 |
0 |
| case 63: /* top_imp_map: YAML_TAGURI indent_sep in_implicit_map */ |
| 1672 |
|
| #line 356 "gram.y" |
| 1673 |
|
| { |
| 1674 |
|
| syck_add_transfer( (yyvsp[-2].name), (yyvsp[0].nodeData), 0 ); |
| 1675 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1676 |
|
| } |
| 1677 |
|
| #line 1678 "gram.c" |
| 1678 |
0 |
| break; |
| 1679 |
|
| |
| 1680 |
0 |
| case 64: /* top_imp_map: YAML_TAGURI top_imp_map */ |
| 1681 |
|
| #line 361 "gram.y" |
| 1682 |
|
| { |
| 1683 |
|
| syck_add_transfer( (yyvsp[-1].name), (yyvsp[0].nodeData), 0 ); |
| 1684 |
|
| (yyval.nodeData) = (yyvsp[0].nodeData); |
| 1685 |
|
| } |
| 1686 |
|
| #line 1687 "gram.c" |
| 1687 |
0 |
| break; |
| 1688 |
|
| |
| 1689 |
1 |
| case 65: /* top_imp_map: YAML_ANCHOR indent_sep in_implicit_map */ |
| 1690 |
|
| #line 366 "gram.y" |
| 1691 |
|
| { |
| 1692 |
|
| (yyval.nodeData) = syck_hdlr_add_anchor( (SyckParser *)parser, (yyvsp[-2].name), (yyvsp[0].nodeData) ); |
| 1693 |
|
| } |
| 1694 |
|
| #line 1695 "gram.c" |
| 1695 |
1 |
| break; |
| 1696 |
|
| |
| 1697 |
1 |
| case 66: /* top_imp_map: YAML_ANCHOR top_imp_map */ |
| 1698 |
|
| #line 370 "gram.y" |
| 1699 |
|
| { |
| 1700 |
|
| (yyval.nodeData) = syck_hdlr_add_anchor( (SyckParser *)parser, (yyvsp[-1].name), (yyvsp[0].nodeData) ); |
| 1701 |
|
| } |
| 1702 |
|
| #line 1703 "gram.c" |
| 1703 |
1 |
| break; |
| 1704 |
|
| |
| 1705 |
0 |
| case 68: /* complex_key: '?' atom indent_sep */ |
| 1706 |
|
| #line 378 "gram.y" |
| 1707 |
|
| { |
| 1708 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1709 |
|
| } |
| 1710 |
|
| #line 1711 "gram.c" |
| 1711 |
0 |
| break; |
| 1712 |
|
| |
| 1713 |
9361480 |
| case 70: /* complex_mapping: complex_key ':' complex_value */ |
| 1714 |
|
| #line 389 "gram.y" |
| 1715 |
|
| { |
| 1716 |
|
| (yyval.nodeData) = syck_new_map( |
| 1717 |
|
| syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[-2].nodeData) ), |
| 1718 |
|
| syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ) ); |
| 1719 |
|
| } |
| 1720 |
|
| #line 1721 "gram.c" |
| 1721 |
9361469 |
| break; |
| 1722 |
|
| |
| 1723 |
0 |
▶ | case 72: /* in_implicit_map: in_implicit_map indent_sep basic_seq */ |
Branch: 1 branch
| Branch | True | False | Total |
| case 72: /* in_implicit_map: in_implicit_map indent_sep basic_seq */ |
0 |
0 |
0 |
|
| 1724 |
|
| #line 399 "gram.y" |
| 1725 |
|
| { |
| 1726 |
|
| if ( (yyvsp[-2].nodeData)->shortcut == NULL ) |
| 1727 |
|
| { |
| 1728 |
|
| (yyvsp[-2].nodeData)->shortcut = syck_new_seq( (yyvsp[0].nodeId) ); |
| 1729 |
|
| } |
| 1730 |
|
| else |
| 1731 |
|
| { |
| 1732 |
|
| syck_seq_add( (yyvsp[-2].nodeData)->shortcut, (yyvsp[0].nodeId) ); |
| 1733 |
|
| } |
| 1734 |
|
| (yyval.nodeData) = (yyvsp[-2].nodeData); |
| 1735 |
|
| } |
| 1736 |
|
| #line 1737 "gram.c" |
| 1737 |
0 |
| break; |
| 1738 |
|
| |
| 1739 |
9359602 |
| case 73: /* in_implicit_map: in_implicit_map indent_sep complex_mapping */ |
| 1740 |
|
| #line 411 "gram.y" |
| 1741 |
|
| { |
| 1742 |
|
| apply_seq_in_map( (SyckParser *)parser, (yyvsp[-2].nodeData) ); |
| 1743 |
|
| syck_map_update( (yyvsp[-2].nodeData), (yyvsp[0].nodeData) ); |
| 1744 |
|
| syck_free_node( (yyvsp[0].nodeData) ); |
| 1745 |
|
| (yyvsp[0].nodeData) = NULL; |
| 1746 |
|
| (yyval.nodeData) = (yyvsp[-2].nodeData); |
| 1747 |
|
| } |
| 1748 |
|
| #line 1749 "gram.c" |
| 1749 |
9359602 |
| break; |
| 1750 |
|
| |
| 1751 |
3 |
| case 74: /* in_implicit_map: in_implicit_map indent_sep */ |
| 1752 |
|
| #line 419 "gram.y" |
| 1753 |
|
| { |
| 1754 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1755 |
|
| } |
| 1756 |
|
| #line 1757 "gram.c" |
| 1757 |
3 |
| break; |
| 1758 |
|
| |
| 1759 |
760 |
| case 75: /* basic_mapping: atom ':' atom_or_empty */ |
| 1760 |
|
| #line 426 "gram.y" |
| 1761 |
|
| { |
| 1762 |
|
| (yyval.nodeData) = syck_new_map( |
| 1763 |
|
| syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[-2].nodeData) ), |
| 1764 |
|
| syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ) ); |
| 1765 |
|
| } |
| 1766 |
|
| #line 1767 "gram.c" |
| 1767 |
760 |
| break; |
| 1768 |
|
| |
| 1769 |
723 |
| case 76: /* inline_map: '{' in_inline_map '}' */ |
| 1770 |
|
| #line 435 "gram.y" |
| 1771 |
|
| { |
| 1772 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1773 |
|
| } |
| 1774 |
|
| #line 1775 "gram.c" |
| 1775 |
723 |
| break; |
| 1776 |
|
| |
| 1777 |
17 |
| case 77: /* inline_map: '{' '}' */ |
| 1778 |
|
| #line 439 "gram.y" |
| 1779 |
|
| { |
| 1780 |
|
| (yyval.nodeData) = syck_alloc_map(); |
| 1781 |
|
| } |
| 1782 |
|
| #line 1783 "gram.c" |
| 1783 |
17 |
| break; |
| 1784 |
|
| |
| 1785 |
37 |
| case 79: /* in_inline_map: in_inline_map ',' inline_map_atom */ |
| 1786 |
|
| #line 447 "gram.y" |
| 1787 |
|
| { |
| 1788 |
|
| syck_map_update( (yyvsp[-2].nodeData), (yyvsp[0].nodeData) ); |
| 1789 |
|
| syck_free_node( (yyvsp[0].nodeData) ); |
| 1790 |
|
| (yyvsp[0].nodeData) = NULL; |
| 1791 |
|
| (yyval.nodeData) = (yyvsp[-2].nodeData); |
| 1792 |
|
| } |
| 1793 |
|
| #line 1794 "gram.c" |
| 1794 |
37 |
| break; |
| 1795 |
|
| |
| 1796 |
2 |
| case 80: /* in_inline_map: in_inline_map ',' */ |
| 1797 |
|
| #line 454 "gram.y" |
| 1798 |
|
| { |
| 1799 |
|
| (yyval.nodeData) = (yyvsp[-1].nodeData); |
| 1800 |
|
| } |
| 1801 |
|
| #line 1802 "gram.c" |
| 1802 |
2 |
| break; |
| 1803 |
|
| |
| 1804 |
0 |
| case 81: /* inline_map_atom: atom */ |
| 1805 |
|
| #line 461 "gram.y" |
| 1806 |
|
| { |
| 1807 |
|
| NULL_NODE( parser, n ); |
| 1808 |
|
| (yyval.nodeData) = syck_new_map( |
| 1809 |
|
| syck_hdlr_add_node( (SyckParser *)parser, (yyvsp[0].nodeData) ), |
| 1810 |
|
| syck_hdlr_add_node( (SyckParser *)parser, n ) ); |
| 1811 |
|
| } |
| 1812 |
|
| #line 1813 "gram.c" |
| 1813 |
0 |
| break; |
| 1814 |
|
| |
| 1815 |
|
| |
| 1816 |
|
| #line 1817 "gram.c" |
| 1817 |
|
| |
| 1818 |
65554721 |
| default: break; |
| 1819 |
|
| } |
| 1820 |
|
| /* User semantic actions sometimes alter yychar, and that requires |
| 1821 |
|
| that yytoken be updated with the new translation. We take the |
| 1822 |
|
| approach of translating immediately before every use of yytoken. |
| 1823 |
|
| One alternative is translating here after every semantic action, |
| 1824 |
|
| but that translation would be missed if the semantic action invokes |
| 1825 |
|
| YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or |
| 1826 |
|
| if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an |
| 1827 |
|
| incorrect destructor might then be invoked immediately. In the |
| 1828 |
|
| case of YYERROR or YYBACKUP, subsequent parser actions might lead |
| 1829 |
|
| to an incorrect destructor call or verbose syntax error message |
| 1830 |
|
| before the lookahead is translated. */ |
| 1831 |
|
| YY_SYMBOL_PRINT ("-> $$ =", YY_CAST (yysymbol_kind_t, yyr1[yyn]), &yyval, &yyloc); |
| 1832 |
|
| |
| 1833 |
84284185 |
| YYPOPSTACK (yylen); |
| 1834 |
84284185 |
| yylen = 0; |
| 1835 |
|
| |
| 1836 |
84284185 |
| *++yyvsp = yyval; |
| 1837 |
|
| |
| 1838 |
|
| /* Now 'shift' the result of the reduction. Determine what state |
| 1839 |
|
| that goes to, based on the state we popped back to and the rule |
| 1840 |
|
| number reduced by. */ |
| 1841 |
|
| { |
| 1842 |
84284185 |
| const int yylhs = yyr1[yyn] - YYNTOKENS; |
| 1843 |
84284185 |
| const int yyi = yypgoto[yylhs] + *yyssp; |
| 1844 |
84270126 |
▶ | yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp |
Branch: 2 branches
| Branch | True | False | Total |
| yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp |
84270126 |
0 |
84270126 |
| yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp |
37453711 |
46816415 |
84270126 |
|
| 1845 |
37453711 |
| ? yytable[yyi] |
| 1846 |
168554311 |
▶ | : yydefgoto[yylhs]); |
Branch: 1 branch
| Branch | True | False | Total |
| : yydefgoto[yylhs]); |
84270126 |
14059 |
84284185 |
|
| 1847 |
|
| } |
| 1848 |
|
| |
| 1849 |
84284185 |
| goto yynewstate; |
| 1850 |
|
| |
| 1851 |
|
| |
| 1852 |
|
| /*--------------------------------------. |
| 1853 |
|
| | yyerrlab -- here on detecting error. | |
| 1854 |
|
| `--------------------------------------*/ |
| 1855 |
13 |
| yyerrlab: |
| 1856 |
|
| /* Make sure we have latest lookahead translation. See comments at |
| 1857 |
|
| user semantic actions for why this is necessary. */ |
| 1858 |
13 |
▶ | yytoken = yychar == SYCKEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar); |
Branch: 3 branches
| Branch | True | False | Total |
| yytoken = yychar == SYCKEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar); |
13 |
0 |
13 |
| yytoken = yychar == SYCKEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar); |
13 |
0 |
13 |
| yytoken = yychar == SYCKEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar); |
13 |
0 |
13 |
|
| 1859 |
|
| /* If not already recovering from an error, report this error. */ |
| 1860 |
13 |
▶ | if (!yyerrstatus) |
Branch: 1 branch
| Branch | True | False | Total |
| if (!yyerrstatus) |
13 |
0 |
13 |
|
| 1861 |
|
| { |
| 1862 |
13 |
| ++yynerrs; |
| 1863 |
13 |
| yyerror (parser, YY_("syntax error")); |
| 1864 |
|
| } |
| 1865 |
|
| |
| 1866 |
0 |
▶ | if (yyerrstatus == 3) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyerrstatus == 3) |
0 |
0 |
0 |
|
| 1867 |
|
| { |
| 1868 |
|
| /* If just tried and failed to reuse lookahead token after an |
| 1869 |
|
| error, discard it. */ |
| 1870 |
|
| |
| 1871 |
0 |
▶ | if (yychar <= SYCKEOF) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yychar <= SYCKEOF) |
0 |
0 |
0 |
|
| 1872 |
|
| { |
| 1873 |
|
| /* Return failure if at end of input. */ |
| 1874 |
0 |
▶ | if (yychar == SYCKEOF) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yychar == SYCKEOF) |
0 |
0 |
0 |
|
| 1875 |
0 |
| YYABORT; |
| 1876 |
|
| } |
| 1877 |
|
| else |
| 1878 |
|
| { |
| 1879 |
0 |
| yydestruct ("Error: discarding", |
| 1880 |
|
| yytoken, &yylval, parser); |
| 1881 |
0 |
| yychar = SYCKEMPTY; |
| 1882 |
|
| } |
| 1883 |
|
| } |
| 1884 |
|
| |
| 1885 |
|
| /* Else will try to reuse lookahead token after shifting the error |
| 1886 |
|
| token. */ |
| 1887 |
0 |
| goto yyerrlab1; |
| 1888 |
|
| |
| 1889 |
|
| |
| 1890 |
|
| /*---------------------------------------------------. |
| 1891 |
|
| | yyerrorlab -- error raised explicitly by YYERROR. | |
| 1892 |
|
| `---------------------------------------------------*/ |
| 1893 |
|
| yyerrorlab: |
| 1894 |
|
| /* Pacify compilers when the user code never invokes YYERROR and the |
| 1895 |
|
| label yyerrorlab therefore never appears in user code. */ |
| 1896 |
|
| if (0) |
| 1897 |
|
| YYERROR; |
| 1898 |
|
| |
| 1899 |
|
| /* Do not reclaim the symbols of the rule whose action triggered |
| 1900 |
|
| this YYERROR. */ |
| 1901 |
|
| YYPOPSTACK (yylen); |
| 1902 |
|
| yylen = 0; |
| 1903 |
|
| YY_STACK_PRINT (yyss, yyssp); |
| 1904 |
|
| yystate = *yyssp; |
| 1905 |
|
| goto yyerrlab1; |
| 1906 |
|
| |
| 1907 |
|
| |
| 1908 |
|
| /*-------------------------------------------------------------. |
| 1909 |
|
| | yyerrlab1 -- common code for both syntax error and YYERROR. | |
| 1910 |
|
| `-------------------------------------------------------------*/ |
| 1911 |
0 |
| yyerrlab1: |
| 1912 |
0 |
| yyerrstatus = 3; /* Each real token shifted decrements this. */ |
| 1913 |
|
| |
| 1914 |
|
| /* Pop stack until we find a state that shifts the error token. */ |
| 1915 |
|
| for (;;) |
| 1916 |
|
| { |
| 1917 |
0 |
| yyn = yypact[yystate]; |
| 1918 |
0 |
▶ | if (!yypact_value_is_default (yyn)) |
Branch: 1 branch
| Branch | True | False | Total |
| if (!yypact_value_is_default (yyn)) |
0 |
0 |
0 |
|
| 1919 |
|
| { |
| 1920 |
0 |
| yyn += YYSYMBOL_YYerror; |
| 1921 |
0 |
▶ | if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror) |
Branch: 3 branches
| Branch | True | False | Total |
| if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror) |
0 |
0 |
0 |
| if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror) |
0 |
0 |
0 |
| if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror) |
0 |
0 |
0 |
|
| 1922 |
|
| { |
| 1923 |
0 |
| yyn = yytable[yyn]; |
| 1924 |
0 |
▶ | if (0 < yyn) |
Branch: 1 branch
| Branch | True | False | Total |
| if (0 < yyn) |
0 |
0 |
0 |
|
| 1925 |
0 |
| break; |
| 1926 |
|
| } |
| 1927 |
|
| } |
| 1928 |
|
| |
| 1929 |
|
| /* Pop the current state because it cannot handle the error token. */ |
| 1930 |
0 |
▶ | if (yyssp == yyss) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyssp == yyss) |
0 |
0 |
0 |
|
| 1931 |
0 |
| YYABORT; |
| 1932 |
|
| |
| 1933 |
|
| |
| 1934 |
0 |
| yydestruct ("Error: popping", |
| 1935 |
0 |
| YY_ACCESSING_SYMBOL (yystate), yyvsp, parser); |
| 1936 |
0 |
| YYPOPSTACK (1); |
| 1937 |
0 |
| yystate = *yyssp; |
| 1938 |
|
| YY_STACK_PRINT (yyss, yyssp); |
| 1939 |
|
| } |
| 1940 |
|
| |
| 1941 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 1942 |
0 |
| *++yyvsp = yylval; |
| 1943 |
|
| YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 1944 |
|
| |
| 1945 |
|
| |
| 1946 |
|
| /* Shift the error token. */ |
| 1947 |
|
| YY_SYMBOL_PRINT ("Shifting", YY_ACCESSING_SYMBOL (yyn), yyvsp, yylsp); |
| 1948 |
|
| |
| 1949 |
0 |
| yystate = yyn; |
| 1950 |
0 |
| goto yynewstate; |
| 1951 |
|
| |
| 1952 |
|
| |
| 1953 |
|
| /*-------------------------------------. |
| 1954 |
|
| | yyacceptlab -- YYACCEPT comes here. | |
| 1955 |
|
| `-------------------------------------*/ |
| 1956 |
2456 |
| yyacceptlab: |
| 1957 |
2456 |
| yyresult = 0; |
| 1958 |
2456 |
| goto yyreturn; |
| 1959 |
|
| |
| 1960 |
|
| |
| 1961 |
|
| /*-----------------------------------. |
| 1962 |
|
| | yyabortlab -- YYABORT comes here. | |
| 1963 |
|
| `-----------------------------------*/ |
| 1964 |
0 |
| yyabortlab: |
| 1965 |
0 |
| yyresult = 1; |
| 1966 |
0 |
| goto yyreturn; |
| 1967 |
|
| |
| 1968 |
|
| |
| 1969 |
|
| #if !defined yyoverflow |
| 1970 |
|
| /*-------------------------------------------------. |
| 1971 |
|
| | yyexhaustedlab -- memory exhaustion comes here. | |
| 1972 |
|
| `-------------------------------------------------*/ |
| 1973 |
0 |
| yyexhaustedlab: |
| 1974 |
0 |
| yyerror (parser, YY_("memory exhausted")); |
| 1975 |
0 |
| yyresult = 2; |
| 1976 |
0 |
| goto yyreturn; |
| 1977 |
|
| #endif |
| 1978 |
|
| |
| 1979 |
|
| |
| 1980 |
|
| /*-------------------------------------------------------. |
| 1981 |
|
| | yyreturn -- parsing is finished, clean up and return. | |
| 1982 |
|
| `-------------------------------------------------------*/ |
| 1983 |
2456 |
| yyreturn: |
| 1984 |
2456 |
▶ | if (yychar != SYCKEMPTY) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yychar != SYCKEMPTY) |
0 |
2456 |
2456 |
|
| 1985 |
|
| { |
| 1986 |
|
| /* Make sure we have latest lookahead translation. See comments at |
| 1987 |
|
| user semantic actions for why this is necessary. */ |
| 1988 |
0 |
▶ | yytoken = YYTRANSLATE (yychar); |
Branch: 2 branches
| Branch | True | False | Total |
| yytoken = YYTRANSLATE (yychar); |
0 |
0 |
0 |
| yytoken = YYTRANSLATE (yychar); |
0 |
0 |
0 |
|
| 1989 |
0 |
| yydestruct ("Cleanup: discarding lookahead", |
| 1990 |
|
| yytoken, &yylval, parser); |
| 1991 |
|
| } |
| 1992 |
|
| /* Do not reclaim the symbols of the rule whose action triggered |
| 1993 |
|
| this YYABORT or YYACCEPT. */ |
| 1994 |
2456 |
| YYPOPSTACK (yylen); |
| 1995 |
|
| YY_STACK_PRINT (yyss, yyssp); |
| 1996 |
7368 |
▶ | while (yyssp != yyss) |
Branch: 1 branch
| Branch | True | False | Total |
| while (yyssp != yyss) |
4912 |
2456 |
7368 |
|
| 1997 |
|
| { |
| 1998 |
4912 |
| yydestruct ("Cleanup: popping", |
| 1999 |
4912 |
| YY_ACCESSING_SYMBOL (+*yyssp), yyvsp, parser); |
| 2000 |
4912 |
| YYPOPSTACK (1); |
| 2001 |
|
| } |
| 2002 |
|
| #ifndef yyoverflow |
| 2003 |
2456 |
▶ | if (yyss != yyssa) |
Branch: 1 branch
| Branch | True | False | Total |
| if (yyss != yyssa) |
2 |
2454 |
2456 |
|
| 2004 |
2 |
| YYSTACK_FREE (yyss); |
| 2005 |
|
| #endif |
| 2006 |
|
| |
| 2007 |
2456 |
| return yyresult; |
| 2008 |
|
| } |
| 2009 |
|
| |
| 2010 |
|
| #line 470 "gram.y" |
| 2011 |
|
| |
| 2012 |
|
| |
| 2013 |
|
| void |
| 2014 |
|
| apply_seq_in_map( SyckParser *parser, SyckNode *n ) |
| 2015 |
|
| { |
| 2016 |
|
| long map_len; |
| 2017 |
|
| if ( n->shortcut == NULL ) |
| 2018 |
|
| { |
| 2019 |
|
| return; |
| 2020 |
|
| } |
| 2021 |
|
| |
| 2022 |
|
| map_len = syck_map_count( n ); |
| 2023 |
|
| syck_map_assign( n, map_value, map_len - 1, |
| 2024 |
|
| syck_hdlr_add_node( parser, n->shortcut ) ); |
| 2025 |
|
| |
| 2026 |
|
| n->shortcut = NULL; |
| 2027 |
|
| } |