-/*
-** 2000-05-29
-**
-** The author disclaims copyright to this source code. In place of
-** a legal notice, here is a blessing:
-**
-** May you do good and not evil.
-** May you find forgiveness for yourself and forgive others.
-** May you share freely, never taking more than you give.
-**
-*************************************************************************
-** Driver template for the LEMON parser generator.
-**
-** The "lemon" program processes an LALR(1) input grammar file, then uses
-** this template to construct a parser. The "lemon" program inserts text
-** at each "%%" line. Also, any "P-a-r-s-e" identifer prefix (without the
-** interstitial "-" characters) contained in this template is changed into
-** the value of the %name directive from the grammar. Otherwise, the content
-** of this template is copied straight through into the generate parser
-** source file.
-**
-** The following is the concatenation of all %include directives from the
-** input grammar file:
-*/
-#include <stdio.h>
-/************ Begin %include sections from the grammar ************************/
-#line 1 "src/parser_proc.y"
+/* A Bison parser, made by GNU Bison 3.0.4. */
+
+/* Skeleton implementation for Bison GLR parsers in C
+
+ Copyright (C) 2002-2015 Free Software Foundation, Inc.
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>. */
+
+/* As a special exception, you may create a larger work that contains
+ part or all of the Bison parser skeleton and distribute that work
+ under terms of your choice, so long as that work isn't itself a
+ parser generator using the skeleton or a modified version thereof
+ as a parser skeleton. Alternatively, if you modify or redistribute
+ the parser skeleton itself, you may (at your option) remove this
+ special exception, which will cause the skeleton and the resulting
+ Bison output files to be licensed under the GNU General Public
+ License without this special exception.
+
+ This special exception was added by the Free Software Foundation in
+ version 2.2 of Bison. */
+
+/* C GLR parser skeleton written by Paul Hilfinger. */
+
+/* Identify Bison output. */
+#define YYBISON 1
+
+/* Bison version. */
+#define YYBISON_VERSION "3.0.4"
+
+/* Skeleton name. */
+#define YYSKELETON_NAME "glr.c"
+
+/* Pure parsers. */
+#define YYPURE 1
+
+
+/* "%code top" blocks. */
+#line 1 "src/parser_proc_grammar.y" /* glr.c:222 */
#include "php_psi_stdinc.h"
+#line 54 "src/parser_proc.c" /* glr.c:222 */
+
+
+/* Substitute the variable and function names. */
+#define yyparse psi_parser_proc_parse
+#define yylex psi_parser_proc_lex
+#define yyerror psi_parser_proc_error
+#define yydebug psi_parser_proc_debug
+
+
+/* First part of user declarations. */
+
+#line 66 "src/parser_proc.c" /* glr.c:240 */
+
+# ifndef YY_NULLPTR
+# if defined __cplusplus && 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# endif
+
+#include "parser_proc.h"
+
+/* Enabling verbose error messages. */
+#ifdef YYERROR_VERBOSE
+# undef YYERROR_VERBOSE
+# define YYERROR_VERBOSE 1
+#else
+# define YYERROR_VERBOSE 1
+#endif
+
+/* Default (constant) value used for initialization for null
+ right-hand sides. Unlike the standard yacc.c template, here we set
+ the default value of $$ to a zeroed-out value. Since the default
+ value is undefined, this behavior is technically correct. */
+static YYSTYPE yyval_default;
+
+/* Copy the second part of user declarations. */
+
+#line 94 "src/parser_proc.c" /* glr.c:263 */
+/* Unqualified %code blocks. */
+#line 5 "src/parser_proc_grammar.y" /* glr.c:264 */
+
#include <assert.h>
#include <stdarg.h>
#include "plist.h"
#include "parser.h"
-/* rename lemon symbols, works better than DEF(%name) */
-#define ParseAlloc psi_parser_proc_init_ex
-#define Parse psi_parser_proc_parse
-#define ParseTrace psi_parser_proc_trace
-#define ParseFree psi_parser_proc_free_ex
+#define YYDEBUG 1
+#define PSI_PARSER_PROC_DEBUG 1
-/* fwd decls */
-void *ParseAlloc(void *(*mallocProc)(size_t));
-void ParseFree(void *p, void (*freeProc)(void*));
+static int psi_parser_proc_lex(YYSTYPE *u, struct psi_parser *P, struct psi_plist *tokens, size_t *index);
+static void psi_parser_proc_error(struct psi_parser *P, struct psi_plist *tokens, size_t *index, const char *msg);
-/* wrappers */
-void *psi_parser_proc_init(void)
+static inline void psi_parser_proc_add_struct(struct psi_parser *P, struct psi_decl_struct *strct)
{
- return ParseAlloc(malloc);
+ assert(strct);
+ if (!P->structs) {
+ P->structs = psi_plist_init((psi_plist_dtor) psi_decl_struct_free);
+ }
+ P->structs = psi_plist_add(P->structs, &strct);
}
-
-void psi_parser_proc_free(void **parser_proc)
+static inline void psi_parser_proc_add_union(struct psi_parser *P, struct psi_decl_union *u)
+{
+ assert(u);
+ if (!P->unions) {
+ P->unions = psi_plist_init((psi_plist_dtor) psi_decl_union_free);
+ }
+ P->unions = psi_plist_add(P->unions, &u);
+}
+static inline void psi_parser_proc_add_enum(struct psi_parser *P, struct psi_decl_enum *e)
+{
+ assert(e);
+ if (!P->enums) {
+ P->enums = psi_plist_init((psi_plist_dtor) psi_decl_enum_free);
+ }
+ P->enums = psi_plist_add(P->enums, &e);
+}
+static inline void psi_parser_proc_deanon_typedef(struct psi_decl_arg *def)
+{
+ switch (def->type->type) {
+ case PSI_T_STRUCT:
+ if (!psi_decl_type_is_anon(def->type->name, "struct")) {
+ return;
+ }
+ break;
+ case PSI_T_UNION:
+ if (!psi_decl_type_is_anon(def->type->name, "union")) {
+ return;
+ }
+ break;
+ case PSI_T_ENUM:
+ if (!psi_decl_type_is_anon(def->type->name, "enum")) {
+ return;
+ }
+ break;
+ default:
+ return;
+ }
+ free(def->type->name);
+ def->type->name = strdup(def->var->name);
+}
+static inline void psi_parser_proc_add_typedef(struct psi_parser *P, struct psi_decl_arg *def)
{
- if (*parser_proc) {
- ParseFree(*parser_proc, free);
- *parser_proc = NULL;
+ assert(def);
+ if (!P->types) {
+ P->types = psi_plist_init((psi_plist_dtor) psi_decl_arg_free);
+ }
+ psi_parser_proc_deanon_typedef(def);
+ P->types = psi_plist_add(P->types, &def);
+}
+static inline void psi_parser_proc_add_const(struct psi_parser *P, struct psi_const *cnst) {
+ assert(cnst);
+ if (!P->consts) {
+ P->consts = psi_plist_init((psi_plist_dtor) psi_const_free);
}
+ P->consts = psi_plist_add(P->consts, &cnst);
+
+}
+static inline void psi_parser_proc_add_decl(struct psi_parser *P, struct psi_decl *decl) {
+ assert(decl);
+
+ if (psi_decl_is_blacklisted(decl->func->var->name)) {
+ psi_decl_free(&decl);
+ return;
+ }
+
+ if (!P->decls) {
+ P->decls = psi_plist_init((psi_plist_dtor) psi_decl_free);
+ }
+ P->decls = psi_plist_add(P->decls, &decl);
+}
+static inline void psi_parser_proc_add_impl(struct psi_parser *P, struct psi_impl *impl) {
+ assert(impl);
+ if (!P->impls) {
+ P->impls = psi_plist_init((psi_plist_dtor) psi_impl_free);
+ }
+ P->impls = psi_plist_add(P->impls, &impl);
}
-#line 62 "src/parser_proc.c"
-/**************** End of %include directives **********************************/
-/* These constants specify the various numeric values for terminal symbols
-** in a format understandable to "makeheaders". This section is blank unless
-** "lemon" is run with the "-m" command-line option.
-***************** Begin makeheaders token definitions *************************/
-/**************** End makeheaders token definitions ***************************/
-
-/* The next sections is a series of control #defines.
-** various aspects of the generated parser.
-** YYCODETYPE is the data type used to store the integer codes
-** that represent terminal and non-terminal symbols.
-** "unsigned char" is used if there are fewer than
-** 256 symbols. Larger types otherwise.
-** YYNOCODE is a number of type YYCODETYPE that is not used for
-** any terminal or nonterminal symbol.
-** YYFALLBACK If defined, this indicates that one or more tokens
-** (also known as: "terminal symbols") have fall-back
-** values which should be used if the original symbol
-** would not parse. This permits keywords to sometimes
-** be used as identifiers, for example.
-** YYACTIONTYPE is the data type used for "action codes" - numbers
-** that indicate what to do in response to the next
-** token.
-** ParseTOKENTYPE is the data type used for minor type for terminal
-** symbols. Background: A "minor type" is a semantic
-** value associated with a terminal or non-terminal
-** symbols. For example, for an "ID" terminal symbol,
-** the minor type might be the name of the identifier.
-** Each non-terminal can have a different minor type.
-** Terminal symbols all have the same minor type, though.
-** This macros defines the minor type for terminal
-** symbols.
-** YYMINORTYPE is the data type used for all minor types.
-** This is typically a union of many types, one of
-** which is ParseTOKENTYPE. The entry in the union
-** for terminal symbols is called "yy0".
-** YYSTACKDEPTH is the maximum depth of the parser's stack. If
-** zero the stack is dynamically sized using realloc()
-** ParseARG_SDECL A static variable declaration for the %extra_argument
-** ParseARG_PDECL A parameter declaration for the %extra_argument
-** ParseARG_STORE Code to store %extra_argument into yypParser
-** ParseARG_FETCH Code to extract %extra_argument from yypParser
-** YYERRORSYMBOL is the code number of the error symbol. If not
-** defined, then do no error processing.
-** YYNSTATE the combined number of states.
-** YYNRULE the number of rules in the grammar
-** YY_MAX_SHIFT Maximum value for shift actions
-** YY_MIN_SHIFTREDUCE Minimum value for shift-reduce actions
-** YY_MAX_SHIFTREDUCE Maximum value for shift-reduce actions
-** YY_MIN_REDUCE Maximum value for reduce actions
-** YY_ERROR_ACTION The yy_action[] code for syntax error
-** YY_ACCEPT_ACTION The yy_action[] code for accept
-** YY_NO_ACTION The yy_action[] code for no-op
-*/
-#ifndef INTERFACE
-# define INTERFACE 1
+/* end code */
+
+#line 198 "src/parser_proc.c" /* glr.c:264 */
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#ifndef YY_
+# if defined YYENABLE_NLS && YYENABLE_NLS
+# if ENABLE_NLS
+# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
+# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
+# endif
+# endif
+# ifndef YY_
+# define YY_(Msgid) Msgid
+# endif
+#endif
+
+#ifndef YYFREE
+# define YYFREE free
+#endif
+#ifndef YYMALLOC
+# define YYMALLOC malloc
+#endif
+#ifndef YYREALLOC
+# define YYREALLOC realloc
+#endif
+
+#define YYSIZEMAX ((size_t) -1)
+
+#ifdef __cplusplus
+ typedef bool yybool;
+#else
+ typedef unsigned char yybool;
+#endif
+#define yytrue 1
+#define yyfalse 0
+
+#ifndef YYSETJMP
+# include <setjmp.h>
+# define YYJMP_BUF jmp_buf
+# define YYSETJMP(Env) setjmp (Env)
+/* Pacify clang. */
+# define YYLONGJMP(Env, Val) (longjmp (Env, Val), YYASSERT (0))
+#endif
+
+#ifndef YY_ATTRIBUTE
+# if (defined __GNUC__ \
+ && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \
+ || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C
+# define YY_ATTRIBUTE(Spec) __attribute__(Spec)
+# else
+# define YY_ATTRIBUTE(Spec) /* empty */
+# endif
+#endif
+
+#ifndef YY_ATTRIBUTE_PURE
+# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__))
+#endif
+
+#ifndef YY_ATTRIBUTE_UNUSED
+# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
+#endif
+
+#if !defined _Noreturn \
+ && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
+# if defined _MSC_VER && 1200 <= _MSC_VER
+# define _Noreturn __declspec (noreturn)
+# else
+# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
+# endif
+#endif
+
+/* Suppress unused-variable warnings by "using" E. */
+#if ! defined lint || defined __GNUC__
+# define YYUSE(E) ((void) (E))
+#else
+# define YYUSE(E) /* empty */
+#endif
+
+#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+/* Suppress an incorrect diagnostic about yylval being uninitialized. */
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
+ _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
+ _Pragma ("GCC diagnostic pop")
+#else
+# define YY_INITIAL_VALUE(Value) Value
+#endif
+#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+# define YY_IGNORE_MAYBE_UNINITIALIZED_END
#endif
-/************* Begin control #defines *****************************************/
-#define YYCODETYPE unsigned char
-#define YYNOCODE 159
-#define YYACTIONTYPE unsigned short int
-#define ParseTOKENTYPE struct psi_token *
-typedef union {
- int yyinit;
- ParseTOKENTYPE yy0;
- struct psi_let_calloc* yy9;
- struct psi_decl_var* yy11;
- struct psi_let_exp* yy20;
- struct psi_set_func* yy26;
- struct psi_let_func* yy27;
- struct psi_impl_var* yy37;
- struct psi_plist * yy43;
- struct psi_decl_enum * yy63;
- struct psi_token** yy78;
- struct psi_return_stmt* yy90;
- struct psi_layout yy91;
- struct psi_impl_def_val* yy93;
- struct psi_free_exp* yy94;
- struct psi_impl* yy97;
- struct psi_set_stmt* yy98;
- struct psi_decl* yy103;
- bool yy121;
- struct psi_decl_type* yy132;
- struct psi_impl_type* yy138;
- struct psi_layout* yy141;
- struct psi_set_exp* yy147;
- struct psi_const* yy154;
- struct psi_plist* yy163;
- struct psi_impl_func* yy168;
- struct psi_const_type* yy171;
- struct psi_decl_arg* yy184;
- struct psi_number* yy188;
- struct psi_free_stmt* yy192;
- unsigned yy202;
- struct psi_impl_arg* yy210;
- struct psi_decl_enum_item* yy217;
- struct psi_decl_abi* yy218;
- struct psi_let_callback* yy220;
- struct psi_num_exp* yy259;
- struct psi_decl_union* yy271;
- struct psi_decl_struct* yy275;
- struct psi_let_stmt* yy311;
-} YYMINORTYPE;
-#ifndef YYSTACKDEPTH
-#define YYSTACKDEPTH 100
+#ifndef YY_INITIAL_VALUE
+# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif
-#define ParseARG_SDECL struct psi_parser *P;
-#define ParseARG_PDECL ,struct psi_parser *P
-#define ParseARG_FETCH struct psi_parser *P = yypParser->P
-#define ParseARG_STORE yypParser->P = P
-#define YYFALLBACK 1
-#define YYNSTATE 197
-#define YYNRULE 157
-#define YY_MAX_SHIFT 196
-#define YY_MIN_SHIFTREDUCE 328
-#define YY_MAX_SHIFTREDUCE 484
-#define YY_MIN_REDUCE 485
-#define YY_MAX_REDUCE 641
-#define YY_ERROR_ACTION 642
-#define YY_ACCEPT_ACTION 643
-#define YY_NO_ACTION 644
-/************* End control #defines *******************************************/
-
-/* Define the yytestcase() macro to be a no-op if is not already defined
-** otherwise.
-**
-** Applications can choose to define yytestcase() in the %include section
-** to a macro that can assist in verifying code coverage. For production
-** code the yytestcase() macro should be turned off. But it is useful
-** for testing.
-*/
-#ifndef yytestcase
-# define yytestcase(X)
+
+
+#ifndef YYASSERT
+# define YYASSERT(Condition) ((void) ((Condition) || (abort (), 0)))
#endif
+/* YYFINAL -- State number of the termination state. */
+#define YYFINAL 169
+/* YYLAST -- Last index in YYTABLE. */
+#define YYLAST 3650
+
+/* YYNTOKENS -- Number of terminals. */
+#define YYNTOKENS 140
+/* YYNNTS -- Number of nonterminals. */
+#define YYNNTS 137
+/* YYNRULES -- Number of rules. */
+#define YYNRULES 630
+/* YYNRULES -- Number of states. */
+#define YYNSTATES 896
+/* YYMAXRHS -- Maximum number of symbols on right-hand side of rule. */
+#define YYMAXRHS 13
+/* YYMAXLEFT -- Maximum number of symbols to the left of a handle
+ accessed by $0, $-1, etc., in any rule. */
+#define YYMAXLEFT 0
+
+/* YYTRANSLATE(X) -- Bison symbol number corresponding to X. */
+#define YYUNDEFTOK 2
+#define YYMAXUTOK 394
-/* Next are the tables used to determine what action to take based on the
-** current state and lookahead token. These tables are used to implement
-** functions that take a state number and lookahead value and return an
-** action integer.
-**
-** Suppose the action integer is N. Then the action is determined as
-** follows
-**
-** 0 <= N <= YY_MAX_SHIFT Shift N. That is, push the lookahead
-** token onto the stack and goto state N.
-**
-** N between YY_MIN_SHIFTREDUCE Shift to an arbitrary state then
-** and YY_MAX_SHIFTREDUCE reduce by rule N-YY_MIN_SHIFTREDUCE.
-**
-** N between YY_MIN_REDUCE Reduce by rule N-YY_MIN_REDUCE
-** and YY_MAX_REDUCE
-**
-** N == YY_ERROR_ACTION A syntax error has occurred.
-**
-** N == YY_ACCEPT_ACTION The parser accepts its input.
-**
-** N == YY_NO_ACTION No such action. Denotes unused
-** slots in the yy_action[] table.
-**
-** The action table is constructed as a single large table named yy_action[].
-** Given state S and lookahead X, the action is computed as either:
-**
-** (A) N = yy_action[ yy_shift_ofst[S] + X ]
-** (B) N = yy_default[S]
-**
-** The (A) formula is preferred. The B formula is used instead if:
-** (1) The yy_shift_ofst[S]+X value is out of range, or
-** (2) yy_lookahead[yy_shift_ofst[S]+X] is not equal to X, or
-** (3) yy_shift_ofst[S] equal YY_SHIFT_USE_DFLT.
-** (Implementation note: YY_SHIFT_USE_DFLT is chosen so that
-** YY_SHIFT_USE_DFLT+X will be out of range for all possible lookaheads X.
-** Hence only tests (1) and (2) need to be evaluated.)
-**
-** The formulas above are for computing the action when the lookahead is
-** a terminal symbol. If the lookahead is a non-terminal (as occurs after
-** a reduce action) then the yy_reduce_ofst[] array is used in place of
-** the yy_shift_ofst[] array and YY_REDUCE_USE_DFLT is used in place of
-** YY_SHIFT_USE_DFLT.
-**
-** The following are the tables generated in this section:
-**
-** yy_action[] A single table containing all actions.
-** yy_lookahead[] A table containing the lookahead for each entry in
-** yy_action. Used to detect hash collisions.
-** yy_shift_ofst[] For each state, the offset into yy_action for
-** shifting terminals.
-** yy_reduce_ofst[] For each state, the offset into yy_action for
-** shifting non-terminals after a reduce.
-** yy_default[] Default action for each state.
-**
-*********** Begin parsing tables **********************************************/
-#define YY_ACTTAB_COUNT (960)
-static const YYACTIONTYPE yy_action[] = {
- /* 0 */ 394, 409, 93, 409, 409, 409, 409, 409, 409, 409,
- /* 10 */ 409, 409, 409, 93, 436, 430, 478, 164, 116, 430,
- /* 20 */ 350, 423, 15, 475, 431, 27, 27, 478, 2, 133,
- /* 30 */ 27, 27, 148, 148, 148, 148, 148, 148, 148, 148,
- /* 40 */ 148, 148, 432, 100, 48, 440, 442, 83, 29, 29,
- /* 50 */ 29, 29, 29, 29, 29, 29, 29, 29, 149, 56,
- /* 60 */ 478, 422, 107, 122, 28, 155, 90, 89, 88, 365,
- /* 70 */ 348, 397, 35, 470, 410, 43, 70, 390, 81, 67,
- /* 80 */ 65, 64, 394, 409, 47, 409, 409, 409, 409, 409,
- /* 90 */ 409, 409, 409, 409, 409, 39, 49, 11, 10, 60,
- /* 100 */ 93, 437, 430, 349, 352, 411, 430, 417, 417, 417,
- /* 110 */ 417, 417, 27, 27, 478, 405, 146, 27, 27, 148,
- /* 120 */ 148, 148, 148, 148, 148, 148, 148, 148, 148, 83,
- /* 130 */ 374, 108, 394, 409, 376, 409, 409, 409, 409, 409,
- /* 140 */ 409, 409, 409, 409, 409, 149, 405, 80, 179, 181,
- /* 150 */ 180, 28, 193, 182, 35, 425, 153, 376, 427, 390,
- /* 160 */ 81, 67, 65, 64, 359, 166, 428, 494, 77, 122,
- /* 170 */ 426, 429, 165, 122, 494, 382, 114, 410, 33, 41,
- /* 180 */ 410, 43, 394, 409, 431, 409, 409, 409, 409, 409,
- /* 190 */ 409, 409, 409, 409, 409, 158, 115, 416, 90, 89,
- /* 200 */ 88, 415, 432, 96, 34, 414, 182, 375, 134, 390,
- /* 210 */ 81, 67, 65, 64, 194, 87, 85, 178, 405, 136,
- /* 220 */ 421, 405, 167, 122, 169, 79, 137, 4, 384, 83,
- /* 230 */ 410, 43, 394, 409, 112, 409, 409, 409, 409, 409,
- /* 240 */ 409, 409, 409, 409, 409, 357, 122, 394, 90, 89,
- /* 250 */ 88, 382, 117, 182, 35, 119, 410, 43, 122, 390,
- /* 260 */ 81, 67, 65, 64, 178, 122, 379, 194, 87, 85,
- /* 270 */ 94, 405, 79, 122, 395, 385, 343, 410, 43, 76,
- /* 280 */ 479, 366, 394, 409, 122, 409, 409, 409, 409, 409,
- /* 290 */ 409, 409, 409, 409, 409, 478, 402, 405, 179, 181,
- /* 300 */ 180, 383, 349, 351, 35, 124, 410, 43, 401, 390,
- /* 310 */ 81, 67, 65, 64, 194, 87, 85, 53, 405, 131,
- /* 320 */ 419, 419, 419, 419, 390, 81, 67, 431, 68, 66,
- /* 330 */ 147, 132, 394, 409, 431, 409, 409, 409, 409, 409,
- /* 340 */ 409, 409, 409, 409, 409, 432, 97, 405, 179, 181,
- /* 350 */ 180, 38, 432, 102, 35, 124, 431, 127, 431, 390,
- /* 360 */ 81, 67, 65, 64, 36, 128, 122, 418, 419, 419,
- /* 370 */ 419, 419, 419, 122, 432, 98, 432, 104, 20, 83,
- /* 380 */ 106, 472, 394, 409, 431, 409, 409, 409, 409, 409,
- /* 390 */ 409, 409, 409, 409, 409, 122, 377, 122, 179, 181,
- /* 400 */ 180, 368, 432, 103, 35, 353, 353, 353, 353, 390,
- /* 410 */ 81, 67, 65, 64, 29, 29, 29, 29, 29, 29,
- /* 420 */ 29, 29, 29, 122, 109, 471, 356, 145, 113, 74,
- /* 430 */ 157, 161, 394, 409, 105, 409, 409, 409, 409, 409,
- /* 440 */ 409, 409, 409, 409, 409, 160, 161, 367, 179, 181,
- /* 450 */ 180, 361, 147, 147, 189, 163, 161, 42, 176, 390,
- /* 460 */ 81, 67, 65, 64, 92, 122, 177, 458, 458, 458,
- /* 470 */ 458, 458, 458, 458, 458, 458, 458, 335, 479, 82,
- /* 480 */ 123, 344, 333, 459, 334, 400, 332, 331, 37, 473,
- /* 490 */ 398, 329, 393, 19, 8, 451, 391, 118, 179, 181,
- /* 500 */ 180, 378, 2, 330, 151, 13, 461, 7, 460, 390,
- /* 510 */ 81, 67, 65, 64, 93, 479, 430, 6, 450, 84,
- /* 520 */ 430, 86, 120, 475, 44, 342, 27, 27, 478, 23,
- /* 530 */ 154, 27, 27, 141, 643, 3, 3, 45, 194, 24,
- /* 540 */ 360, 379, 121, 141, 141, 141, 141, 141, 141, 141,
- /* 550 */ 341, 183, 46, 340, 192, 479, 345, 337, 93, 373,
- /* 560 */ 430, 372, 61, 57, 430, 28, 126, 475, 125, 58,
- /* 570 */ 27, 27, 478, 59, 130, 27, 27, 141, 419, 419,
- /* 580 */ 419, 419, 31, 16, 32, 469, 631, 141, 141, 141,
- /* 590 */ 141, 141, 141, 141, 29, 29, 29, 29, 29, 29,
- /* 600 */ 29, 29, 29, 29, 93, 637, 430, 71, 468, 28,
- /* 610 */ 430, 447, 446, 475, 462, 12, 27, 27, 478, 369,
- /* 620 */ 139, 27, 27, 141, 40, 448, 419, 419, 419, 419,
- /* 630 */ 419, 14, 5, 141, 141, 141, 141, 141, 141, 141,
- /* 640 */ 449, 143, 418, 50, 129, 51, 26, 364, 369, 9,
- /* 650 */ 17, 363, 152, 72, 18, 28, 29, 29, 29, 29,
- /* 660 */ 29, 29, 29, 29, 29, 29, 196, 483, 484, 156,
- /* 670 */ 93, 52, 430, 95, 190, 170, 430, 73, 159, 63,
- /* 680 */ 1, 479, 27, 27, 478, 162, 75, 27, 27, 69,
- /* 690 */ 68, 54, 522, 355, 354, 196, 483, 484, 62, 168,
- /* 700 */ 78, 25, 95, 190, 170, 389, 335, 171, 63, 1,
- /* 710 */ 172, 333, 173, 334, 141, 332, 331, 174, 69, 68,
- /* 720 */ 329, 28, 19, 175, 141, 141, 141, 141, 141, 141,
- /* 730 */ 141, 387, 330, 151, 150, 29, 29, 29, 29, 29,
- /* 740 */ 29, 29, 29, 29, 29, 431, 386, 494, 408, 407,
- /* 750 */ 185, 406, 432, 101, 358, 439, 441, 140, 184, 438,
- /* 760 */ 452, 110, 339, 432, 99, 482, 186, 194, 144, 142,
- /* 770 */ 187, 431, 188, 122, 456, 91, 463, 371, 191, 30,
- /* 780 */ 55, 433, 147, 140, 122, 328, 195, 487, 487, 432,
- /* 790 */ 99, 487, 487, 150, 487, 39, 49, 11, 10, 60,
- /* 800 */ 465, 111, 463, 150, 487, 487, 487, 487, 147, 487,
- /* 810 */ 122, 432, 101, 413, 439, 441, 487, 487, 438, 453,
- /* 820 */ 487, 432, 101, 487, 439, 441, 150, 487, 438, 445,
- /* 830 */ 487, 487, 122, 487, 487, 487, 487, 487, 431, 487,
- /* 840 */ 487, 431, 122, 487, 432, 101, 487, 439, 441, 487,
- /* 850 */ 140, 438, 138, 140, 487, 487, 432, 99, 487, 432,
- /* 860 */ 99, 487, 487, 487, 487, 122, 487, 135, 487, 463,
- /* 870 */ 467, 431, 463, 487, 431, 147, 487, 122, 147, 487,
- /* 880 */ 122, 487, 487, 140, 487, 487, 140, 487, 487, 432,
- /* 890 */ 99, 487, 432, 99, 487, 487, 487, 487, 487, 487,
- /* 900 */ 466, 487, 463, 457, 487, 463, 487, 487, 147, 487,
- /* 910 */ 122, 147, 487, 122, 487, 21, 424, 487, 487, 427,
- /* 920 */ 487, 487, 22, 424, 487, 487, 427, 428, 487, 487,
- /* 930 */ 487, 426, 429, 487, 428, 487, 487, 487, 426, 429,
- /* 940 */ 487, 39, 49, 11, 10, 60, 487, 487, 487, 487,
- /* 950 */ 487, 487, 487, 487, 487, 487, 487, 487, 487, 412,
+#define YYTRANSLATE(YYX) \
+ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
+
+/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
+static const unsigned char yytranslate[] =
+{
+ 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
+ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
+ 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
+ 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
+ 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
+ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
+ 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
+ 65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
+ 75, 76, 77, 78, 79, 80, 81, 82, 83, 84,
+ 85, 86, 87, 88, 89, 90, 91, 92, 93, 94,
+ 95, 96, 97, 98, 99, 100, 101, 102, 103, 104,
+ 105, 106, 107, 108, 109, 110, 111, 112, 113, 114,
+ 115, 116, 117, 118, 119, 120, 121, 122, 123, 124,
+ 125, 126, 127, 128, 129, 130, 131, 132, 133, 134,
+ 135, 136, 137, 138, 139
};
-static const YYCODETYPE yy_lookahead[] = {
- /* 0 */ 2, 3, 14, 5, 6, 7, 8, 9, 10, 11,
- /* 10 */ 12, 13, 14, 14, 15, 16, 28, 143, 144, 20,
- /* 20 */ 63, 118, 23, 23, 105, 26, 27, 28, 71, 14,
- /* 30 */ 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
- /* 40 */ 41, 42, 123, 124, 141, 126, 127, 49, 21, 22,
- /* 50 */ 23, 24, 25, 26, 27, 28, 29, 30, 59, 60,
- /* 60 */ 28, 118, 119, 144, 65, 103, 68, 69, 70, 107,
- /* 70 */ 72, 5, 74, 63, 112, 113, 66, 79, 80, 81,
- /* 80 */ 82, 83, 2, 3, 141, 5, 6, 7, 8, 9,
- /* 90 */ 10, 11, 12, 13, 14, 54, 55, 56, 57, 58,
- /* 100 */ 14, 15, 16, 91, 92, 112, 20, 15, 16, 17,
- /* 110 */ 18, 19, 26, 27, 28, 153, 157, 31, 32, 33,
- /* 120 */ 34, 35, 36, 37, 38, 39, 40, 41, 42, 49,
- /* 130 */ 105, 106, 2, 3, 105, 5, 6, 7, 8, 9,
- /* 140 */ 10, 11, 12, 13, 14, 59, 153, 81, 68, 69,
- /* 150 */ 70, 65, 14, 88, 74, 122, 76, 105, 125, 79,
- /* 160 */ 80, 81, 82, 83, 99, 100, 133, 64, 103, 144,
- /* 170 */ 137, 138, 107, 144, 71, 107, 108, 112, 113, 49,
- /* 180 */ 112, 113, 2, 3, 105, 5, 6, 7, 8, 9,
- /* 190 */ 10, 11, 12, 13, 14, 143, 144, 141, 68, 69,
- /* 200 */ 70, 141, 123, 124, 74, 141, 88, 105, 136, 79,
- /* 210 */ 80, 81, 82, 83, 149, 150, 151, 99, 153, 105,
- /* 220 */ 116, 153, 116, 144, 96, 107, 105, 109, 110, 49,
- /* 230 */ 112, 113, 2, 3, 105, 5, 6, 7, 8, 9,
- /* 240 */ 10, 11, 12, 13, 14, 105, 144, 2, 68, 69,
- /* 250 */ 70, 107, 108, 88, 74, 144, 112, 113, 144, 79,
- /* 260 */ 80, 81, 82, 83, 99, 144, 14, 149, 150, 151,
- /* 270 */ 66, 153, 107, 144, 155, 110, 72, 112, 113, 49,
- /* 280 */ 28, 14, 2, 3, 144, 5, 6, 7, 8, 9,
- /* 290 */ 10, 11, 12, 13, 14, 28, 153, 153, 68, 69,
- /* 300 */ 70, 107, 91, 92, 74, 117, 112, 113, 153, 79,
- /* 310 */ 80, 81, 82, 83, 149, 150, 151, 65, 153, 142,
- /* 320 */ 1, 2, 3, 4, 79, 80, 81, 105, 85, 49,
- /* 330 */ 142, 115, 2, 3, 105, 5, 6, 7, 8, 9,
- /* 340 */ 10, 11, 12, 13, 14, 123, 124, 153, 68, 69,
- /* 350 */ 70, 142, 123, 124, 74, 117, 105, 76, 105, 79,
- /* 360 */ 80, 81, 82, 83, 66, 67, 144, 86, 49, 50,
- /* 370 */ 51, 52, 53, 144, 123, 124, 123, 124, 65, 49,
- /* 380 */ 142, 140, 2, 3, 105, 5, 6, 7, 8, 9,
- /* 390 */ 10, 11, 12, 13, 14, 144, 101, 144, 68, 69,
- /* 400 */ 70, 101, 123, 124, 74, 1, 2, 3, 4, 79,
- /* 410 */ 80, 81, 82, 83, 22, 23, 24, 25, 26, 27,
- /* 420 */ 28, 29, 30, 144, 139, 140, 105, 117, 117, 49,
- /* 430 */ 143, 144, 2, 3, 144, 5, 6, 7, 8, 9,
- /* 440 */ 10, 11, 12, 13, 14, 143, 144, 101, 68, 69,
- /* 450 */ 70, 101, 142, 142, 64, 143, 144, 94, 64, 79,
- /* 460 */ 80, 81, 82, 83, 14, 144, 111, 33, 34, 35,
- /* 470 */ 36, 37, 38, 39, 40, 41, 42, 88, 28, 49,
- /* 480 */ 89, 90, 93, 49, 95, 2, 97, 98, 66, 67,
- /* 490 */ 156, 102, 2, 104, 66, 67, 154, 144, 68, 69,
- /* 500 */ 70, 14, 71, 114, 115, 66, 67, 66, 67, 79,
- /* 510 */ 80, 81, 82, 83, 14, 28, 16, 66, 67, 94,
- /* 520 */ 20, 94, 14, 23, 91, 148, 26, 27, 28, 66,
- /* 530 */ 67, 31, 32, 33, 145, 146, 147, 91, 149, 66,
- /* 540 */ 67, 14, 14, 43, 44, 45, 46, 47, 48, 49,
- /* 550 */ 148, 14, 94, 148, 77, 28, 90, 14, 14, 152,
- /* 560 */ 16, 152, 73, 64, 20, 65, 86, 23, 67, 64,
- /* 570 */ 26, 27, 28, 64, 20, 31, 32, 33, 1, 2,
- /* 580 */ 3, 4, 65, 71, 65, 63, 86, 43, 44, 45,
- /* 590 */ 46, 47, 48, 49, 21, 22, 23, 24, 25, 26,
- /* 600 */ 27, 28, 29, 30, 14, 0, 16, 73, 63, 65,
- /* 610 */ 20, 63, 63, 23, 67, 73, 26, 27, 28, 14,
- /* 620 */ 76, 31, 32, 33, 65, 67, 49, 50, 51, 52,
- /* 630 */ 53, 66, 65, 43, 44, 45, 46, 47, 48, 49,
- /* 640 */ 67, 67, 86, 65, 67, 65, 65, 63, 14, 73,
- /* 650 */ 71, 63, 67, 67, 65, 65, 21, 22, 23, 24,
- /* 660 */ 25, 26, 27, 28, 29, 30, 61, 62, 63, 14,
- /* 670 */ 14, 65, 16, 68, 69, 70, 20, 67, 14, 74,
- /* 680 */ 75, 28, 26, 27, 28, 14, 67, 31, 32, 84,
- /* 690 */ 85, 65, 65, 63, 63, 61, 62, 63, 73, 20,
- /* 700 */ 14, 66, 68, 69, 70, 67, 88, 16, 74, 75,
- /* 710 */ 66, 93, 16, 95, 33, 97, 98, 65, 84, 85,
- /* 720 */ 102, 65, 104, 64, 43, 44, 45, 46, 47, 48,
- /* 730 */ 49, 63, 114, 115, 105, 21, 22, 23, 24, 25,
- /* 740 */ 26, 27, 28, 29, 30, 105, 63, 71, 14, 14,
- /* 750 */ 66, 14, 123, 124, 14, 126, 127, 117, 16, 130,
- /* 760 */ 131, 132, 67, 123, 124, 147, 16, 149, 128, 129,
- /* 770 */ 65, 105, 64, 144, 134, 14, 136, 78, 16, 73,
- /* 780 */ 71, 67, 142, 117, 144, 63, 19, 158, 158, 123,
- /* 790 */ 124, 158, 158, 105, 158, 54, 55, 56, 57, 58,
- /* 800 */ 134, 135, 136, 105, 158, 158, 158, 158, 142, 158,
- /* 810 */ 144, 123, 124, 72, 126, 127, 158, 158, 130, 131,
- /* 820 */ 158, 123, 124, 158, 126, 127, 105, 158, 130, 131,
- /* 830 */ 158, 158, 144, 158, 158, 158, 158, 158, 105, 158,
- /* 840 */ 158, 105, 144, 158, 123, 124, 158, 126, 127, 158,
- /* 850 */ 117, 130, 131, 117, 158, 158, 123, 124, 158, 123,
- /* 860 */ 124, 158, 158, 158, 158, 144, 158, 134, 158, 136,
- /* 870 */ 134, 105, 136, 158, 105, 142, 158, 144, 142, 158,
- /* 880 */ 144, 158, 158, 117, 158, 158, 117, 158, 158, 123,
- /* 890 */ 124, 158, 123, 124, 158, 158, 158, 158, 158, 158,
- /* 900 */ 134, 158, 136, 134, 158, 136, 158, 158, 142, 158,
- /* 910 */ 144, 142, 158, 144, 158, 121, 122, 158, 158, 125,
- /* 920 */ 158, 158, 121, 122, 158, 158, 125, 133, 158, 158,
- /* 930 */ 158, 137, 138, 158, 133, 158, 158, 158, 137, 138,
- /* 940 */ 158, 54, 55, 56, 57, 58, 158, 158, 158, 158,
- /* 950 */ 158, 158, 158, 158, 158, 158, 158, 158, 158, 72,
+
+#if YYDEBUG
+/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
+static const unsigned short int yyrline[] =
+{
+ 0, 424, 424, 424, 424, 424, 424, 424, 424, 424,
+ 424, 424, 424, 424, 424, 424, 424, 424, 424, 424,
+ 425, 425, 425, 425, 426, 426, 426, 426, 426, 426,
+ 426, 426, 426, 426, 426, 426, 426, 426, 426, 426,
+ 426, 426, 426, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 427, 427, 427, 427, 427, 427, 427, 427, 427,
+ 427, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 428, 428, 428,
+ 428, 428, 428, 428, 428, 428, 428, 432, 433, 436,
+ 437, 440, 441, 442, 443, 449, 457, 460, 463, 464,
+ 465, 468, 471, 474, 477, 483, 489, 492, 498, 521,
+ 525, 529, 534, 538, 542, 546, 553, 554, 558, 559,
+ 563, 564, 565, 569, 570, 574, 575, 579, 580, 581,
+ 585, 586, 590, 591, 592, 593, 594, 595, 596, 600,
+ 605, 613, 616, 619, 620, 626, 631, 639, 642, 646,
+ 650, 657, 661, 665, 669, 674, 684, 694, 699, 704,
+ 708, 714, 723, 726, 730, 734, 740, 747, 753, 754,
+ 755, 756, 760, 763, 794, 801, 802, 803, 804, 808,
+ 811, 820, 826, 829, 835, 838, 844, 845, 853, 864,
+ 873, 885, 886, 890, 900, 909, 921, 924, 927, 931,
+ 935, 939, 944, 949, 957, 958, 959, 965, 968, 971,
+ 977, 978, 982, 985, 988, 994, 997, 1000, 1008, 1020,
+ 1023, 1026, 1029, 1036, 1039, 1049, 1052, 1055, 1058, 1059,
+ 1060, 1064, 1067, 1070, 1081, 1084, 1090, 1091, 1095, 1096,
+ 1100, 1104, 1110, 1111, 1117, 1120, 1126, 1129, 1132, 1138,
+ 1142, 1143, 1147, 1148, 1152, 1153, 1160, 1161, 1165, 1172,
+ 1183, 1190, 1201, 1208, 1219, 1230, 1244, 1245, 1257, 1260,
+ 1263, 1269, 1272, 1279, 1282, 1288, 1297, 1309, 1317, 1320,
+ 1330, 1343, 1348, 1356, 1366, 1376, 1379, 1383, 1389, 1403,
+ 1420, 1423, 1429, 1436, 1446, 1453, 1456, 1462, 1467, 1475,
+ 1479, 1483, 1487, 1491, 1495, 1502, 1506, 1510, 1514, 1518,
+ 1522, 1528, 1532, 1539, 1542, 1554, 1558, 1562, 1568, 1581,
+ 1594, 1607, 1610, 1617, 1618, 1622, 1625, 1628, 1631, 1637,
+ 1641, 1648, 1651, 1654, 1657, 1668, 1671, 1677, 1678, 1684,
+ 1687, 1693, 1694, 1704, 1707, 1714, 1719, 1724, 1734, 1737,
+ 1743, 1746, 1752, 1759, 1766, 1767, 1768, 1769, 1770, 1771,
+ 1772, 1773, 1774, 1778, 1781, 1787, 1790, 1793, 1796, 1799,
+ 1805, 1809, 1817, 1818, 1822, 1829, 1832, 1835, 1838, 1842,
+ 1845, 1851, 1855, 1863, 1870, 1875, 1883, 1891, 1892, 1893,
+ 1894, 1895, 1896, 1897, 1898, 1899, 1900, 1904, 1907, 1913,
+ 1916, 1922, 1923, 1927, 1930, 1936, 1939, 1945, 1952, 1956,
+ 1963, 1966, 1969, 1975, 1982, 1985, 1988, 1995, 2000, 2008,
+ 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2019, 2022, 2028,
+ 2031, 2037, 2044, 2045, 2049, 2056, 2059, 2065, 2073, 2076,
+ 2082
};
-#define YY_SHIFT_USE_DFLT (960)
-#define YY_SHIFT_COUNT (196)
-#define YY_SHIFT_MIN (-43)
-#define YY_SHIFT_MAX (887)
-static const short yy_shift_ofst[] = {
- /* 0 */ 634, 130, 180, 605, -2, 500, -1, 544, -1, -1,
- /* 10 */ -1, 590, 590, 590, 590, 86, 41, 41, 230, 280,
- /* 20 */ 230, 741, 887, 80, 330, 656, 656, 656, 656, 656,
- /* 30 */ 656, 577, -12, -12, 380, 430, 319, -12, -12, -12,
- /* 40 */ -12, 267, -43, -12, -12, -12, -43, 0, 0, 15,
- /* 50 */ 0, 0, 32, 32, 32, 138, 434, 319, 319, 319,
- /* 60 */ 681, 92, 92, 404, 245, 245, 267, 66, 0, 243,
- /* 70 */ 15, 0, 313, 313, 32, 313, 32, 313, 390, 394,
- /* 80 */ 483, 490, 32, 32, 431, 390, 431, 390, 508, 528,
- /* 90 */ 537, 390, 477, 477, 138, 543, 573, 635, 714, 27,
- /* 100 */ 27, 27, 27, 27, 392, 252, 281, 298, 422, 10,
- /* 110 */ 428, 439, 441, 451, 463, 450, 487, 473, 527, 487,
- /* 120 */ 103, 103, 450, 204, 489, 499, 501, 480, 505, 509,
- /* 130 */ 517, 554, 512, 519, 522, 545, 548, 534, 549, 547,
- /* 140 */ 542, 559, 565, 558, 574, 567, 578, 556, 580, 581,
- /* 150 */ 576, 579, 584, 585, 588, 589, 586, 655, 606, 610,
- /* 160 */ 664, 653, 619, 671, 626, 627, 630, 631, 625, 679,
- /* 170 */ 686, 638, 691, 644, 696, 652, 659, 668, 683, 734,
- /* 180 */ 735, 737, 740, 676, 695, 742, 684, 750, 705, 708,
- /* 190 */ 761, 699, 762, 706, 709, 722, 767,
+#endif
+
+#if YYDEBUG || YYERROR_VERBOSE || 1
+/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
+ First, the terminals, then, starting at YYNTOKENS, nonterminals. */
+static const char *const yytname[] =
+{
+ "\"end of file\"", "error", "$undefined", "BOOL", "CHAR", "SHORT",
+ "INT", "SIGNED", "UNSIGNED", "LONG", "FLOAT", "DOUBLE", "STRING",
+ "MIXED", "ARRAY", "OBJECT", "CALLABLE", "VOID", "ZVAL", "NULL", "TRUE",
+ "FALSE", "NAME", "NSNAME", "DOLLAR_NAME", "NUMBER", "QUOTED_STRING",
+ "QUOTED_CHAR", "SIZEOF", "VOLATILE", "\"end of line\"", "\";\"", "\"(\"",
+ "\")\"", "\",\"", "\":\"", "\"{\"", "\"}\"", "\"[\"", "\"]\"", "\"=\"",
+ "\"#\"", "\"|\"", "\"^\"", "\"&\"", "\"<<\"", "\">>\"", "\"+\"", "\"-\"",
+ "\"*\"", "\"/\"", "\"%\"", "\"<\"", "\">\"", "\">=\"", "\"<=\"",
+ "\"||\"", "\"&&\"", "\"==\"", "\"!=\"", "\"~\"", "\"!\"", "\".\"",
+ "\"\\\\\"", "\"...\"", "\"?\"", "PRAGMA", "PRAGMA_ONCE", "LINE", "ERROR",
+ "WARNING", "IF", "IFDEF", "IFNDEF", "ELSE", "ELIF", "ENDIF", "DEFINE",
+ "DEFINED", "UNDEF", "IMPORT", "INCLUDE", "INCLUDE_NEXT", "TYPEDEF",
+ "STRUCT", "UNION", "ENUM", "CONST", "LIB", "STATIC", "CALLBACK",
+ "FUNCTION", "LET", "SET", "TEMP", "FREE", "RETURN", "AS", "PRE_ASSERT",
+ "POST_ASSERT", "BOOLVAL", "INTVAL", "STRVAL", "PATHVAL", "STRLEN",
+ "FLOATVAL", "ARRVAL", "OBJVAL", "COUNT", "CALLOC", "TO_BOOL", "TO_INT",
+ "TO_STRING", "TO_FLOAT", "TO_ARRAY", "TO_OBJECT", "COMMENT",
+ "WHITESPACE", "NO_WHITESPACE", "CPP_HEADER", "CPP_ATTRIBUTE",
+ "CPP_EXTENSION", "CPP_PASTE", "CPP_INLINE", "CPP_RESTRICT", "CPP_ASM",
+ "BSLASH", "LONG_DOUBLE", "INT8", "UINT8", "INT16", "UINT16", "INT32",
+ "UINT32", "INT64", "UINT64", "INT128", "UINT128", "BINARY", "UNARY",
+ "$accept", "binary_op_token", "unary_op_token", "name_token",
+ "any_noeol_token", "any_nobrace_token", "file", "blocks", "block", "lib",
+ "cpp", "cpp_exp", "cpp_ignored_token", "cpp_message_token",
+ "cpp_include_token", "cpp_header_token", "cpp_no_arg_token",
+ "cpp_name_arg_token", "cpp_exp_arg_token", "cpp_special_name_token",
+ "cpp_macro_decl", "cpp_macro_sig", "cpp_macro_sig_args",
+ "cpp_macro_decl_tokens", "cpp_macro_decl_token_list", "cpp_macro_exp",
+ "cpp_macro_call_args", "cpp_macro_call_arg_list", "constant",
+ "constant_type", "constant_type_token", "impl_def_val",
+ "impl_def_val_token", "decl_typedef", "typedef", "typedef_anon",
+ "typedef_decl", "typedef_anon_decl", "qualified_decl_type", "decl_type",
+ "decl_type_complex", "decl_type_simple", "decl_real_type", "int_signed",
+ "int_width", "decl_int_type", "int_signed_types", "signed_short_types",
+ "signed_long_types", "int_width_types", "decl_stmt", "decl_asm",
+ "ignored_quoted_strings", "decl_ext_var_stmt", "decl_ext_var",
+ "decl_ext_var_list", "decl_vars", "ignored_decl", "ignored_decl_body",
+ "ignored_decl_body_stmts", "ignored_decl_body_stmt", "decl", "decl_body",
+ "decl_func_body", "decl_functor_body", "decl_functor", "decl_func",
+ "decl_args", "decl_arg_list", "decl_anon_arg", "decl_arg", "decl_var",
+ "decl_union", "decl_struct", "decl_struct_args", "struct_args_block",
+ "struct_args", "struct_arg_var_list", "decl_vars_with_layout",
+ "decl_enum", "decl_enum_items", "decl_enum_item", "num_exp", "number",
+ "sizeof", "sizeof_body", "sizeof_body_notypes", "enum_name",
+ "union_name", "struct_name", "optional_name", "optional_comma",
+ "decl_layout", "align_and_size", "array_size", "indirection", "pointers",
+ "asterisks", "asterisk", "impl", "impl_func", "impl_args", "impl_arg",
+ "impl_var", "impl_type", "impl_type_token", "impl_stmts", "impl_stmt",
+ "let_stmt", "let_exp", "let_exp_byref", "let_exp_assign", "let_calloc",
+ "let_callback", "let_func", "let_func_token", "let_func_exps",
+ "let_exps", "callback_rval", "callback_arg_list", "callback_args",
+ "return_stmt", "return_exp", "call_decl_vars", "set_stmt", "set_exp",
+ "set_func", "set_func_token", "set_func_exps", "set_exps", "assert_stmt",
+ "assert_stmt_token", "free_stmt", "free_exps", "free_exp", "reference",
+ "byref", YY_NULLPTR
};
-#define YY_REDUCE_USE_DFLT (-127)
-#define YY_REDUCE_COUNT (95)
-#define YY_REDUCE_MIN (-126)
-#define YY_REDUCE_MAX (801)
-static const short yy_reduce_ofst[] = {
- /* 0 */ 389, 65, 118, 618, 165, 640, 629, 666, 688, 698,
- /* 10 */ 721, 733, 736, 766, 769, -81, 794, 801, 68, -38,
- /* 20 */ 144, 33, 33, 194, 194, 79, 222, 229, 251, 253,
- /* 30 */ 279, -57, 25, 52, -7, -7, -97, 102, 114, 121,
- /* 40 */ 129, -126, 12, 29, 140, 321, 211, 188, 238, 285,
- /* 50 */ 310, 311, 287, 302, 312, 391, -41, 56, 60, 64,
- /* 60 */ 72, 104, 106, 128, 143, 155, 111, 119, 177, 216,
- /* 70 */ 241, 209, 295, 300, 290, 346, 111, 350, 363, 355,
- /* 80 */ 334, 342, 353, 111, 433, 425, 446, 427, 377, 402,
- /* 90 */ 405, 458, 407, 409, 466, 405,
+#endif
+
+#define YYPACT_NINF -699
+#define YYTABLE_NINF -629
+
+ /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
+ STATE-NUM. */
+static const short int yypact[] =
+{
+ 497, -699, -699, -699, -699, -699, 60, -699, -699, 2504,
+ 1667, 2537, -699, -699, 754, 466, 3359, 3359, 3359, 71,
+ 25, 265, 51, -699, 1634, 1893, 42, 497, -699, -699,
+ -699, -699, -699, 2730, -699, -699, -699, -699, 284, 79,
+ -699, -699, -699, 68, -699, -20, -699, -699, 87, 99,
+ 107, -699, -699, -699, -699, 113, -699, 115, -699, -699,
+ -699, -699, -699, 842, -699, 110, 75, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, 2843, 10, -699,
+ -699, -699, -699, 3359, 3359, 3359, 661, -699, 88, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, 688, -699, -699, -699, -699, 149, 968, 968,
+ 24, -699, 688, 2391, 2504, 3359, 3359, 2006, 143, -699,
+ -699, -699, 157, 3359, 146, 146, 111, 111, 169, -699,
+ -699, 191, 200, -699, 110, 202, -699, -699, 196, 1893,
+ 193, 198, -699, 212, -699, 2119, 1401, -20, 193, -699,
+ -699, 205, -699, 204, 3359, -699, 234, -699, 100, -699,
+ -699, -699, 359, -699, -699, 213, 215, 2311, 2311, 3359,
+ 478, 3359, -699, -699, 110, -699, -699, -699, -699, -699,
+ -699, 2730, -699, -699, -699, -699, -699, -699, -699, 129,
+ 968, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, 968, -699, -699, -699, -699, -699, -699,
+ -699, -699, 126, 2391, -699, -699, -699, -699, 2956, 2391,
+ 225, 3513, -699, 227, 102, -699, 136, -699, -699, -699,
+ -699, 209, 224, 224, 58, 58, 3069, 221, -699, 193,
+ 1220, -699, 478, 231, 233, 235, -699, 1334, -699, 110,
+ 205, -699, -699, -699, 261, -699, -699, 242, -699, 16,
+ 755, 2730, 144, 251, -699, -699, 154, 246, 257, -699,
+ 2730, 2052, 2730, 3359, 2730, -699, -699, 18, -699, -699,
+ -699, -699, -699, 2278, -699, 259, 3359, 270, -699, 3359,
+ 273, -699, -699, -699, -699, 635, 285, -699, 2834, 3359,
+ -699, -699, 2391, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, 2391, 2391, -699, 276, 1446, 2730, 2730, -699, -699,
+ -699, -699, 110, -699, 1600, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, -699, 1094, -699, 185, 527, -699, -699,
+ -699, -699, -699, -699, 1487, -699, 271, 2278, -699, 3489,
+ -699, -699, 3359, -699, -699, -699, 40, 2843, 110, 204,
+ 205, 247, 2345, 205, 248, 2278, 3359, 279, 277, 289,
+ 3537, 287, 293, -699, 296, 301, 291, 305, 114, -699,
+ 306, 312, -699, -699, -699, 2712, -699, 311, 2730, 3128,
+ 110, 313, -699, -699, -699, 314, 3513, 315, 319, 3440,
+ -699, 330, 2006, 322, -699, -699, 2617, 292, 3359, 146,
+ 146, -699, -699, 3359, 162, -699, -699, -699, 329, -699,
+ 3537, -699, -699, -699, -699, -699, -699, -699, -699, -699,
+ -699, -699, -699, 326, 164, -699, 51, -699, 333, 2537,
+ 337, 2947, -699, -699, -699, 2278, 2278, 339, -699, -699,
+ 3069, -699, 340, 16, -699, -699, 341, 3537, -699, -699,
+ 1713, -699, 2052, -699, 2730, -699, 51, 2730, -699, 3359,
+ 3241, -699, -699, -699, -699, -699, -699, 347, 328, -699,
+ -699, -699, -699, 2391, 2391, 348, -699, 37, 349, -699,
+ 322, 224, 224, 351, -699, 725, 354, 725, 346, 2278,
+ -699, 3465, -699, -699, 205, 205, 176, 281, 461, 360,
+ 3537, -699, -699, -699, -699, 362, 2165, -699, 361, 2730,
+ 170, -699, 364, 270, 365, 968, 3300, 3513, 3561, 374,
+ 367, 368, 2730, 372, 349, 2730, 2730, -699, -699, 725,
+ -699, 51, 1600, -699, 2278, -699, -699, 360, -699, -699,
+ -699, 3241, -699, 376, 2278, 51, -699, 1826, 378, 383,
+ -699, 318, -699, -699, -699, 384, 381, 393, 322, 385,
+ -699, 389, -699, 39, -699, 3585, 394, 51, 3222, 395,
+ 397, -699, 398, -699, -699, 106, -699, 396, 399, -699,
+ 2730, -699, 407, 338, 405, 2278, 1713, 406, -699, 2052,
+ -699, -699, 409, 421, 422, 322, 416, 148, 1939, 3060,
+ 277, -699, -699, -699, 423, 2165, -699, -699, 425, 427,
+ -699, 420, 424, 431, 432, -699, -699, 1713, -699, 440,
+ -699, 725, 51, 434, 2052, -699, 436, -699, 448, -699,
+ -699, -699, 1939, 451, 452, -699
};
-static const YYACTIONTYPE yy_default[] = {
- /* 0 */ 642, 642, 642, 642, 642, 611, 642, 631, 642, 642,
- /* 10 */ 642, 631, 631, 631, 631, 642, 642, 642, 537, 642,
- /* 20 */ 537, 642, 642, 642, 642, 642, 642, 642, 642, 642,
- /* 30 */ 642, 642, 642, 633, 642, 642, 642, 642, 642, 642,
- /* 40 */ 642, 633, 642, 642, 642, 642, 642, 631, 631, 642,
- /* 50 */ 631, 631, 633, 633, 633, 642, 642, 642, 642, 642,
- /* 60 */ 642, 642, 642, 642, 561, 560, 642, 553, 631, 642,
- /* 70 */ 642, 631, 642, 642, 642, 642, 538, 642, 495, 545,
- /* 80 */ 556, 549, 642, 642, 642, 495, 642, 495, 493, 493,
- /* 90 */ 493, 495, 527, 527, 642, 493, 642, 642, 642, 621,
- /* 100 */ 601, 600, 592, 503, 591, 642, 642, 642, 642, 642,
- /* 110 */ 642, 642, 642, 642, 642, 634, 634, 642, 642, 642,
- /* 120 */ 564, 563, 642, 642, 577, 642, 642, 642, 642, 642,
- /* 130 */ 642, 642, 642, 642, 642, 642, 642, 642, 642, 642,
- /* 140 */ 642, 642, 612, 642, 642, 642, 642, 642, 642, 642,
- /* 150 */ 588, 642, 642, 642, 642, 642, 642, 642, 642, 642,
- /* 160 */ 642, 634, 642, 642, 642, 519, 642, 642, 642, 642,
- /* 170 */ 642, 642, 642, 642, 642, 642, 642, 642, 642, 642,
- /* 180 */ 642, 642, 642, 565, 642, 642, 642, 642, 642, 642,
- /* 190 */ 642, 642, 642, 504, 642, 642, 642,
+
+ /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
+ Performed when YYTABLE does not specify something else to do. Zero
+ means the default is an error. */
+static const unsigned short int yydefact[] =
+{
+ 277, 405, 402, 406, 400, 401, 403, 397, 398, 0,
+ 396, 0, 282, 281, 0, 0, 0, 0, 511, 0,
+ 0, 0, 628, 283, 0, 0, 0, 278, 279, 285,
+ 284, 286, 290, 525, 388, 390, 389, 395, 409, 421,
+ 394, 287, 289, 0, 288, 426, 444, 446, 447, 0,
+ 0, 456, 292, 291, 293, 0, 294, 0, 404, 399,
+ 33, 34, 616, 577, 24, 525, 531, 39, 38, 37,
+ 35, 36, 32, 31, 25, 29, 28, 26, 27, 40,
+ 585, 584, 582, 580, 581, 583, 579, 578, 586, 30,
+ 614, 612, 611, 613, 610, 609, 457, 0, 527, 529,
+ 41, 42, 396, 0, 0, 0, 0, 445, 432, 387,
+ 296, 307, 304, 306, 308, 309, 320, 317, 318, 315,
+ 321, 316, 0, 319, 310, 311, 312, 0, 337, 337,
+ 0, 300, 0, 0, 0, 511, 511, 0, 0, 372,
+ 377, 467, 376, 0, 519, 519, 391, 392, 393, 508,
+ 358, 406, 397, 361, 0, 0, 357, 386, 0, 0,
+ 0, 0, 630, 0, 629, 396, 0, 426, 0, 1,
+ 280, 521, 468, 0, 526, 411, 415, 413, 417, 410,
+ 407, 422, 409, 408, 430, 0, 0, 458, 458, 0,
+ 0, 0, 526, 532, 525, 470, 528, 530, 391, 392,
+ 393, 0, 431, 323, 324, 325, 327, 328, 326, 322,
+ 337, 302, 297, 68, 43, 44, 45, 46, 47, 48,
+ 49, 50, 51, 52, 53, 54, 55, 56, 57, 58,
+ 59, 60, 61, 62, 63, 64, 65, 66, 67, 158,
+ 159, 69, 70, 71, 72, 73, 74, 75, 76, 77,
+ 78, 79, 80, 81, 82, 83, 84, 85, 86, 87,
+ 88, 89, 90, 91, 92, 93, 94, 95, 96, 97,
+ 98, 99, 100, 101, 102, 108, 106, 107, 105, 103,
+ 104, 109, 110, 111, 112, 113, 114, 115, 116, 117,
+ 118, 119, 120, 121, 122, 123, 124, 125, 126, 127,
+ 128, 129, 130, 131, 132, 160, 133, 134, 135, 136,
+ 137, 138, 139, 140, 141, 142, 143, 144, 145, 146,
+ 147, 148, 149, 150, 151, 152, 156, 153, 154, 155,
+ 157, 339, 305, 338, 298, 313, 314, 299, 322, 301,
+ 347, 348, 0, 0, 22, 23, 20, 21, 0, 0,
+ 350, 303, 349, 457, 391, 510, 392, 509, 373, 369,
+ 378, 0, 0, 0, 0, 0, 0, 0, 295, 0,
+ 0, 436, 0, 0, 0, 0, 437, 0, 472, 525,
+ 521, 416, 412, 418, 419, 414, 423, 0, 424, 459,
+ 0, 525, 0, 460, 461, 463, 0, 487, 513, 485,
+ 0, 628, 0, 0, 0, 622, 623, 0, 553, 556,
+ 555, 557, 558, 0, 559, 0, 0, 433, 434, 0,
+ 0, 330, 340, 507, 506, 0, 0, 502, 0, 0,
+ 345, 342, 352, 2, 3, 4, 5, 6, 7, 8,
+ 9, 10, 11, 13, 12, 14, 15, 16, 17, 18,
+ 19, 0, 0, 370, 0, 0, 0, 0, 475, 474,
+ 476, 473, 525, 469, 362, 438, 186, 161, 162, 163,
+ 164, 165, 166, 167, 168, 169, 170, 171, 172, 173,
+ 174, 175, 176, 177, 178, 179, 180, 181, 182, 183,
+ 184, 185, 274, 275, 187, 188, 189, 190, 191, 192,
+ 193, 194, 195, 196, 197, 198, 199, 200, 201, 202,
+ 203, 204, 205, 206, 207, 208, 209, 210, 211, 212,
+ 213, 214, 215, 216, 217, 218, 224, 222, 223, 221,
+ 219, 220, 225, 226, 227, 228, 229, 230, 231, 232,
+ 233, 234, 235, 236, 237, 238, 239, 240, 241, 242,
+ 243, 244, 245, 246, 247, 248, 276, 249, 250, 251,
+ 252, 253, 254, 255, 256, 257, 258, 259, 260, 261,
+ 262, 263, 264, 265, 266, 267, 268, 272, 269, 270,
+ 271, 273, 442, 443, 0, 440, 0, 0, 371, 425,
+ 498, 496, 495, 497, 0, 522, 0, 0, 499, 0,
+ 489, 500, 0, 471, 420, 428, 0, 466, 0, 464,
+ 521, 0, 0, 521, 0, 0, 514, 0, 0, 0,
+ 605, 0, 0, 604, 42, 0, 0, 0, 0, 625,
+ 0, 0, 599, 533, 554, 0, 455, 0, 0, 331,
+ 525, 0, 503, 505, 341, 0, 354, 0, 353, 0,
+ 343, 0, 0, 515, 381, 374, 382, 0, 383, 519,
+ 519, 380, 379, 0, 498, 366, 367, 368, 0, 364,
+ 363, 439, 441, 534, 546, 547, 548, 549, 545, 550,
+ 551, 552, 544, 0, 0, 538, 628, 543, 24, 0,
+ 0, 0, 523, 493, 524, 0, 0, 0, 429, 427,
+ 465, 450, 0, 0, 462, 448, 0, 488, 486, 484,
+ 0, 560, 628, 603, 0, 542, 628, 0, 624, 0,
+ 600, 597, 621, 454, 435, 332, 335, 0, 333, 504,
+ 501, 346, 351, 0, 0, 0, 375, 0, 480, 477,
+ 515, 0, 0, 0, 356, 0, 0, 0, 540, 0,
+ 491, 0, 492, 452, 521, 521, 498, 0, 31, 30,
+ 566, 571, 567, 569, 570, 41, 0, 606, 617, 0,
+ 0, 626, 616, 602, 0, 337, 0, 355, 344, 0,
+ 516, 0, 0, 0, 480, 385, 384, 453, 535, 0,
+ 539, 628, 362, 490, 0, 451, 449, 0, 568, 591,
+ 577, 600, 592, 0, 0, 628, 572, 628, 0, 0,
+ 627, 0, 329, 334, 336, 0, 0, 0, 515, 481,
+ 478, 0, 536, 0, 541, 494, 0, 628, 0, 587,
+ 0, 619, 618, 607, 561, 0, 520, 0, 0, 482,
+ 0, 479, 0, 0, 0, 0, 0, 0, 608, 628,
+ 615, 598, 0, 0, 0, 515, 0, 0, 593, 0,
+ 499, 589, 564, 562, 588, 0, 576, 620, 0, 0,
+ 483, 0, 0, 0, 594, 595, 573, 0, 563, 0,
+ 517, 0, 628, 0, 628, 590, 0, 537, 0, 574,
+ 596, 518, 593, 0, 0, 575
};
-/********** End of lemon-generated parsing tables *****************************/
-
-/* The next table maps tokens (terminal symbols) into fallback tokens.
-** If a construct like the following:
-**
-** %fallback ID X Y Z.
-**
-** appears in the grammar, then ID becomes a fallback token for X, Y,
-** and Z. Whenever one of the tokens X, Y, or Z is input to the parser
-** but it does not parse, the type of the token is changed to ID and
-** the parse is retried before an error is thrown.
-**
-** This feature can be used, for example, to cause some keywords in a language
-** to revert to identifiers if they keyword does not apply in the context where
-** it appears.
-*/
-#ifdef YYFALLBACK
-static const YYCODETYPE yyFallback[] = {
- 0, /* $ => nothing */
- 0, /* BOOL => nothing */
- 0, /* INT => nothing */
- 0, /* FLOAT => nothing */
- 14, /* STRING => NAME */
- 0, /* DOUBLE => nothing */
- 0, /* INT8 => nothing */
- 0, /* UINT8 => nothing */
- 0, /* INT16 => nothing */
- 0, /* UINT16 => nothing */
- 0, /* INT32 => nothing */
- 0, /* UINT32 => nothing */
- 0, /* INT64 => nothing */
- 0, /* UINT64 => nothing */
- 0, /* NAME => nothing */
- 0, /* NULL => nothing */
- 0, /* NUMBER => nothing */
- 0, /* TRUE => nothing */
- 0, /* FALSE => nothing */
- 0, /* QUOTED_STRING => nothing */
- 0, /* NSNAME => nothing */
- 0, /* PIPE => nothing */
- 0, /* CARET => nothing */
- 0, /* AMPERSAND => nothing */
- 0, /* LSHIFT => nothing */
- 0, /* RSHIFT => nothing */
- 0, /* PLUS => nothing */
- 0, /* MINUS => nothing */
- 0, /* ASTERISK => nothing */
- 0, /* SLASH => nothing */
- 0, /* MODULO => nothing */
- 0, /* TILDE => nothing */
- 0, /* NOT => nothing */
- 14, /* ZVAL => NAME */
- 0, /* OBJVAL => nothing */
- 0, /* ARRVAL => nothing */
- 0, /* PATHVAL => nothing */
- 0, /* STRLEN => nothing */
- 0, /* STRVAL => nothing */
- 0, /* FLOATVAL => nothing */
- 0, /* INTVAL => nothing */
- 0, /* BOOLVAL => nothing */
- 14, /* COUNT => NAME */
- 0, /* TO_OBJECT => nothing */
- 0, /* TO_ARRAY => nothing */
- 0, /* TO_STRING => nothing */
- 0, /* TO_INT => nothing */
- 0, /* TO_FLOAT => nothing */
- 0, /* TO_BOOL => nothing */
- 0, /* VOID => nothing */
- 0, /* MIXED => nothing */
- 0, /* ARRAY => nothing */
- 0, /* OBJECT => nothing */
- 0, /* CALLABLE => nothing */
- 14, /* TEMP => NAME */
- 14, /* FREE => NAME */
- 14, /* SET => NAME */
- 14, /* LET => NAME */
- 14, /* RETURN => NAME */
- 14, /* CALLOC => NAME */
- 14, /* CALLBACK => NAME */
- 14, /* LIB => NAME */
+
+ /* YYPGOTO[NTERM-NUM]. */
+static const short int yypgoto[] =
+{
+ -699, -327, -119, -7, 153, -699, -699, -699, 454, -699,
+ -699, -699, -699, -699, -699, -699, -699, -699, -699, 355,
+ -699, -699, -699, -126, -699, -291, -699, -699, -699, -699,
+ -699, -298, -699, -699, 334, -161, 26, -153, -160, 1,
+ -699, -699, -699, 471, -699, -699, 331, -699, -699, -699,
+ -699, 344, -699, -699, -699, -699, -194, -699, -130, -699,
+ -72, 491, 35, 7, 43, -699, -699, 332, -699, -96,
+ -2, -33, -699, -699, 159, -337, -699, -266, -699, 6,
+ -699, -94, -356, -699, -117, -699, 104, -699, -424, -415,
+ 77, -699, -686, -128, -348, -61, -4, -699, 437, -699,
+ 513, -699, -211, -651, -698, -699, 173, -371, -699, -331,
+ -664, 147, -209, -699, -699, -666, -699, -699, -308, -338,
+ -699, -699, -699, -246, -699, -386, -381, -367, -699, -699,
+ -699, -699, -699, -699, -163, -21, -671
};
-#endif /* YYFALLBACK */
-
-/* The following structure represents a single element of the
-** parser's stack. Information stored includes:
-**
-** + The state number for the parser at this level of the stack.
-**
-** + The value of the token stored at this level of the stack.
-** (In other words, the "major" token.)
-**
-** + The semantic value stored at this level of the stack. This is
-** the information used by the action routines in the grammar.
-** It is sometimes called the "minor" token.
-**
-** After the "shift" half of a SHIFTREDUCE action, the stateno field
-** actually contains the reduce action for the second half of the
-** SHIFTREDUCE.
-*/
-struct yyStackEntry {
- YYACTIONTYPE stateno; /* The state-number, or reduce action in SHIFTREDUCE */
- YYCODETYPE major; /* The major token value. This is the code
- ** number for the token at this stack level */
- YYMINORTYPE minor; /* The user-supplied minor token value. This
- ** is the value of the token */
+
+ /* YYDEFGOTO[NTERM-NUM]. */
+static const short int yydefgoto[] =
+{
+ -1, 696, 597, 171, 331, 582, 26, 27, 28, 29,
+ 30, 127, 128, 129, 130, 337, 131, 132, 133, 210,
+ 211, 727, 728, 332, 333, 351, 647, 648, 31, 155,
+ 156, 668, 669, 32, 138, 653, 654, 655, 33, 34,
+ 35, 36, 37, 38, 39, 40, 180, 382, 385, 183,
+ 41, 186, 606, 42, 43, 202, 773, 44, 583, 584,
+ 585, 45, 46, 47, 141, 49, 50, 392, 393, 394,
+ 51, 598, 52, 53, 459, 460, 657, 783, 819, 143,
+ 398, 399, 620, 600, 601, 641, 427, 55, 144, 145,
+ 149, 617, 738, 362, 378, 173, 419, 98, 99, 56,
+ 57, 684, 685, 621, 686, 687, 407, 408, 409, 861,
+ 862, 863, 762, 763, 764, 100, 847, 864, 803, 873,
+ 874, 410, 631, 774, 411, 875, 623, 101, 808, 832,
+ 412, 413, 414, 628, 629, 625, 164
};
-typedef struct yyStackEntry yyStackEntry;
-
-/* The state of the parser is completely contained in an instance of
-** the following structure */
-struct yyParser {
- yyStackEntry *yytos; /* Pointer to top element of the stack */
-#ifdef YYTRACKMAXSTACKDEPTH
- int yyhwm; /* High-water mark of the stack */
-#endif
-#ifndef YYNOERRORRECOVERY
- int yyerrcnt; /* Shifts left before out of the error */
-#endif
- ParseARG_SDECL /* A place to hold %extra_argument */
-#if YYSTACKDEPTH<=0
- int yystksz; /* Current side of the stack */
- yyStackEntry *yystack; /* The parser's stack */
- yyStackEntry yystk0; /* First stack entry */
-#else
- yyStackEntry yystack[YYSTACKDEPTH]; /* The parser's stack */
-#endif
+
+ /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
+ positive, shift that token. If negative, reduce the rule whose
+ number is the opposite. If YYTABLE_NINF, syntax error. */
+static const short int yytable[] =
+{
+ 172, 163, 96, 334, 191, 97, 54, 417, 108, 146,
+ 147, 148, 109, 142, 349, 622, 352, 363, 364, 365,
+ 157, 599, 140, 632, 452, 456, 457, 391, 391, 174,
+ 371, 659, 603, 54, 624, 748, 634, 624, 376, 766,
+ 660, 139, 169, 48, 765, 107, 761, 788, 65, 791,
+ 335, 158, 428, 48, 784, 633, 160, 635, 431, 66,
+ 168, 192, 780, 715, 48, 66, 698, 48, 48, 58,
+ 48, 59, 781, 699, 150, 1, 2, 151, 4, 5,
+ 6, 152, 8, 153, 421, 181, 4, 5, 154, 458,
+ 195, 822, 802, 102, 455, 162, 198, 199, 200, 184,
+ 765, 452, 806, 842, 452, 185, 383, 157, 670, 384,
+ 400, 401, 402, 403, 404, 209, 405, 406, -447, -467,
+ -456, -467, 201, 62, 850, 338, 350, 353, 354, 356,
+ 97, 187, 839, 416, 196, 142, 360, -391, -512, 188,
+ 748, 646, -519, 336, 140, 718, 361, -519, 719, 189,
+ 366, 190, 423, 424, 829, 103, 104, 105, 425, 66,
+ 649, 650, 193, 358, 142, 799, 800, 380, 418, 870,
+ 426, -392, -512, 140, 359, 865, 844, 610, 611, 212,
+ 765, 361, 397, 887, 415, 395, 395, 613, 614, -456,
+ 192, 802, 139, -365, 369, -365, -365, 746, 747, 765,
+ 107, 878, 48, 810, 638, -512, 865, -498, 48, -498,
+ -498, 765, 355, 357, -359, 634, 90, 91, 92, 93,
+ 94, 95, 673, -360, 349, 367, 352, 368, 659, 370,
+ 349, 888, 352, 659, 372, 373, 379, 660, 691, 465,
+ 381, 693, 660, 377, 454, 387, 388, 420, 80, 81,
+ 82, 83, 84, 85, 86, 87, 88, 432, 453, 707,
+ 455, 464, 701, 587, 588, 705, 589, 604, 605, 1,
+ 2, 3, 4, 5, 6, 7, 8, 400, 401, 402,
+ 403, 404, 9, 405, 406, 612, 615, 102, 175, 176,
+ 177, 616, 636, 178, 11, 656, 1, 2, 3, 4,
+ 5, 6, 7, 8, 638, 639, 179, 643, 651, 9,
+ 692, 702, 706, 349, 102, 352, 709, 710, 602, 452,
+ 711, 11, 452, 452, 713, 715, 767, 712, 714, 739,
+ 609, 716, 349, 349, 352, 352, 350, 717, 720, 751,
+ 752, 430, 350, 721, 723, 624, 730, 731, 732, 103,
+ 104, 105, 106, 733, 760, 735, 22, 737, 172, 463,
+ 744, 745, 776, 175, 176, 177, -24, 618, 178, 626,
+ 749, 630, 753, 754, 755, 192, 135, 136, 18, 106,
+ 775, 179, 779, 782, 787, 607, 792, 174, 159, 789,
+ 797, 157, 804, 793, 805, 807, 627, -601, 811, 815,
+ 817, 663, 816, 820, 785, 786, 795, 796, 827, 637,
+ 760, 833, 380, 652, 834, 835, 837, 836, 838, 840,
+ 841, 831, 645, 661, 662, 350, 640, 843, 853, 846,
+ 848, 856, 849, 854, 690, 857, 670, 858, 825, 866,
+ 624, 714, 777, 778, 350, 350, 868, 869, 828, 871,
+ 452, 452, 391, 142, 851, 881, 882, 877, 192, 879,
+ 880, 658, 140, 867, 883, 886, 884, 889, 852, 891,
+ 1, 2, 3, 4, 5, 6, 7, 8, 799, 800,
+ 892, 170, 624, 134, 894, 895, 422, 339, 102, 859,
+ 760, 624, 656, 801, 824, 11, 740, 656, 890, 736,
+ 374, 1, 2, 3, 4, 5, 6, 7, 8, 760,
+ 182, 375, 672, 386, 9, 167, 704, 624, 821, 10,
+ 396, 760, 708, 770, 461, 624, 11, 12, 13, 642,
+ 674, 741, 742, 675, 161, 197, 790, 676, 14, 677,
+ 678, 679, 680, 681, 682, 586, 885, 619, 798, 872,
+ 135, 136, 18, 106, 893, 826, 771, 0, 0, 0,
+ 683, 80, 81, 82, 83, 84, 85, 86, 87, 88,
+ 400, 401, 402, 403, 404, 0, 405, 406, 0, 729,
+ 15, 16, 17, 18, 19, 20, 21, 137, 22, 0,
+ 0, 0, 0, 0, 0, 697, 0, 0, 0, 0,
+ 195, 0, 0, 0, 700, 724, 0, 0, 0, 397,
+ 395, 0, 0, 23, 349, 349, 352, 352, 24, 0,
+ 25, 0, 0, 172, 0, 0, 0, 0, 0, 0,
+ 0, 0, 726, 0, 0, 0, 192, 0, 0, 1,
+ 2, 3, 4, 5, 6, 7, 8, 0, 0, 812,
+ 142, 360, 174, 0, 0, 142, 743, 102, 658, 140,
+ 0, 423, 424, 658, 140, 1, 2, 3, 4, 5,
+ 6, 7, 8, 0, 0, 0, 0, 0, 154, 426,
+ 0, 768, 0, 102, 418, 0, 0, 418, 0, 0,
+ 157, 60, 0, 463, 0, 769, 0, 0, 0, 607,
+ 61, 0, 0, 0, 0, 62, 63, 203, 204, 205,
+ 64, 0, 627, 0, 0, 0, 0, 0, 0, 103,
+ 104, 105, 0, 0, 0, 0, 350, 350, 674, 0,
+ 0, 675, 0, 0, 0, 676, 809, 677, 678, 679,
+ 680, 681, 682, 0, 0, 103, 104, 105, 0, 818,
+ 0, 0, 661, 662, 67, 68, 69, 70, 71, 1,
+ 2, 3, 4, 5, 6, 7, 8, 0, 418, 814,
+ 823, 0, 608, 0, 0, 0, 72, 102, 73, 74,
+ 75, 76, 77, 78, 110, 79, 0, 0, 80, 81,
+ 82, 83, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 94, 95, 0, 0, 0, 855, 0, 206,
+ 0, 207, 208, 860, 0, 0, 0, 0, 0, 0,
+ 111, 112, 113, 114, 115, 116, 117, 118, 119, 120,
+ 121, 122, 0, 123, 124, 125, 126, 0, 0, 103,
+ 104, 105, -577, 0, 860, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, 0, -577, 0, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, -577,
+ -577, -577, -577, -577, -577, -577, -577, -577, -577, 0,
+ -577, -577, 0, -577, -577, -577, -577, -577, 213, 0,
+ 0, 214, 215, 216, 217, 218, 219, 220, 221, 222,
+ 223, 224, 225, 226, 227, 228, 229, 230, 231, 232,
+ 233, 234, 235, 236, 237, 238, 239, 240, 0, 241,
+ 242, 243, 244, 245, 246, 247, 248, 249, 250, 251,
+ 252, 253, 254, 255, 256, 257, 258, 259, 260, 261,
+ 262, 263, 264, 265, 266, 267, 268, 269, 270, 271,
+ 272, 273, 274, 275, 276, 277, 278, 279, 280, 281,
+ 282, 283, 284, 285, 286, 287, 288, 289, 0, 290,
+ 0, 291, 292, 293, 294, 295, 296, 297, 298, 299,
+ 300, 301, 302, 303, 304, 305, 306, 307, 308, 309,
+ 310, 311, 312, 313, 314, 315, 316, 317, 318, 319,
+ 320, 321, 322, 323, 324, 0, 0, 325, 0, 326,
+ 327, 328, 329, 330, 466, 0, 0, 467, 468, 469,
+ 470, 471, 472, 473, 474, 475, 476, 477, 478, 479,
+ 480, 481, 482, 483, 484, 485, 486, 487, 488, 489,
+ 490, 491, 492, 493, 0, 494, 495, 496, 497, 498,
+ 370, 671, 499, 500, 501, 502, 503, 504, 505, 506,
+ 507, 508, 509, 510, 511, 512, 513, 514, 515, 516,
+ 517, 518, 519, 520, 521, 522, 523, 524, 525, 526,
+ 527, 528, 529, 530, 531, 532, 533, 534, 535, 536,
+ 537, 538, 539, 540, 0, 541, 0, 542, 543, 544,
+ 545, 546, 547, 548, 549, 550, 551, 552, 553, 554,
+ 555, 556, 557, 558, 559, 560, 561, 562, 563, 564,
+ 565, 566, 567, 568, 569, 570, 571, 572, 573, 574,
+ 575, 0, 0, 576, 0, 577, 578, 579, 580, 581,
+ 466, 0, 0, 467, 468, 469, 470, 471, 472, 473,
+ 474, 475, 476, 477, 478, 479, 480, 481, 482, 483,
+ 484, 485, 486, 487, 488, 489, 490, 491, 492, 493,
+ 0, 494, 495, 496, 497, 498, 370, 0, 499, 500,
+ 501, 502, 503, 504, 505, 506, 507, 508, 509, 510,
+ 511, 512, 513, 514, 515, 516, 517, 518, 519, 520,
+ 521, 522, 523, 524, 525, 526, 527, 528, 529, 530,
+ 531, 532, 533, 534, 535, 536, 537, 538, 539, 540,
+ 0, 541, 0, 542, 543, 544, 545, 546, 547, 548,
+ 549, 550, 551, 552, 553, 554, 555, 556, 557, 558,
+ 559, 560, 561, 562, 563, 564, 565, 566, 567, 568,
+ 569, 570, 571, 572, 573, 574, 575, 60, 0, 576,
+ 0, 577, 578, 579, 580, 581, 61, 0, 0, 0,
+ 0, 62, 63, 590, 0, 0, 64, 591, 0, 592,
+ 0, 593, 342, 0, 0, 0, 594, 0, 0, 0,
+ 0, 0, 0, 595, 0, 0, 0, 0, 0, 0,
+ 0, 344, 345, 66, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 346, 347, 0, 0, 0, 0,
+ 67, 68, 69, 70, 71, 1, 2, 3, 4, 5,
+ 6, 7, 8, 0, 0, 0, 0, 0, 9, 0,
+ 0, 0, 72, 102, 73, 74, 75, 76, 77, 78,
+ 11, 79, 0, 0, 80, 81, 82, 83, 84, 85,
+ 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
+ 1, 2, 3, 4, 5, 6, 7, 8, 596, 0,
+ 0, 0, 0, 9, 0, 0, 0, 0, 102, 0,
+ 0, 0, 0, 0, 0, 11, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 135, 136, 18, 106, 0,
+ 60, 1, 2, 3, 4, 5, 6, 7, 8, 61,
+ 0, 0, 0, 0, 62, 63, 590, 0, 0, 688,
+ 591, 0, 592, 0, 593, 342, 11, 0, 0, 594,
+ 0, 0, 137, 0, 0, 0, 0, 0, 0, 0,
+ 135, 136, 18, 106, 344, 345, 66, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 346, 347, 0,
+ 0, 0, 0, 67, 68, 69, 70, 71, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 652, 0, 0,
+ 0, 103, 104, 105, 689, 72, 0, 73, 74, 75,
+ 76, 77, 78, 0, 79, 0, 0, 80, 81, 82,
+ 83, 84, 85, 86, 87, 88, 89, 90, 91, 92,
+ 93, 94, 95, 60, 0, 0, 0, 0, 0, 0,
+ 0, 0, 61, 0, 0, 0, 0, 62, 63, 664,
+ 665, 666, 64, 591, 0, 592, 667, 593, 342, 0,
+ 0, 0, 594, 0, 0, 0, 0, 0, 1, 2,
+ 3, 4, 5, 6, 7, 8, 0, 344, 345, 66,
+ 0, 9, 0, 0, 0, 0, 165, 0, 0, 0,
+ 346, 347, 0, 11, 0, 0, 67, 68, 69, 70,
+ 71, 1, 2, 3, 4, 5, 6, 7, 8, 0,
+ 0, 0, 0, 0, 9, 0, 0, 0, 72, 102,
+ 73, 74, 75, 76, 77, 78, 11, 79, 0, 0,
+ 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
+ 90, 91, 92, 93, 94, 95, 60, 166, 103, 104,
+ 105, 106, 0, 0, 0, 61, 0, 0, 0, 0,
+ 62, 63, 756, 0, 0, 64, 591, 0, 592, 0,
+ 593, 342, 0, 0, 0, 594, 0, 0, 0, 0,
+ 0, 103, 104, 105, 106, 0, 0, 162, 0, 0,
+ 344, 345, 66, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 346, 347, 0, 0, 0, 0, 67,
+ 68, 69, 70, 71, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 72, 757, 758, 74, 75, 76, 77, 78, 0,
+ 79, 0, 0, 80, 81, 82, 83, 84, 85, 86,
+ 87, 88, 759, 90, 91, 92, 93, 94, 95, 60,
+ 0, 0, 0, 0, 0, 0, 0, 0, 61, 0,
+ 0, 0, 0, 62, 63, 590, 0, 0, 64, 591,
+ 0, 592, 0, 593, 342, 0, 0, 0, 594, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 162, 0, 0, 344, 345, 66, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 346, 347, 0, 0,
+ 830, 0, 67, 68, 69, 70, 71, 1, 2, 3,
+ 4, 5, 6, 7, 8, 0, 0, 0, 0, 0,
+ 9, 0, 0, 0, 72, 102, 73, 74, 75, 76,
+ 77, 78, 11, 79, 0, 0, 80, 81, 82, 83,
+ 84, 85, 86, 87, 88, 89, 90, 91, 92, 93,
+ 94, 95, 60, 0, 0, 0, 0, 0, 0, 0,
+ 0, 61, 0, 0, 0, 0, 62, 63, 590, 0,
+ 0, 64, 591, -628, 592, 0, 593, 342, 0, 0,
+ 0, 594, 0, 0, 0, 0, 0, 103, 104, 105,
+ 106, 0, 0, 162, 0, 0, 344, 345, 66, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 346,
+ 347, 0, 0, 0, 0, 67, 68, 69, 70, 71,
+ 1, 2, 3, 4, 5, 6, 7, 8, 0, 0,
+ 0, 0, 0, 9, 0, 0, 0, 72, 102, 73,
+ 74, 75, 76, 77, 78, 11, 79, 0, 0, 80,
+ 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,
+ 91, 92, 93, 94, 95, 60, 0, 0, 0, 0,
+ 0, 0, 0, 0, 61, 0, 0, 0, 0, 62,
+ 63, 590, 0, 0, 64, 591, 0, 592, 0, 593,
+ 342, 0, 0, 0, 594, 0, 0, 0, 0, 0,
+ 135, 136, 18, 106, 0, 0, 162, 0, 0, 344,
+ 345, 66, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 346, 347, 0, 0, 0, 0, 67, 68,
+ 69, 70, 71, 1, 2, 3, 4, 5, 6, 7,
+ 8, 0, 0, 0, 0, 0, 9, 0, 0, 0,
+ 72, 102, 73, 74, 75, 76, 77, 78, 11, 79,
+ 0, 0, 80, 81, 82, 83, 84, 85, 86, 87,
+ 88, 89, 90, 91, 92, 93, 94, 95, 60, 0,
+ 0, 0, 0, 0, 0, 0, 0, 61, 0, 0,
+ 0, 0, 62, 63, 756, 0, 0, 64, 591, 0,
+ 592, 0, 593, 342, 0, 0, 0, 594, 0, 0,
+ 0, 0, 0, 103, 104, 105, 106, 0, 0, 0,
+ 0, 0, 344, 345, 66, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 346, 347, 0, 0, 0,
+ 0, 67, 68, 69, 70, 71, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 72, 757, 758, 74, 75, 76, 77,
+ 78, 0, 79, 0, 0, 80, 81, 82, 83, 84,
+ 85, 86, 87, 88, 759, 90, 91, 92, 93, 94,
+ 95, 60, 0, 0, 0, 0, 0, 0, 0, 0,
+ 61, 0, 0, 0, 0, 62, 63, 590, 0, 0,
+ 64, 591, 0, 592, 0, 593, 342, 0, 0, 0,
+ 594, 0, 0, 0, 0, 1, 2, 3, 4, 5,
+ 6, 7, 8, 0, 0, 344, 345, 66, 389, 0,
+ 0, 0, 0, 102, 0, 0, 0, 0, 346, 347,
+ 11, 0, 0, 0, 67, 68, 69, 70, 71, 1,
+ 2, 3, 4, 5, 6, 7, 8, 0, 0, 0,
+ 0, 0, 703, 0, 0, 0, 72, 102, 73, 74,
+ 75, 76, 77, 78, 11, 79, 0, 0, 80, 81,
+ 82, 83, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 94, 95, 60, 103, 104, 105, 390, 0,
+ 0, 0, 0, 61, 0, 0, 0, 0, 62, 63,
+ 0, 0, 0, 64, 0, 0, 340, 0, 341, 342,
+ 0, 0, 0, 343, 0, 0, 0, 0, 0, 103,
+ 104, 105, 390, 0, 0, 0, 0, 0, 344, 345,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 346, 347, 0, 0, 0, 0, 67, 68, 69,
+ 70, 71, 0, 0, 0, 0, 0, 0, 0, 348,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 72,
+ 0, 73, 74, 75, 76, 77, 78, 0, 79, 0,
+ 0, 80, 81, 82, 83, 84, 85, 86, 87, 88,
+ 89, 90, 91, 92, 93, 94, 95, 60, 0, 0,
+ 0, 0, 0, 0, 0, 0, 61, 0, 0, 0,
+ 0, 62, 63, 0, 0, 0, 64, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 65, 0, 0, 0,
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 0,
+ 0, 0, 0, 66, 0, 0, 0, 0, 0, 102,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 67, 68, 69, 70, 71, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 72, 0, 73, 74, 75, 76, 77, 78,
+ 0, 79, 0, 0, 80, 81, 82, 83, 84, 85,
+ 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
+ 60, 103, 104, 105, 0, 0, 0, 0, 0, 61,
+ 0, 0, 0, 0, 62, 63, 0, 0, 0, 64,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, -525,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 66, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 67, 68, 69, 70, 71, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 72, 0, 73, 74, 75,
+ 76, 77, 78, 0, 79, 0, 0, 80, 81, 82,
+ 83, 84, 85, 86, 87, 88, 89, 90, 91, 92,
+ 93, 94, 95, 60, 0, 0, 0, 0, 0, 0,
+ 0, 0, 61, 722, 0, 0, 0, 62, 63, 0,
+ 0, 0, 64, 0, 433, 434, 435, 436, 437, 438,
+ 439, 440, 441, 442, 443, 444, 445, 446, 447, 448,
+ 449, 450, 0, 0, 0, 0, 0, 695, 0, 66,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 67, 68, 69, 70,
+ 71, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 72, 0,
+ 73, 74, 75, 76, 77, 78, 0, 79, 0, 0,
+ 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
+ 90, 91, 92, 93, 94, 95, 60, 0, 0, 0,
+ 0, 0, 0, 0, 0, 61, 0, 0, 0, 0,
+ 62, 63, 0, 0, 0, 64, 0, 644, 0, 0,
+ 0, 0, 0, 0, 0, 194, 433, 434, 435, 436,
+ 437, 438, 439, 440, 441, 442, 443, 444, 445, 446,
+ 447, 448, 449, 450, 0, 0, 0, 0, 0, 451,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 67,
+ 68, 69, 70, 71, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 72, 0, 73, 74, 75, 76, 77, 78, 0,
+ 79, 0, 0, 80, 81, 82, 83, 84, 85, 86,
+ 87, 88, 89, 90, 91, 92, 93, 94, 95, 60,
+ 0, 0, 0, 0, 0, 0, 0, 0, 61, 0,
+ 0, 0, 0, 62, 63, 0, 0, 0, 64, 0,
+ 750, 0, 0, 0, 0, 0, 0, 0, 429, 433,
+ 434, 435, 436, 437, 438, 439, 440, 441, 442, 443,
+ 444, 445, 446, 447, 448, 449, 450, 0, 0, 0,
+ 0, 0, 695, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 67, 68, 69, 70, 71, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 72, 0, 73, 74, 75, 76,
+ 77, 78, 0, 79, 0, 0, 80, 81, 82, 83,
+ 84, 85, 86, 87, 88, 89, 90, 91, 92, 93,
+ 94, 95, 60, 0, 0, 0, 0, 0, 0, 0,
+ 0, 61, 0, 0, 0, 0, 62, 63, 0, 0,
+ 0, 64, 0, 876, 0, 0, 0, 0, 0, 0,
+ 0, 462, 433, 434, 435, 436, 437, 438, 439, 440,
+ 441, 442, 443, 444, 445, 446, 447, 448, 449, 450,
+ 0, 0, 0, 0, 0, 695, 0, 0, 0, 0,
+ 0, 60, 0, 0, 0, 67, 68, 69, 70, 71,
+ 61, 0, 0, 0, 0, 62, 63, 0, 0, 0,
+ 64, 0, 0, 0, 0, 0, 0, 72, 0, 73,
+ 74, 75, 76, 77, 78, 0, 79, 0, 0, 80,
+ 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,
+ 91, 92, 93, 94, 95, 0, 0, 0, 0, 0,
+ 0, 0, 725, 0, 67, 68, 69, 70, 71, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 72, 0, 73, 74,
+ 75, 76, 77, 78, 0, 79, 0, 0, 80, 81,
+ 82, 83, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 94, 95, 60, 0, 0, 0, 0, 0,
+ 0, 0, 0, 61, 0, 0, 845, 0, 772, 63,
+ 0, 0, 0, 64, 433, 434, 435, 436, 437, 438,
+ 439, 440, 441, 442, 443, 444, 445, 446, 447, 448,
+ 449, 450, 0, 0, 0, 0, 0, 695, 0, 0,
+ 66, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 60, 0, 0, 0, 67, 68, 69,
+ 70, 71, 61, 0, 0, 0, 0, 62, 63, 0,
+ 0, 0, 64, 0, 0, 0, 0, 0, 0, 72,
+ 0, 73, 74, 75, 76, 77, 78, 0, 79, 0,
+ 0, 80, 81, 82, 83, 84, 85, 86, 87, 88,
+ 89, 90, 91, 92, 93, 94, 95, 0, 0, 0,
+ 0, 0, 60, 0, 813, 0, 67, 68, 69, 70,
+ 71, 61, 0, 0, 0, 0, 62, 63, 0, 0,
+ 0, 64, 0, 0, 0, 0, 0, 0, 72, 0,
+ 73, 74, 75, 76, 77, 78, 0, 79, 0, 0,
+ 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
+ 90, 91, 92, 93, 94, 95, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 67, 68, 69, 70, 71,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 72, 0, 73,
+ 74, 75, 76, 77, 78, 0, 79, 0, 0, 80,
+ 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,
+ 91, 92, 93, 94, 95, 734, 0, 0, 0, 0,
+ 0, 0, 433, 434, 435, 436, 437, 438, 439, 440,
+ 441, 442, 443, 444, 445, 446, 447, 448, 449, 450,
+ 794, 0, 0, 0, 0, 451, 0, 433, 434, 435,
+ 436, 437, 438, 439, 440, 441, 442, 443, 444, 445,
+ 446, 447, 448, 449, 450, 0, 0, 0, 694, 0,
+ 695, 433, 434, 435, 436, 437, 438, 439, 440, 441,
+ 442, 443, 444, 445, 446, 447, 448, 449, 450, 0,
+ 0, 0, 0, 0, 695, 433, 434, 435, 436, 437,
+ 438, 439, 440, 441, 442, 443, 444, 445, 446, 447,
+ 448, 449, 450, 0, 0, 0, 0, 0, 451, 433,
+ 434, 435, 436, 437, 438, 439, 440, 441, 442, 443,
+ 444, 445, 446, 447, 448, 449, 450, 0, 0, 0,
+ 0, 0, 695, 433, 434, 435, 436, 437, 438, 439,
+ 440, 441, 442, 443, 444, 445, 446, 447, 448, 449,
+ 450, 0, 0, 0, 0, 0, 451, 433, 434, 435,
+ 436, 437, 438, 439, 440, 441, 442, 443, 444, 445,
+ 446, 447, 448, 449, 450, 0, 0, 0, 0, 0,
+ 695
};
-typedef struct yyParser yyParser;
-#ifndef NDEBUG
-#include <stdio.h>
-static FILE *yyTraceFILE = 0;
-static char *yyTracePrompt = 0;
-#endif /* NDEBUG */
-
-#ifndef NDEBUG
-/*
-** Turn parser tracing on by giving a stream to which to write the trace
-** and a prompt to preface each trace message. Tracing is turned off
-** by making either argument NULL
-**
-** Inputs:
-** <ul>
-** <li> A FILE* to which trace output should be written.
-** If NULL, then tracing is turned off.
-** <li> A prefix string written at the beginning of every
-** line of trace output. If NULL, then tracing is
-** turned off.
-** </ul>
-**
-** Outputs:
-** None.
-*/
-void ParseTrace(FILE *TraceFILE, char *zTracePrompt){
- yyTraceFILE = TraceFILE;
- yyTracePrompt = zTracePrompt;
- if( yyTraceFILE==0 ) yyTracePrompt = 0;
- else if( yyTracePrompt==0 ) yyTraceFILE = 0;
-}
-#endif /* NDEBUG */
-
-#ifndef NDEBUG
-/* For tracing shifts, the names of all terminals and nonterminals
-** are required. The following table supplies these names */
-static const char *const yyTokenName[] = {
- "$", "BOOL", "INT", "FLOAT",
- "STRING", "DOUBLE", "INT8", "UINT8",
- "INT16", "UINT16", "INT32", "UINT32",
- "INT64", "UINT64", "NAME", "NULL",
- "NUMBER", "TRUE", "FALSE", "QUOTED_STRING",
- "NSNAME", "PIPE", "CARET", "AMPERSAND",
- "LSHIFT", "RSHIFT", "PLUS", "MINUS",
- "ASTERISK", "SLASH", "MODULO", "TILDE",
- "NOT", "ZVAL", "OBJVAL", "ARRVAL",
- "PATHVAL", "STRLEN", "STRVAL", "FLOATVAL",
- "INTVAL", "BOOLVAL", "COUNT", "TO_OBJECT",
- "TO_ARRAY", "TO_STRING", "TO_INT", "TO_FLOAT",
- "TO_BOOL", "VOID", "MIXED", "ARRAY",
- "OBJECT", "CALLABLE", "TEMP", "FREE",
- "SET", "LET", "RETURN", "CALLOC",
- "CALLBACK", "LIB", "EOF", "EOS",
- "COLON", "LPAREN", "COMMA", "RPAREN",
- "ENUM", "STRUCT", "UNION", "LBRACE",
- "RBRACE", "EQUALS", "CONST", "TYPEDEF",
- "ELLIPSIS", "LBRACKET", "RBRACKET", "CHAR",
- "SHORT", "LONG", "UNSIGNED", "SIGNED",
- "STATIC", "FUNCTION", "DOLLAR_NAME", "error",
- "decl_enum", "decl_enum_items", "decl_enum_item", "decl_struct_args_block",
- "decl_struct_args", "decl_struct", "align_and_size", "decl_union",
- "const_type", "constant", "decl_typedef", "decl_typedef_body_ex",
- "decl_typedef_body", "decl_typedef_body_fn_args", "decl", "decl_func",
- "decl_abi", "decl_var", "decl_vars", "decl_arg",
- "decl_args", "struct_args", "struct_arg", "decl_layout",
- "decl_type", "const_decl_type", "impl", "impl_func",
- "impl_def_val", "impl_var", "impl_arg", "impl_args",
- "impl_vararg", "impl_stmts", "impl_stmt", "number",
- "num_exp", "let_stmt", "let_calloc", "let_func",
- "callback_arg_list", "callback_args", "let_callback", "let_exp",
- "let_exps", "set_stmt", "set_exp", "set_exps",
- "set_func", "return_stmt", "free_stmt", "free_exps",
- "free_exp", "impl_type", "reference", "indirection",
- "pointers", "file", "blocks", "block",
- "optional_name", "enum_name", "struct_name", "union_name",
- "decl_var_array_size", "decl_scalar_type", "decl_scalar_type_short", "decl_scalar_type_long",
- "decl_scalar_type_long_long", "callback_rval",
+static const short int yycheck[] =
+{
+ 33, 22, 9, 129, 65, 9, 0, 201, 10, 16,
+ 17, 18, 11, 15, 133, 401, 133, 145, 146, 147,
+ 19, 377, 15, 404, 351, 362, 363, 187, 188, 33,
+ 160, 455, 380, 27, 401, 686, 407, 404, 168, 710,
+ 455, 15, 0, 0, 710, 10, 710, 745, 32, 747,
+ 26, 26, 343, 10, 740, 37, 21, 413, 349, 49,
+ 25, 65, 25, 24, 21, 49, 26, 24, 25, 9,
+ 27, 11, 35, 33, 3, 4, 5, 6, 7, 8,
+ 9, 10, 11, 12, 210, 6, 7, 8, 17, 31,
+ 97, 789, 758, 22, 36, 44, 103, 104, 105, 31,
+ 766, 428, 766, 64, 431, 125, 6, 106, 464, 9,
+ 92, 93, 94, 95, 96, 122, 98, 99, 31, 32,
+ 32, 34, 34, 17, 18, 132, 133, 134, 135, 136,
+ 134, 32, 818, 194, 124, 137, 143, 35, 36, 32,
+ 791, 432, 31, 119, 137, 31, 35, 36, 34, 36,
+ 154, 36, 26, 27, 805, 84, 85, 86, 32, 49,
+ 451, 452, 87, 137, 166, 17, 18, 174, 201, 855,
+ 44, 35, 36, 166, 31, 846, 827, 33, 34, 30,
+ 846, 35, 189, 881, 191, 187, 188, 33, 34, 32,
+ 194, 857, 166, 31, 159, 33, 34, 33, 34, 865,
+ 165, 865, 159, 33, 34, 36, 877, 31, 165, 33,
+ 34, 877, 135, 136, 23, 586, 110, 111, 112, 113,
+ 114, 115, 37, 23, 343, 23, 343, 31, 652, 36,
+ 349, 882, 349, 657, 36, 23, 32, 652, 594, 369,
+ 6, 597, 657, 38, 35, 32, 31, 118, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 32, 31, 615,
+ 36, 40, 610, 32, 31, 613, 31, 6, 26, 4,
+ 5, 6, 7, 8, 9, 10, 11, 92, 93, 94,
+ 95, 96, 17, 98, 99, 34, 40, 22, 4, 5,
+ 6, 34, 33, 9, 29, 455, 4, 5, 6, 7,
+ 8, 9, 10, 11, 34, 32, 22, 22, 32, 17,
+ 39, 64, 64, 432, 22, 432, 37, 40, 379, 646,
+ 31, 29, 649, 650, 31, 24, 712, 40, 32, 37,
+ 391, 40, 451, 452, 451, 452, 343, 32, 32, 695,
+ 696, 348, 349, 31, 33, 712, 33, 33, 33, 84,
+ 85, 86, 87, 34, 710, 25, 91, 35, 391, 366,
+ 31, 35, 34, 4, 5, 6, 33, 400, 9, 402,
+ 33, 404, 33, 33, 33, 379, 84, 85, 86, 87,
+ 33, 22, 34, 34, 33, 389, 40, 391, 123, 35,
+ 109, 390, 32, 749, 32, 34, 403, 33, 33, 25,
+ 32, 462, 35, 31, 741, 742, 754, 755, 32, 416,
+ 766, 33, 419, 121, 31, 97, 35, 33, 25, 34,
+ 31, 807, 429, 456, 457, 432, 425, 33, 32, 34,
+ 33, 24, 34, 34, 594, 97, 792, 32, 794, 33,
+ 807, 32, 733, 734, 451, 452, 25, 25, 804, 33,
+ 777, 778, 612, 455, 835, 35, 32, 34, 462, 34,
+ 33, 455, 455, 849, 33, 25, 34, 33, 835, 33,
+ 4, 5, 6, 7, 8, 9, 10, 11, 17, 18,
+ 32, 27, 849, 17, 33, 33, 333, 132, 22, 845,
+ 846, 858, 652, 32, 792, 29, 657, 657, 884, 652,
+ 166, 4, 5, 6, 7, 8, 9, 10, 11, 865,
+ 39, 167, 584, 182, 17, 24, 612, 884, 784, 22,
+ 188, 877, 616, 717, 365, 892, 29, 30, 31, 425,
+ 3, 659, 660, 6, 21, 98, 747, 10, 41, 12,
+ 13, 14, 15, 16, 17, 372, 877, 400, 757, 857,
+ 84, 85, 86, 87, 892, 801, 719, -1, -1, -1,
+ 33, 100, 101, 102, 103, 104, 105, 106, 107, 108,
+ 92, 93, 94, 95, 96, -1, 98, 99, -1, 640,
+ 83, 84, 85, 86, 87, 88, 89, 121, 91, -1,
+ -1, -1, -1, -1, -1, 602, -1, -1, -1, -1,
+ 607, -1, -1, -1, 608, 638, -1, -1, -1, 616,
+ 612, -1, -1, 116, 733, 734, 733, 734, 121, -1,
+ 123, -1, -1, 656, -1, -1, -1, -1, -1, -1,
+ -1, -1, 639, -1, -1, -1, 640, -1, -1, 4,
+ 5, 6, 7, 8, 9, 10, 11, -1, -1, 775,
+ 652, 658, 656, -1, -1, 657, 663, 22, 652, 652,
+ -1, 26, 27, 657, 657, 4, 5, 6, 7, 8,
+ 9, 10, 11, -1, -1, -1, -1, -1, 17, 44,
+ -1, 714, -1, 22, 717, -1, -1, 720, -1, -1,
+ 689, 3, -1, 700, -1, 716, -1, -1, -1, 703,
+ 12, -1, -1, -1, -1, 17, 18, 19, 20, 21,
+ 22, -1, 719, -1, -1, -1, -1, -1, -1, 84,
+ 85, 86, -1, -1, -1, -1, 733, 734, 3, -1,
+ -1, 6, -1, -1, -1, 10, 769, 12, 13, 14,
+ 15, 16, 17, -1, -1, 84, 85, 86, -1, 782,
+ -1, -1, 785, 786, 66, 67, 68, 69, 70, 4,
+ 5, 6, 7, 8, 9, 10, 11, -1, 801, 776,
+ 791, -1, 17, -1, -1, -1, 88, 22, 90, 91,
+ 92, 93, 94, 95, 30, 97, -1, -1, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, -1, -1, -1, 840, -1, 121,
+ -1, 123, 124, 846, -1, -1, -1, -1, -1, -1,
+ 66, 67, 68, 69, 70, 71, 72, 73, 74, 75,
+ 76, 77, -1, 79, 80, 81, 82, -1, -1, 84,
+ 85, 86, 0, -1, 877, 3, 4, 5, 6, 7,
+ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
+ 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
+ 28, 29, 30, 31, 32, 33, 34, 35, 36, 37,
+ 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
+ 48, 49, 50, 51, 52, 53, 54, 55, 56, 57,
+ 58, 59, 60, 61, 62, 63, 64, 65, 66, 67,
+ 68, 69, 70, 71, 72, 73, 74, 75, 76, 77,
+ 78, 79, -1, 81, -1, 83, 84, 85, 86, 87,
+ 88, 89, 90, 91, 92, 93, 94, 95, 96, 97,
+ 98, 99, 100, 101, 102, 103, 104, 105, 106, 107,
+ 108, 109, 110, 111, 112, 113, 114, 115, 116, -1,
+ 118, 119, -1, 121, 122, 123, 124, 125, 0, -1,
+ -1, 3, 4, 5, 6, 7, 8, 9, 10, 11,
+ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
+ 22, 23, 24, 25, 26, 27, 28, 29, -1, 31,
+ 32, 33, 34, 35, 36, 37, 38, 39, 40, 41,
+ 42, 43, 44, 45, 46, 47, 48, 49, 50, 51,
+ 52, 53, 54, 55, 56, 57, 58, 59, 60, 61,
+ 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
+ 72, 73, 74, 75, 76, 77, 78, 79, -1, 81,
+ -1, 83, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, 116, -1, -1, 119, -1, 121,
+ 122, 123, 124, 125, 0, -1, -1, 3, 4, 5,
+ 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
+ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
+ 26, 27, 28, 29, -1, 31, 32, 33, 34, 35,
+ 36, 37, 38, 39, 40, 41, 42, 43, 44, 45,
+ 46, 47, 48, 49, 50, 51, 52, 53, 54, 55,
+ 56, 57, 58, 59, 60, 61, 62, 63, 64, 65,
+ 66, 67, 68, 69, 70, 71, 72, 73, 74, 75,
+ 76, 77, 78, 79, -1, 81, -1, 83, 84, 85,
+ 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
+ 96, 97, 98, 99, 100, 101, 102, 103, 104, 105,
+ 106, 107, 108, 109, 110, 111, 112, 113, 114, 115,
+ 116, -1, -1, 119, -1, 121, 122, 123, 124, 125,
+ 0, -1, -1, 3, 4, 5, 6, 7, 8, 9,
+ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
+ 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
+ -1, 31, 32, 33, 34, 35, 36, -1, 38, 39,
+ 40, 41, 42, 43, 44, 45, 46, 47, 48, 49,
+ 50, 51, 52, 53, 54, 55, 56, 57, 58, 59,
+ 60, 61, 62, 63, 64, 65, 66, 67, 68, 69,
+ 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
+ -1, 81, -1, 83, 84, 85, 86, 87, 88, 89,
+ 90, 91, 92, 93, 94, 95, 96, 97, 98, 99,
+ 100, 101, 102, 103, 104, 105, 106, 107, 108, 109,
+ 110, 111, 112, 113, 114, 115, 116, 3, -1, 119,
+ -1, 121, 122, 123, 124, 125, 12, -1, -1, -1,
+ -1, 17, 18, 19, -1, -1, 22, 23, -1, 25,
+ -1, 27, 28, -1, -1, -1, 32, -1, -1, -1,
+ -1, -1, -1, 39, -1, -1, -1, -1, -1, -1,
+ -1, 47, 48, 49, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 60, 61, -1, -1, -1, -1,
+ 66, 67, 68, 69, 70, 4, 5, 6, 7, 8,
+ 9, 10, 11, -1, -1, -1, -1, -1, 17, -1,
+ -1, -1, 88, 22, 90, 91, 92, 93, 94, 95,
+ 29, 97, -1, -1, 100, 101, 102, 103, 104, 105,
+ 106, 107, 108, 109, 110, 111, 112, 113, 114, 115,
+ 4, 5, 6, 7, 8, 9, 10, 11, 124, -1,
+ -1, -1, -1, 17, -1, -1, -1, -1, 22, -1,
+ -1, -1, -1, -1, -1, 29, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 84, 85, 86, 87, -1,
+ 3, 4, 5, 6, 7, 8, 9, 10, 11, 12,
+ -1, -1, -1, -1, 17, 18, 19, -1, -1, 22,
+ 23, -1, 25, -1, 27, 28, 29, -1, -1, 32,
+ -1, -1, 121, -1, -1, -1, -1, -1, -1, -1,
+ 84, 85, 86, 87, 47, 48, 49, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 60, 61, -1,
+ -1, -1, -1, 66, 67, 68, 69, 70, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 121, -1, -1,
+ -1, 84, 85, 86, 87, 88, -1, 90, 91, 92,
+ 93, 94, 95, -1, 97, -1, -1, 100, 101, 102,
+ 103, 104, 105, 106, 107, 108, 109, 110, 111, 112,
+ 113, 114, 115, 3, -1, -1, -1, -1, -1, -1,
+ -1, -1, 12, -1, -1, -1, -1, 17, 18, 19,
+ 20, 21, 22, 23, -1, 25, 26, 27, 28, -1,
+ -1, -1, 32, -1, -1, -1, -1, -1, 4, 5,
+ 6, 7, 8, 9, 10, 11, -1, 47, 48, 49,
+ -1, 17, -1, -1, -1, -1, 22, -1, -1, -1,
+ 60, 61, -1, 29, -1, -1, 66, 67, 68, 69,
+ 70, 4, 5, 6, 7, 8, 9, 10, 11, -1,
+ -1, -1, -1, -1, 17, -1, -1, -1, 88, 22,
+ 90, 91, 92, 93, 94, 95, 29, 97, -1, -1,
+ 100, 101, 102, 103, 104, 105, 106, 107, 108, 109,
+ 110, 111, 112, 113, 114, 115, 3, 83, 84, 85,
+ 86, 87, -1, -1, -1, 12, -1, -1, -1, -1,
+ 17, 18, 19, -1, -1, 22, 23, -1, 25, -1,
+ 27, 28, -1, -1, -1, 32, -1, -1, -1, -1,
+ -1, 84, 85, 86, 87, -1, -1, 44, -1, -1,
+ 47, 48, 49, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 60, 61, -1, -1, -1, -1, 66,
+ 67, 68, 69, 70, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 88, 89, 90, 91, 92, 93, 94, 95, -1,
+ 97, -1, -1, 100, 101, 102, 103, 104, 105, 106,
+ 107, 108, 109, 110, 111, 112, 113, 114, 115, 3,
+ -1, -1, -1, -1, -1, -1, -1, -1, 12, -1,
+ -1, -1, -1, 17, 18, 19, -1, -1, 22, 23,
+ -1, 25, -1, 27, 28, -1, -1, -1, 32, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 44, -1, -1, 47, 48, 49, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 60, 61, -1, -1,
+ 64, -1, 66, 67, 68, 69, 70, 4, 5, 6,
+ 7, 8, 9, 10, 11, -1, -1, -1, -1, -1,
+ 17, -1, -1, -1, 88, 22, 90, 91, 92, 93,
+ 94, 95, 29, 97, -1, -1, 100, 101, 102, 103,
+ 104, 105, 106, 107, 108, 109, 110, 111, 112, 113,
+ 114, 115, 3, -1, -1, -1, -1, -1, -1, -1,
+ -1, 12, -1, -1, -1, -1, 17, 18, 19, -1,
+ -1, 22, 23, 24, 25, -1, 27, 28, -1, -1,
+ -1, 32, -1, -1, -1, -1, -1, 84, 85, 86,
+ 87, -1, -1, 44, -1, -1, 47, 48, 49, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 60,
+ 61, -1, -1, -1, -1, 66, 67, 68, 69, 70,
+ 4, 5, 6, 7, 8, 9, 10, 11, -1, -1,
+ -1, -1, -1, 17, -1, -1, -1, 88, 22, 90,
+ 91, 92, 93, 94, 95, 29, 97, -1, -1, 100,
+ 101, 102, 103, 104, 105, 106, 107, 108, 109, 110,
+ 111, 112, 113, 114, 115, 3, -1, -1, -1, -1,
+ -1, -1, -1, -1, 12, -1, -1, -1, -1, 17,
+ 18, 19, -1, -1, 22, 23, -1, 25, -1, 27,
+ 28, -1, -1, -1, 32, -1, -1, -1, -1, -1,
+ 84, 85, 86, 87, -1, -1, 44, -1, -1, 47,
+ 48, 49, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 60, 61, -1, -1, -1, -1, 66, 67,
+ 68, 69, 70, 4, 5, 6, 7, 8, 9, 10,
+ 11, -1, -1, -1, -1, -1, 17, -1, -1, -1,
+ 88, 22, 90, 91, 92, 93, 94, 95, 29, 97,
+ -1, -1, 100, 101, 102, 103, 104, 105, 106, 107,
+ 108, 109, 110, 111, 112, 113, 114, 115, 3, -1,
+ -1, -1, -1, -1, -1, -1, -1, 12, -1, -1,
+ -1, -1, 17, 18, 19, -1, -1, 22, 23, -1,
+ 25, -1, 27, 28, -1, -1, -1, 32, -1, -1,
+ -1, -1, -1, 84, 85, 86, 87, -1, -1, -1,
+ -1, -1, 47, 48, 49, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 60, 61, -1, -1, -1,
+ -1, 66, 67, 68, 69, 70, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 88, 89, 90, 91, 92, 93, 94,
+ 95, -1, 97, -1, -1, 100, 101, 102, 103, 104,
+ 105, 106, 107, 108, 109, 110, 111, 112, 113, 114,
+ 115, 3, -1, -1, -1, -1, -1, -1, -1, -1,
+ 12, -1, -1, -1, -1, 17, 18, 19, -1, -1,
+ 22, 23, -1, 25, -1, 27, 28, -1, -1, -1,
+ 32, -1, -1, -1, -1, 4, 5, 6, 7, 8,
+ 9, 10, 11, -1, -1, 47, 48, 49, 17, -1,
+ -1, -1, -1, 22, -1, -1, -1, -1, 60, 61,
+ 29, -1, -1, -1, 66, 67, 68, 69, 70, 4,
+ 5, 6, 7, 8, 9, 10, 11, -1, -1, -1,
+ -1, -1, 17, -1, -1, -1, 88, 22, 90, 91,
+ 92, 93, 94, 95, 29, 97, -1, -1, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, 3, 84, 85, 86, 87, -1,
+ -1, -1, -1, 12, -1, -1, -1, -1, 17, 18,
+ -1, -1, -1, 22, -1, -1, 25, -1, 27, 28,
+ -1, -1, -1, 32, -1, -1, -1, -1, -1, 84,
+ 85, 86, 87, -1, -1, -1, -1, -1, 47, 48,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 60, 61, -1, -1, -1, -1, 66, 67, 68,
+ 69, 70, -1, -1, -1, -1, -1, -1, -1, 78,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 88,
+ -1, 90, 91, 92, 93, 94, 95, -1, 97, -1,
+ -1, 100, 101, 102, 103, 104, 105, 106, 107, 108,
+ 109, 110, 111, 112, 113, 114, 115, 3, -1, -1,
+ -1, -1, -1, -1, -1, -1, 12, -1, -1, -1,
+ -1, 17, 18, -1, -1, -1, 22, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 32, -1, -1, -1,
+ -1, 4, 5, 6, 7, 8, 9, 10, 11, -1,
+ -1, -1, -1, 49, -1, -1, -1, -1, -1, 22,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 66, 67, 68, 69, 70, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 88, -1, 90, 91, 92, 93, 94, 95,
+ -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
+ 106, 107, 108, 109, 110, 111, 112, 113, 114, 115,
+ 3, 84, 85, 86, -1, -1, -1, -1, -1, 12,
+ -1, -1, -1, -1, 17, 18, -1, -1, -1, 22,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 32,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 49, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 66, 67, 68, 69, 70, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 88, -1, 90, 91, 92,
+ 93, 94, 95, -1, 97, -1, -1, 100, 101, 102,
+ 103, 104, 105, 106, 107, 108, 109, 110, 111, 112,
+ 113, 114, 115, 3, -1, -1, -1, -1, -1, -1,
+ -1, -1, 12, 31, -1, -1, -1, 17, 18, -1,
+ -1, -1, 22, -1, 42, 43, 44, 45, 46, 47,
+ 48, 49, 50, 51, 52, 53, 54, 55, 56, 57,
+ 58, 59, -1, -1, -1, -1, -1, 65, -1, 49,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 66, 67, 68, 69,
+ 70, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 88, -1,
+ 90, 91, 92, 93, 94, 95, -1, 97, -1, -1,
+ 100, 101, 102, 103, 104, 105, 106, 107, 108, 109,
+ 110, 111, 112, 113, 114, 115, 3, -1, -1, -1,
+ -1, -1, -1, -1, -1, 12, -1, -1, -1, -1,
+ 17, 18, -1, -1, -1, 22, -1, 33, -1, -1,
+ -1, -1, -1, -1, -1, 32, 42, 43, 44, 45,
+ 46, 47, 48, 49, 50, 51, 52, 53, 54, 55,
+ 56, 57, 58, 59, -1, -1, -1, -1, -1, 65,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 66,
+ 67, 68, 69, 70, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 88, -1, 90, 91, 92, 93, 94, 95, -1,
+ 97, -1, -1, 100, 101, 102, 103, 104, 105, 106,
+ 107, 108, 109, 110, 111, 112, 113, 114, 115, 3,
+ -1, -1, -1, -1, -1, -1, -1, -1, 12, -1,
+ -1, -1, -1, 17, 18, -1, -1, -1, 22, -1,
+ 33, -1, -1, -1, -1, -1, -1, -1, 32, 42,
+ 43, 44, 45, 46, 47, 48, 49, 50, 51, 52,
+ 53, 54, 55, 56, 57, 58, 59, -1, -1, -1,
+ -1, -1, 65, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 66, 67, 68, 69, 70, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 88, -1, 90, 91, 92, 93,
+ 94, 95, -1, 97, -1, -1, 100, 101, 102, 103,
+ 104, 105, 106, 107, 108, 109, 110, 111, 112, 113,
+ 114, 115, 3, -1, -1, -1, -1, -1, -1, -1,
+ -1, 12, -1, -1, -1, -1, 17, 18, -1, -1,
+ -1, 22, -1, 33, -1, -1, -1, -1, -1, -1,
+ -1, 32, 42, 43, 44, 45, 46, 47, 48, 49,
+ 50, 51, 52, 53, 54, 55, 56, 57, 58, 59,
+ -1, -1, -1, -1, -1, 65, -1, -1, -1, -1,
+ -1, 3, -1, -1, -1, 66, 67, 68, 69, 70,
+ 12, -1, -1, -1, -1, 17, 18, -1, -1, -1,
+ 22, -1, -1, -1, -1, -1, -1, 88, -1, 90,
+ 91, 92, 93, 94, 95, -1, 97, -1, -1, 100,
+ 101, 102, 103, 104, 105, 106, 107, 108, 109, 110,
+ 111, 112, 113, 114, 115, -1, -1, -1, -1, -1,
+ -1, -1, 64, -1, 66, 67, 68, 69, 70, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 88, -1, 90, 91,
+ 92, 93, 94, 95, -1, 97, -1, -1, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, 3, -1, -1, -1, -1, -1,
+ -1, -1, -1, 12, -1, -1, 34, -1, 17, 18,
+ -1, -1, -1, 22, 42, 43, 44, 45, 46, 47,
+ 48, 49, 50, 51, 52, 53, 54, 55, 56, 57,
+ 58, 59, -1, -1, -1, -1, -1, 65, -1, -1,
+ 49, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 3, -1, -1, -1, 66, 67, 68,
+ 69, 70, 12, -1, -1, -1, -1, 17, 18, -1,
+ -1, -1, 22, -1, -1, -1, -1, -1, -1, 88,
+ -1, 90, 91, 92, 93, 94, 95, -1, 97, -1,
+ -1, 100, 101, 102, 103, 104, 105, 106, 107, 108,
+ 109, 110, 111, 112, 113, 114, 115, -1, -1, -1,
+ -1, -1, 3, -1, 64, -1, 66, 67, 68, 69,
+ 70, 12, -1, -1, -1, -1, 17, 18, -1, -1,
+ -1, 22, -1, -1, -1, -1, -1, -1, 88, -1,
+ 90, 91, 92, 93, 94, 95, -1, 97, -1, -1,
+ 100, 101, 102, 103, 104, 105, 106, 107, 108, 109,
+ 110, 111, 112, 113, 114, 115, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 66, 67, 68, 69, 70,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 88, -1, 90,
+ 91, 92, 93, 94, 95, -1, 97, -1, -1, 100,
+ 101, 102, 103, 104, 105, 106, 107, 108, 109, 110,
+ 111, 112, 113, 114, 115, 35, -1, -1, -1, -1,
+ -1, -1, 42, 43, 44, 45, 46, 47, 48, 49,
+ 50, 51, 52, 53, 54, 55, 56, 57, 58, 59,
+ 35, -1, -1, -1, -1, 65, -1, 42, 43, 44,
+ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
+ 55, 56, 57, 58, 59, -1, -1, -1, 39, -1,
+ 65, 42, 43, 44, 45, 46, 47, 48, 49, 50,
+ 51, 52, 53, 54, 55, 56, 57, 58, 59, -1,
+ -1, -1, -1, -1, 65, 42, 43, 44, 45, 46,
+ 47, 48, 49, 50, 51, 52, 53, 54, 55, 56,
+ 57, 58, 59, -1, -1, -1, -1, -1, 65, 42,
+ 43, 44, 45, 46, 47, 48, 49, 50, 51, 52,
+ 53, 54, 55, 56, 57, 58, 59, -1, -1, -1,
+ -1, -1, 65, 42, 43, 44, 45, 46, 47, 48,
+ 49, 50, 51, 52, 53, 54, 55, 56, 57, 58,
+ 59, -1, -1, -1, -1, -1, 65, 42, 43, 44,
+ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
+ 55, 56, 57, 58, 59, -1, -1, -1, -1, -1,
+ 65
};
-#endif /* NDEBUG */
-
-#ifndef NDEBUG
-/* For tracing reduce actions, the names of all rules are required.
-*/
-static const char *const yyRuleName[] = {
- /* 0 */ "block ::= LIB QUOTED_STRING EOS",
- /* 1 */ "block ::= decl",
- /* 2 */ "block ::= impl",
- /* 3 */ "block ::= decl_typedef",
- /* 4 */ "block ::= constant",
- /* 5 */ "block ::= decl_struct",
- /* 6 */ "block ::= decl_union",
- /* 7 */ "block ::= decl_enum",
- /* 8 */ "optional_name ::=",
- /* 9 */ "optional_name ::= NAME",
- /* 10 */ "align_and_size ::=",
- /* 11 */ "align_and_size ::= COLON COLON LPAREN NUMBER COMMA NUMBER RPAREN",
- /* 12 */ "enum_name ::= ENUM optional_name",
- /* 13 */ "struct_name ::= STRUCT optional_name",
- /* 14 */ "union_name ::= UNION optional_name",
- /* 15 */ "decl_enum ::= enum_name LBRACE decl_enum_items RBRACE",
- /* 16 */ "decl_enum_items ::= decl_enum_item",
- /* 17 */ "decl_enum_items ::= decl_enum_items COMMA decl_enum_item",
- /* 18 */ "decl_enum_item ::= NAME EQUALS num_exp",
- /* 19 */ "decl_enum_item ::= NAME",
- /* 20 */ "decl_struct_args_block ::= LBRACE struct_args RBRACE",
- /* 21 */ "decl_struct_args ::= decl_struct_args_block",
- /* 22 */ "decl_struct_args ::= EOS",
- /* 23 */ "decl_struct ::= STRUCT NAME align_and_size decl_struct_args",
- /* 24 */ "decl_union ::= UNION NAME align_and_size decl_struct_args",
- /* 25 */ "const_type ::= BOOL|INT|FLOAT|STRING",
- /* 26 */ "constant ::= CONST const_type NSNAME EQUALS impl_def_val EOS",
- /* 27 */ "decl_typedef ::= TYPEDEF decl_typedef_body EOS",
- /* 28 */ "decl_typedef_body_ex ::= struct_name align_and_size decl_struct_args_block decl_var",
- /* 29 */ "decl_typedef_body_ex ::= union_name align_and_size decl_struct_args_block decl_var",
- /* 30 */ "decl_typedef_body_ex ::= decl_enum NAME",
- /* 31 */ "decl_typedef_body ::= decl_typedef_body_ex",
- /* 32 */ "decl_typedef_body_fn_args ::= LPAREN decl_args RPAREN",
- /* 33 */ "decl_typedef_body ::= decl_func decl_typedef_body_fn_args",
- /* 34 */ "decl_typedef_body ::= decl_arg",
- /* 35 */ "decl ::= decl_abi decl_func LPAREN decl_args RPAREN EOS",
- /* 36 */ "decl ::= decl_abi decl_func LPAREN decl_args COMMA ELLIPSIS RPAREN EOS",
- /* 37 */ "decl_func ::= decl_arg",
- /* 38 */ "decl_func ::= VOID NAME",
- /* 39 */ "decl_typedef_body ::= VOID indirection LPAREN indirection NAME RPAREN decl_typedef_body_fn_args",
- /* 40 */ "decl_typedef_body ::= CONST VOID pointers LPAREN indirection NAME RPAREN decl_typedef_body_fn_args",
- /* 41 */ "decl_abi ::= NAME",
- /* 42 */ "decl_var_array_size ::=",
- /* 43 */ "decl_var_array_size ::= LBRACKET NUMBER RBRACKET",
- /* 44 */ "decl_var ::= NAME decl_var_array_size",
- /* 45 */ "decl_var ::= pointers NAME decl_var_array_size",
- /* 46 */ "decl_vars ::= decl_var",
- /* 47 */ "decl_vars ::= decl_vars COMMA decl_var",
- /* 48 */ "decl_arg ::= const_decl_type decl_var",
- /* 49 */ "decl_typedef_body ::= const_decl_type indirection LPAREN indirection NAME RPAREN decl_typedef_body_fn_args",
- /* 50 */ "decl_arg ::= VOID pointers NAME",
- /* 51 */ "decl_arg ::= CONST VOID pointers NAME",
- /* 52 */ "decl_args ::=",
- /* 53 */ "decl_args ::= VOID",
- /* 54 */ "decl_args ::= decl_arg",
- /* 55 */ "decl_args ::= decl_args COMMA decl_arg",
- /* 56 */ "struct_args ::= struct_arg",
- /* 57 */ "struct_args ::= struct_args struct_arg",
- /* 58 */ "struct_arg ::= decl_typedef_body_ex EOS",
- /* 59 */ "struct_arg ::= decl_arg decl_layout EOS",
- /* 60 */ "decl_layout ::=",
- /* 61 */ "decl_layout ::= COLON COLON LPAREN NUMBER COMMA NUMBER RPAREN",
- /* 62 */ "decl_scalar_type ::= CHAR",
- /* 63 */ "decl_scalar_type ::= SHORT decl_scalar_type_short",
- /* 64 */ "decl_scalar_type_short ::=",
- /* 65 */ "decl_scalar_type_short ::= INT",
- /* 66 */ "decl_scalar_type ::= INT",
- /* 67 */ "decl_scalar_type ::= LONG decl_scalar_type_long",
- /* 68 */ "decl_scalar_type_long ::=",
- /* 69 */ "decl_scalar_type_long ::= DOUBLE",
- /* 70 */ "decl_scalar_type_long ::= LONG decl_scalar_type_long_long",
- /* 71 */ "decl_scalar_type_long_long ::=",
- /* 72 */ "decl_scalar_type_long_long ::= INT",
- /* 73 */ "decl_type ::= UNSIGNED decl_scalar_type",
- /* 74 */ "decl_type ::= SIGNED decl_scalar_type",
- /* 75 */ "decl_type ::= UNSIGNED",
- /* 76 */ "decl_type ::= SIGNED",
- /* 77 */ "decl_type ::= decl_scalar_type",
- /* 78 */ "decl_type ::= STRUCT NAME",
- /* 79 */ "decl_type ::= UNION NAME",
- /* 80 */ "decl_type ::= ENUM NAME",
- /* 81 */ "decl_type ::= FLOAT|DOUBLE|INT8|UINT8|INT16|UINT16|INT32|UINT32|INT64|UINT64|NAME",
- /* 82 */ "const_decl_type ::= decl_type",
- /* 83 */ "const_decl_type ::= CONST decl_type",
- /* 84 */ "impl ::= impl_func LBRACE impl_stmts RBRACE",
- /* 85 */ "impl ::= STATIC impl_func LBRACE impl_stmts RBRACE",
- /* 86 */ "impl_func ::= FUNCTION reference NSNAME LPAREN RPAREN COLON impl_type",
- /* 87 */ "impl_func ::= FUNCTION reference NSNAME LPAREN impl_args RPAREN COLON impl_type",
- /* 88 */ "impl_func ::= FUNCTION reference NSNAME LPAREN impl_args COMMA impl_type reference ELLIPSIS DOLLAR_NAME RPAREN COLON impl_type",
- /* 89 */ "impl_def_val ::= NULL|NUMBER|TRUE|FALSE|QUOTED_STRING",
- /* 90 */ "impl_var ::= reference DOLLAR_NAME",
- /* 91 */ "impl_type ::= VOID|MIXED|BOOL|INT|FLOAT|STRING|ARRAY|OBJECT|CALLABLE",
- /* 92 */ "impl_arg ::= impl_type impl_var",
- /* 93 */ "impl_arg ::= impl_type impl_var EQUALS impl_def_val",
- /* 94 */ "impl_args ::= impl_arg",
- /* 95 */ "impl_args ::= impl_args COMMA impl_arg",
- /* 96 */ "impl_stmts ::= impl_stmt",
- /* 97 */ "impl_stmts ::= impl_stmts impl_stmt",
- /* 98 */ "impl_stmt ::= return_stmt",
- /* 99 */ "impl_stmt ::= let_stmt",
- /* 100 */ "impl_stmt ::= set_stmt",
- /* 101 */ "impl_stmt ::= free_stmt",
- /* 102 */ "number ::= NUMBER|NSNAME",
- /* 103 */ "number ::= decl_var",
- /* 104 */ "num_exp ::= number",
- /* 105 */ "num_exp ::= LPAREN num_exp RPAREN",
- /* 106 */ "num_exp ::= num_exp PIPE|CARET|AMPERSAND|LSHIFT|RSHIFT|PLUS|MINUS|ASTERISK|SLASH|MODULO num_exp",
- /* 107 */ "num_exp ::= TILDE|NOT|PLUS|MINUS num_exp",
- /* 108 */ "let_exp ::= NULL",
- /* 109 */ "let_exp ::= AMPERSAND NULL",
- /* 110 */ "let_exp ::= let_callback",
- /* 111 */ "let_exp ::= let_calloc",
- /* 112 */ "let_exp ::= AMPERSAND let_calloc",
- /* 113 */ "let_exp ::= let_func",
- /* 114 */ "let_exp ::= AMPERSAND let_func",
- /* 115 */ "let_exp ::= num_exp",
- /* 116 */ "let_exp ::= AMPERSAND num_exp",
- /* 117 */ "let_exp ::= decl_var EQUALS let_exp",
- /* 118 */ "let_stmt ::= LET let_exp EOS",
- /* 119 */ "let_stmt ::= TEMP decl_var EQUALS reference decl_var EOS",
- /* 120 */ "let_callback ::= CALLBACK callback_rval LPAREN impl_var LPAREN callback_arg_list RPAREN RPAREN",
- /* 121 */ "let_calloc ::= CALLOC LPAREN num_exp COMMA num_exp RPAREN",
- /* 122 */ "let_func ::= ZVAL|OBJVAL|ARRVAL|PATHVAL|STRLEN|STRVAL|FLOATVAL|INTVAL|BOOLVAL|COUNT LPAREN impl_var RPAREN",
- /* 123 */ "let_func ::= ZVAL|OBJVAL|ARRVAL|PATHVAL|STRLEN|STRVAL|FLOATVAL|INTVAL|BOOLVAL|COUNT LPAREN impl_var COMMA let_exps RPAREN",
- /* 124 */ "let_exps ::= let_exp",
- /* 125 */ "let_exps ::= let_exps COMMA let_exp",
- /* 126 */ "callback_arg_list ::=",
- /* 127 */ "callback_arg_list ::= callback_args",
- /* 128 */ "callback_args ::= set_exp",
- /* 129 */ "callback_args ::= callback_args COMMA set_exp",
- /* 130 */ "callback_rval ::= ZVAL|OBJVAL|ARRVAL|PATHVAL|STRLEN|STRVAL|FLOATVAL|INTVAL|BOOLVAL|COUNT",
- /* 131 */ "callback_rval ::= VOID",
- /* 132 */ "set_func ::= TO_OBJECT|TO_ARRAY|TO_STRING|TO_INT|TO_FLOAT|TO_BOOL|ZVAL|VOID LPAREN decl_var RPAREN",
- /* 133 */ "set_func ::= TO_OBJECT|TO_ARRAY|TO_STRING|TO_INT|TO_FLOAT|TO_BOOL|ZVAL|VOID LPAREN decl_var COMMA set_exps RPAREN",
- /* 134 */ "set_func ::= TO_OBJECT|TO_ARRAY|TO_STRING|TO_INT|TO_FLOAT|TO_BOOL|ZVAL|VOID LPAREN decl_var COMMA ELLIPSIS RPAREN",
- /* 135 */ "set_exp ::= set_func",
- /* 136 */ "set_exp ::= num_exp",
- /* 137 */ "set_exps ::= set_exp",
- /* 138 */ "set_exps ::= set_exps COMMA set_exp",
- /* 139 */ "set_exp ::= impl_var EQUALS set_exp",
- /* 140 */ "set_stmt ::= SET set_exp EOS",
- /* 141 */ "return_stmt ::= RETURN set_func EOS",
- /* 142 */ "free_stmt ::= FREE free_exps EOS",
- /* 143 */ "free_exps ::= free_exp",
- /* 144 */ "free_exps ::= free_exps COMMA free_exp",
- /* 145 */ "free_exp ::= NAME LPAREN decl_vars RPAREN",
- /* 146 */ "reference ::=",
- /* 147 */ "reference ::= AMPERSAND",
- /* 148 */ "indirection ::=",
- /* 149 */ "indirection ::= pointers",
- /* 150 */ "pointers ::= ASTERISK",
- /* 151 */ "pointers ::= pointers ASTERISK",
- /* 152 */ "file ::= blocks",
- /* 153 */ "blocks ::= block",
- /* 154 */ "blocks ::= blocks block",
- /* 155 */ "block ::= EOF",
- /* 156 */ "block ::= EOS",
+
+ /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
+ symbol of state STATE-NUM. */
+static const unsigned short int yystos[] =
+{
+ 0, 4, 5, 6, 7, 8, 9, 10, 11, 17,
+ 22, 29, 30, 31, 41, 83, 84, 85, 86, 87,
+ 88, 89, 91, 116, 121, 123, 146, 147, 148, 149,
+ 150, 168, 173, 178, 179, 180, 181, 182, 183, 184,
+ 185, 190, 193, 194, 197, 201, 202, 203, 204, 205,
+ 206, 210, 212, 213, 219, 227, 239, 240, 9, 11,
+ 3, 12, 17, 18, 22, 32, 49, 66, 67, 68,
+ 69, 70, 88, 90, 91, 92, 93, 94, 95, 97,
+ 100, 101, 102, 103, 104, 105, 106, 107, 108, 109,
+ 110, 111, 112, 113, 114, 115, 143, 236, 237, 238,
+ 255, 267, 22, 84, 85, 86, 87, 202, 210, 179,
+ 30, 66, 67, 68, 69, 70, 71, 72, 73, 74,
+ 75, 76, 77, 79, 80, 81, 82, 151, 152, 153,
+ 154, 156, 157, 158, 17, 84, 85, 121, 174, 176,
+ 203, 204, 210, 219, 228, 229, 143, 143, 143, 230,
+ 3, 6, 10, 12, 17, 169, 170, 179, 26, 123,
+ 202, 240, 44, 275, 276, 22, 83, 201, 202, 0,
+ 148, 143, 211, 235, 236, 4, 5, 6, 9, 22,
+ 186, 6, 183, 189, 31, 125, 191, 32, 32, 36,
+ 36, 235, 236, 87, 32, 143, 124, 238, 143, 143,
+ 143, 34, 195, 19, 20, 21, 121, 123, 124, 143,
+ 159, 160, 30, 0, 3, 4, 5, 6, 7, 8,
+ 9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
+ 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
+ 29, 31, 32, 33, 34, 35, 36, 37, 38, 39,
+ 40, 41, 42, 43, 44, 45, 46, 47, 48, 49,
+ 50, 51, 52, 53, 54, 55, 56, 57, 58, 59,
+ 60, 61, 62, 63, 64, 65, 66, 67, 68, 69,
+ 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
+ 81, 83, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, 116, 119, 121, 122, 123, 124,
+ 125, 144, 163, 164, 163, 26, 119, 155, 143, 159,
+ 25, 27, 28, 32, 47, 48, 60, 61, 78, 142,
+ 143, 165, 224, 143, 143, 230, 143, 230, 176, 31,
+ 143, 35, 233, 233, 233, 233, 236, 23, 31, 202,
+ 36, 198, 36, 23, 174, 191, 198, 38, 234, 32,
+ 143, 6, 187, 6, 9, 188, 186, 32, 31, 17,
+ 87, 178, 207, 208, 209, 210, 207, 143, 220, 221,
+ 92, 93, 94, 95, 96, 98, 99, 246, 247, 248,
+ 261, 264, 270, 271, 272, 143, 235, 196, 211, 236,
+ 118, 163, 144, 26, 27, 32, 44, 226, 165, 32,
+ 143, 165, 32, 42, 43, 44, 45, 46, 47, 48,
+ 49, 50, 51, 52, 53, 54, 55, 56, 57, 58,
+ 59, 65, 141, 31, 35, 36, 215, 215, 31, 214,
+ 215, 214, 32, 143, 40, 198, 0, 3, 4, 5,
+ 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
+ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
+ 26, 27, 28, 29, 31, 32, 33, 34, 35, 38,
+ 39, 40, 41, 42, 43, 44, 45, 46, 47, 48,
+ 49, 50, 51, 52, 53, 54, 55, 56, 57, 58,
+ 59, 60, 61, 62, 63, 64, 65, 66, 67, 68,
+ 69, 70, 71, 72, 73, 74, 75, 76, 77, 78,
+ 79, 81, 83, 84, 85, 86, 87, 88, 89, 90,
+ 91, 92, 93, 94, 95, 96, 97, 98, 99, 100,
+ 101, 102, 103, 104, 105, 106, 107, 108, 109, 110,
+ 111, 112, 113, 114, 115, 116, 119, 121, 122, 123,
+ 124, 125, 145, 198, 199, 200, 246, 32, 31, 31,
+ 19, 23, 25, 27, 32, 39, 124, 142, 211, 222,
+ 223, 224, 235, 234, 6, 26, 192, 236, 17, 235,
+ 33, 34, 34, 33, 34, 40, 34, 231, 211, 251,
+ 222, 243, 265, 266, 267, 275, 211, 143, 273, 274,
+ 211, 262, 266, 37, 247, 222, 33, 143, 34, 32,
+ 179, 225, 226, 22, 33, 143, 165, 166, 167, 165,
+ 165, 32, 121, 175, 176, 177, 178, 216, 219, 228,
+ 229, 211, 211, 235, 19, 20, 21, 26, 171, 172,
+ 222, 37, 200, 37, 3, 6, 10, 12, 13, 14,
+ 15, 16, 17, 33, 241, 242, 244, 245, 22, 87,
+ 178, 222, 39, 222, 39, 65, 141, 143, 26, 33,
+ 236, 234, 64, 17, 209, 234, 64, 222, 221, 37,
+ 40, 31, 40, 31, 32, 24, 40, 32, 31, 34,
+ 32, 31, 31, 33, 211, 64, 143, 161, 162, 235,
+ 33, 33, 33, 34, 35, 25, 177, 35, 232, 37,
+ 175, 233, 233, 143, 31, 35, 33, 34, 243, 33,
+ 33, 222, 222, 33, 33, 33, 19, 89, 90, 109,
+ 222, 250, 252, 253, 254, 255, 276, 265, 211, 275,
+ 196, 274, 17, 196, 263, 33, 34, 165, 165, 34,
+ 25, 35, 34, 217, 232, 215, 215, 33, 244, 35,
+ 242, 244, 40, 222, 35, 234, 234, 109, 252, 17,
+ 18, 32, 255, 258, 32, 32, 250, 34, 268, 211,
+ 33, 33, 163, 64, 143, 25, 35, 32, 211, 218,
+ 31, 217, 244, 275, 171, 222, 263, 32, 222, 243,
+ 64, 265, 269, 33, 31, 97, 33, 35, 25, 232,
+ 34, 31, 64, 33, 243, 34, 34, 256, 33, 34,
+ 18, 266, 267, 32, 34, 211, 24, 97, 32, 222,
+ 211, 249, 250, 251, 257, 276, 33, 265, 25, 25,
+ 232, 33, 258, 259, 260, 265, 33, 34, 250, 34,
+ 33, 35, 32, 33, 34, 249, 25, 244, 243, 33,
+ 265, 33, 32, 259, 33, 33
};
-#endif /* NDEBUG */
-
-
-#if YYSTACKDEPTH<=0
-/*
-** Try to increase the size of the parser stack. Return the number
-** of errors. Return 0 on success.
-*/
-static int yyGrowStack(yyParser *p){
- int newSize;
- int idx;
- yyStackEntry *pNew;
-
- newSize = p->yystksz*2 + 100;
- idx = p->yytos ? (int)(p->yytos - p->yystack) : 0;
- if( p->yystack==&p->yystk0 ){
- pNew = malloc(newSize*sizeof(pNew[0]));
- if( pNew ) pNew[0] = p->yystk0;
- }else{
- pNew = realloc(p->yystack, newSize*sizeof(pNew[0]));
- }
- if( pNew ){
- p->yystack = pNew;
- p->yytos = &p->yystack[idx];
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sStack grows from %d to %d entries.\n",
- yyTracePrompt, p->yystksz, newSize);
- }
+
+ /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
+static const unsigned short int yyr1[] =
+{
+ 0, 140, 141, 141, 141, 141, 141, 141, 141, 141,
+ 141, 141, 141, 141, 141, 141, 141, 141, 141, 141,
+ 142, 142, 142, 142, 143, 143, 143, 143, 143, 143,
+ 143, 143, 143, 143, 143, 143, 143, 143, 143, 143,
+ 143, 143, 143, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
+ 144, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
+ 145, 145, 145, 145, 145, 145, 145, 146, 146, 147,
+ 147, 148, 148, 148, 148, 148, 148, 148, 148, 148,
+ 148, 148, 148, 148, 148, 149, 150, 150, 151, 151,
+ 151, 151, 151, 151, 151, 151, 152, 152, 153, 153,
+ 154, 154, 154, 155, 155, 156, 156, 157, 157, 157,
+ 158, 158, 159, 159, 159, 159, 159, 159, 159, 160,
+ 160, 161, 161, 161, 161, 162, 162, 163, 163, 164,
+ 164, 165, 165, 165, 165, 165, 165, 165, 165, 165,
+ 165, 165, 166, 166, 167, 167, 168, 169, 170, 170,
+ 170, 170, 171, 171, 171, 172, 172, 172, 172, 173,
+ 173, 173, 174, 174, 175, 175, 176, 176, 176, 176,
+ 176, 177, 177, 177, 177, 177, 178, 178, 178, 179,
+ 179, 180, 180, 180, 181, 181, 181, 182, 182, 182,
+ 183, 183, 184, 184, 184, 185, 185, 185, 185, 186,
+ 186, 186, 186, 186, 186, 187, 187, 188, 188, 188,
+ 188, 189, 189, 189, 190, 190, 191, 191, 192, 192,
+ 193, 194, 195, 195, 196, 196, 197, 197, 197, 198,
+ 199, 199, 200, 200, 201, 201, 202, 202, 203, 203,
+ 204, 204, 205, 205, 205, 205, 206, 206, 207, 207,
+ 207, 208, 208, 209, 209, 209, 209, 210, 210, 210,
+ 210, 211, 211, 212, 213, 214, 214, 215, 216, 216,
+ 217, 217, 218, 218, 219, 220, 220, 221, 221, 222,
+ 222, 222, 222, 222, 222, 223, 223, 223, 223, 223,
+ 223, 224, 224, 225, 225, 226, 226, 226, 227, 228,
+ 229, 230, 230, 231, 231, 232, 232, 232, 232, 233,
+ 233, 234, 234, 234, 234, 235, 235, 236, 236, 237,
+ 237, 238, 238, 239, 239, 240, 240, 240, 241, 241,
+ 242, 242, 243, 244, 245, 245, 245, 245, 245, 245,
+ 245, 245, 245, 246, 246, 247, 247, 247, 247, 247,
+ 248, 248, 249, 249, 249, 250, 250, 250, 250, 250,
+ 250, 251, 251, 252, 253, 253, 254, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 256, 256, 257,
+ 257, 258, 258, 259, 259, 260, 260, 261, 262, 262,
+ 263, 263, 263, 264, 265, 265, 265, 266, 266, 267,
+ 267, 267, 267, 267, 267, 267, 267, 268, 268, 269,
+ 269, 270, 271, 271, 272, 273, 273, 274, 275, 275,
+ 276
+};
+
+ /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
+static const unsigned char yyr2[] =
+{
+ 0, 2, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 0, 1, 1,
+ 2, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 3, 2, 3, 2, 2,
+ 1, 2, 2, 2, 1, 2, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 6,
+ 2, 0, 1, 1, 3, 1, 3, 0, 1, 1,
+ 2, 3, 2, 3, 5, 2, 4, 1, 1, 1,
+ 1, 4, 0, 1, 1, 3, 6, 1, 1, 1,
+ 1, 1, 0, 1, 1, 1, 1, 1, 1, 3,
+ 4, 4, 1, 2, 1, 2, 1, 1, 2, 4,
+ 4, 1, 1, 1, 3, 3, 2, 2, 1, 1,
+ 1, 2, 2, 2, 1, 1, 1, 1, 1, 2,
+ 1, 1, 1, 1, 2, 1, 1, 2, 2, 0,
+ 1, 1, 2, 1, 2, 0, 1, 0, 1, 1,
+ 2, 0, 1, 2, 3, 4, 0, 4, 1, 2,
+ 2, 3, 0, 2, 1, 3, 3, 3, 4, 3,
+ 1, 2, 1, 1, 1, 2, 1, 1, 5, 7,
+ 5, 7, 6, 7, 6, 5, 1, 2, 0, 1,
+ 1, 1, 3, 1, 2, 3, 2, 1, 2, 4,
+ 3, 3, 2, 4, 4, 1, 1, 3, 4, 5,
+ 0, 2, 2, 4, 5, 1, 3, 1, 3, 1,
+ 4, 3, 3, 2, 5, 1, 1, 1, 1, 1,
+ 1, 4, 2, 1, 2, 2, 1, 1, 2, 2,
+ 2, 0, 1, 0, 1, 0, 2, 7, 9, 0,
+ 7, 0, 2, 3, 3, 0, 1, 1, 2, 1,
+ 2, 1, 2, 4, 5, 7, 8, 13, 1, 3,
+ 2, 4, 2, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 2, 1, 1, 1, 1, 1,
+ 3, 6, 1, 2, 1, 1, 1, 1, 2, 1,
+ 1, 3, 4, 6, 8, 12, 5, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 0, 2, 1,
+ 3, 1, 1, 0, 1, 1, 3, 3, 6, 1,
+ 0, 1, 1, 3, 1, 1, 3, 5, 6, 1,
+ 1, 1, 1, 1, 1, 1, 1, 0, 2, 1,
+ 3, 3, 1, 1, 3, 1, 3, 4, 0, 1,
+ 1
+};
+
+
+/* YYDPREC[RULE-NUM] -- Dynamic precedence of rule #RULE-NUM (0 if none). */
+static const unsigned char yydprec[] =
+{
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 1, 2, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 2, 1, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 2, 1, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 2, 1, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0
+};
+
+/* YYMERGER[RULE-NUM] -- Index of merging function for rule #RULE-NUM. */
+static const unsigned char yymerger[] =
+{
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0
+};
+
+/* YYIMMEDIATE[RULE-NUM] -- True iff rule #RULE-NUM is not to be deferred, as
+ in the case of predicates. */
+static const yybool yyimmediate[] =
+{
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0
+};
+
+/* YYCONFLP[YYPACT[STATE-NUM]] -- Pointer into YYCONFL of start of
+ list of conflicting reductions corresponding to action entry for
+ state STATE-NUM in yytable. 0 means no conflicts. The list in
+ yyconfl is terminated by a rule number of 0. */
+static const unsigned short int yyconflp[] =
+{
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 255, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 257, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 263, 0, 265, 267, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 271, 0, 273,
+ 275, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 259, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 5, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 261, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 269, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 253, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 277, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 9, 0, 0, 11, 13, 15, 17, 19,
+ 21, 23, 25, 27, 29, 31, 33, 35, 37, 39,
+ 41, 43, 45, 47, 49, 51, 53, 55, 57, 59,
+ 61, 63, 65, 67, 69, 71, 73, 75, 77, 79,
+ 81, 83, 85, 87, 89, 91, 93, 95, 97, 99,
+ 101, 103, 105, 107, 109, 111, 113, 115, 117, 119,
+ 121, 123, 125, 127, 129, 131, 133, 135, 137, 139,
+ 141, 143, 145, 147, 149, 151, 153, 155, 157, 159,
+ 161, 163, 0, 165, 0, 167, 169, 171, 173, 175,
+ 177, 179, 181, 183, 185, 187, 189, 191, 193, 195,
+ 197, 199, 201, 203, 205, 207, 209, 211, 213, 215,
+ 217, 219, 221, 223, 225, 227, 229, 231, 233, 0,
+ 235, 237, 0, 239, 241, 243, 245, 247, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 1, 0, 0, 0, 0, 3,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 249, 0, 0, 0,
+ 0, 251, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 279, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 281
+};
+
+/* YYCONFL[I] -- lists of conflicting rule numbers, each terminated by
+ 0, pointed into by YYCONFLP. */
+static const short int yyconfl[] =
+{
+ 0, 396, 0, 396, 0, 409, 0, 467, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 615,
+ 0, 615, 0, 615, 0, 615, 0, 615, 0, 396,
+ 0, 396, 0, 409, 0, 512, 0, 512, 0, 460,
+ 0, 42, 0, 498, 0, 498, 0, 498, 0, 396,
+ 0, 565, 0, 565, 0, 565, 0, 616, 0, 344,
+ 0, 494, 0
+};
+
+/* Error token number */
+#define YYTERROR 1
+
+
+
+
+#undef yynerrs
+#define yynerrs (yystackp->yyerrcnt)
+#undef yychar
+#define yychar (yystackp->yyrawchar)
+#undef yylval
+#define yylval (yystackp->yyval)
+#undef yylloc
+#define yylloc (yystackp->yyloc)
+#define psi_parser_proc_nerrs yynerrs
+#define psi_parser_proc_char yychar
+#define psi_parser_proc_lval yylval
+#define psi_parser_proc_lloc yylloc
+
+static const int YYEOF = 0;
+static const int YYEMPTY = -2;
+
+typedef enum { yyok, yyaccept, yyabort, yyerr } YYRESULTTAG;
+
+#define YYCHK(YYE) \
+ do { \
+ YYRESULTTAG yychk_flag = YYE; \
+ if (yychk_flag != yyok) \
+ return yychk_flag; \
+ } while (0)
+
+#if YYDEBUG
+
+# ifndef YYFPRINTF
+# define YYFPRINTF fprintf
+# endif
+
+/* This macro is provided for backward compatibility. */
+#ifndef YY_LOCATION_PRINT
+# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
#endif
- p->yystksz = newSize;
- }
- return pNew==0;
+
+
+# define YYDPRINTF(Args) \
+ do { \
+ if (yydebug) \
+ YYFPRINTF Args; \
+ } while (0)
+
+
+/*----------------------------------------.
+| Print this symbol's value on YYOUTPUT. |
+`----------------------------------------*/
+
+static void
+yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ FILE *yyo = yyoutput;
+ YYUSE (yyo);
+ YYUSE (P);
+ YYUSE (tokens);
+ YYUSE (index);
+ if (!yyvaluep)
+ return;
+ YYUSE (yytype);
}
-#endif
-/* Datatype of the argument to the memory allocated passed as the
-** second argument to ParseAlloc() below. This can be changed by
-** putting an appropriate #define in the %include section of the input
-** grammar.
-*/
-#ifndef YYMALLOCARGTYPE
-# define YYMALLOCARGTYPE size_t
+
+/*--------------------------------.
+| Print this symbol on YYOUTPUT. |
+`--------------------------------*/
+
+static void
+yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ YYFPRINTF (yyoutput, "%s %s (",
+ yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
+
+ yy_symbol_value_print (yyoutput, yytype, yyvaluep, P, tokens, index);
+ YYFPRINTF (yyoutput, ")");
+}
+
+# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
+ do { \
+ if (yydebug) \
+ { \
+ YYFPRINTF (stderr, "%s ", Title); \
+ yy_symbol_print (stderr, Type, Value, P, tokens, index); \
+ YYFPRINTF (stderr, "\n"); \
+ } \
+ } while (0)
+
+/* Nonzero means print parse trace. It is left uninitialized so that
+ multiple parsers can coexist. */
+int yydebug;
+
+struct yyGLRStack;
+static void yypstack (struct yyGLRStack* yystackp, size_t yyk)
+ YY_ATTRIBUTE_UNUSED;
+static void yypdumpstack (struct yyGLRStack* yystackp)
+ YY_ATTRIBUTE_UNUSED;
+
+#else /* !YYDEBUG */
+
+# define YYDPRINTF(Args)
+# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
+
+#endif /* !YYDEBUG */
+
+/* YYINITDEPTH -- initial size of the parser's stacks. */
+#ifndef YYINITDEPTH
+# define YYINITDEPTH 200
#endif
-/* Initialize a new parser that has already been allocated.
-*/
-void ParseInit(void *yypParser){
- yyParser *pParser = (yyParser*)yypParser;
-#ifdef YYTRACKMAXSTACKDEPTH
- pParser->yyhwm = 0;
+/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
+ if the built-in stack extension method is used).
+
+ Do not make this value too large; the results are undefined if
+ SIZE_MAX < YYMAXDEPTH * sizeof (GLRStackItem)
+ evaluated with infinite-precision integer arithmetic. */
+
+#ifndef YYMAXDEPTH
+# define YYMAXDEPTH 10000
#endif
-#if YYSTACKDEPTH<=0
- pParser->yytos = NULL;
- pParser->yystack = NULL;
- pParser->yystksz = 0;
- if( yyGrowStack(pParser) ){
- pParser->yystack = &pParser->yystk0;
- pParser->yystksz = 1;
- }
+
+/* Minimum number of free items on the stack allowed after an
+ allocation. This is to allow allocation and initialization
+ to be completed by functions that call yyexpandGLRStack before the
+ stack is expanded, thus insuring that all necessary pointers get
+ properly redirected to new data. */
+#define YYHEADROOM 2
+
+#ifndef YYSTACKEXPANDABLE
+# define YYSTACKEXPANDABLE 1
#endif
-#ifndef YYNOERRORRECOVERY
- pParser->yyerrcnt = -1;
+
+#if YYSTACKEXPANDABLE
+# define YY_RESERVE_GLRSTACK(Yystack) \
+ do { \
+ if (Yystack->yyspaceLeft < YYHEADROOM) \
+ yyexpandGLRStack (Yystack); \
+ } while (0)
+#else
+# define YY_RESERVE_GLRSTACK(Yystack) \
+ do { \
+ if (Yystack->yyspaceLeft < YYHEADROOM) \
+ yyMemoryExhausted (Yystack); \
+ } while (0)
#endif
- pParser->yytos = pParser->yystack;
- pParser->yystack[0].stateno = 0;
- pParser->yystack[0].major = 0;
-}
-
-#ifndef Parse_ENGINEALWAYSONSTACK
-/*
-** This function allocates a new parser.
-** The only argument is a pointer to a function which works like
-** malloc.
-**
-** Inputs:
-** A pointer to the function used to allocate memory.
-**
-** Outputs:
-** A pointer to a parser. This pointer is used in subsequent calls
-** to Parse and ParseFree.
-*/
-void *ParseAlloc(void *(*mallocProc)(YYMALLOCARGTYPE)){
- yyParser *pParser;
- pParser = (yyParser*)(*mallocProc)( (YYMALLOCARGTYPE)sizeof(yyParser) );
- if( pParser ) ParseInit(pParser);
- return pParser;
-}
-#endif /* Parse_ENGINEALWAYSONSTACK */
-
-
-/* The following function deletes the "minor type" or semantic value
-** associated with a symbol. The symbol can be either a terminal
-** or nonterminal. "yymajor" is the symbol code, and "yypminor" is
-** a pointer to the value to be deleted. The code used to do the
-** deletions is derived from the %destructor and/or %token_destructor
-** directives of the input grammar.
-*/
-static void yy_destructor(
- yyParser *yypParser, /* The parser */
- YYCODETYPE yymajor, /* Type code for object to destroy */
- YYMINORTYPE *yypminor /* The object to be destroyed */
-){
- ParseARG_FETCH;
- switch( yymajor ){
- /* Here is inserted the actions which take place when a
- ** terminal or non-terminal is destroyed. This can happen
- ** when the symbol is popped from the stack during a
- ** reduce or during error processing or when a parser is
- ** being destroyed before it is finished parsing.
- **
- ** Note: during a reduce, the only symbols destroyed are those
- ** which appear on the RHS of the rule, but which are *not* used
- ** inside the C code.
- */
-/********* Begin destructor definitions ***************************************/
- /* TERMINAL Destructor */
- case 1: /* BOOL */
- case 2: /* INT */
- case 3: /* FLOAT */
- case 4: /* STRING */
- case 5: /* DOUBLE */
- case 6: /* INT8 */
- case 7: /* UINT8 */
- case 8: /* INT16 */
- case 9: /* UINT16 */
- case 10: /* INT32 */
- case 11: /* UINT32 */
- case 12: /* INT64 */
- case 13: /* UINT64 */
- case 14: /* NAME */
- case 15: /* NULL */
- case 16: /* NUMBER */
- case 17: /* TRUE */
- case 18: /* FALSE */
- case 19: /* QUOTED_STRING */
- case 20: /* NSNAME */
- case 21: /* PIPE */
- case 22: /* CARET */
- case 23: /* AMPERSAND */
- case 24: /* LSHIFT */
- case 25: /* RSHIFT */
- case 26: /* PLUS */
- case 27: /* MINUS */
- case 28: /* ASTERISK */
- case 29: /* SLASH */
- case 30: /* MODULO */
- case 31: /* TILDE */
- case 32: /* NOT */
- case 33: /* ZVAL */
- case 34: /* OBJVAL */
- case 35: /* ARRVAL */
- case 36: /* PATHVAL */
- case 37: /* STRLEN */
- case 38: /* STRVAL */
- case 39: /* FLOATVAL */
- case 40: /* INTVAL */
- case 41: /* BOOLVAL */
- case 42: /* COUNT */
- case 43: /* TO_OBJECT */
- case 44: /* TO_ARRAY */
- case 45: /* TO_STRING */
- case 46: /* TO_INT */
- case 47: /* TO_FLOAT */
- case 48: /* TO_BOOL */
- case 49: /* VOID */
- case 50: /* MIXED */
- case 51: /* ARRAY */
- case 52: /* OBJECT */
- case 53: /* CALLABLE */
- case 54: /* TEMP */
- case 55: /* FREE */
- case 56: /* SET */
- case 57: /* LET */
- case 58: /* RETURN */
- case 59: /* CALLOC */
- case 60: /* CALLBACK */
- case 61: /* LIB */
- case 62: /* EOF */
- case 63: /* EOS */
- case 64: /* COLON */
- case 65: /* LPAREN */
- case 66: /* COMMA */
- case 67: /* RPAREN */
- case 68: /* ENUM */
- case 69: /* STRUCT */
- case 70: /* UNION */
- case 71: /* LBRACE */
- case 72: /* RBRACE */
- case 73: /* EQUALS */
- case 74: /* CONST */
- case 75: /* TYPEDEF */
- case 76: /* ELLIPSIS */
- case 77: /* LBRACKET */
- case 78: /* RBRACKET */
- case 79: /* CHAR */
- case 80: /* SHORT */
- case 81: /* LONG */
- case 82: /* UNSIGNED */
- case 83: /* SIGNED */
- case 84: /* STATIC */
- case 85: /* FUNCTION */
- case 86: /* DOLLAR_NAME */
-{
-#line 37 "src/parser_proc.y"
-free((yypminor->yy0));
-#line 1092 "src/parser_proc.c"
-}
- break;
- /* Default NON-TERMINAL Destructor */
- case 87: /* error */
- case 94: /* align_and_size */
- case 142: /* reference */
- case 143: /* indirection */
- case 144: /* pointers */
- case 145: /* file */
- case 146: /* blocks */
- case 147: /* block */
- case 148: /* optional_name */
- case 149: /* enum_name */
- case 150: /* struct_name */
- case 151: /* union_name */
- case 152: /* decl_var_array_size */
- case 153: /* decl_scalar_type */
- case 154: /* decl_scalar_type_short */
- case 155: /* decl_scalar_type_long */
- case 156: /* decl_scalar_type_long_long */
- case 157: /* callback_rval */
-{
-#line 38 "src/parser_proc.y"
-(void)P;
-#line 1117 "src/parser_proc.c"
-}
- break;
- case 88: /* decl_enum */
-{
-#line 60 "src/parser_proc.y"
-psi_decl_enum_free(&(yypminor->yy63));
-#line 1124 "src/parser_proc.c"
-}
- break;
- case 89: /* decl_enum_items */
- case 91: /* decl_struct_args_block */
- case 92: /* decl_struct_args */
- case 101: /* decl_typedef_body_fn_args */
- case 106: /* decl_vars */
- case 108: /* decl_args */
- case 109: /* struct_args */
- case 119: /* impl_args */
- case 121: /* impl_stmts */
- case 132: /* let_exps */
- case 135: /* set_exps */
- case 139: /* free_exps */
-{
-#line 62 "src/parser_proc.y"
-psi_plist_free((yypminor->yy163));
-#line 1142 "src/parser_proc.c"
+
+
+#if YYERROR_VERBOSE
+
+# ifndef yystpcpy
+# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
+# define yystpcpy stpcpy
+# else
+/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
+ YYDEST. */
+static char *
+yystpcpy (char *yydest, const char *yysrc)
+{
+ char *yyd = yydest;
+ const char *yys = yysrc;
+
+ while ((*yyd++ = *yys++) != '\0')
+ continue;
+
+ return yyd - 1;
}
- break;
- case 90: /* decl_enum_item */
-{
-#line 64 "src/parser_proc.y"
-psi_decl_enum_item_free(&(yypminor->yy217));
-#line 1149 "src/parser_proc.c"
+# endif
+# endif
+
+# ifndef yytnamerr
+/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
+ quotes and backslashes, so that it's suitable for yyerror. The
+ heuristic is that double-quoting is unnecessary unless the string
+ contains an apostrophe, a comma, or backslash (other than
+ backslash-backslash). YYSTR is taken from yytname. If YYRES is
+ null, do not copy; instead, return the length of what the result
+ would have been. */
+static size_t
+yytnamerr (char *yyres, const char *yystr)
+{
+ if (*yystr == '"')
+ {
+ size_t yyn = 0;
+ char const *yyp = yystr;
+
+ for (;;)
+ switch (*++yyp)
+ {
+ case '\'':
+ case ',':
+ goto do_not_strip_quotes;
+
+ case '\\':
+ if (*++yyp != '\\')
+ goto do_not_strip_quotes;
+ /* Fall through. */
+ default:
+ if (yyres)
+ yyres[yyn] = *yyp;
+ yyn++;
+ break;
+
+ case '"':
+ if (yyres)
+ yyres[yyn] = '\0';
+ return yyn;
+ }
+ do_not_strip_quotes: ;
+ }
+
+ if (! yyres)
+ return strlen (yystr);
+
+ return yystpcpy (yyres, yystr) - yyres;
}
- break;
- case 93: /* decl_struct */
+# endif
+
+#endif /* !YYERROR_VERBOSE */
+
+/** State numbers, as in LALR(1) machine */
+typedef int yyStateNum;
+
+/** Rule numbers, as in LALR(1) machine */
+typedef int yyRuleNum;
+
+/** Grammar symbol */
+typedef int yySymbol;
+
+/** Item references, as in LALR(1) machine */
+typedef short int yyItemNum;
+
+typedef struct yyGLRState yyGLRState;
+typedef struct yyGLRStateSet yyGLRStateSet;
+typedef struct yySemanticOption yySemanticOption;
+typedef union yyGLRStackItem yyGLRStackItem;
+typedef struct yyGLRStack yyGLRStack;
+
+struct yyGLRState {
+ /** Type tag: always true. */
+ yybool yyisState;
+ /** Type tag for yysemantics. If true, yysval applies, otherwise
+ * yyfirstVal applies. */
+ yybool yyresolved;
+ /** Number of corresponding LALR(1) machine state. */
+ yyStateNum yylrState;
+ /** Preceding state in this stack */
+ yyGLRState* yypred;
+ /** Source position of the last token produced by my symbol */
+ size_t yyposn;
+ union {
+ /** First in a chain of alternative reductions producing the
+ * non-terminal corresponding to this state, threaded through
+ * yynext. */
+ yySemanticOption* yyfirstVal;
+ /** Semantic value for this state. */
+ YYSTYPE yysval;
+ } yysemantics;
+};
+
+struct yyGLRStateSet {
+ yyGLRState** yystates;
+ /** During nondeterministic operation, yylookaheadNeeds tracks which
+ * stacks have actually needed the current lookahead. During deterministic
+ * operation, yylookaheadNeeds[0] is not maintained since it would merely
+ * duplicate yychar != YYEMPTY. */
+ yybool* yylookaheadNeeds;
+ size_t yysize, yycapacity;
+};
+
+struct yySemanticOption {
+ /** Type tag: always false. */
+ yybool yyisState;
+ /** Rule number for this reduction */
+ yyRuleNum yyrule;
+ /** The last RHS state in the list of states to be reduced. */
+ yyGLRState* yystate;
+ /** The lookahead for this reduction. */
+ int yyrawchar;
+ YYSTYPE yyval;
+ /** Next sibling in chain of options. To facilitate merging,
+ * options are chained in decreasing order by address. */
+ yySemanticOption* yynext;
+};
+
+/** Type of the items in the GLR stack. The yyisState field
+ * indicates which item of the union is valid. */
+union yyGLRStackItem {
+ yyGLRState yystate;
+ yySemanticOption yyoption;
+};
+
+struct yyGLRStack {
+ int yyerrState;
+
+
+ int yyerrcnt;
+ int yyrawchar;
+ YYSTYPE yyval;
+
+ YYJMP_BUF yyexception_buffer;
+ yyGLRStackItem* yyitems;
+ yyGLRStackItem* yynextFree;
+ size_t yyspaceLeft;
+ yyGLRState* yysplitPoint;
+ yyGLRState* yylastDeleted;
+ yyGLRStateSet yytops;
+};
+
+#if YYSTACKEXPANDABLE
+static void yyexpandGLRStack (yyGLRStack* yystackp);
+#endif
+
+static _Noreturn void
+yyFail (yyGLRStack* yystackp, struct psi_parser *P, struct psi_plist *tokens, size_t *index, const char* yymsg)
{
-#line 70 "src/parser_proc.y"
-psi_decl_struct_free(&(yypminor->yy275));
-#line 1156 "src/parser_proc.c"
+ if (yymsg != YY_NULLPTR)
+ yyerror (P, tokens, index, yymsg);
+ YYLONGJMP (yystackp->yyexception_buffer, 1);
}
- break;
- case 95: /* decl_union */
+
+static _Noreturn void
+yyMemoryExhausted (yyGLRStack* yystackp)
{
-#line 73 "src/parser_proc.y"
-psi_decl_union_free(&(yypminor->yy271));
-#line 1163 "src/parser_proc.c"
+ YYLONGJMP (yystackp->yyexception_buffer, 2);
}
- break;
- case 96: /* const_type */
+
+#if YYDEBUG || YYERROR_VERBOSE
+/** A printable representation of TOKEN. */
+static inline const char*
+yytokenName (yySymbol yytoken)
{
-#line 75 "src/parser_proc.y"
-psi_const_type_free(&(yypminor->yy171));
-#line 1170 "src/parser_proc.c"
+ if (yytoken == YYEMPTY)
+ return "";
+
+ return yytname[yytoken];
}
- break;
- case 97: /* constant */
+#endif
+
+/** Fill in YYVSP[YYLOW1 .. YYLOW0-1] from the chain of states starting
+ * at YYVSP[YYLOW0].yystate.yypred. Leaves YYVSP[YYLOW1].yystate.yypred
+ * containing the pointer to the next state in the chain. */
+static void yyfillin (yyGLRStackItem *, int, int) YY_ATTRIBUTE_UNUSED;
+static void
+yyfillin (yyGLRStackItem *yyvsp, int yylow0, int yylow1)
{
-#line 77 "src/parser_proc.y"
-psi_const_free(&(yypminor->yy154));
-#line 1177 "src/parser_proc.c"
+ int i;
+ yyGLRState *s = yyvsp[yylow0].yystate.yypred;
+ for (i = yylow0-1; i >= yylow1; i -= 1)
+ {
+#if YYDEBUG
+ yyvsp[i].yystate.yylrState = s->yylrState;
+#endif
+ yyvsp[i].yystate.yyresolved = s->yyresolved;
+ if (s->yyresolved)
+ yyvsp[i].yystate.yysemantics.yysval = s->yysemantics.yysval;
+ else
+ /* The effect of using yysval or yyloc (in an immediate rule) is
+ * undefined. */
+ yyvsp[i].yystate.yysemantics.yyfirstVal = YY_NULLPTR;
+ s = yyvsp[i].yystate.yypred = s->yypred;
+ }
}
- break;
- case 98: /* decl_typedef */
- case 99: /* decl_typedef_body_ex */
- case 100: /* decl_typedef_body */
- case 103: /* decl_func */
- case 107: /* decl_arg */
- case 110: /* struct_arg */
-{
-#line 79 "src/parser_proc.y"
-psi_decl_arg_free(&(yypminor->yy184));
-#line 1189 "src/parser_proc.c"
+
+/* Do nothing if YYNORMAL or if *YYLOW <= YYLOW1. Otherwise, fill in
+ * YYVSP[YYLOW1 .. *YYLOW-1] as in yyfillin and set *YYLOW = YYLOW1.
+ * For convenience, always return YYLOW1. */
+static inline int yyfill (yyGLRStackItem *, int *, int, yybool)
+ YY_ATTRIBUTE_UNUSED;
+static inline int
+yyfill (yyGLRStackItem *yyvsp, int *yylow, int yylow1, yybool yynormal)
+{
+ if (!yynormal && yylow1 < *yylow)
+ {
+ yyfillin (yyvsp, *yylow, yylow1);
+ *yylow = yylow1;
+ }
+ return yylow1;
}
- break;
- case 102: /* decl */
-{
-#line 87 "src/parser_proc.y"
-psi_decl_free(&(yypminor->yy103));
-#line 1196 "src/parser_proc.c"
+
+/** Perform user action for rule number YYN, with RHS length YYRHSLEN,
+ * and top stack item YYVSP. YYLVALP points to place to put semantic
+ * value ($$), and yylocp points to place for location information
+ * (@$). Returns yyok for normal return, yyaccept for YYACCEPT,
+ * yyerr for YYERROR, yyabort for YYABORT. */
+static YYRESULTTAG
+yyuserAction (yyRuleNum yyn, size_t yyrhslen, yyGLRStackItem* yyvsp,
+ yyGLRStack* yystackp,
+ YYSTYPE* yyvalp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ yybool yynormal YY_ATTRIBUTE_UNUSED = (yystackp->yysplitPoint == YY_NULLPTR);
+ int yylow;
+ YYUSE (yyvalp);
+ YYUSE (P);
+ YYUSE (tokens);
+ YYUSE (index);
+ YYUSE (yyrhslen);
+# undef yyerrok
+# define yyerrok (yystackp->yyerrState = 0)
+# undef YYACCEPT
+# define YYACCEPT return yyaccept
+# undef YYABORT
+# define YYABORT return yyabort
+# undef YYERROR
+# define YYERROR return yyerrok, yyerr
+# undef YYRECOVERING
+# define YYRECOVERING() (yystackp->yyerrState != 0)
+# undef yyclearin
+# define yyclearin (yychar = YYEMPTY)
+# undef YYFILL
+# define YYFILL(N) yyfill (yyvsp, &yylow, N, yynormal)
+# undef YYBACKUP
+# define YYBACKUP(Token, Value) \
+ return yyerror (P, tokens, index, YY_("syntax error: cannot back up")), \
+ yyerrok, yyerr
+
+ yylow = 1;
+ if (yyrhslen == 0)
+ *yyvalp = yyval_default;
+ else
+ *yyvalp = yyvsp[YYFILL (1-yyrhslen)].yystate.yysemantics.yysval;
+ switch (yyn)
+ {
+ case 284:
+#line 443 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_cpp_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ psi_cpp_exp_exec((*(struct psi_cpp_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), P->preproc, PSI_DATA(P));
+ psi_cpp_exp_free(&(*(struct psi_cpp_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ }
}
- break;
- case 104: /* decl_abi */
-{
-#line 91 "src/parser_proc.y"
-psi_decl_abi_free(&(yypminor->yy218));
-#line 1203 "src/parser_proc.c"
+#line 2770 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 285:
+#line 449 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if (P->file.ln) {
+ P->error(PSI_DATA(P), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), PSI_WARNING,
+ "Extra 'lib \"%s\"' statement has no effect", (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
+ } else {
+ P->file.ln = strndup((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->size);
+ }
}
- break;
- case 105: /* decl_var */
-{
-#line 93 "src/parser_proc.y"
-psi_decl_var_free(&(yypminor->yy11));
-#line 1210 "src/parser_proc.c"
+#line 2783 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 286:
+#line 457 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_parser_proc_add_const(P, (*(struct psi_const **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 111: /* decl_layout */
-{
-#line 105 "src/parser_proc.y"
-psi_layout_free(&(yypminor->yy141));
-#line 1217 "src/parser_proc.c"
+#line 2791 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 287:
+#line 460 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_parser_proc_add_decl(P, (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 112: /* decl_type */
- case 113: /* const_decl_type */
-{
-#line 107 "src/parser_proc.y"
-psi_decl_type_free(&(yypminor->yy132));
-#line 1225 "src/parser_proc.c"
+#line 2799 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 290:
+#line 465 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_parser_proc_add_typedef(P, (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 114: /* impl */
-{
-#line 111 "src/parser_proc.y"
-psi_impl_free(&(yypminor->yy97));
-#line 1232 "src/parser_proc.c"
+#line 2807 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 291:
+#line 468 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_parser_proc_add_struct(P, (*(struct psi_decl_struct **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 115: /* impl_func */
-{
-#line 113 "src/parser_proc.y"
-psi_impl_func_free(&(yypminor->yy168));
-#line 1239 "src/parser_proc.c"
+#line 2815 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 292:
+#line 471 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_parser_proc_add_union(P, (*(struct psi_decl_union **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 116: /* impl_def_val */
-{
-#line 115 "src/parser_proc.y"
-psi_impl_def_val_free(&(yypminor->yy93));
-#line 1246 "src/parser_proc.c"
+#line 2823 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 293:
+#line 474 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_parser_proc_add_enum(P, (*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 117: /* impl_var */
-{
-#line 117 "src/parser_proc.y"
-psi_impl_var_free(&(yypminor->yy37));
-#line 1253 "src/parser_proc.c"
+#line 2831 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 294:
+#line 477 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_parser_proc_add_impl(P, (*(struct psi_impl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 118: /* impl_arg */
- case 120: /* impl_vararg */
-{
-#line 119 "src/parser_proc.y"
-psi_impl_arg_free(&(yypminor->yy210));
-#line 1261 "src/parser_proc.c"
+#line 2839 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 295:
+#line 483 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
}
- break;
- case 122: /* impl_stmt */
-{
-#line 127 "src/parser_proc.y"
-psi_impl_stmt_free(&(yypminor->yy78));
-#line 1268 "src/parser_proc.c"
+#line 2847 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 296:
+#line 489 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = NULL;
}
- break;
- case 123: /* number */
-{
-#line 129 "src/parser_proc.y"
-psi_number_free(&(yypminor->yy188));
-#line 1275 "src/parser_proc.c"
+#line 2855 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 297:
+#line 492 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = (*(struct psi_cpp_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
}
- break;
- case 124: /* num_exp */
-{
-#line 131 "src/parser_proc.y"
-psi_num_exp_free(&(yypminor->yy259));
-#line 1282 "src/parser_proc.c"
+#line 2863 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 298:
+#line 498 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ struct psi_token *msg = NULL;
+
+ if (psi_plist_get((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), 0, &msg)) {
+ size_t index = 1;
+ struct psi_token *next;
+
+ msg = psi_token_copy(msg);
+ while (psi_plist_get((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), index++, &next)) {
+ struct psi_token *old = msg;
+ msg = psi_token_cat(" ", 2, msg, next);
+ free(old);
+ }
+ }
+ psi_plist_free((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, msg);
+ } else {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, NULL);
+ }
+ (*(struct psi_cpp_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
}
- break;
- case 125: /* let_stmt */
-{
-#line 133 "src/parser_proc.y"
-psi_let_stmt_free(&(yypminor->yy311));
-#line 1289 "src/parser_proc.c"
-}
- break;
- case 126: /* let_calloc */
-{
-#line 135 "src/parser_proc.y"
-psi_let_calloc_free(&(yypminor->yy9));
-#line 1296 "src/parser_proc.c"
+#line 2891 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 299:
+#line 521 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))));
+ (*(struct psi_cpp_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 2900 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 300:
+#line 525 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, NULL);
+ (*(struct psi_cpp_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 2909 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 301:
+#line 529 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))));
+ (*(struct psi_cpp_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 2919 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 302:
+#line 534 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_cpp_macro_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_cpp_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 2928 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 303:
+#line 538 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_cpp_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 2937 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 304:
+#line 542 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = psi_cpp_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, NULL);
+ (*(struct psi_cpp_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 2946 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 305:
+#line 546 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_plist_free((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_cpp_exp **)(&(*yyvalp))) = NULL;
+}
+#line 2955 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 329:
+#line 600 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_cpp_macro_decl **)(&(*yyvalp))) = psi_cpp_macro_decl_init((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), NULL);
+ (*(struct psi_cpp_macro_decl **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)));
+}
+#line 2965 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 330:
+#line 605 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_cpp_macro_decl **)(&(*yyvalp))) = psi_cpp_macro_decl_init(NULL, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), NULL);
+ (*(struct psi_cpp_macro_decl **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 2975 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 331:
+#line 613 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_init(NULL);
}
- break;
- case 127: /* let_func */
-{
-#line 137 "src/parser_proc.y"
-psi_let_func_free(&(yypminor->yy27));
-#line 1303 "src/parser_proc.c"
+#line 2983 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 332:
+#line 616 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_init(NULL); /* FIXME */
}
- break;
- case 128: /* callback_arg_list */
- case 129: /* callback_args */
-{
-#line 139 "src/parser_proc.y"
-psi_plist_free((yypminor->yy43));
-#line 1311 "src/parser_proc.c"
+#line 2991 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 334:
+#line 620 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
}
- break;
- case 130: /* let_callback */
-{
-#line 143 "src/parser_proc.y"
-psi_let_callback_free(&(yypminor->yy220));
-#line 1318 "src/parser_proc.c"
+#line 2999 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 335:
+#line 626 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_token_free), &(*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3009 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 336:
+#line 631 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3019 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 337:
+#line 639 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
- break;
- case 131: /* let_exp */
-{
-#line 145 "src/parser_proc.y"
-psi_let_exp_free(&(yypminor->yy20));
-#line 1325 "src/parser_proc.c"
+#line 3027 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 339:
+#line 646 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_token_free), &(*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3036 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 340:
+#line 650 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), &(*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3045 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 341:
+#line 657 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_unary((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 3054 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 342:
+#line 661 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_unary((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3063 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 343:
+#line 665 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_binary((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3072 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 344:
+#line 669 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_ternary((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+}
+#line 3081 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 345:
+#line 674 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ {
+ uint8_t exists;
+
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ exists = psi_cpp_defined(P->preproc, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num(psi_number_init(PSI_T_UINT8, &exists, 0));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ }
}
- break;
- case 133: /* set_stmt */
-{
-#line 149 "src/parser_proc.y"
-psi_set_stmt_free(&(yypminor->yy98));
-#line 1332 "src/parser_proc.c"
+#line 3096 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 346:
+#line 684 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ {
+ uint8_t exists;
+
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ exists = psi_cpp_defined(P->preproc, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num(psi_number_init(PSI_T_UINT8, &exists, 0));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ }
}
- break;
- case 134: /* set_exp */
-{
-#line 151 "src/parser_proc.y"
-psi_set_exp_free(&(yypminor->yy147));
-#line 1339 "src/parser_proc.c"
+#line 3111 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 347:
+#line 694 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num(psi_number_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->flags));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->data.n->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3121 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 348:
+#line 699 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num(psi_number_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, 0));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->data.n->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3131 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 349:
+#line 704 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num((*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->token);
+}
+#line 3140 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 350:
+#line 708 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num(psi_number_init(PSI_T_DEFINE, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, 0));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->data.n->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3151 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 351:
+#line 714 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num(psi_number_init(PSI_T_FUNCTION,
+ psi_cpp_macro_call_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))), 0));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+}
+#line 3162 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 352:
+#line 723 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
- break;
- case 136: /* set_func */
-{
-#line 155 "src/parser_proc.y"
-psi_set_func_free(&(yypminor->yy26));
-#line 1346 "src/parser_proc.c"
+#line 3170 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 354:
+#line 730 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_num_exp_free),
+ &(*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3179 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 355:
+#line 734 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 137: /* return_stmt */
-{
-#line 157 "src/parser_proc.y"
-psi_return_stmt_free(&(yypminor->yy90));
-#line 1353 "src/parser_proc.c"
+#line 3187 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 356:
+#line 740 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_const **)(&(*yyvalp))) = psi_const_init((*(struct psi_const_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text, (*(struct psi_impl_def_val **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_const **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+}
+#line 3196 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 357:
+#line 747 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_const_type **)(&(*yyvalp))) = psi_const_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
}
- break;
- case 138: /* free_stmt */
-{
-#line 159 "src/parser_proc.y"
-psi_free_stmt_free(&(yypminor->yy192));
-#line 1360 "src/parser_proc.c"
+#line 3204 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 362:
+#line 760 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_def_val **)(&(*yyvalp))) = NULL;
}
- break;
- case 140: /* free_exp */
-{
-#line 163 "src/parser_proc.y"
-psi_free_exp_free(&(yypminor->yy94));
-#line 1367 "src/parser_proc.c"
+#line 3212 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 363:
+#line 763 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if (psi_num_exp_validate(PSI_DATA(P), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), NULL, NULL, NULL, NULL, NULL)) {
+ impl_val res = {0};
+ token_t type = psi_num_exp_exec((*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), &res, NULL, &P->preproc->defs);
+
+ if (type == PSI_T_FLOAT || type == PSI_T_DOUBLE) {
+ (*(struct psi_impl_def_val **)(&(*yyvalp))) = psi_impl_def_val_init(type, NULL);
+ } else {
+ (*(struct psi_impl_def_val **)(&(*yyvalp))) = psi_impl_def_val_init(PSI_T_INT, NULL);
+ }
+
+ switch (type) {
+ case PSI_T_UINT8: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.u8; break;
+ case PSI_T_UINT16: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.u16; break;
+ case PSI_T_UINT32: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.u32; break;
+ case PSI_T_UINT64: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.u64; break; /* FIXME */
+ case PSI_T_INT8: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.i8; break;
+ case PSI_T_INT16: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.i16; break;
+ case PSI_T_INT32: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.i32; break;
+ case PSI_T_INT64: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.zend.lval = res.i64; break;
+ case PSI_T_FLOAT: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.dval = res.fval; break;
+ case PSI_T_DOUBLE: (*(struct psi_impl_def_val **)(&(*yyvalp)))->ival.dval = res.dval; break;
+ default:
+ assert(0);
+
+ }
+ } else {
+ (*(struct psi_impl_def_val **)(&(*yyvalp))) = NULL;
+ }
+ psi_num_exp_free(&(*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 141: /* impl_type */
-{
-#line 165 "src/parser_proc.y"
-psi_impl_type_free(&(yypminor->yy138));
-#line 1374 "src/parser_proc.c"
+#line 3248 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 364:
+#line 794 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_def_val **)(&(*yyvalp))) = psi_impl_def_val_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
+ (*(struct psi_impl_def_val **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3257 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 369:
+#line 808 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
}
- break;
-/********* End destructor definitions *****************************************/
- default: break; /* If no destructor action specified: do nothing */
- }
+#line 3265 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 370:
+#line 811 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init(PSI_T_VOID, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text, 0, 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3279 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 371:
+#line 820 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
}
+#line 3287 "src/parser_proc.c" /* glr.c:816 */
+ break;
-/*
-** Pop the parser's stack once.
-**
-** If there is a destructor routine associated with the token which
-** is popped from the stack, then call it.
-*/
-static void yy_pop_parser_stack(yyParser *pParser){
- yyStackEntry *yytos;
- assert( pParser->yytos!=0 );
- assert( pParser->yytos > pParser->yystack );
- yytos = pParser->yytos--;
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sPopping %s\n",
- yyTracePrompt,
- yyTokenName[yytos->major]);
- }
-#endif
- yy_destructor(pParser, yytos->major, &yytos->minor);
+ case 372:
+#line 826 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
+#line 3295 "src/parser_proc.c" /* glr.c:816 */
+ break;
-/*
-** Clear all secondary memory allocations from the parser
-*/
-void ParseFinalize(void *p){
- yyParser *pParser = (yyParser*)p;
- while( pParser->yytos>pParser->yystack ) yy_pop_parser_stack(pParser);
-#if YYSTACKDEPTH<=0
- if( pParser->yystack!=&pParser->yystk0 ) free(pParser->yystack);
-#endif
+ case 373:
+#line 829 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
+#line 3303 "src/parser_proc.c" /* glr.c:816 */
+ break;
-#ifndef Parse_ENGINEALWAYSONSTACK
-/*
-** Deallocate and destroy a parser. Destructors are called for
-** all stack elements before shutting the parser down.
-**
-** If the YYPARSEFREENEVERNULL macro exists (for example because it
-** is defined in a %include section of the input grammar) then it is
-** assumed that the input pointer is never NULL.
-*/
-void ParseFree(
- void *p, /* The parser to be deleted */
- void (*freeProc)(void*) /* Function used to reclaim memory */
-){
-#ifndef YYPARSEFREENEVERNULL
- if( p==0 ) return;
-#endif
- ParseFinalize(p);
- (*freeProc)(p);
+ case 374:
+#line 835 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#endif /* Parse_ENGINEALWAYSONSTACK */
+#line 3311 "src/parser_proc.c" /* glr.c:816 */
+ break;
-/*
-** Return the peak depth of the stack for a parser.
-*/
-#ifdef YYTRACKMAXSTACKDEPTH
-int ParseStackPeak(void *p){
- yyParser *pParser = (yyParser*)p;
- return pParser->yyhwm;
+ case 375:
+#line 838 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#endif
+#line 3319 "src/parser_proc.c" /* glr.c:816 */
+ break;
-/*
-** Find the appropriate action for a parser given the terminal
-** look-ahead token iLookAhead.
-*/
-static unsigned int yy_find_shift_action(
- yyParser *pParser, /* The parser */
- YYCODETYPE iLookAhead /* The look-ahead token */
-){
- int i;
- int stateno = pParser->yytos->stateno;
-
- if( stateno>=YY_MIN_REDUCE ) return stateno;
- assert( stateno <= YY_SHIFT_COUNT );
- do{
- i = yy_shift_ofst[stateno];
- assert( iLookAhead!=YYNOCODE );
- i += iLookAhead;
- if( i<0 || i>=YY_ACTTAB_COUNT || yy_lookahead[i]!=iLookAhead ){
-#ifdef YYFALLBACK
- YYCODETYPE iFallback; /* Fallback token */
- if( iLookAhead<sizeof(yyFallback)/sizeof(yyFallback[0])
- && (iFallback = yyFallback[iLookAhead])!=0 ){
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE, "%sFALLBACK %s => %s\n",
- yyTracePrompt, yyTokenName[iLookAhead], yyTokenName[iFallback]);
- }
-#endif
- assert( yyFallback[iFallback]==0 ); /* Fallback loop must terminate */
- iLookAhead = iFallback;
- continue;
- }
-#endif
-#ifdef YYWILDCARD
- {
- int j = i - iLookAhead + YYWILDCARD;
- if(
-#if YY_SHIFT_MIN+YYWILDCARD<0
- j>=0 &&
-#endif
-#if YY_SHIFT_MAX+YYWILDCARD>=YY_ACTTAB_COUNT
- j<YY_ACTTAB_COUNT &&
-#endif
- yy_lookahead[j]==YYWILDCARD && iLookAhead>0
- ){
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE, "%sWILDCARD %s => %s\n",
- yyTracePrompt, yyTokenName[iLookAhead],
- yyTokenName[YYWILDCARD]);
- }
-#endif /* NDEBUG */
- return yy_action[j];
- }
- }
-#endif /* YYWILDCARD */
- return yy_default[stateno];
- }else{
- return yy_action[i];
- }
- }while(1);
+ case 377:
+#line 845 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init(PSI_T_FUNCTION, (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->func->var->name),
+ psi_decl_var_copy((*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->func->var)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->func->token);
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.func = (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+}
+#line 3332 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 378:
+#line 853 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init(PSI_T_ENUM, (*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->name),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, 0, 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->token);
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.enm = (*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
+ psi_parser_proc_add_enum(P, (*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3348 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 379:
+#line 864 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(psi_decl_type_init(PSI_T_STRUCT, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text), (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct = psi_decl_struct_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct->align = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)).pos;
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct->size = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)).len;
+ psi_parser_proc_add_struct(P, (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct);
+}
+#line 3362 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 380:
+#line 873 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(psi_decl_type_init(PSI_T_UNION, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text), (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn = psi_decl_union_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn->align = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)).pos;
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn->size = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)).len;
+ psi_parser_proc_add_union(P, (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn);
+}
+#line 3376 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 382:
+#line 886 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init((*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), psi_decl_var_init(NULL, 0, 0));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->token);
+}
+#line 3385 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 383:
+#line 890 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init(PSI_T_ENUM, (*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->name),
+ psi_decl_var_init(NULL, 0, 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->token);
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->token);
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.enm = (*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ psi_parser_proc_add_enum(P, (*(struct psi_decl_enum **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3400 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 384:
+#line 900 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(psi_decl_type_init(PSI_T_STRUCT, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text), psi_decl_var_init(NULL, 0, 0));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct = psi_decl_struct_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct->align = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).pos;
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct->size = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).len;
+ psi_parser_proc_add_struct(P, (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.strct);
+}
+#line 3414 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 385:
+#line 909 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(psi_decl_type_init(PSI_T_UNION, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text), psi_decl_var_init(NULL, 0, 0));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn = psi_decl_union_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn->align = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).pos;
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn->size = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).len;
+ psi_parser_proc_add_union(P, (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.unn);
+}
+#line 3428 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 386:
+#line 921 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_type **)(&(*yyvalp))) = (*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
+#line 3436 "src/parser_proc.c" /* glr.c:816 */
+ break;
-/*
-** Find the appropriate action for a parser given the non-terminal
-** look-ahead token iLookAhead.
-*/
-static int yy_find_reduce_action(
- int stateno, /* Current state number */
- YYCODETYPE iLookAhead /* The look-ahead token */
-){
- int i;
-#ifdef YYERRORSYMBOL
- if( stateno>YY_REDUCE_COUNT ){
- return yy_default[stateno];
- }
-#else
- assert( stateno<=YY_REDUCE_COUNT );
-#endif
- i = yy_reduce_ofst[stateno];
- assert( i!=YY_REDUCE_USE_DFLT );
- assert( iLookAhead!=YYNOCODE );
- i += iLookAhead;
-#ifdef YYERRORSYMBOL
- if( i<0 || i>=YY_ACTTAB_COUNT || yy_lookahead[i]!=iLookAhead ){
- return yy_default[stateno];
- }
-#else
- assert( i>=0 && i<YY_ACTTAB_COUNT );
- assert( yy_lookahead[i]==iLookAhead );
-#endif
- return yy_action[i];
-}
-
-/*
-** The following routine is called if the stack overflows.
-*/
-static void yyStackOverflow(yyParser *yypParser){
- ParseARG_FETCH;
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sStack Overflow!\n",yyTracePrompt);
- }
-#endif
- while( yypParser->yytos>yypParser->yystack ) yy_pop_parser_stack(yypParser);
- /* Here code is inserted which will execute if the parser
- ** stack every overflows */
-/******** Begin %stack_overflow code ******************************************/
-/******** End %stack_overflow code ********************************************/
- ParseARG_STORE; /* Suppress warning about unused %extra_argument var */
-}
-
-/*
-** Print tracing information for a SHIFT action
-*/
-#ifndef NDEBUG
-static void yyTraceShift(yyParser *yypParser, int yyNewState){
- if( yyTraceFILE ){
- if( yyNewState<YYNSTATE ){
- fprintf(yyTraceFILE,"%sShift '%s', go to state %d\n",
- yyTracePrompt,yyTokenName[yypParser->yytos->major],
- yyNewState);
- }else{
- fprintf(yyTraceFILE,"%sShift '%s'\n",
- yyTracePrompt,yyTokenName[yypParser->yytos->major]);
- }
- }
+ case 387:
+#line 924 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_type **)(&(*yyvalp))) = (*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#else
-# define yyTraceShift(X,Y)
-#endif
+#line 3444 "src/parser_proc.c" /* glr.c:816 */
+ break;
-/*
-** Perform a shift action.
-*/
-static void yy_shift(
- yyParser *yypParser, /* The parser to be shifted */
- int yyNewState, /* The new state to shift in */
- int yyMajor, /* The major token to shift in */
- ParseTOKENTYPE yyMinor /* The minor token to shift in */
-){
- yyStackEntry *yytos;
- yypParser->yytos++;
-#ifdef YYTRACKMAXSTACKDEPTH
- if( (int)(yypParser->yytos - yypParser->yystack)>yypParser->yyhwm ){
- yypParser->yyhwm++;
- assert( yypParser->yyhwm == (int)(yypParser->yytos - yypParser->yystack) );
- }
-#endif
-#if YYSTACKDEPTH>0
- if( yypParser->yytos>=&yypParser->yystack[YYSTACKDEPTH] ){
- yypParser->yytos--;
- yyStackOverflow(yypParser);
- return;
- }
-#else
- if( yypParser->yytos>=&yypParser->yystack[yypParser->yystksz] ){
- if( yyGrowStack(yypParser) ){
- yypParser->yytos--;
- yyStackOverflow(yypParser);
- return;
- }
- }
-#endif
- if( yyNewState > YY_MAX_SHIFT ){
- yyNewState += YY_MIN_REDUCE - YY_MIN_SHIFTREDUCE;
- }
- yytos = yypParser->yytos;
- yytos->stateno = (YYACTIONTYPE)yyNewState;
- yytos->major = (YYCODETYPE)yyMajor;
- yytos->minor.yy0 = yyMinor;
- yyTraceShift(yypParser, yyNewState);
-}
-
-/* The following table contains information about every rule that
-** is used during the reduce.
-*/
-static const struct {
- YYCODETYPE lhs; /* Symbol on the left-hand side of the rule */
- unsigned char nrhs; /* Number of right-hand side symbols in the rule */
-} yyRuleInfo[] = {
- { 147, 3 },
- { 147, 1 },
- { 147, 1 },
- { 147, 1 },
- { 147, 1 },
- { 147, 1 },
- { 147, 1 },
- { 147, 1 },
- { 148, 0 },
- { 148, 1 },
- { 94, 0 },
- { 94, 7 },
- { 149, 2 },
- { 150, 2 },
- { 151, 2 },
- { 88, 4 },
- { 89, 1 },
- { 89, 3 },
- { 90, 3 },
- { 90, 1 },
- { 91, 3 },
- { 92, 1 },
- { 92, 1 },
- { 93, 4 },
- { 95, 4 },
- { 96, 1 },
- { 97, 6 },
- { 98, 3 },
- { 99, 4 },
- { 99, 4 },
- { 99, 2 },
- { 100, 1 },
- { 101, 3 },
- { 100, 2 },
- { 100, 1 },
- { 102, 6 },
- { 102, 8 },
- { 103, 1 },
- { 103, 2 },
- { 100, 7 },
- { 100, 8 },
- { 104, 1 },
- { 152, 0 },
- { 152, 3 },
- { 105, 2 },
- { 105, 3 },
- { 106, 1 },
- { 106, 3 },
- { 107, 2 },
- { 100, 7 },
- { 107, 3 },
- { 107, 4 },
- { 108, 0 },
- { 108, 1 },
- { 108, 1 },
- { 108, 3 },
- { 109, 1 },
- { 109, 2 },
- { 110, 2 },
- { 110, 3 },
- { 111, 0 },
- { 111, 7 },
- { 153, 1 },
- { 153, 2 },
- { 154, 0 },
- { 154, 1 },
- { 153, 1 },
- { 153, 2 },
- { 155, 0 },
- { 155, 1 },
- { 155, 2 },
- { 156, 0 },
- { 156, 1 },
- { 112, 2 },
- { 112, 2 },
- { 112, 1 },
- { 112, 1 },
- { 112, 1 },
- { 112, 2 },
- { 112, 2 },
- { 112, 2 },
- { 112, 1 },
- { 113, 1 },
- { 113, 2 },
- { 114, 4 },
- { 114, 5 },
- { 115, 7 },
- { 115, 8 },
- { 115, 13 },
- { 116, 1 },
- { 117, 2 },
- { 141, 1 },
- { 118, 2 },
- { 118, 4 },
- { 119, 1 },
- { 119, 3 },
- { 121, 1 },
- { 121, 2 },
- { 122, 1 },
- { 122, 1 },
- { 122, 1 },
- { 122, 1 },
- { 123, 1 },
- { 123, 1 },
- { 124, 1 },
- { 124, 3 },
- { 124, 3 },
- { 124, 2 },
- { 131, 1 },
- { 131, 2 },
- { 131, 1 },
- { 131, 1 },
- { 131, 2 },
- { 131, 1 },
- { 131, 2 },
- { 131, 1 },
- { 131, 2 },
- { 131, 3 },
- { 125, 3 },
- { 125, 6 },
- { 130, 8 },
- { 126, 6 },
- { 127, 4 },
- { 127, 6 },
- { 132, 1 },
- { 132, 3 },
- { 128, 0 },
- { 128, 1 },
- { 129, 1 },
- { 129, 3 },
- { 157, 1 },
- { 157, 1 },
- { 136, 4 },
- { 136, 6 },
- { 136, 6 },
- { 134, 1 },
- { 134, 1 },
- { 135, 1 },
- { 135, 3 },
- { 134, 3 },
- { 133, 3 },
- { 137, 3 },
- { 138, 3 },
- { 139, 1 },
- { 139, 3 },
- { 140, 4 },
- { 142, 0 },
- { 142, 1 },
- { 143, 0 },
- { 143, 1 },
- { 144, 1 },
- { 144, 2 },
- { 145, 1 },
- { 146, 1 },
- { 146, 2 },
- { 147, 1 },
- { 147, 1 },
-};
+ case 389:
+#line 931 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_type **)(&(*yyvalp))) = psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
+ (*(struct psi_decl_type **)(&(*yyvalp)))->token = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+}
+#line 3453 "src/parser_proc.c" /* glr.c:816 */
+ break;
-static void yy_accept(yyParser*); /* Forward Declaration */
-
-/*
-** Perform a reduce action and the shift that must immediately
-** follow the reduce.
-*/
-static void yy_reduce(
- yyParser *yypParser, /* The parser */
- unsigned int yyruleno /* Number of the rule by which to reduce */
-){
- int yygoto; /* The next state */
- int yyact; /* The next action */
- yyStackEntry *yymsp; /* The top of the parser's stack */
- int yysize; /* Amount to pop the stack */
- ParseARG_FETCH;
- yymsp = yypParser->yytos;
-#ifndef NDEBUG
- if( yyTraceFILE && yyruleno<(int)(sizeof(yyRuleName)/sizeof(yyRuleName[0])) ){
- yysize = yyRuleInfo[yyruleno].nrhs;
- fprintf(yyTraceFILE, "%sReduce [%s], go to state %d.\n", yyTracePrompt,
- yyRuleName[yyruleno], yymsp[-yysize].stateno);
- }
-#endif /* NDEBUG */
-
- /* Check that the stack is large enough to grow by a single entry
- ** if the RHS of the rule is empty. This ensures that there is room
- ** enough on the stack to push the LHS value */
- if( yyRuleInfo[yyruleno].nrhs==0 ){
-#ifdef YYTRACKMAXSTACKDEPTH
- if( (int)(yypParser->yytos - yypParser->yystack)>yypParser->yyhwm ){
- yypParser->yyhwm++;
- assert( yypParser->yyhwm == (int)(yypParser->yytos - yypParser->yystack));
- }
-#endif
-#if YYSTACKDEPTH>0
- if( yypParser->yytos>=&yypParser->yystack[YYSTACKDEPTH-1] ){
- yyStackOverflow(yypParser);
- return;
- }
-#else
- if( yypParser->yytos>=&yypParser->yystack[yypParser->yystksz-1] ){
- if( yyGrowStack(yypParser) ){
- yyStackOverflow(yypParser);
- return;
- }
- yymsp = yypParser->yytos;
- }
-#endif
- }
+ case 391:
+#line 939 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_type **)(&(*yyvalp))) = psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
+ (*(struct psi_decl_type **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3463 "src/parser_proc.c" /* glr.c:816 */
+ break;
- switch( yyruleno ){
- /* Beginning here are the reduction cases. A typical example
- ** follows:
- ** case 0:
- ** #line <lineno> <grammarfile>
- ** { ... } // User supplied code
- ** #line <lineno> <thisfile>
- ** break;
- */
-/********** Begin reduce actions **********************************************/
- YYMINORTYPE yylhsminor;
- case 0: /* block ::= LIB QUOTED_STRING EOS */
-#line 174 "src/parser_proc.y"
-{
- if (P->file.ln) {
- P->error(PSI_DATA(P), yymsp[-2].minor.yy0, PSI_WARNING, "Extra 'lib %s' statement has no effect", yymsp[-1].minor.yy0->text);
- } else {
- P->file.ln = strndup(yymsp[-1].minor.yy0->text + 1, yymsp[-1].minor.yy0->size - 2);
- }
- free(yymsp[-1].minor.yy0);
- free(yymsp[-2].minor.yy0);
-}
-#line 1857 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- break;
- case 1: /* block ::= decl */
-#line 183 "src/parser_proc.y"
-{
- if (!P->decls) {
- P->decls = psi_plist_init((psi_plist_dtor) psi_decl_free);
- }
- P->decls = psi_plist_add(P->decls, &yymsp[0].minor.yy103);
-}
-#line 1868 "src/parser_proc.c"
- break;
- case 2: /* block ::= impl */
-#line 189 "src/parser_proc.y"
-{
- if (!P->impls) {
- P->impls = psi_plist_init((psi_plist_dtor) psi_impl_free);
- }
- P->impls = psi_plist_add(P->impls, &yymsp[0].minor.yy97);
-}
-#line 1878 "src/parser_proc.c"
- break;
- case 3: /* block ::= decl_typedef */
-#line 195 "src/parser_proc.y"
-{
- if (!P->types) {
- P->types = psi_plist_init((psi_plist_dtor) psi_decl_arg_free);
- }
- P->types = psi_plist_add(P->types, &yymsp[0].minor.yy184);
- switch (yymsp[0].minor.yy184->type->type) {
- case PSI_T_STRUCT:
- if (yymsp[0].minor.yy184->type->real.strct) {
- if (!P->structs) {
- P->structs = psi_plist_init((psi_plist_dtor) psi_decl_struct_free);
- }
- P->structs = psi_plist_add(P->structs, &yymsp[0].minor.yy184->type->real.strct);
- }
- break;
- case PSI_T_UNION:
- if (yymsp[0].minor.yy184->type->real.unn) {
- if (!P->unions) {
- P->unions = psi_plist_init((psi_plist_dtor) psi_decl_union_free);
- }
- P->unions = psi_plist_add(P->unions, &yymsp[0].minor.yy184->type->real.unn);
- }
- break;
- case PSI_T_ENUM:
- if (yymsp[0].minor.yy184->type->real.enm) {
- if (!P->enums) {
- P->enums = psi_plist_init((psi_plist_dtor) psi_decl_enum_free);
- }
- P->enums = psi_plist_add(P->enums, &yymsp[0].minor.yy184->type->real.enm);
- }
- break;
- }
+ case 392:
+#line 944 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_type **)(&(*yyvalp))) = psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
+ (*(struct psi_decl_type **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3473 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 393:
+#line 949 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_type **)(&(*yyvalp))) = psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
+ (*(struct psi_decl_type **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3483 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 396:
+#line 959 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1914 "src/parser_proc.c"
- break;
- case 4: /* block ::= constant */
-#line 227 "src/parser_proc.y"
-{
- if (!P->consts) {
- P->consts = psi_plist_init((psi_plist_dtor) psi_const_free);
- }
- P->consts = psi_plist_add(P->consts, &yymsp[0].minor.yy154);
+#line 3491 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 397:
+#line 965 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1924 "src/parser_proc.c"
- break;
- case 5: /* block ::= decl_struct */
-#line 233 "src/parser_proc.y"
-{
- if (!P->structs) {
- P->structs = psi_plist_init((psi_plist_dtor) psi_decl_struct_free);
- }
- P->structs = psi_plist_add(P->structs, &yymsp[0].minor.yy275);
+#line 3499 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 398:
+#line 968 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1934 "src/parser_proc.c"
- break;
- case 6: /* block ::= decl_union */
-#line 239 "src/parser_proc.y"
-{
- if (!P->unions) {
- P->unions = psi_plist_init((psi_plist_dtor) psi_decl_union_free);
- }
- P->unions = psi_plist_add(P->unions, &yymsp[0].minor.yy271);
+#line 3507 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 399:
+#line 971 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_cat(" ", 2, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1944 "src/parser_proc.c"
- break;
- case 7: /* block ::= decl_enum */
-#line 245 "src/parser_proc.y"
-{
- if (!P->enums) {
- P->enums = psi_plist_init((psi_plist_dtor) psi_decl_enum_free);
- }
- P->enums = psi_plist_add(P->enums, &yymsp[0].minor.yy63);
+#line 3515 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 402:
+#line 982 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1954 "src/parser_proc.c"
- break;
- case 8: /* optional_name ::= */
- case 42: /* decl_var_array_size ::= */ yytestcase(yyruleno==42);
- case 64: /* decl_scalar_type_short ::= */ yytestcase(yyruleno==64);
- case 68: /* decl_scalar_type_long ::= */ yytestcase(yyruleno==68);
- case 71: /* decl_scalar_type_long_long ::= */ yytestcase(yyruleno==71);
-#line 251 "src/parser_proc.y"
-{
- yymsp[1].minor.yy0 = NULL;
+#line 3523 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 403:
+#line 985 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1965 "src/parser_proc.c"
- break;
- case 9: /* optional_name ::= NAME */
- case 62: /* decl_scalar_type ::= CHAR */ yytestcase(yyruleno==62);
- case 65: /* decl_scalar_type_short ::= INT */ yytestcase(yyruleno==65);
- case 66: /* decl_scalar_type ::= INT */ yytestcase(yyruleno==66);
- case 69: /* decl_scalar_type_long ::= DOUBLE */ yytestcase(yyruleno==69);
- case 72: /* decl_scalar_type_long_long ::= INT */ yytestcase(yyruleno==72);
- case 130: /* callback_rval ::= ZVAL|OBJVAL|ARRVAL|PATHVAL|STRLEN|STRVAL|FLOATVAL|INTVAL|BOOLVAL|COUNT */ yytestcase(yyruleno==130);
- case 131: /* callback_rval ::= VOID */ yytestcase(yyruleno==131);
-#line 254 "src/parser_proc.y"
-{
- yylhsminor.yy0 = yymsp[0].minor.yy0;
+#line 3531 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 404:
+#line 988 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_cat(" ", 2, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1979 "src/parser_proc.c"
- yymsp[0].minor.yy0 = yylhsminor.yy0;
- break;
- case 10: /* align_and_size ::= */
-#line 257 "src/parser_proc.y"
-{
- yymsp[1].minor.yy91.pos = 0;
- yymsp[1].minor.yy91.len = 0;
+#line 3539 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 405:
+#line 994 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1988 "src/parser_proc.c"
- break;
- case 11: /* align_and_size ::= COLON COLON LPAREN NUMBER COMMA NUMBER RPAREN */
-{ yy_destructor(yypParser,64,&yymsp[-6].minor);
-#line 261 "src/parser_proc.y"
-{
- yymsp[-6].minor.yy91.pos = atol(yymsp[-3].minor.yy0->text);
- yymsp[-6].minor.yy91.len = atol(yymsp[-1].minor.yy0->text);
- free(yymsp[-3].minor.yy0);
- free(yymsp[-1].minor.yy0);
+#line 3547 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 406:
+#line 997 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 1999 "src/parser_proc.c"
- yy_destructor(yypParser,64,&yymsp[-5].minor);
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,66,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
+#line 3555 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 407:
+#line 1000 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_cat(" ", 2, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ free((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ }
}
- break;
- case 12: /* enum_name ::= ENUM optional_name */
- case 13: /* struct_name ::= STRUCT optional_name */ yytestcase(yyruleno==13);
- case 14: /* union_name ::= UNION optional_name */ yytestcase(yyruleno==14);
-#line 267 "src/parser_proc.y"
-{
- if (yymsp[0].minor.yy0) {
- yylhsminor.yy0 = yymsp[0].minor.yy0;
- free(yymsp[-1].minor.yy0);
- } else {
- char digest[17];
- psi_token_hash(yymsp[-1].minor.yy0, digest);
- yylhsminor.yy0 = psi_token_translit(psi_token_append(yymsp[-1].minor.yy0, 1, digest), " ", "@");
- }
+#line 3568 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 408:
+#line 1008 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_cat(" ", 2, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ free((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ free((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ (*(struct psi_token **)(&(*yyvalp))) = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
+ }
}
-#line 2020 "src/parser_proc.c"
- yymsp[-1].minor.yy0 = yylhsminor.yy0;
- break;
- case 15: /* decl_enum ::= enum_name LBRACE decl_enum_items RBRACE */
-#line 297 "src/parser_proc.y"
-{
- yylhsminor.yy63 = psi_decl_enum_init(yymsp[-3].minor.yy0->text, yymsp[-1].minor.yy163);
- yylhsminor.yy63->token = yymsp[-3].minor.yy0;
+#line 3582 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 409:
+#line 1020 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = NULL;
}
-#line 2029 "src/parser_proc.c"
- yy_destructor(yypParser,71,&yymsp[-2].minor);
- yy_destructor(yypParser,72,&yymsp[0].minor);
- yymsp[-3].minor.yy63 = yylhsminor.yy63;
- break;
- case 16: /* decl_enum_items ::= decl_enum_item */
-#line 301 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_enum_item_free),
- &yymsp[0].minor.yy217);
+#line 3590 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 410:
+#line 1023 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2040 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 17: /* decl_enum_items ::= decl_enum_items COMMA decl_enum_item */
-#line 305 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(yymsp[-2].minor.yy163, &yymsp[0].minor.yy217);
+#line 3598 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 411:
+#line 1026 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2048 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy163 = yylhsminor.yy163;
- break;
- case 18: /* decl_enum_item ::= NAME EQUALS num_exp */
-#line 308 "src/parser_proc.y"
-{
- yylhsminor.yy217 = psi_decl_enum_item_init(yymsp[-2].minor.yy0->text, yymsp[0].minor.yy259);
- yylhsminor.yy217->token = yymsp[-2].minor.yy0;
+#line 3606 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 412:
+#line 1029 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_cat(" ", 2, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ }
}
-#line 2058 "src/parser_proc.c"
- yy_destructor(yypParser,73,&yymsp[-1].minor);
- yymsp[-2].minor.yy217 = yylhsminor.yy217;
- break;
- case 19: /* decl_enum_item ::= NAME */
-#line 312 "src/parser_proc.y"
-{
- yylhsminor.yy217 = psi_decl_enum_item_init(yymsp[0].minor.yy0->text, NULL);
- yylhsminor.yy217->token = yymsp[0].minor.yy0;
+#line 3618 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 413:
+#line 1036 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2068 "src/parser_proc.c"
- yymsp[0].minor.yy217 = yylhsminor.yy217;
- break;
- case 20: /* decl_struct_args_block ::= LBRACE struct_args RBRACE */
-{ yy_destructor(yypParser,71,&yymsp[-2].minor);
-#line 316 "src/parser_proc.y"
-{
- yymsp[-2].minor.yy163 = yymsp[-1].minor.yy163;
+#line 3626 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 414:
+#line 1039 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_cat(" ", 2, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ }
}
-#line 2077 "src/parser_proc.c"
- yy_destructor(yypParser,72,&yymsp[0].minor);
+#line 3638 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 415:
+#line 1049 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = NULL;
}
- break;
- case 21: /* decl_struct_args ::= decl_struct_args_block */
-#line 319 "src/parser_proc.y"
-{
- yylhsminor.yy163 = yymsp[0].minor.yy163;
+#line 3646 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 417:
+#line 1055 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = NULL;
}
-#line 2086 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 22: /* decl_struct_args ::= EOS */
-{ yy_destructor(yypParser,63,&yymsp[0].minor);
-#line 322 "src/parser_proc.y"
-{
- yymsp[0].minor.yy163 = psi_plist_init((psi_plist_dtor) psi_decl_arg_free);
+#line 3654 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 421:
+#line 1064 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = NULL;
}
-#line 2095 "src/parser_proc.c"
+#line 3662 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 422:
+#line 1067 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 23: /* decl_struct ::= STRUCT NAME align_and_size decl_struct_args */
-{ yy_destructor(yypParser,69,&yymsp[-3].minor);
-#line 325 "src/parser_proc.y"
-{
- yymsp[-3].minor.yy275 = psi_decl_struct_init(yymsp[-2].minor.yy0->text, yymsp[0].minor.yy163);
- yymsp[-3].minor.yy275->align = yymsp[-1].minor.yy91.pos;
- yymsp[-3].minor.yy275->size = yymsp[-1].minor.yy91.len;
- yymsp[-3].minor.yy275->token = yymsp[-2].minor.yy0;
+#line 3670 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 423:
+#line 1070 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_cat(" ", 2, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ free((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ }
}
-#line 2107 "src/parser_proc.c"
+#line 3683 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 424:
+#line 1081 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl **)(&(*yyvalp))) = (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
}
- break;
- case 24: /* decl_union ::= UNION NAME align_and_size decl_struct_args */
-{ yy_destructor(yypParser,70,&yymsp[-3].minor);
-#line 331 "src/parser_proc.y"
-{
- yymsp[-3].minor.yy271 = psi_decl_union_init(yymsp[-2].minor.yy0->text, yymsp[0].minor.yy163);
- yymsp[-3].minor.yy271->align = yymsp[-1].minor.yy91.pos;
- yymsp[-3].minor.yy271->size = yymsp[-1].minor.yy91.len;
- yymsp[-3].minor.yy271->token = yymsp[-2].minor.yy0;
+#line 3691 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 425:
+#line 1084 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl **)(&(*yyvalp))) = (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
}
-#line 2119 "src/parser_proc.c"
+#line 3699 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 431:
+#line 1104 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_decl_arg_free(&(*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
}
- break;
- case 25: /* const_type ::= BOOL|INT|FLOAT|STRING */
-#line 337 "src/parser_proc.y"
-{
- yylhsminor.yy171 = psi_const_type_init(yymsp[0].minor.yy0->type, yymsp[0].minor.yy0->text);
- free(yymsp[0].minor.yy0);
+#line 3707 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 433:
+#line 1111 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_plist_free((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2128 "src/parser_proc.c"
- yymsp[0].minor.yy171 = yylhsminor.yy171;
- break;
- case 26: /* constant ::= CONST const_type NSNAME EQUALS impl_def_val EOS */
-{ yy_destructor(yypParser,74,&yymsp[-5].minor);
-#line 341 "src/parser_proc.y"
-{
- yymsp[-5].minor.yy154 = psi_const_init(yymsp[-4].minor.yy171, yymsp[-3].minor.yy0->text, yymsp[-1].minor.yy93);
- yymsp[-5].minor.yy154->token = yymsp[-3].minor.yy0;
+#line 3715 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 434:
+#line 1117 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_var_free), &(*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2138 "src/parser_proc.c"
- yy_destructor(yypParser,73,&yymsp[-2].minor);
- yy_destructor(yypParser,63,&yymsp[0].minor);
+#line 3723 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 435:
+#line 1120 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 27: /* decl_typedef ::= TYPEDEF decl_typedef_body EOS */
-#line 345 "src/parser_proc.y"
-{
- yylhsminor.yy184 = yymsp[-1].minor.yy184;
- yylhsminor.yy184->token = yymsp[-2].minor.yy0;
+#line 3731 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 436:
+#line 1126 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_decl_free(&(*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
}
-#line 2149 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-2].minor.yy184 = yylhsminor.yy184;
- break;
- case 28: /* decl_typedef_body_ex ::= struct_name align_and_size decl_struct_args_block decl_var */
-#line 349 "src/parser_proc.y"
-{
- yylhsminor.yy184 = psi_decl_arg_init(psi_decl_type_init(PSI_T_STRUCT, yymsp[-3].minor.yy0->text), yymsp[0].minor.yy11);
- yylhsminor.yy184->type->token = psi_token_copy(yymsp[-3].minor.yy0);
- yylhsminor.yy184->type->real.strct = psi_decl_struct_init(yymsp[-3].minor.yy0->text, yymsp[-1].minor.yy163);
- yylhsminor.yy184->type->real.strct->token = yymsp[-3].minor.yy0;
- yylhsminor.yy184->type->real.strct->align = yymsp[-2].minor.yy91.pos;
- yylhsminor.yy184->type->real.strct->size = yymsp[-2].minor.yy91.len;
+#line 3739 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 437:
+#line 1129 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_decl_free(&(*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
}
-#line 2163 "src/parser_proc.c"
- yymsp[-3].minor.yy184 = yylhsminor.yy184;
- break;
- case 29: /* decl_typedef_body_ex ::= union_name align_and_size decl_struct_args_block decl_var */
-#line 357 "src/parser_proc.y"
-{
- yylhsminor.yy184 = psi_decl_arg_init(psi_decl_type_init(PSI_T_UNION, yymsp[-3].minor.yy0->text), yymsp[0].minor.yy11);
- yylhsminor.yy184->type->token = psi_token_copy(yymsp[-3].minor.yy0);
- yylhsminor.yy184->type->real.unn = psi_decl_union_init(yymsp[-3].minor.yy0->text, yymsp[-1].minor.yy163);
- yylhsminor.yy184->type->real.unn->token = yymsp[-3].minor.yy0;
- yylhsminor.yy184->type->real.unn->align = yymsp[-2].minor.yy91.pos;
- yylhsminor.yy184->type->real.unn->size = yymsp[-2].minor.yy91.len;
+#line 3747 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 438:
+#line 1132 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ psi_decl_free(&(*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
}
-#line 2176 "src/parser_proc.c"
- yymsp[-3].minor.yy184 = yylhsminor.yy184;
- break;
- case 30: /* decl_typedef_body_ex ::= decl_enum NAME */
-#line 365 "src/parser_proc.y"
-{
- yylhsminor.yy184 = psi_decl_arg_init(psi_decl_type_init(PSI_T_ENUM, yymsp[-1].minor.yy63->name), psi_decl_var_init(yymsp[0].minor.yy0->text, 0, 0));
- yylhsminor.yy184->var->token = yymsp[0].minor.yy0;
- yylhsminor.yy184->type->token = psi_token_copy(yymsp[-1].minor.yy63->token);
- yylhsminor.yy184->type->real.enm = yymsp[-1].minor.yy63;
+#line 3755 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 445:
+#line 1153 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl **)(&(*yyvalp))) = (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_decl **)(&(*yyvalp)))->abi = psi_decl_abi_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text);
+}
+#line 3764 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 448:
+#line 1165 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl **)(&(*yyvalp))) = psi_decl_init((*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ if ((*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->pointer_level += 1;
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->array_size = (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ }
}
-#line 2187 "src/parser_proc.c"
- yymsp[-1].minor.yy184 = yylhsminor.yy184;
- break;
- case 31: /* decl_typedef_body ::= decl_typedef_body_ex */
- case 34: /* decl_typedef_body ::= decl_arg */ yytestcase(yyruleno==34);
- case 37: /* decl_func ::= decl_arg */ yytestcase(yyruleno==37);
-#line 371 "src/parser_proc.y"
-{
- yylhsminor.yy184 = yymsp[0].minor.yy184;
+#line 3776 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 449:
+#line 1172 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl **)(&(*yyvalp))) = psi_decl_init((*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl **)(&(*yyvalp)))->varargs = 1;
+ if ((*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->pointer_level += 1;
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->array_size = (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ }
}
-#line 2197 "src/parser_proc.c"
- yymsp[0].minor.yy184 = yylhsminor.yy184;
- break;
- case 32: /* decl_typedef_body_fn_args ::= LPAREN decl_args RPAREN */
-{ yy_destructor(yypParser,65,&yymsp[-2].minor);
-#line 374 "src/parser_proc.y"
-{
- yymsp[-2].minor.yy163 = yymsp[-1].minor.yy163;
+#line 3789 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 450:
+#line 1183 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl **)(&(*yyvalp))) = psi_decl_init((*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ if ((*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->pointer_level += 1;
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->array_size = (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ }
}
-#line 2206 "src/parser_proc.c"
- yy_destructor(yypParser,67,&yymsp[0].minor);
+#line 3801 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 451:
+#line 1190 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl **)(&(*yyvalp))) = psi_decl_init((*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl **)(&(*yyvalp)))->varargs = 1;
+ if ((*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->pointer_level += 1;
+ (*(struct psi_decl **)(&(*yyvalp)))->func->var->array_size = (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ }
}
- break;
- case 33: /* decl_typedef_body ::= decl_func decl_typedef_body_fn_args */
-#line 377 "src/parser_proc.y"
-{
- yylhsminor.yy184 = psi_decl_arg_init(psi_decl_type_init(PSI_T_FUNCTION, yymsp[-1].minor.yy184->var->name), psi_decl_var_copy(yymsp[-1].minor.yy184->var));
- yylhsminor.yy184->type->token = psi_token_copy(yymsp[-1].minor.yy184->token);
- yylhsminor.yy184->type->real.func = psi_decl_init(psi_decl_abi_init("default"), yymsp[-1].minor.yy184, yymsp[0].minor.yy163);
+#line 3814 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 452:
+#line 1201 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (void) (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init((*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)), psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), 0));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3826 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 453:
+#line 1208 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (void) (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3842 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 454:
+#line 1219 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (void) (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3858 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 455:
+#line 1230 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (void) (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text, 0, 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3874 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 457:
+#line 1245 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, 0, 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 3888 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 458:
+#line 1257 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2217 "src/parser_proc.c"
- yymsp[-1].minor.yy184 = yylhsminor.yy184;
- break;
- case 35: /* decl ::= decl_abi decl_func LPAREN decl_args RPAREN EOS */
-#line 385 "src/parser_proc.y"
-{
- yylhsminor.yy103 = psi_decl_init(yymsp[-5].minor.yy218, yymsp[-4].minor.yy184, yymsp[-2].minor.yy163);
+#line 3896 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 459:
+#line 1260 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2225 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-3].minor);
- yy_destructor(yypParser,67,&yymsp[-1].minor);
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-5].minor.yy103 = yylhsminor.yy103;
- break;
- case 36: /* decl ::= decl_abi decl_func LPAREN decl_args COMMA ELLIPSIS RPAREN EOS */
-#line 388 "src/parser_proc.y"
-{
- yylhsminor.yy103 = psi_decl_init(yymsp[-7].minor.yy218, yymsp[-6].minor.yy184, yymsp[-4].minor.yy163);
- yylhsminor.yy103->varargs = 1;
+#line 3904 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 460:
+#line 1263 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2237 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-5].minor);
- yy_destructor(yypParser,66,&yymsp[-3].minor);
- yy_destructor(yypParser,76,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[-1].minor);
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-7].minor.yy103 = yylhsminor.yy103;
- break;
- case 38: /* decl_func ::= VOID NAME */
-#line 395 "src/parser_proc.y"
-{
- yylhsminor.yy184 = psi_decl_arg_init(
- psi_decl_type_init(yymsp[-1].minor.yy0->type, yymsp[-1].minor.yy0->text),
- psi_decl_var_init(yymsp[0].minor.yy0->text, 0, 0)
- );
- yylhsminor.yy184->type->token = yymsp[-1].minor.yy0;
- yylhsminor.yy184->var->token = yymsp[0].minor.yy0;
- yylhsminor.yy184->token = yymsp[0].minor.yy0;
+#line 3912 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 461:
+#line 1269 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_arg_free), &(*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2256 "src/parser_proc.c"
- yymsp[-1].minor.yy184 = yylhsminor.yy184;
- break;
- case 39: /* decl_typedef_body ::= VOID indirection LPAREN indirection NAME RPAREN decl_typedef_body_fn_args */
-#line 404 "src/parser_proc.y"
-{
- struct psi_decl_arg *func_ = psi_decl_arg_init(
- psi_decl_type_init(yymsp[-6].minor.yy0->type, yymsp[-6].minor.yy0->text),
- psi_decl_var_init(yymsp[-2].minor.yy0->text, yymsp[-5].minor.yy202, 0)
- );
- func_->type->token = yymsp[-6].minor.yy0;
- func_->var->token = yymsp[-2].minor.yy0;
- func_->token = yymsp[-2].minor.yy0;
- yylhsminor.yy184 = psi_decl_arg_init(
- psi_decl_type_init(PSI_T_FUNCTION, func_->var->name),
- psi_decl_var_copy(func_->var)
- );
- yylhsminor.yy184->var->pointer_level = yymsp[-3].minor.yy202;
- yylhsminor.yy184->type->token = psi_token_copy(func_->token);
- yylhsminor.yy184->type->real.func = psi_decl_init(psi_decl_abi_init("default"), func_, yymsp[0].minor.yy163);
+#line 3920 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 462:
+#line 1272 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2277 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,67,&yymsp[-1].minor);
- yymsp[-6].minor.yy184 = yylhsminor.yy184;
- break;
- case 40: /* decl_typedef_body ::= CONST VOID pointers LPAREN indirection NAME RPAREN decl_typedef_body_fn_args */
-{ yy_destructor(yypParser,74,&yymsp[-7].minor);
-#line 420 "src/parser_proc.y"
-{
- struct psi_decl_arg *func_ = psi_decl_arg_init(
- psi_decl_type_init(yymsp[-6].minor.yy0->type, yymsp[-6].minor.yy0->text),
- psi_decl_var_init(yymsp[-2].minor.yy0->text, yymsp[-5].minor.yy202, 0)
- );
- func_->type->token = yymsp[-6].minor.yy0;
- func_->var->token = yymsp[-2].minor.yy0;
- func_->token = yymsp[-2].minor.yy0;
- yymsp[-7].minor.yy184 = psi_decl_arg_init(
- psi_decl_type_init(PSI_T_FUNCTION, func_->var->name),
- psi_decl_var_copy(func_->var)
- );
- yymsp[-7].minor.yy184->var->pointer_level = yymsp[-3].minor.yy202;
- yymsp[-7].minor.yy184->type->token = psi_token_copy(func_->token);
- yymsp[-7].minor.yy184->type->real.func = psi_decl_init(psi_decl_abi_init("default"), func_, yymsp[0].minor.yy163);
-}
-#line 2301 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,67,&yymsp[-1].minor);
-}
- break;
- case 41: /* decl_abi ::= NAME */
-#line 436 "src/parser_proc.y"
-{
- yylhsminor.yy218 = psi_decl_abi_init(yymsp[0].minor.yy0->text);
- yylhsminor.yy218->token = yymsp[0].minor.yy0;
-}
-#line 2312 "src/parser_proc.c"
- yymsp[0].minor.yy218 = yylhsminor.yy218;
- break;
- case 43: /* decl_var_array_size ::= LBRACKET NUMBER RBRACKET */
-{ yy_destructor(yypParser,77,&yymsp[-2].minor);
-#line 443 "src/parser_proc.y"
-{
- yymsp[-2].minor.yy0 = yymsp[-1].minor.yy0;
-}
-#line 2321 "src/parser_proc.c"
- yy_destructor(yypParser,78,&yymsp[0].minor);
-}
- break;
- case 44: /* decl_var ::= NAME decl_var_array_size */
-#line 446 "src/parser_proc.y"
-{
- yylhsminor.yy11 = psi_decl_var_init(yymsp[-1].minor.yy0->text, 0, yymsp[0].minor.yy0?atol(yymsp[0].minor.yy0->text):0);
- yylhsminor.yy11->token = yymsp[-1].minor.yy0;
- if (yymsp[0].minor.yy0) {
- free(yymsp[0].minor.yy0);
- }
-}
-#line 2334 "src/parser_proc.c"
- yymsp[-1].minor.yy11 = yylhsminor.yy11;
- break;
- case 45: /* decl_var ::= pointers NAME decl_var_array_size */
-#line 453 "src/parser_proc.y"
-{
- yylhsminor.yy11 = psi_decl_var_init(yymsp[-1].minor.yy0->text, yymsp[-2].minor.yy202+!!yymsp[0].minor.yy0, yymsp[0].minor.yy0?atol(yymsp[0].minor.yy0->text):0);
- yylhsminor.yy11->token = yymsp[-1].minor.yy0;
- if (yymsp[0].minor.yy0) {
- free(yymsp[0].minor.yy0);
- }
+#line 3928 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 463:
+#line 1279 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2346 "src/parser_proc.c"
- yymsp[-2].minor.yy11 = yylhsminor.yy11;
- break;
- case 46: /* decl_vars ::= decl_var */
-#line 460 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_var_free),
- &yymsp[0].minor.yy11);
+#line 3936 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 464:
+#line 1282 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ (*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)),
+ psi_decl_var_init(NULL, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), 0)
+ );
+}
+#line 3947 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 465:
+#line 1288 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init(NULL, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3961 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 466:
+#line 1297 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init(NULL, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 3975 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 467:
+#line 1309 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init(PSI_T_FUNCTION, (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->func->var->name),
+ psi_decl_var_copy((*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->func->var)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->func->token);
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->real.func = (*(struct psi_decl **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+}
+#line 3988 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 468:
+#line 1317 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init((*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2355 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 47: /* decl_vars ::= decl_vars COMMA decl_var */
-#line 464 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(yymsp[-2].minor.yy163, &yymsp[0].minor.yy11);
+#line 3996 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 469:
+#line 1320 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4011 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 470:
+#line 1330 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_arg **)(&(*yyvalp))) = psi_decl_arg_init(
+ psi_decl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text),
+ psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), 0)
+ );
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->type->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_arg **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4026 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 471:
+#line 1343 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_var **)(&(*yyvalp))) = psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text, (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)) + !! (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_var **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 4036 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 472:
+#line 1348 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_var **)(&(*yyvalp))) = psi_decl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text, !! (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_var **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 4046 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 473:
+#line 1356 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_union **)(&(*yyvalp))) = psi_decl_union_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_union **)(&(*yyvalp)))->align = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).pos;
+ (*(struct psi_decl_union **)(&(*yyvalp)))->size = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).len;
+ (*(struct psi_decl_union **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 4058 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 474:
+#line 1366 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_struct **)(&(*yyvalp))) = psi_decl_struct_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_struct **)(&(*yyvalp)))->align = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).pos;
+ (*(struct psi_decl_struct **)(&(*yyvalp)))->size = (*(struct psi_layout*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)).len;
+ (*(struct psi_decl_struct **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 4070 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 475:
+#line 1376 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2363 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy163 = yylhsminor.yy163;
- break;
- case 48: /* decl_arg ::= const_decl_type decl_var */
-#line 467 "src/parser_proc.y"
-{
- yylhsminor.yy184 = psi_decl_arg_init(yymsp[-1].minor.yy132, yymsp[0].minor.yy11);
+#line 4078 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 477:
+#line 1383 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
}
-#line 2372 "src/parser_proc.c"
- yymsp[-1].minor.yy184 = yylhsminor.yy184;
- break;
- case 49: /* decl_typedef_body ::= const_decl_type indirection LPAREN indirection NAME RPAREN decl_typedef_body_fn_args */
-#line 470 "src/parser_proc.y"
-{
- struct psi_decl_arg *func_ = psi_decl_arg_init(
- yymsp[-6].minor.yy132,
- psi_decl_var_init(yymsp[-2].minor.yy0->text, yymsp[-5].minor.yy202, 0)
- );
- func_->var->token = yymsp[-2].minor.yy0;
- func_->token = yymsp[-2].minor.yy0;
- yylhsminor.yy184 = psi_decl_arg_init(
- psi_decl_type_init(PSI_T_FUNCTION, func_->var->name),
- psi_decl_var_copy(func_->var)
- );
- yylhsminor.yy184->var->pointer_level = yymsp[-3].minor.yy202;
- yylhsminor.yy184->type->token = psi_token_copy(func_->token);
- yylhsminor.yy184->type->real.func = psi_decl_init(psi_decl_abi_init("default"), func_, yymsp[0].minor.yy163);
+#line 4086 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 478:
+#line 1389 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->layout = (*(struct psi_layout **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_arg_free), &(*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+ if ((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))) {
+ size_t i = 0;
+ struct psi_decl_arg *arg;
+
+ while (psi_plist_get((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), i++, &arg)) {
+ arg->type = psi_decl_type_copy((*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->type);
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&(*yyvalp))), &arg);
+ }
+ free((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ }
}
-#line 2392 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,67,&yymsp[-1].minor);
- yymsp[-6].minor.yy184 = yylhsminor.yy184;
- break;
- case 50: /* decl_arg ::= VOID pointers NAME */
-#line 485 "src/parser_proc.y"
-{
- yylhsminor.yy184 = psi_decl_arg_init(
- psi_decl_type_init(yymsp[-2].minor.yy0->type, yymsp[-2].minor.yy0->text),
- psi_decl_var_init(yymsp[0].minor.yy0->text, yymsp[-1].minor.yy202, 0)
- );
- yylhsminor.yy184->type->token = yymsp[-2].minor.yy0;
- yylhsminor.yy184->var->token = yymsp[0].minor.yy0;
- yylhsminor.yy184->token = yymsp[0].minor.yy0;
+#line 4105 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 479:
+#line 1403 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->layout = (*(struct psi_layout **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), &(*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+ if ((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))) {
+ size_t i = 0;
+ struct psi_decl_arg *arg;
+
+ while (psi_plist_get((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), i++, &arg)) {
+ arg->type = psi_decl_type_copy((*(struct psi_decl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->type);
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&(*yyvalp))), &arg);
+ }
+ free((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ }
}
-#line 2408 "src/parser_proc.c"
- yymsp[-2].minor.yy184 = yylhsminor.yy184;
- break;
- case 51: /* decl_arg ::= CONST VOID pointers NAME */
-{ yy_destructor(yypParser,74,&yymsp[-3].minor);
-#line 494 "src/parser_proc.y"
-{
- yymsp[-3].minor.yy184 = psi_decl_arg_init(
- psi_decl_type_init(yymsp[-2].minor.yy0->type, yymsp[-2].minor.yy0->text),
- psi_decl_var_init(yymsp[0].minor.yy0->text, yymsp[-1].minor.yy202, 0)
- );
- yymsp[-3].minor.yy184->type->token = yymsp[-2].minor.yy0;
- yymsp[-3].minor.yy184->var->token = yymsp[0].minor.yy0;
- yymsp[-3].minor.yy184->token = yymsp[0].minor.yy0;
+#line 4124 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 480:
+#line 1420 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2423 "src/parser_proc.c"
+#line 4132 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 481:
+#line 1423 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
- break;
- case 52: /* decl_args ::= */
-#line 503 "src/parser_proc.y"
-{
- yymsp[1].minor.yy163 = NULL;
+#line 4140 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 482:
+#line 1429 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ {
+ struct psi_decl_arg *arg = psi_decl_arg_init(NULL, (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ arg->layout = (*(struct psi_layout **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_arg_free), &arg);
+ }
}
-#line 2431 "src/parser_proc.c"
- break;
- case 53: /* decl_args ::= VOID */
-{ yy_destructor(yypParser,49,&yymsp[0].minor);
-#line 506 "src/parser_proc.y"
-{
- yymsp[0].minor.yy163 = NULL;
+#line 4152 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 483:
+#line 1436 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ {
+ struct psi_decl_arg *arg = psi_decl_arg_init(NULL, (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ arg->layout = (*(struct psi_layout **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)), &arg);
+ }
}
-#line 2439 "src/parser_proc.c"
+#line 4164 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 484:
+#line 1446 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_decl_enum **)(&(*yyvalp))) = psi_decl_enum_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_enum **)(&(*yyvalp)))->token = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval));
+}
+#line 4173 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 485:
+#line 1453 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_enum_item_free), &(*(struct psi_decl_enum_item **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 54: /* decl_args ::= decl_arg */
- case 56: /* struct_args ::= struct_arg */ yytestcase(yyruleno==56);
-#line 509 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_decl_arg_free),
- &yymsp[0].minor.yy184);
+#line 4181 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 486:
+#line 1456 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_decl_enum_item **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2449 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 55: /* decl_args ::= decl_args COMMA decl_arg */
-#line 513 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(yymsp[-2].minor.yy163, &yymsp[0].minor.yy184);
+#line 4189 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 487:
+#line 1462 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_enum_item **)(&(*yyvalp))) = psi_decl_enum_item_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, NULL);
+ (*(struct psi_decl_enum_item **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4199 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 488:
+#line 1467 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_decl_enum_item **)(&(*yyvalp))) = psi_decl_enum_item_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->text, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_decl_enum_item **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 4209 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 489:
+#line 1475 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_num((*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->token);
+}
+#line 4218 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 490:
+#line 1479 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_cast((*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->token);
+}
+#line 4227 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 491:
+#line 1483 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_unary(PSI_T_LPAREN, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 4236 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 492:
+#line 1487 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_binary((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 4245 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 493:
+#line 1491 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_unary((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 4254 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 494:
+#line 1495 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_num_exp **)(&(*yyvalp))) = psi_num_exp_init_ternary((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_num_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+}
+#line 4263 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 495:
+#line 1502 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->flags);
+ (*(struct psi_number **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4272 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 496:
+#line 1506 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, 0);
+ (*(struct psi_number **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4281 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 497:
+#line 1510 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, 0);
+ (*(struct psi_number **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4290 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 498:
+#line 1514 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, 0);
+ (*(struct psi_number **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4299 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 499:
+#line 1518 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init(PSI_T_NAME, (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), 0);
+ (*(struct psi_number **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->token);
+}
+#line 4308 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 500:
+#line 1522 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = (*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2457 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy163 = yylhsminor.yy163;
- break;
- case 57: /* struct_args ::= struct_args struct_arg */
-#line 520 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(yymsp[-1].minor.yy163, &yymsp[0].minor.yy184);
+#line 4316 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 501:
+#line 1528 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = (*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
+ (*(struct psi_number **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+}
+#line 4325 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 502:
+#line 1532 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = (*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_number **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+}
+#line 4334 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 503:
+#line 1539 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = (*(struct psi_number **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2466 "src/parser_proc.c"
- yymsp[-1].minor.yy163 = yylhsminor.yy163;
- break;
- case 58: /* struct_arg ::= decl_typedef_body_ex EOS */
-#line 523 "src/parser_proc.y"
-{
- yylhsminor.yy184 = yymsp[-1].minor.yy184;
- switch (yymsp[-1].minor.yy184->type->type) {
- case PSI_T_STRUCT:
- if (yymsp[-1].minor.yy184->type->real.strct) {
- if (!P->structs) {
- P->structs = psi_plist_init((psi_plist_dtor) psi_decl_struct_free);
- }
- P->structs = psi_plist_add(P->structs, &yymsp[-1].minor.yy184->type->real.strct);
- }
- break;
- case PSI_T_UNION:
- if (yymsp[-1].minor.yy184->type->real.unn) {
- if (!P->unions) {
- P->unions = psi_plist_init((psi_plist_dtor) psi_decl_union_free);
- }
- P->unions = psi_plist_add(P->unions, &yymsp[-1].minor.yy184->type->real.unn);
- }
- break;
- case PSI_T_ENUM:
- if (yymsp[-1].minor.yy184->type->real.enm) {
- if (!P->enums) {
- P->enums = psi_plist_init((psi_plist_dtor) psi_decl_enum_free);
- }
- P->enums = psi_plist_add(P->enums, &yymsp[-1].minor.yy184->type->real.enm);
- }
- break;
- }
+#line 4342 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 504:
+#line 1542 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ int8_t sizeof_void_p = sizeof(void *);
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init(PSI_T_INT8, &sizeof_void_p, 0);
+ psi_decl_type_free(&(*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ } else {
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init(PSI_T_SIZEOF, (*(struct psi_decl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), 0);
+ }
}
-#line 2500 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-1].minor.yy184 = yylhsminor.yy184;
- break;
- case 59: /* struct_arg ::= decl_arg decl_layout EOS */
-#line 552 "src/parser_proc.y"
-{
- yymsp[-2].minor.yy184->layout = yymsp[-1].minor.yy141;
- yylhsminor.yy184 = yymsp[-2].minor.yy184;
+#line 4356 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 505:
+#line 1554 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ int8_t sizeof_void_p = sizeof(void *);
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init(PSI_T_INT8, &sizeof_void_p, 0);
+}
+#line 4365 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 506:
+#line 1558 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ int8_t sizeof_a = sizeof('a');
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init(PSI_T_INT8, &sizeof_a, 0);
+}
+#line 4374 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 507:
+#line 1562 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_number **)(&(*yyvalp))) = psi_number_init(PSI_T_INT64, &(*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->size, 0);
}
-#line 2510 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-2].minor.yy184 = yylhsminor.yy184;
- break;
- case 60: /* decl_layout ::= */
-#line 556 "src/parser_proc.y"
-{
- yymsp[1].minor.yy141 = NULL;
+#line 4382 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 508:
+#line 1568 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ char digest[17];
+
+ psi_token_hash((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), digest);
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_append("@", psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))), 1, digest);
+ }
}
-#line 2519 "src/parser_proc.c"
- break;
- case 61: /* decl_layout ::= COLON COLON LPAREN NUMBER COMMA NUMBER RPAREN */
-{ yy_destructor(yypParser,64,&yymsp[-6].minor);
-#line 559 "src/parser_proc.y"
-{
- yymsp[-6].minor.yy141 = psi_layout_init(atol(yymsp[-3].minor.yy0->text), atol(yymsp[-1].minor.yy0->text));
- free(yymsp[-3].minor.yy0);
- free(yymsp[-1].minor.yy0);
+#line 4397 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 509:
+#line 1581 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ char digest[17];
+
+ psi_token_hash((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), digest);
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_append("@", psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))), 1, digest);
+ }
}
-#line 2529 "src/parser_proc.c"
- yy_destructor(yypParser,64,&yymsp[-5].minor);
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,66,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
+#line 4412 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 510:
+#line 1594 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if ((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))) {
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ } else {
+ char digest[17];
+
+ psi_token_hash((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), digest);
+ (*(struct psi_token **)(&(*yyvalp))) = psi_token_append("@", psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))), 1, digest);
+ }
}
- break;
- case 63: /* decl_scalar_type ::= SHORT decl_scalar_type_short */
- case 67: /* decl_scalar_type ::= LONG decl_scalar_type_long */ yytestcase(yyruleno==67);
- case 70: /* decl_scalar_type_long ::= LONG decl_scalar_type_long_long */ yytestcase(yyruleno==70);
-#line 567 "src/parser_proc.y"
-{
- if (yymsp[0].minor.yy0) {
- yylhsminor.yy0 = psi_token_cat(2, yymsp[-1].minor.yy0, yymsp[0].minor.yy0);
- free(yymsp[-1].minor.yy0);
- free(yymsp[0].minor.yy0);
- } else {
- yylhsminor.yy0 = yymsp[-1].minor.yy0;
- }
+#line 4427 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 511:
+#line 1607 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = NULL;
}
-#line 2549 "src/parser_proc.c"
- yymsp[-1].minor.yy0 = yylhsminor.yy0;
- break;
- case 73: /* decl_type ::= UNSIGNED decl_scalar_type */
- case 74: /* decl_type ::= SIGNED decl_scalar_type */ yytestcase(yyruleno==74);
-#line 615 "src/parser_proc.y"
-{
- struct psi_token *T = psi_token_cat(2, yymsp[-1].minor.yy0, yymsp[0].minor.yy0);
- yylhsminor.yy132 = psi_decl_type_init(T->type, T->text);
- yylhsminor.yy132->token = T;
- free(yymsp[-1].minor.yy0);
- free(yymsp[0].minor.yy0);
+#line 4435 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 512:
+#line 1610 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&(*yyvalp))) = (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_token **)(&(*yyvalp)))->type = PSI_T_NAME;
+}
+#line 4444 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 515:
+#line 1622 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_layout **)(&(*yyvalp))) = NULL;
}
-#line 2562 "src/parser_proc.c"
- yymsp[-1].minor.yy132 = yylhsminor.yy132;
- break;
- case 75: /* decl_type ::= UNSIGNED */
- case 76: /* decl_type ::= SIGNED */ yytestcase(yyruleno==76);
-#line 629 "src/parser_proc.y"
-{
- yylhsminor.yy132 = psi_decl_type_init(PSI_T_NAME, yymsp[0].minor.yy0->text);
- yylhsminor.yy132->token = yymsp[0].minor.yy0;
+#line 4452 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 516:
+#line 1625 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_layout **)(&(*yyvalp))) = psi_layout_init(0, 0, psi_layout_init(0, atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text), NULL));
}
-#line 2572 "src/parser_proc.c"
- yymsp[0].minor.yy132 = yylhsminor.yy132;
- break;
- case 77: /* decl_type ::= decl_scalar_type */
- case 81: /* decl_type ::= FLOAT|DOUBLE|INT8|UINT8|INT16|UINT16|INT32|UINT32|INT64|UINT64|NAME */ yytestcase(yyruleno==81);
-#line 637 "src/parser_proc.y"
-{
- yylhsminor.yy132 = psi_decl_type_init(yymsp[0].minor.yy0->type, yymsp[0].minor.yy0->text);
- yylhsminor.yy132->token = yymsp[0].minor.yy0;
+#line 4460 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 517:
+#line 1628 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_layout **)(&(*yyvalp))) = psi_layout_init(atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text), atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text), NULL);
}
-#line 2582 "src/parser_proc.c"
- yymsp[0].minor.yy132 = yylhsminor.yy132;
- break;
- case 78: /* decl_type ::= STRUCT NAME */
- case 79: /* decl_type ::= UNION NAME */ yytestcase(yyruleno==79);
- case 80: /* decl_type ::= ENUM NAME */ yytestcase(yyruleno==80);
-#line 641 "src/parser_proc.y"
-{
- yylhsminor.yy132 = psi_decl_type_init(yymsp[-1].minor.yy0->type, yymsp[0].minor.yy0->text);
- yylhsminor.yy132->token = yymsp[0].minor.yy0;
- free(yymsp[-1].minor.yy0);
+#line 4468 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 518:
+#line 1631 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_layout **)(&(*yyvalp))) = psi_layout_init(atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text), atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text), psi_layout_init(0, atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-7)].yystate.yysemantics.yysval))->text), NULL));
}
-#line 2594 "src/parser_proc.c"
- yymsp[-1].minor.yy132 = yylhsminor.yy132;
- break;
- case 82: /* const_decl_type ::= decl_type */
-#line 660 "src/parser_proc.y"
-{
- yylhsminor.yy132 = yymsp[0].minor.yy132;
+#line 4476 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 519:
+#line 1637 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_layout*)(&(*yyvalp))).pos = 0;
+ (*(struct psi_layout*)(&(*yyvalp))).len = 0;
+}
+#line 4485 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 520:
+#line 1641 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_layout*)(&(*yyvalp))).pos = atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text);
+ (*(struct psi_layout*)(&(*yyvalp))).len = atol((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))->text);
+}
+#line 4494 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 521:
+#line 1648 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = 0;
}
-#line 2602 "src/parser_proc.c"
- yymsp[0].minor.yy132 = yylhsminor.yy132;
- break;
- case 83: /* const_decl_type ::= CONST decl_type */
-{ yy_destructor(yypParser,74,&yymsp[-1].minor);
-#line 663 "src/parser_proc.y"
-{
- yymsp[-1].minor.yy132 = yymsp[0].minor.yy132;
+#line 4502 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 522:
+#line 1651 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = 0;
}
-#line 2611 "src/parser_proc.c"
+#line 4510 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 523:
+#line 1654 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = 0;
}
- break;
- case 84: /* impl ::= impl_func LBRACE impl_stmts RBRACE */
-#line 666 "src/parser_proc.y"
-{
- yylhsminor.yy97 = psi_impl_init(yymsp[-3].minor.yy168, yymsp[-1].minor.yy163);
+#line 4518 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 524:
+#line 1657 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ if (psi_num_exp_validate(PSI_DATA(P), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), NULL, NULL, NULL, NULL, NULL)) {
+ (*(size_t*)(&(*yyvalp))) = psi_long_num_exp((*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), NULL, &P->preproc->defs);
+ } else {
+ (*(size_t*)(&(*yyvalp))) = 0;
+ }
+ psi_num_exp_free(&(*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
}
-#line 2619 "src/parser_proc.c"
- yy_destructor(yypParser,71,&yymsp[-2].minor);
- yy_destructor(yypParser,72,&yymsp[0].minor);
- yymsp[-3].minor.yy97 = yylhsminor.yy97;
- break;
- case 85: /* impl ::= STATIC impl_func LBRACE impl_stmts RBRACE */
-{ yy_destructor(yypParser,84,&yymsp[-4].minor);
-#line 669 "src/parser_proc.y"
-{
- yymsp[-3].minor.yy168->static_memory = 1;
- yymsp[-4].minor.yy97 = psi_impl_init(yymsp[-3].minor.yy168, yymsp[-1].minor.yy163);
+#line 4531 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 525:
+#line 1668 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = 0;
}
-#line 2631 "src/parser_proc.c"
- yy_destructor(yypParser,71,&yymsp[-2].minor);
- yy_destructor(yypParser,72,&yymsp[0].minor);
+#line 4539 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 526:
+#line 1671 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
- break;
- case 86: /* impl_func ::= FUNCTION reference NSNAME LPAREN RPAREN COLON impl_type */
-{ yy_destructor(yypParser,85,&yymsp[-6].minor);
-#line 673 "src/parser_proc.y"
-{
- yymsp[-6].minor.yy168 = psi_impl_func_init(yymsp[-4].minor.yy0->text, NULL, yymsp[0].minor.yy138);
- yymsp[-6].minor.yy168->token = yymsp[-4].minor.yy0;
- yymsp[-6].minor.yy168->return_reference = yymsp[-5].minor.yy121;
+#line 4547 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 528:
+#line 1678 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
}
-#line 2644 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-3].minor);
- yy_destructor(yypParser,67,&yymsp[-2].minor);
- yy_destructor(yypParser,64,&yymsp[-1].minor);
+#line 4555 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 529:
+#line 1684 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = 1;
}
- break;
- case 87: /* impl_func ::= FUNCTION reference NSNAME LPAREN impl_args RPAREN COLON impl_type */
-{ yy_destructor(yypParser,85,&yymsp[-7].minor);
-#line 678 "src/parser_proc.y"
-{
- yymsp[-7].minor.yy168 = psi_impl_func_init(yymsp[-5].minor.yy0->text, yymsp[-3].minor.yy163, yymsp[0].minor.yy138);
- yymsp[-7].minor.yy168->token = yymsp[-5].minor.yy0;
- yymsp[-7].minor.yy168->return_reference = yymsp[-6].minor.yy121;
+#line 4563 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 530:
+#line 1687 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(size_t*)(&(*yyvalp))) = (*(size_t*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)) + 1;
}
-#line 2658 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,67,&yymsp[-2].minor);
- yy_destructor(yypParser,64,&yymsp[-1].minor);
+#line 4571 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 533:
+#line 1704 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl **)(&(*yyvalp))) = psi_impl_init((*(struct psi_impl_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
}
- break;
- case 88: /* impl_func ::= FUNCTION reference NSNAME LPAREN impl_args COMMA impl_type reference ELLIPSIS DOLLAR_NAME RPAREN COLON impl_type */
-{ yy_destructor(yypParser,85,&yymsp[-12].minor);
-#line 683 "src/parser_proc.y"
-{
- yymsp[-12].minor.yy168 = psi_impl_func_init(yymsp[-10].minor.yy0->text, yymsp[-8].minor.yy163, yymsp[0].minor.yy138);
- yymsp[-12].minor.yy168->token = yymsp[-10].minor.yy0;
- yymsp[-12].minor.yy168->return_reference = yymsp[-11].minor.yy121;
- yymsp[-12].minor.yy168->vararg = psi_impl_arg_init(yymsp[-6].minor.yy138, psi_impl_var_init(yymsp[-3].minor.yy0->text, yymsp[-5].minor.yy121), NULL);
- free(yymsp[-3].minor.yy0);
+#line 4579 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 534:
+#line 1707 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl **)(&(*yyvalp))) = psi_impl_init((*(struct psi_impl_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->static_memory = 1;
+}
+#line 4588 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 535:
+#line 1714 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_func **)(&(*yyvalp))) = psi_impl_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->text, NULL, (*(struct psi_impl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_func **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_func **)(&(*yyvalp)))->return_reference = (*(bool*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval));
+}
+#line 4598 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 536:
+#line 1719 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_func **)(&(*yyvalp))) = psi_impl_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)), (*(struct psi_impl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_func **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_func **)(&(*yyvalp)))->return_reference = (*(bool*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval));
+}
+#line 4608 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 537:
+#line 1724 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_func **)(&(*yyvalp))) = psi_impl_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-10)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-8)].yystate.yysemantics.yysval)), (*(struct psi_impl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_func **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-10)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_func **)(&(*yyvalp)))->return_reference = (*(bool*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-11)].yystate.yysemantics.yysval));
+ (*(struct psi_impl_func **)(&(*yyvalp)))->vararg = psi_impl_arg_init((*(struct psi_impl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval)), psi_impl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text, (*(bool*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))), NULL);
+ (*(struct psi_impl_func **)(&(*yyvalp)))->vararg->var->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+}
+#line 4620 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 538:
+#line 1734 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_impl_arg_free), &(*(struct psi_impl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2674 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-9].minor);
- yy_destructor(yypParser,66,&yymsp[-7].minor);
- yy_destructor(yypParser,76,&yymsp[-4].minor);
- yy_destructor(yypParser,67,&yymsp[-2].minor);
- yy_destructor(yypParser,64,&yymsp[-1].minor);
+#line 4628 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 539:
+#line 1737 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_impl_arg **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 89: /* impl_def_val ::= NULL|NUMBER|TRUE|FALSE|QUOTED_STRING */
-#line 690 "src/parser_proc.y"
-{
- yylhsminor.yy93 = psi_impl_def_val_init(yymsp[0].minor.yy0->type, yymsp[0].minor.yy0->text);
- yylhsminor.yy93->token = yymsp[0].minor.yy0;
+#line 4636 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 540:
+#line 1743 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_arg **)(&(*yyvalp))) = psi_impl_arg_init((*(struct psi_impl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), (*(struct psi_impl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)), NULL);
}
-#line 2688 "src/parser_proc.c"
- yymsp[0].minor.yy93 = yylhsminor.yy93;
- break;
- case 90: /* impl_var ::= reference DOLLAR_NAME */
-#line 694 "src/parser_proc.y"
-{
- yylhsminor.yy37 = psi_impl_var_init(yymsp[0].minor.yy0->text, yymsp[-1].minor.yy121);
- yylhsminor.yy37->token = yymsp[0].minor.yy0;
+#line 4644 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 541:
+#line 1746 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_arg **)(&(*yyvalp))) = psi_impl_arg_init((*(struct psi_impl_type **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)), (*(struct psi_impl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_impl_def_val **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2697 "src/parser_proc.c"
- yymsp[-1].minor.yy37 = yylhsminor.yy37;
- break;
- case 91: /* impl_type ::= VOID|MIXED|BOOL|INT|FLOAT|STRING|ARRAY|OBJECT|CALLABLE */
-#line 698 "src/parser_proc.y"
-{
- yylhsminor.yy138 = psi_impl_type_init(yymsp[0].minor.yy0->type, yymsp[0].minor.yy0->text);
- free(yymsp[0].minor.yy0);
+#line 4652 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 542:
+#line 1752 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_var **)(&(*yyvalp))) = psi_impl_var_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text, (*(bool*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_impl_var **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4661 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 543:
+#line 1759 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_impl_type **)(&(*yyvalp))) = psi_impl_type_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->text);
+ (*(struct psi_impl_type **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+}
+#line 4670 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 553:
+#line 1778 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_impl_stmt_free), &(*(struct psi_token ***)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2706 "src/parser_proc.c"
- yymsp[0].minor.yy138 = yylhsminor.yy138;
- break;
- case 92: /* impl_arg ::= impl_type impl_var */
-#line 702 "src/parser_proc.y"
-{
- yylhsminor.yy210 = psi_impl_arg_init(yymsp[-1].minor.yy138, yymsp[0].minor.yy37, NULL);
+#line 4678 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 554:
+#line 1781 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)), &(*(struct psi_token ***)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2714 "src/parser_proc.c"
- yymsp[-1].minor.yy210 = yylhsminor.yy210;
- break;
- case 93: /* impl_arg ::= impl_type impl_var EQUALS impl_def_val */
-#line 705 "src/parser_proc.y"
-{
- yylhsminor.yy210 = psi_impl_arg_init(yymsp[-3].minor.yy138, yymsp[-2].minor.yy37, yymsp[0].minor.yy93);
+#line 4686 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 555:
+#line 1787 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token ***)(&(*yyvalp))) = (struct psi_token **) (*(struct psi_return_stmt **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2722 "src/parser_proc.c"
- yy_destructor(yypParser,73,&yymsp[-1].minor);
- yymsp[-3].minor.yy210 = yylhsminor.yy210;
- break;
- case 94: /* impl_args ::= impl_arg */
-#line 708 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_impl_arg_free),
- &yymsp[0].minor.yy210);
+#line 4694 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 556:
+#line 1790 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token ***)(&(*yyvalp))) = (struct psi_token **) (*(struct psi_let_stmt **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2732 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 95: /* impl_args ::= impl_args COMMA impl_arg */
-#line 712 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(yymsp[-2].minor.yy163, &yymsp[0].minor.yy210);
+#line 4702 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 557:
+#line 1793 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token ***)(&(*yyvalp))) = (struct psi_token **) (*(struct psi_set_stmt **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2740 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy163 = yylhsminor.yy163;
- break;
- case 96: /* impl_stmts ::= impl_stmt */
-#line 715 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_impl_stmt_free),
- &yymsp[0].minor.yy78);
+#line 4710 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 558:
+#line 1796 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token ***)(&(*yyvalp))) = (struct psi_token **) (*(struct psi_assert_stmt **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2750 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 97: /* impl_stmts ::= impl_stmts impl_stmt */
-#line 719 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(yymsp[-1].minor.yy163, &yymsp[0].minor.yy78);
+#line 4718 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 559:
+#line 1799 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token ***)(&(*yyvalp))) = (struct psi_token **) (*(struct psi_free_stmt **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2758 "src/parser_proc.c"
- yymsp[-1].minor.yy163 = yylhsminor.yy163;
- break;
- case 98: /* impl_stmt ::= return_stmt */
-#line 722 "src/parser_proc.y"
-{
- yylhsminor.yy78 = (struct psi_token**) yymsp[0].minor.yy90;
+#line 4726 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 560:
+#line 1805 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_stmt **)(&(*yyvalp))) = psi_let_stmt_init((*(struct psi_let_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_stmt **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 4735 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 561:
+#line 1809 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_stmt **)(&(*yyvalp))) = psi_let_stmt_init(psi_let_exp_init_ex((*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)), PSI_LET_TMP, (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval))));
+ (*(struct psi_let_stmt **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_stmt **)(&(*yyvalp)))->exp->is_reference = (*(bool*)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+}
+#line 4745 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 563:
+#line 1818 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = (*(struct psi_let_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_let_exp **)(&(*yyvalp)))->is_reference = true;
+}
+#line 4754 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 564:
+#line 1822 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = (*(struct psi_let_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_let_exp **)(&(*yyvalp)))->is_reference = false;
+}
+#line 4763 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 565:
+#line 1829 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = psi_let_exp_init(PSI_LET_NULL, NULL);
}
-#line 2766 "src/parser_proc.c"
- yymsp[0].minor.yy78 = yylhsminor.yy78;
- break;
- case 99: /* impl_stmt ::= let_stmt */
-#line 725 "src/parser_proc.y"
-{
- yylhsminor.yy78 = (struct psi_token**) yymsp[0].minor.yy311;
+#line 4771 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 566:
+#line 1832 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = psi_let_exp_init_ex(NULL, PSI_LET_NUMEXP, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2774 "src/parser_proc.c"
- yymsp[0].minor.yy78 = yylhsminor.yy78;
- break;
- case 100: /* impl_stmt ::= set_stmt */
-#line 728 "src/parser_proc.y"
-{
- yylhsminor.yy78 = (struct psi_token**) yymsp[0].minor.yy98;
+#line 4779 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 567:
+#line 1835 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = psi_let_exp_init(PSI_LET_CALLOC, (*(struct psi_let_calloc **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2782 "src/parser_proc.c"
- yymsp[0].minor.yy78 = yylhsminor.yy78;
- break;
- case 101: /* impl_stmt ::= free_stmt */
-#line 731 "src/parser_proc.y"
-{
- yylhsminor.yy78 = (struct psi_token**) yymsp[0].minor.yy192;
+#line 4787 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 568:
+#line 1838 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = psi_let_exp_init(PSI_LET_CALLOC, (*(struct psi_let_calloc **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_calloc **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->static_memory = 1;
+}
+#line 4796 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 569:
+#line 1842 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = psi_let_exp_init(PSI_LET_CALLBACK, (*(struct psi_let_callback **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2790 "src/parser_proc.c"
- yymsp[0].minor.yy78 = yylhsminor.yy78;
- break;
- case 102: /* number ::= NUMBER|NSNAME */
-#line 734 "src/parser_proc.y"
-{
- yylhsminor.yy188 = psi_number_init(yymsp[0].minor.yy0->type, yymsp[0].minor.yy0->text);
- yylhsminor.yy188->token = yymsp[0].minor.yy0;
+#line 4804 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 570:
+#line 1845 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = psi_let_exp_init_ex(NULL, PSI_LET_FUNC, (*(struct psi_let_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2799 "src/parser_proc.c"
- yymsp[0].minor.yy188 = yylhsminor.yy188;
- break;
- case 103: /* number ::= decl_var */
-#line 738 "src/parser_proc.y"
-{
- yylhsminor.yy188 = psi_number_init(PSI_T_NAME, yymsp[0].minor.yy11);
- yylhsminor.yy188->token = psi_token_copy(yymsp[0].minor.yy11->token);
+#line 4812 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 571:
+#line 1851 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = (*(struct psi_let_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_let_exp **)(&(*yyvalp)))->var = (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+}
+#line 4821 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 572:
+#line 1855 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_exp **)(&(*yyvalp))) = (*(struct psi_let_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_let_exp **)(&(*yyvalp)))->is_reference = 1;
+ (*(struct psi_let_exp **)(&(*yyvalp)))->var = (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval));
+}
+#line 4831 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 573:
+#line 1863 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_calloc **)(&(*yyvalp))) = psi_let_calloc_init((*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)), (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_calloc **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)));
+}
+#line 4840 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 574:
+#line 1870 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_callback **)(&(*yyvalp))) = psi_let_callback_init(psi_let_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval))->text, (*(struct psi_impl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), NULL);
+ (*(struct psi_let_callback **)(&(*yyvalp)))->func->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_callback **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-7)].yystate.yysemantics.yysval)));
+}
+#line 4850 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 575:
+#line 1875 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_callback **)(&(*yyvalp))) = psi_let_callback_init(psi_let_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval))->text, (*(struct psi_impl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-9)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_callback **)(&(*yyvalp)))->func->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_callback **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-11)].yystate.yysemantics.yysval)));
+}
+#line 4860 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 576:
+#line 1883 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_let_func **)(&(*yyvalp))) = psi_let_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->text, (*(struct psi_impl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_func **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)));
+ (*(struct psi_let_func **)(&(*yyvalp)))->inner = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
+}
+#line 4870 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 587:
+#line 1904 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2808 "src/parser_proc.c"
- yymsp[0].minor.yy188 = yylhsminor.yy188;
- break;
- case 104: /* num_exp ::= number */
-#line 742 "src/parser_proc.y"
-{
- yylhsminor.yy259 = psi_num_exp_init_num(yymsp[0].minor.yy188);
- yylhsminor.yy259->token = psi_token_copy(yymsp[0].minor.yy188->token);
+#line 4878 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 588:
+#line 1907 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2817 "src/parser_proc.c"
- yymsp[0].minor.yy259 = yylhsminor.yy259;
- break;
- case 105: /* num_exp ::= LPAREN num_exp RPAREN */
-#line 746 "src/parser_proc.y"
-{
- yylhsminor.yy259 = psi_num_exp_init_unary(PSI_T_LPAREN, yymsp[-1].minor.yy259);
- yylhsminor.yy259->token = yymsp[-2].minor.yy0;
+#line 4886 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 589:
+#line 1913 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_let_exp_free), &(*(struct psi_let_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2826 "src/parser_proc.c"
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-2].minor.yy259 = yylhsminor.yy259;
- break;
- case 106: /* num_exp ::= num_exp PIPE|CARET|AMPERSAND|LSHIFT|RSHIFT|PLUS|MINUS|ASTERISK|SLASH|MODULO num_exp */
-#line 750 "src/parser_proc.y"
-{
- yylhsminor.yy259 = psi_num_exp_init_binary(yymsp[-1].minor.yy0->type, yymsp[-2].minor.yy259, yymsp[0].minor.yy259);
- yylhsminor.yy259->token = yymsp[-1].minor.yy0;
+#line 4894 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 590:
+#line 1916 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_let_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2836 "src/parser_proc.c"
- yymsp[-2].minor.yy259 = yylhsminor.yy259;
- break;
- case 107: /* num_exp ::= TILDE|NOT|PLUS|MINUS num_exp */
-#line 754 "src/parser_proc.y"
-{
- yylhsminor.yy259 = psi_num_exp_init_unary(yymsp[-1].minor.yy0->type, yymsp[0].minor.yy259);
- yylhsminor.yy259->token = yymsp[-1].minor.yy0;
+#line 4902 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 593:
+#line 1927 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2845 "src/parser_proc.c"
- yymsp[-1].minor.yy259 = yylhsminor.yy259;
- break;
- case 108: /* let_exp ::= NULL */
-{ yy_destructor(yypParser,15,&yymsp[0].minor);
-#line 758 "src/parser_proc.y"
-{
- yymsp[0].minor.yy20 = psi_let_exp_init(PSI_LET_NULL, NULL);
+#line 4910 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 594:
+#line 1930 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2854 "src/parser_proc.c"
+#line 4918 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 595:
+#line 1936 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_set_exp_free), &(*(struct psi_set_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 109: /* let_exp ::= AMPERSAND NULL */
-{ yy_destructor(yypParser,23,&yymsp[-1].minor);
-#line 761 "src/parser_proc.y"
-{
- yymsp[-1].minor.yy20 = psi_let_exp_init(PSI_LET_NULL, NULL);
- yymsp[-1].minor.yy20->is_reference = 1;
+#line 4926 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 596:
+#line 1939 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_set_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2864 "src/parser_proc.c"
- yy_destructor(yypParser,15,&yymsp[0].minor);
+#line 4934 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 597:
+#line 1945 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_return_stmt **)(&(*yyvalp))) = psi_return_stmt_init((*(struct psi_return_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_return_stmt **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 4943 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 598:
+#line 1952 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_return_exp **)(&(*yyvalp))) = psi_return_exp_init((*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)), (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)), psi_set_exp_init(PSI_SET_FUNC, (*(struct psi_set_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))));
+ (*(struct psi_return_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->token);
+}
+#line 4952 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 599:
+#line 1956 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_return_exp **)(&(*yyvalp))) = psi_return_exp_init(NULL, NULL, psi_set_exp_init(PSI_SET_FUNC, (*(struct psi_set_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))));
+ (*(struct psi_return_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_set_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval))->token);
+}
+#line 4961 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 600:
+#line 1963 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
- break;
- case 110: /* let_exp ::= let_callback */
-#line 765 "src/parser_proc.y"
-{
- yylhsminor.yy20 = psi_let_exp_init(PSI_LET_CALLBACK, yymsp[0].minor.yy220);
+#line 4969 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 601:
+#line 1966 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2873 "src/parser_proc.c"
- yymsp[0].minor.yy20 = yylhsminor.yy20;
- break;
- case 111: /* let_exp ::= let_calloc */
-#line 768 "src/parser_proc.y"
-{
- yylhsminor.yy20 = psi_let_exp_init(PSI_LET_CALLOC, yymsp[0].minor.yy9);
+#line 4977 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 602:
+#line 1969 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2881 "src/parser_proc.c"
- yymsp[0].minor.yy20 = yylhsminor.yy20;
- break;
- case 112: /* let_exp ::= AMPERSAND let_calloc */
-{ yy_destructor(yypParser,23,&yymsp[-1].minor);
-#line 771 "src/parser_proc.y"
-{
- yymsp[-1].minor.yy20 = psi_let_exp_init(PSI_LET_CALLOC, yymsp[0].minor.yy9);
- yymsp[-1].minor.yy20->is_reference = 1;
+#line 4985 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 603:
+#line 1975 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_set_stmt **)(&(*yyvalp))) = psi_set_stmt_init((*(struct psi_set_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_set_stmt **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 4994 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 604:
+#line 1982 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_set_exp **)(&(*yyvalp))) = psi_set_exp_init(PSI_SET_FUNC, (*(struct psi_set_func **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2891 "src/parser_proc.c"
+#line 5002 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 605:
+#line 1985 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_set_exp **)(&(*yyvalp))) = psi_set_exp_init(PSI_SET_NUMEXP, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 113: /* let_exp ::= let_func */
-#line 775 "src/parser_proc.y"
-{
- yylhsminor.yy20 = psi_let_exp_init_ex(NULL, PSI_LET_FUNC, yymsp[0].minor.yy27);
+#line 5010 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 606:
+#line 1988 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_set_exp **)(&(*yyvalp))) = (*(struct psi_set_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
+ (*(struct psi_set_exp **)(&(*yyvalp)))->var = (*(struct psi_impl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval));
+}
+#line 5019 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 607:
+#line 1995 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_set_func **)(&(*yyvalp))) = psi_set_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval))->text, (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+ (*(struct psi_set_func **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval)));
+ (*(struct psi_set_func **)(&(*yyvalp)))->inner = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval));
+}
+#line 5029 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 608:
+#line 2000 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_set_func **)(&(*yyvalp))) = psi_set_func_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->type, (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval))->text, (*(struct psi_decl_var **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+ (*(struct psi_set_func **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval)));
+ (*(struct psi_set_func **)(&(*yyvalp)))->recursive = 1;
+}
+#line 5039 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 617:
+#line 2019 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = NULL;
}
-#line 2899 "src/parser_proc.c"
- yymsp[0].minor.yy20 = yylhsminor.yy20;
- break;
- case 114: /* let_exp ::= AMPERSAND let_func */
-{ yy_destructor(yypParser,23,&yymsp[-1].minor);
-#line 778 "src/parser_proc.y"
-{
- yymsp[-1].minor.yy20 = psi_let_exp_init_ex(NULL, PSI_LET_FUNC, yymsp[0].minor.yy27);
- yymsp[-1].minor.yy20->is_reference = 1;
+#line 5047 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 618:
+#line 2022 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval));
}
-#line 2909 "src/parser_proc.c"
+#line 5055 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 619:
+#line 2028 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_set_exp_free), &(*(struct psi_set_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 115: /* let_exp ::= num_exp */
-#line 782 "src/parser_proc.y"
-{
- yylhsminor.yy20 = psi_let_exp_init_ex(NULL, PSI_LET_NUMEXP, yymsp[0].minor.yy259);
+#line 5063 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 620:
+#line 2031 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_set_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2917 "src/parser_proc.c"
- yymsp[0].minor.yy20 = yylhsminor.yy20;
- break;
- case 116: /* let_exp ::= AMPERSAND num_exp */
-{ yy_destructor(yypParser,23,&yymsp[-1].minor);
-#line 785 "src/parser_proc.y"
-{
- yymsp[-1].minor.yy20 = psi_let_exp_init_ex(NULL, PSI_LET_NUMEXP, yymsp[0].minor.yy259);
- yymsp[-1].minor.yy20->is_reference = 1;
+#line 5071 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 621:
+#line 2037 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_assert_stmt **)(&(*yyvalp))) = psi_assert_stmt_init((enum psi_assert_kind) (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval))->type, (*(struct psi_num_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_assert_stmt **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 5080 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 624:
+#line 2049 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_free_stmt **)(&(*yyvalp))) = psi_free_stmt_init((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_free_stmt **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)));
+}
+#line 5089 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 625:
+#line 2056 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_free_exp_free), &(*(struct psi_free_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
-#line 2927 "src/parser_proc.c"
+#line 5097 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 626:
+#line 2059 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_plist **)(&(*yyvalp))) = psi_plist_add((*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval)), &(*(struct psi_free_exp **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval)));
}
- break;
- case 117: /* let_exp ::= decl_var EQUALS let_exp */
-#line 789 "src/parser_proc.y"
-{
- yylhsminor.yy20 = yymsp[0].minor.yy20;
- yylhsminor.yy20->var = yymsp[-2].minor.yy11;
+#line 5105 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 627:
+#line 2065 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->type = PSI_T_NAME;
+ (*(struct psi_free_exp **)(&(*yyvalp))) = psi_free_exp_init((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval))->text, (*(struct psi_plist **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval)));
+ (*(struct psi_free_exp **)(&(*yyvalp)))->token = psi_token_copy((*(struct psi_token **)(&((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval)));
+}
+#line 5115 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 628:
+#line 2073 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(bool*)(&(*yyvalp))) = false;
}
-#line 2936 "src/parser_proc.c"
- yy_destructor(yypParser,73,&yymsp[-1].minor);
- yymsp[-2].minor.yy20 = yylhsminor.yy20;
- break;
- case 118: /* let_stmt ::= LET let_exp EOS */
-#line 793 "src/parser_proc.y"
-{
- yylhsminor.yy311 = psi_let_stmt_init(yymsp[-1].minor.yy20);
- yylhsminor.yy311->token = yymsp[-2].minor.yy0;
+#line 5123 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+ case 629:
+#line 2076 "src/parser_proc_grammar.y" /* glr.c:816 */
+ {
+ (*(bool*)(&(*yyvalp))) = true;
}
-#line 2946 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-2].minor.yy311 = yylhsminor.yy311;
- break;
- case 119: /* let_stmt ::= TEMP decl_var EQUALS reference decl_var EOS */
-#line 797 "src/parser_proc.y"
-{
- yylhsminor.yy311 = psi_let_stmt_init(psi_let_exp_init_ex(yymsp[-4].minor.yy11, PSI_LET_TMP, yymsp[-1].minor.yy11));
- yylhsminor.yy311->token = yymsp[-5].minor.yy0;
- yylhsminor.yy311->exp->is_reference = yymsp[-2].minor.yy121 ? 1 : 0;
+#line 5131 "src/parser_proc.c" /* glr.c:816 */
+ break;
+
+
+#line 5135 "src/parser_proc.c" /* glr.c:816 */
+ default: break;
+ }
+
+ return yyok;
+# undef yyerrok
+# undef YYABORT
+# undef YYACCEPT
+# undef YYERROR
+# undef YYBACKUP
+# undef yyclearin
+# undef YYRECOVERING
}
-#line 2957 "src/parser_proc.c"
- yy_destructor(yypParser,73,&yymsp[-3].minor);
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-5].minor.yy311 = yylhsminor.yy311;
- break;
- case 120: /* let_callback ::= CALLBACK callback_rval LPAREN impl_var LPAREN callback_arg_list RPAREN RPAREN */
-#line 802 "src/parser_proc.y"
+
+
+static void
+yyuserMerge (int yyn, YYSTYPE* yy0, YYSTYPE* yy1)
{
- yylhsminor.yy220 = psi_let_callback_init(psi_let_func_init(yymsp[-6].minor.yy0->type, yymsp[-6].minor.yy0->text, yymsp[-4].minor.yy37), yymsp[-2].minor.yy43);
- yylhsminor.yy220->token = yymsp[-7].minor.yy0;
- free(yymsp[-6].minor.yy0);
+ YYUSE (yy0);
+ YYUSE (yy1);
+
+ switch (yyn)
+ {
+
+ default: break;
+ }
}
-#line 2969 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-5].minor);
- yy_destructor(yypParser,65,&yymsp[-3].minor);
- yy_destructor(yypParser,67,&yymsp[-1].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-7].minor.yy220 = yylhsminor.yy220;
+
+ /* Bison grammar-table manipulation. */
+
+/*-----------------------------------------------.
+| Release the memory associated to this symbol. |
+`-----------------------------------------------*/
+
+static void
+yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ YYUSE (yyvaluep);
+ YYUSE (P);
+ YYUSE (tokens);
+ YYUSE (index);
+ if (!yymsg)
+ yymsg = "Deleting";
+ YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
+
+ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+ switch (yytype)
+ {
+ case 141: /* binary_op_token */
+#line 307 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5186 "src/parser_proc.c" /* glr.c:846 */
break;
- case 121: /* let_calloc ::= CALLOC LPAREN num_exp COMMA num_exp RPAREN */
-#line 807 "src/parser_proc.y"
-{
- yylhsminor.yy9 = psi_let_calloc_init(yymsp[-3].minor.yy259, yymsp[-1].minor.yy259);
- yylhsminor.yy9->token = yymsp[-5].minor.yy0;
-}
-#line 2982 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,66,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-5].minor.yy9 = yylhsminor.yy9;
+
+ case 142: /* unary_op_token */
+#line 307 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5192 "src/parser_proc.c" /* glr.c:846 */
break;
- case 122: /* let_func ::= ZVAL|OBJVAL|ARRVAL|PATHVAL|STRLEN|STRVAL|FLOATVAL|INTVAL|BOOLVAL|COUNT LPAREN impl_var RPAREN */
-#line 811 "src/parser_proc.y"
-{
- yylhsminor.yy27 = psi_let_func_init(yymsp[-3].minor.yy0->type, yymsp[-3].minor.yy0->text, yymsp[-1].minor.yy37);
- yylhsminor.yy27->token = yymsp[-3].minor.yy0;
-}
-#line 2994 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-3].minor.yy27 = yylhsminor.yy27;
+
+ case 143: /* name_token */
+#line 307 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5198 "src/parser_proc.c" /* glr.c:846 */
break;
- case 123: /* let_func ::= ZVAL|OBJVAL|ARRVAL|PATHVAL|STRLEN|STRVAL|FLOATVAL|INTVAL|BOOLVAL|COUNT LPAREN impl_var COMMA let_exps RPAREN */
-#line 815 "src/parser_proc.y"
-{
- yylhsminor.yy27 = psi_let_func_init(yymsp[-5].minor.yy0->type, yymsp[-5].minor.yy0->text, yymsp[-3].minor.yy37);
- yylhsminor.yy27->token = yymsp[-5].minor.yy0;
- yylhsminor.yy27->inner = yymsp[-1].minor.yy163;
-}
-#line 3006 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,66,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-5].minor.yy27 = yylhsminor.yy27;
+
+ case 144: /* any_noeol_token */
+#line 307 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5204 "src/parser_proc.c" /* glr.c:846 */
break;
- case 124: /* let_exps ::= let_exp */
-#line 820 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_let_exp_free),
- &yymsp[0].minor.yy20);
-}
-#line 3018 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
+
+ case 149: /* lib */
+#line 301 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5210 "src/parser_proc.c" /* glr.c:846 */
break;
- case 125: /* let_exps ::= let_exps COMMA let_exp */
-#line 824 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(yymsp[-2].minor.yy163, &yymsp[0].minor.yy20);
-}
-#line 3026 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy163 = yylhsminor.yy163;
+
+ case 150: /* cpp */
+#line 316 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_cpp_exp_free(&(*(struct psi_cpp_exp **)(&(*yyvaluep))));}
+#line 5216 "src/parser_proc.c" /* glr.c:846 */
break;
- case 126: /* callback_arg_list ::= */
-#line 827 "src/parser_proc.y"
-{
- yymsp[1].minor.yy43 = NULL;
-}
-#line 3035 "src/parser_proc.c"
+
+ case 151: /* cpp_exp */
+#line 316 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_cpp_exp_free(&(*(struct psi_cpp_exp **)(&(*yyvaluep))));}
+#line 5222 "src/parser_proc.c" /* glr.c:846 */
break;
- case 127: /* callback_arg_list ::= callback_args */
-#line 830 "src/parser_proc.y"
-{
- yylhsminor.yy43 = yymsp[0].minor.yy43;
-}
-#line 3042 "src/parser_proc.c"
- yymsp[0].minor.yy43 = yylhsminor.yy43;
+
+ case 153: /* cpp_message_token */
+#line 304 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5228 "src/parser_proc.c" /* glr.c:846 */
break;
- case 128: /* callback_args ::= set_exp */
-#line 833 "src/parser_proc.y"
-{
- yylhsminor.yy43 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_set_exp_free),
- &yymsp[0].minor.yy147);
-}
-#line 3051 "src/parser_proc.c"
- yymsp[0].minor.yy43 = yylhsminor.yy43;
+
+ case 154: /* cpp_include_token */
+#line 304 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5234 "src/parser_proc.c" /* glr.c:846 */
break;
- case 129: /* callback_args ::= callback_args COMMA set_exp */
-#line 837 "src/parser_proc.y"
-{
- yylhsminor.yy43 = psi_plist_add(yymsp[-2].minor.yy43, &yymsp[0].minor.yy147);
-}
-#line 3059 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy43 = yylhsminor.yy43;
+
+ case 155: /* cpp_header_token */
+#line 304 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5240 "src/parser_proc.c" /* glr.c:846 */
break;
- case 132: /* set_func ::= TO_OBJECT|TO_ARRAY|TO_STRING|TO_INT|TO_FLOAT|TO_BOOL|ZVAL|VOID LPAREN decl_var RPAREN */
-#line 846 "src/parser_proc.y"
-{
- yylhsminor.yy26 = psi_set_func_init(yymsp[-3].minor.yy0->type, yymsp[-3].minor.yy0->text, yymsp[-1].minor.yy11);
- yylhsminor.yy26->token = yymsp[-3].minor.yy0;
-}
-#line 3069 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-3].minor.yy26 = yylhsminor.yy26;
+
+ case 156: /* cpp_no_arg_token */
+#line 304 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5246 "src/parser_proc.c" /* glr.c:846 */
break;
- case 133: /* set_func ::= TO_OBJECT|TO_ARRAY|TO_STRING|TO_INT|TO_FLOAT|TO_BOOL|ZVAL|VOID LPAREN decl_var COMMA set_exps RPAREN */
-#line 850 "src/parser_proc.y"
-{
- yylhsminor.yy26 = psi_set_func_init(yymsp[-5].minor.yy0->type, yymsp[-5].minor.yy0->text, yymsp[-3].minor.yy11);
- yylhsminor.yy26->token = yymsp[-5].minor.yy0;
- yylhsminor.yy26->inner = yymsp[-1].minor.yy163;
-}
-#line 3081 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,66,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-5].minor.yy26 = yylhsminor.yy26;
+
+ case 157: /* cpp_name_arg_token */
+#line 304 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5252 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 158: /* cpp_exp_arg_token */
+#line 304 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5258 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 159: /* cpp_special_name_token */
+#line 304 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5264 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 160: /* cpp_macro_decl */
+#line 318 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_cpp_macro_decl_free(&(*(struct psi_cpp_macro_decl **)(&(*yyvaluep))));}
+#line 5270 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 161: /* cpp_macro_sig */
+#line 320 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5276 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 162: /* cpp_macro_sig_args */
+#line 320 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5282 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 163: /* cpp_macro_decl_tokens */
+#line 320 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5288 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 164: /* cpp_macro_decl_token_list */
+#line 320 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5294 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 165: /* cpp_macro_exp */
+#line 322 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_num_exp_free(&(*(struct psi_num_exp **)(&(*yyvaluep))));}
+#line 5300 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 166: /* cpp_macro_call_args */
+#line 320 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5306 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 167: /* cpp_macro_call_arg_list */
+#line 320 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5312 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 168: /* constant */
+#line 328 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_const_free(&(*(struct psi_const **)(&(*yyvaluep))));}
+#line 5318 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 169: /* constant_type */
+#line 330 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_const_type_free(&(*(struct psi_const_type **)(&(*yyvaluep))));}
+#line 5324 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 170: /* constant_type_token */
+#line 325 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5330 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 171: /* impl_def_val */
+#line 332 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_impl_def_val_free(&(*(struct psi_impl_def_val **)(&(*yyvaluep))));}
+#line 5336 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 172: /* impl_def_val_token */
+#line 325 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5342 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 173: /* decl_typedef */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5348 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 174: /* typedef */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5354 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 175: /* typedef_anon */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5360 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 176: /* typedef_decl */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5366 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 177: /* typedef_anon_decl */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5372 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 178: /* qualified_decl_type */
+#line 338 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_type_free(&(*(struct psi_decl_type **)(&(*yyvaluep))));}
+#line 5378 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 179: /* decl_type */
+#line 338 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_type_free(&(*(struct psi_decl_type **)(&(*yyvaluep))));}
+#line 5384 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 180: /* decl_type_complex */
+#line 338 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_type_free(&(*(struct psi_decl_type **)(&(*yyvaluep))));}
+#line 5390 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 181: /* decl_type_simple */
+#line 335 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5396 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 182: /* decl_real_type */
+#line 335 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5402 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 183: /* int_signed */
+#line 313 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5408 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 184: /* int_width */
+#line 310 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5414 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 185: /* decl_int_type */
+#line 335 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5420 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 186: /* int_signed_types */
+#line 310 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5426 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 187: /* signed_short_types */
+#line 313 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5432 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 188: /* signed_long_types */
+#line 313 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5438 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 189: /* int_width_types */
+#line 310 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5444 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 190: /* decl_stmt */
+#line 340 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_free(&(*(struct psi_decl **)(&(*yyvaluep))));}
+#line 5450 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 196: /* decl_vars */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5456 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 201: /* decl */
+#line 340 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_free(&(*(struct psi_decl **)(&(*yyvaluep))));}
+#line 5462 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 202: /* decl_body */
+#line 340 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_free(&(*(struct psi_decl **)(&(*yyvaluep))));}
+#line 5468 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 203: /* decl_func_body */
+#line 340 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_free(&(*(struct psi_decl **)(&(*yyvaluep))));}
+#line 5474 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 204: /* decl_functor_body */
+#line 340 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_free(&(*(struct psi_decl **)(&(*yyvaluep))));}
+#line 5480 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 205: /* decl_functor */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5486 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 206: /* decl_func */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5492 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 207: /* decl_args */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5498 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 208: /* decl_arg_list */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5504 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 209: /* decl_anon_arg */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5510 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 210: /* decl_arg */
+#line 342 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_arg_free(&(*(struct psi_decl_arg **)(&(*yyvaluep))));}
+#line 5516 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 211: /* decl_var */
+#line 344 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_var_free(&(*(struct psi_decl_var **)(&(*yyvaluep))));}
+#line 5522 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 212: /* decl_union */
+#line 348 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_union_free(&(*(struct psi_decl_union **)(&(*yyvaluep))));}
+#line 5528 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 213: /* decl_struct */
+#line 346 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_struct_free(&(*(struct psi_decl_struct **)(&(*yyvaluep))));}
+#line 5534 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 214: /* decl_struct_args */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5540 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 215: /* struct_args_block */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5546 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 216: /* struct_args */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5552 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 217: /* struct_arg_var_list */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5558 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 218: /* decl_vars_with_layout */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5564 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 219: /* decl_enum */
+#line 350 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_enum_free(&(*(struct psi_decl_enum **)(&(*yyvaluep))));}
+#line 5570 "src/parser_proc.c" /* glr.c:846 */
break;
- case 134: /* set_func ::= TO_OBJECT|TO_ARRAY|TO_STRING|TO_INT|TO_FLOAT|TO_BOOL|ZVAL|VOID LPAREN decl_var COMMA ELLIPSIS RPAREN */
-#line 855 "src/parser_proc.y"
+
+ case 220: /* decl_enum_items */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5576 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 221: /* decl_enum_item */
+#line 352 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_decl_enum_item_free(&(*(struct psi_decl_enum_item **)(&(*yyvaluep))));}
+#line 5582 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 222: /* num_exp */
+#line 410 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_num_exp_free(&(*(struct psi_num_exp **)(&(*yyvaluep))));}
+#line 5588 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 223: /* number */
+#line 412 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_number_free(&(*(struct psi_number **)(&(*yyvaluep))));}
+#line 5594 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 224: /* sizeof */
+#line 362 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_number_free(&(*(struct psi_number **)(&(*yyvaluep))));}
+#line 5600 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 225: /* sizeof_body */
+#line 362 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_number_free(&(*(struct psi_number **)(&(*yyvaluep))));}
+#line 5606 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 226: /* sizeof_body_notypes */
+#line 362 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_number_free(&(*(struct psi_number **)(&(*yyvaluep))));}
+#line 5612 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 227: /* enum_name */
+#line 301 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5618 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 228: /* union_name */
+#line 301 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5624 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 229: /* struct_name */
+#line 301 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5630 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 230: /* optional_name */
+#line 301 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5636 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 232: /* decl_layout */
+#line 359 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_layout_free(&(*(struct psi_layout **)(&(*yyvaluep))));}
+#line 5642 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 233: /* align_and_size */
+#line 357 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5648 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 234: /* array_size */
+#line 415 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5654 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 235: /* indirection */
+#line 415 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5660 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 236: /* pointers */
+#line 415 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5666 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 237: /* asterisks */
+#line 415 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5672 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 239: /* impl */
+#line 365 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_impl_free(&(*(struct psi_impl **)(&(*yyvaluep))));}
+#line 5678 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 240: /* impl_func */
+#line 367 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_impl_func_free(&(*(struct psi_impl_func **)(&(*yyvaluep))));}
+#line 5684 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 241: /* impl_args */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5690 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 242: /* impl_arg */
+#line 369 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_impl_arg_free(&(*(struct psi_impl_arg **)(&(*yyvaluep))));}
+#line 5696 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 243: /* impl_var */
+#line 373 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_impl_var_free(&(*(struct psi_impl_var **)(&(*yyvaluep))));}
+#line 5702 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 244: /* impl_type */
+#line 371 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_impl_type_free(&(*(struct psi_impl_type **)(&(*yyvaluep))));}
+#line 5708 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 245: /* impl_type_token */
+#line 405 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5714 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 246: /* impl_stmts */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5720 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 247: /* impl_stmt */
+#line 403 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_impl_stmt_free(&(*(struct psi_token ***)(&(*yyvaluep))));}
+#line 5726 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 248: /* let_stmt */
+#line 376 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_let_stmt_free(&(*(struct psi_let_stmt **)(&(*yyvaluep))));}
+#line 5732 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 249: /* let_exp */
+#line 378 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_let_exp_free(&(*(struct psi_let_exp **)(&(*yyvaluep))));}
+#line 5738 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 250: /* let_exp_byref */
+#line 378 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_let_exp_free(&(*(struct psi_let_exp **)(&(*yyvaluep))));}
+#line 5744 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 251: /* let_exp_assign */
+#line 378 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_let_exp_free(&(*(struct psi_let_exp **)(&(*yyvaluep))));}
+#line 5750 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 252: /* let_calloc */
+#line 380 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_let_calloc_free(&(*(struct psi_let_calloc **)(&(*yyvaluep))));}
+#line 5756 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 253: /* let_callback */
+#line 382 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_let_callback_free(&(*(struct psi_let_callback **)(&(*yyvaluep))));}
+#line 5762 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 254: /* let_func */
+#line 384 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_let_func_free(&(*(struct psi_let_func **)(&(*yyvaluep))));}
+#line 5768 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 255: /* let_func_token */
+#line 405 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5774 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 256: /* let_func_exps */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5780 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 257: /* let_exps */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5786 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 258: /* callback_rval */
+#line 405 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5792 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 259: /* callback_arg_list */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5798 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 260: /* callback_args */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5804 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 261: /* return_stmt */
+#line 394 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_return_stmt_free(&(*(struct psi_return_stmt **)(&(*yyvaluep))));}
+#line 5810 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 262: /* return_exp */
+#line 396 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_return_exp_free(&(*(struct psi_return_exp **)(&(*yyvaluep))));}
+#line 5816 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 263: /* call_decl_vars */
+#line 354 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5822 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 264: /* set_stmt */
+#line 386 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_set_stmt_free(&(*(struct psi_set_stmt **)(&(*yyvaluep))));}
+#line 5828 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 265: /* set_exp */
+#line 388 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_set_exp_free(&(*(struct psi_set_exp **)(&(*yyvaluep))));}
+#line 5834 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 266: /* set_func */
+#line 390 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_set_func_free(&(*(struct psi_set_func **)(&(*yyvaluep))));}
+#line 5840 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 267: /* set_func_token */
+#line 405 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5846 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 268: /* set_func_exps */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5852 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 269: /* set_exps */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5858 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 270: /* assert_stmt */
+#line 392 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_assert_stmt_free(&(*(struct psi_assert_stmt **)(&(*yyvaluep))));}
+#line 5864 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 271: /* assert_stmt_token */
+#line 405 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_token_free(&(*(struct psi_token **)(&(*yyvaluep))));}
+#line 5870 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 272: /* free_stmt */
+#line 398 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_free_stmt_free(&(*(struct psi_free_stmt **)(&(*yyvaluep))));}
+#line 5876 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 273: /* free_exps */
+#line 407 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_plist_free((*(struct psi_plist **)(&(*yyvaluep))));}
+#line 5882 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 274: /* free_exp */
+#line 400 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {psi_free_exp_free(&(*(struct psi_free_exp **)(&(*yyvaluep))));}
+#line 5888 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+ case 275: /* reference */
+#line 417 "src/parser_proc_grammar.y" /* glr.c:846 */
+ {}
+#line 5894 "src/parser_proc.c" /* glr.c:846 */
+ break;
+
+
+ default:
+ break;
+ }
+ YY_IGNORE_MAYBE_UNINITIALIZED_END
+}
+
+/** Number of symbols composing the right hand side of rule #RULE. */
+static inline int
+yyrhsLength (yyRuleNum yyrule)
{
- yylhsminor.yy26 = psi_set_func_init(yymsp[-5].minor.yy0->type, yymsp[-5].minor.yy0->text, yymsp[-3].minor.yy11);
- yylhsminor.yy26->token = yymsp[-5].minor.yy0;
- yylhsminor.yy26->recursive = 1;
+ return yyr2[yyrule];
}
-#line 3094 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-4].minor);
- yy_destructor(yypParser,66,&yymsp[-2].minor);
- yy_destructor(yypParser,76,&yymsp[-1].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-5].minor.yy26 = yylhsminor.yy26;
- break;
- case 135: /* set_exp ::= set_func */
-#line 860 "src/parser_proc.y"
+
+static void
+yydestroyGLRState (char const *yymsg, yyGLRState *yys, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ if (yys->yyresolved)
+ yydestruct (yymsg, yystos[yys->yylrState],
+ &yys->yysemantics.yysval, P, tokens, index);
+ else
+ {
+#if YYDEBUG
+ if (yydebug)
+ {
+ if (yys->yysemantics.yyfirstVal)
+ YYFPRINTF (stderr, "%s unresolved", yymsg);
+ else
+ YYFPRINTF (stderr, "%s incomplete", yymsg);
+ YY_SYMBOL_PRINT ("", yystos[yys->yylrState], YY_NULLPTR, &yys->yyloc);
+ }
+#endif
+
+ if (yys->yysemantics.yyfirstVal)
+ {
+ yySemanticOption *yyoption = yys->yysemantics.yyfirstVal;
+ yyGLRState *yyrh;
+ int yyn;
+ for (yyrh = yyoption->yystate, yyn = yyrhsLength (yyoption->yyrule);
+ yyn > 0;
+ yyrh = yyrh->yypred, yyn -= 1)
+ yydestroyGLRState (yymsg, yyrh, P, tokens, index);
+ }
+ }
+}
+
+/** Left-hand-side symbol for rule #YYRULE. */
+static inline yySymbol
+yylhsNonterm (yyRuleNum yyrule)
{
- yylhsminor.yy147 = psi_set_exp_init(PSI_SET_FUNC, yymsp[0].minor.yy26);
+ return yyr1[yyrule];
}
-#line 3106 "src/parser_proc.c"
- yymsp[0].minor.yy147 = yylhsminor.yy147;
- break;
- case 136: /* set_exp ::= num_exp */
-#line 863 "src/parser_proc.y"
+
+#define yypact_value_is_default(Yystate) \
+ (!!((Yystate) == (-699)))
+
+/** True iff LR state YYSTATE has only a default reduction (regardless
+ * of token). */
+static inline yybool
+yyisDefaultedState (yyStateNum yystate)
{
- yylhsminor.yy147 = psi_set_exp_init(PSI_SET_NUMEXP, yymsp[0].minor.yy259);
+ return yypact_value_is_default (yypact[yystate]);
}
-#line 3114 "src/parser_proc.c"
- yymsp[0].minor.yy147 = yylhsminor.yy147;
- break;
- case 137: /* set_exps ::= set_exp */
-#line 866 "src/parser_proc.y"
+
+/** The default reduction for YYSTATE, assuming it has one. */
+static inline yyRuleNum
+yydefaultAction (yyStateNum yystate)
{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_set_exp_free),
- &yymsp[0].minor.yy147);
+ return yydefact[yystate];
}
-#line 3123 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 138: /* set_exps ::= set_exps COMMA set_exp */
-#line 870 "src/parser_proc.y"
+
+#define yytable_value_is_error(Yytable_value) \
+ 0
+
+/** Set *YYACTION to the action to take in YYSTATE on seeing YYTOKEN.
+ * Result R means
+ * R < 0: Reduce on rule -R.
+ * R = 0: Error.
+ * R > 0: Shift to state R.
+ * Set *YYCONFLICTS to a pointer into yyconfl to a 0-terminated list
+ * of conflicting reductions.
+ */
+static inline void
+yygetLRActions (yyStateNum yystate, int yytoken,
+ int* yyaction, const short int** yyconflicts)
+{
+ int yyindex = yypact[yystate] + yytoken;
+ if (yypact_value_is_default (yypact[yystate])
+ || yyindex < 0 || YYLAST < yyindex || yycheck[yyindex] != yytoken)
+ {
+ *yyaction = -yydefact[yystate];
+ *yyconflicts = yyconfl;
+ }
+ else if (! yytable_value_is_error (yytable[yyindex]))
+ {
+ *yyaction = yytable[yyindex];
+ *yyconflicts = yyconfl + yyconflp[yyindex];
+ }
+ else
+ {
+ *yyaction = 0;
+ *yyconflicts = yyconfl + yyconflp[yyindex];
+ }
+}
+
+/** Compute post-reduction state.
+ * \param yystate the current state
+ * \param yysym the nonterminal to push on the stack
+ */
+static inline yyStateNum
+yyLRgotoState (yyStateNum yystate, yySymbol yysym)
+{
+ int yyr = yypgoto[yysym - YYNTOKENS] + yystate;
+ if (0 <= yyr && yyr <= YYLAST && yycheck[yyr] == yystate)
+ return yytable[yyr];
+ else
+ return yydefgoto[yysym - YYNTOKENS];
+}
+
+static inline yybool
+yyisShiftAction (int yyaction)
{
- yylhsminor.yy163 = psi_plist_add(yymsp[-2].minor.yy163, &yymsp[0].minor.yy147);
+ return 0 < yyaction;
}
-#line 3131 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy163 = yylhsminor.yy163;
- break;
- case 139: /* set_exp ::= impl_var EQUALS set_exp */
-#line 873 "src/parser_proc.y"
+
+static inline yybool
+yyisErrorAction (int yyaction)
{
- yylhsminor.yy147 = yymsp[0].minor.yy147;
- yylhsminor.yy147->var = yymsp[-2].minor.yy37;
+ return yyaction == 0;
}
-#line 3141 "src/parser_proc.c"
- yy_destructor(yypParser,73,&yymsp[-1].minor);
- yymsp[-2].minor.yy147 = yylhsminor.yy147;
- break;
- case 140: /* set_stmt ::= SET set_exp EOS */
-#line 877 "src/parser_proc.y"
+
+ /* GLRStates */
+
+/** Return a fresh GLRStackItem in YYSTACKP. The item is an LR state
+ * if YYISSTATE, and otherwise a semantic option. Callers should call
+ * YY_RESERVE_GLRSTACK afterwards to make sure there is sufficient
+ * headroom. */
+
+static inline yyGLRStackItem*
+yynewGLRStackItem (yyGLRStack* yystackp, yybool yyisState)
{
- yylhsminor.yy98 = psi_set_stmt_init(yymsp[-1].minor.yy147);
- yylhsminor.yy98->token = yymsp[-2].minor.yy0;
+ yyGLRStackItem* yynewItem = yystackp->yynextFree;
+ yystackp->yyspaceLeft -= 1;
+ yystackp->yynextFree += 1;
+ yynewItem->yystate.yyisState = yyisState;
+ return yynewItem;
}
-#line 3151 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-2].minor.yy98 = yylhsminor.yy98;
- break;
- case 141: /* return_stmt ::= RETURN set_func EOS */
-#line 881 "src/parser_proc.y"
+
+/** Add a new semantic action that will execute the action for rule
+ * YYRULE on the semantic values in YYRHS to the list of
+ * alternative actions for YYSTATE. Assumes that YYRHS comes from
+ * stack #YYK of *YYSTACKP. */
+static void
+yyaddDeferredAction (yyGLRStack* yystackp, size_t yyk, yyGLRState* yystate,
+ yyGLRState* yyrhs, yyRuleNum yyrule)
+{
+ yySemanticOption* yynewOption =
+ &yynewGLRStackItem (yystackp, yyfalse)->yyoption;
+ YYASSERT (!yynewOption->yyisState);
+ yynewOption->yystate = yyrhs;
+ yynewOption->yyrule = yyrule;
+ if (yystackp->yytops.yylookaheadNeeds[yyk])
+ {
+ yynewOption->yyrawchar = yychar;
+ yynewOption->yyval = yylval;
+ }
+ else
+ yynewOption->yyrawchar = YYEMPTY;
+ yynewOption->yynext = yystate->yysemantics.yyfirstVal;
+ yystate->yysemantics.yyfirstVal = yynewOption;
+
+ YY_RESERVE_GLRSTACK (yystackp);
+}
+
+ /* GLRStacks */
+
+/** Initialize YYSET to a singleton set containing an empty stack. */
+static yybool
+yyinitStateSet (yyGLRStateSet* yyset)
+{
+ yyset->yysize = 1;
+ yyset->yycapacity = 16;
+ yyset->yystates = (yyGLRState**) YYMALLOC (16 * sizeof yyset->yystates[0]);
+ if (! yyset->yystates)
+ return yyfalse;
+ yyset->yystates[0] = YY_NULLPTR;
+ yyset->yylookaheadNeeds =
+ (yybool*) YYMALLOC (16 * sizeof yyset->yylookaheadNeeds[0]);
+ if (! yyset->yylookaheadNeeds)
+ {
+ YYFREE (yyset->yystates);
+ return yyfalse;
+ }
+ return yytrue;
+}
+
+static void yyfreeStateSet (yyGLRStateSet* yyset)
{
- yylhsminor.yy90 = psi_return_stmt_init(psi_set_exp_init(PSI_SET_FUNC, yymsp[-1].minor.yy26));
- yylhsminor.yy90->token = yymsp[-2].minor.yy0;
+ YYFREE (yyset->yystates);
+ YYFREE (yyset->yylookaheadNeeds);
}
-#line 3161 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-2].minor.yy90 = yylhsminor.yy90;
- break;
- case 142: /* free_stmt ::= FREE free_exps EOS */
-#line 885 "src/parser_proc.y"
-{
- yylhsminor.yy192 = psi_free_stmt_init(yymsp[-1].minor.yy163);
- yylhsminor.yy192->token = yymsp[-2].minor.yy0;
+
+/** Initialize *YYSTACKP to a single empty stack, with total maximum
+ * capacity for all stacks of YYSIZE. */
+static yybool
+yyinitGLRStack (yyGLRStack* yystackp, size_t yysize)
+{
+ yystackp->yyerrState = 0;
+ yynerrs = 0;
+ yystackp->yyspaceLeft = yysize;
+ yystackp->yyitems =
+ (yyGLRStackItem*) YYMALLOC (yysize * sizeof yystackp->yynextFree[0]);
+ if (!yystackp->yyitems)
+ return yyfalse;
+ yystackp->yynextFree = yystackp->yyitems;
+ yystackp->yysplitPoint = YY_NULLPTR;
+ yystackp->yylastDeleted = YY_NULLPTR;
+ return yyinitStateSet (&yystackp->yytops);
}
-#line 3171 "src/parser_proc.c"
- yy_destructor(yypParser,63,&yymsp[0].minor);
- yymsp[-2].minor.yy192 = yylhsminor.yy192;
- break;
- case 143: /* free_exps ::= free_exp */
-#line 889 "src/parser_proc.y"
-{
- yylhsminor.yy163 = psi_plist_add(psi_plist_init((psi_plist_dtor) psi_free_exp_free),
- &yymsp[0].minor.yy94);
+
+
+#if YYSTACKEXPANDABLE
+# define YYRELOC(YYFROMITEMS,YYTOITEMS,YYX,YYTYPE) \
+ &((YYTOITEMS) - ((YYFROMITEMS) - (yyGLRStackItem*) (YYX)))->YYTYPE
+
+/** If *YYSTACKP is expandable, extend it. WARNING: Pointers into the
+ stack from outside should be considered invalid after this call.
+ We always expand when there are 1 or fewer items left AFTER an
+ allocation, so that we can avoid having external pointers exist
+ across an allocation. */
+static void
+yyexpandGLRStack (yyGLRStack* yystackp)
+{
+ yyGLRStackItem* yynewItems;
+ yyGLRStackItem* yyp0, *yyp1;
+ size_t yynewSize;
+ size_t yyn;
+ size_t yysize = yystackp->yynextFree - yystackp->yyitems;
+ if (YYMAXDEPTH - YYHEADROOM < yysize)
+ yyMemoryExhausted (yystackp);
+ yynewSize = 2*yysize;
+ if (YYMAXDEPTH < yynewSize)
+ yynewSize = YYMAXDEPTH;
+ yynewItems = (yyGLRStackItem*) YYMALLOC (yynewSize * sizeof yynewItems[0]);
+ if (! yynewItems)
+ yyMemoryExhausted (yystackp);
+ for (yyp0 = yystackp->yyitems, yyp1 = yynewItems, yyn = yysize;
+ 0 < yyn;
+ yyn -= 1, yyp0 += 1, yyp1 += 1)
+ {
+ *yyp1 = *yyp0;
+ if (*(yybool *) yyp0)
+ {
+ yyGLRState* yys0 = &yyp0->yystate;
+ yyGLRState* yys1 = &yyp1->yystate;
+ if (yys0->yypred != YY_NULLPTR)
+ yys1->yypred =
+ YYRELOC (yyp0, yyp1, yys0->yypred, yystate);
+ if (! yys0->yyresolved && yys0->yysemantics.yyfirstVal != YY_NULLPTR)
+ yys1->yysemantics.yyfirstVal =
+ YYRELOC (yyp0, yyp1, yys0->yysemantics.yyfirstVal, yyoption);
+ }
+ else
+ {
+ yySemanticOption* yyv0 = &yyp0->yyoption;
+ yySemanticOption* yyv1 = &yyp1->yyoption;
+ if (yyv0->yystate != YY_NULLPTR)
+ yyv1->yystate = YYRELOC (yyp0, yyp1, yyv0->yystate, yystate);
+ if (yyv0->yynext != YY_NULLPTR)
+ yyv1->yynext = YYRELOC (yyp0, yyp1, yyv0->yynext, yyoption);
+ }
+ }
+ if (yystackp->yysplitPoint != YY_NULLPTR)
+ yystackp->yysplitPoint = YYRELOC (yystackp->yyitems, yynewItems,
+ yystackp->yysplitPoint, yystate);
+
+ for (yyn = 0; yyn < yystackp->yytops.yysize; yyn += 1)
+ if (yystackp->yytops.yystates[yyn] != YY_NULLPTR)
+ yystackp->yytops.yystates[yyn] =
+ YYRELOC (yystackp->yyitems, yynewItems,
+ yystackp->yytops.yystates[yyn], yystate);
+ YYFREE (yystackp->yyitems);
+ yystackp->yyitems = yynewItems;
+ yystackp->yynextFree = yynewItems + yysize;
+ yystackp->yyspaceLeft = yynewSize - yysize;
}
-#line 3181 "src/parser_proc.c"
- yymsp[0].minor.yy163 = yylhsminor.yy163;
- break;
- case 144: /* free_exps ::= free_exps COMMA free_exp */
-#line 893 "src/parser_proc.y"
+#endif
+
+static void
+yyfreeGLRStack (yyGLRStack* yystackp)
{
- yylhsminor.yy163 = psi_plist_add(yymsp[-2].minor.yy163, &yymsp[0].minor.yy94);
+ YYFREE (yystackp->yyitems);
+ yyfreeStateSet (&yystackp->yytops);
}
-#line 3189 "src/parser_proc.c"
- yy_destructor(yypParser,66,&yymsp[-1].minor);
- yymsp[-2].minor.yy163 = yylhsminor.yy163;
- break;
- case 145: /* free_exp ::= NAME LPAREN decl_vars RPAREN */
-#line 896 "src/parser_proc.y"
+
+/** Assuming that YYS is a GLRState somewhere on *YYSTACKP, update the
+ * splitpoint of *YYSTACKP, if needed, so that it is at least as deep as
+ * YYS. */
+static inline void
+yyupdateSplit (yyGLRStack* yystackp, yyGLRState* yys)
{
- yylhsminor.yy94 = psi_free_exp_init(yymsp[-3].minor.yy0->text, yymsp[-1].minor.yy163);
- yylhsminor.yy94->token = yymsp[-3].minor.yy0;
+ if (yystackp->yysplitPoint != YY_NULLPTR && yystackp->yysplitPoint > yys)
+ yystackp->yysplitPoint = yys;
}
-#line 3199 "src/parser_proc.c"
- yy_destructor(yypParser,65,&yymsp[-2].minor);
- yy_destructor(yypParser,67,&yymsp[0].minor);
- yymsp[-3].minor.yy94 = yylhsminor.yy94;
- break;
- case 146: /* reference ::= */
-#line 900 "src/parser_proc.y"
+
+/** Invalidate stack #YYK in *YYSTACKP. */
+static inline void
+yymarkStackDeleted (yyGLRStack* yystackp, size_t yyk)
{
- yymsp[1].minor.yy121 = false;
+ if (yystackp->yytops.yystates[yyk] != YY_NULLPTR)
+ yystackp->yylastDeleted = yystackp->yytops.yystates[yyk];
+ yystackp->yytops.yystates[yyk] = YY_NULLPTR;
}
-#line 3209 "src/parser_proc.c"
- break;
- case 147: /* reference ::= AMPERSAND */
-{ yy_destructor(yypParser,23,&yymsp[0].minor);
-#line 903 "src/parser_proc.y"
+
+/** Undelete the last stack in *YYSTACKP that was marked as deleted. Can
+ only be done once after a deletion, and only when all other stacks have
+ been deleted. */
+static void
+yyundeleteLastStack (yyGLRStack* yystackp)
{
- yymsp[0].minor.yy121 = true;
+ if (yystackp->yylastDeleted == YY_NULLPTR || yystackp->yytops.yysize != 0)
+ return;
+ yystackp->yytops.yystates[0] = yystackp->yylastDeleted;
+ yystackp->yytops.yysize = 1;
+ YYDPRINTF ((stderr, "Restoring last deleted stack as stack #0.\n"));
+ yystackp->yylastDeleted = YY_NULLPTR;
}
-#line 3217 "src/parser_proc.c"
+
+static inline void
+yyremoveDeletes (yyGLRStack* yystackp)
+{
+ size_t yyi, yyj;
+ yyi = yyj = 0;
+ while (yyj < yystackp->yytops.yysize)
+ {
+ if (yystackp->yytops.yystates[yyi] == YY_NULLPTR)
+ {
+ if (yyi == yyj)
+ {
+ YYDPRINTF ((stderr, "Removing dead stacks.\n"));
+ }
+ yystackp->yytops.yysize -= 1;
+ }
+ else
+ {
+ yystackp->yytops.yystates[yyj] = yystackp->yytops.yystates[yyi];
+ /* In the current implementation, it's unnecessary to copy
+ yystackp->yytops.yylookaheadNeeds[yyi] since, after
+ yyremoveDeletes returns, the parser immediately either enters
+ deterministic operation or shifts a token. However, it doesn't
+ hurt, and the code might evolve to need it. */
+ yystackp->yytops.yylookaheadNeeds[yyj] =
+ yystackp->yytops.yylookaheadNeeds[yyi];
+ if (yyj != yyi)
+ {
+ YYDPRINTF ((stderr, "Rename stack %lu -> %lu.\n",
+ (unsigned long int) yyi, (unsigned long int) yyj));
+ }
+ yyj += 1;
+ }
+ yyi += 1;
+ }
}
- break;
- case 148: /* indirection ::= */
-#line 906 "src/parser_proc.y"
-{
- yymsp[1].minor.yy202 = 0;
+
+/** Shift to a new state on stack #YYK of *YYSTACKP, corresponding to LR
+ * state YYLRSTATE, at input position YYPOSN, with (resolved) semantic
+ * value *YYVALP and source location *YYLOCP. */
+static inline void
+yyglrShift (yyGLRStack* yystackp, size_t yyk, yyStateNum yylrState,
+ size_t yyposn,
+ YYSTYPE* yyvalp)
+{
+ yyGLRState* yynewState = &yynewGLRStackItem (yystackp, yytrue)->yystate;
+
+ yynewState->yylrState = yylrState;
+ yynewState->yyposn = yyposn;
+ yynewState->yyresolved = yytrue;
+ yynewState->yypred = yystackp->yytops.yystates[yyk];
+ yynewState->yysemantics.yysval = *yyvalp;
+ yystackp->yytops.yystates[yyk] = yynewState;
+
+ YY_RESERVE_GLRSTACK (yystackp);
}
-#line 3225 "src/parser_proc.c"
- break;
- case 149: /* indirection ::= pointers */
-#line 909 "src/parser_proc.y"
-{
- yylhsminor.yy202 = yymsp[0].minor.yy202;
+
+/** Shift stack #YYK of *YYSTACKP, to a new state corresponding to LR
+ * state YYLRSTATE, at input position YYPOSN, with the (unresolved)
+ * semantic value of YYRHS under the action for YYRULE. */
+static inline void
+yyglrShiftDefer (yyGLRStack* yystackp, size_t yyk, yyStateNum yylrState,
+ size_t yyposn, yyGLRState* yyrhs, yyRuleNum yyrule)
+{
+ yyGLRState* yynewState = &yynewGLRStackItem (yystackp, yytrue)->yystate;
+ YYASSERT (yynewState->yyisState);
+
+ yynewState->yylrState = yylrState;
+ yynewState->yyposn = yyposn;
+ yynewState->yyresolved = yyfalse;
+ yynewState->yypred = yystackp->yytops.yystates[yyk];
+ yynewState->yysemantics.yyfirstVal = YY_NULLPTR;
+ yystackp->yytops.yystates[yyk] = yynewState;
+
+ /* Invokes YY_RESERVE_GLRSTACK. */
+ yyaddDeferredAction (yystackp, yyk, yynewState, yyrhs, yyrule);
}
-#line 3232 "src/parser_proc.c"
- yymsp[0].minor.yy202 = yylhsminor.yy202;
- break;
- case 150: /* pointers ::= ASTERISK */
-{ yy_destructor(yypParser,28,&yymsp[0].minor);
-#line 912 "src/parser_proc.y"
-{
- yymsp[0].minor.yy202 = 1;
+
+#if !YYDEBUG
+# define YY_REDUCE_PRINT(Args)
+#else
+# define YY_REDUCE_PRINT(Args) \
+do { \
+ if (yydebug) \
+ yy_reduce_print Args; \
+} while (0)
+
+/*----------------------------------------------------------------------.
+| Report that stack #YYK of *YYSTACKP is going to be reduced by YYRULE. |
+`----------------------------------------------------------------------*/
+
+static inline void
+yy_reduce_print (int yynormal, yyGLRStackItem* yyvsp, size_t yyk,
+ yyRuleNum yyrule, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ int yynrhs = yyrhsLength (yyrule);
+ int yyi;
+ YYFPRINTF (stderr, "Reducing stack %lu by rule %d (line %lu):\n",
+ (unsigned long int) yyk, yyrule - 1,
+ (unsigned long int) yyrline[yyrule]);
+ if (! yynormal)
+ yyfillin (yyvsp, 1, -yynrhs);
+ /* The symbols being reduced. */
+ for (yyi = 0; yyi < yynrhs; yyi++)
+ {
+ YYFPRINTF (stderr, " $%d = ", yyi + 1);
+ yy_symbol_print (stderr,
+ yystos[yyvsp[yyi - yynrhs + 1].yystate.yylrState],
+ &yyvsp[yyi - yynrhs + 1].yystate.yysemantics.yysval
+ , P, tokens, index);
+ if (!yyvsp[yyi - yynrhs + 1].yystate.yyresolved)
+ YYFPRINTF (stderr, " (unresolved)");
+ YYFPRINTF (stderr, "\n");
+ }
}
-#line 3241 "src/parser_proc.c"
+#endif
+
+/** Pop the symbols consumed by reduction #YYRULE from the top of stack
+ * #YYK of *YYSTACKP, and perform the appropriate semantic action on their
+ * semantic values. Assumes that all ambiguities in semantic values
+ * have been previously resolved. Set *YYVALP to the resulting value,
+ * and *YYLOCP to the computed location (if any). Return value is as
+ * for userAction. */
+static inline YYRESULTTAG
+yydoAction (yyGLRStack* yystackp, size_t yyk, yyRuleNum yyrule,
+ YYSTYPE* yyvalp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ int yynrhs = yyrhsLength (yyrule);
+
+ if (yystackp->yysplitPoint == YY_NULLPTR)
+ {
+ /* Standard special case: single stack. */
+ yyGLRStackItem* yyrhs = (yyGLRStackItem*) yystackp->yytops.yystates[yyk];
+ YYASSERT (yyk == 0);
+ yystackp->yynextFree -= yynrhs;
+ yystackp->yyspaceLeft += yynrhs;
+ yystackp->yytops.yystates[0] = & yystackp->yynextFree[-1].yystate;
+ YY_REDUCE_PRINT ((1, yyrhs, yyk, yyrule, P, tokens, index));
+ return yyuserAction (yyrule, yynrhs, yyrhs, yystackp,
+ yyvalp, P, tokens, index);
+ }
+ else
+ {
+ int yyi;
+ yyGLRState* yys;
+ yyGLRStackItem yyrhsVals[YYMAXRHS + YYMAXLEFT + 1];
+ yys = yyrhsVals[YYMAXRHS + YYMAXLEFT].yystate.yypred
+ = yystackp->yytops.yystates[yyk];
+ for (yyi = 0; yyi < yynrhs; yyi += 1)
+ {
+ yys = yys->yypred;
+ YYASSERT (yys);
+ }
+ yyupdateSplit (yystackp, yys);
+ yystackp->yytops.yystates[yyk] = yys;
+ YY_REDUCE_PRINT ((0, yyrhsVals + YYMAXRHS + YYMAXLEFT - 1, yyk, yyrule, P, tokens, index));
+ return yyuserAction (yyrule, yynrhs, yyrhsVals + YYMAXRHS + YYMAXLEFT - 1,
+ yystackp, yyvalp, P, tokens, index);
+ }
}
- break;
- case 151: /* pointers ::= pointers ASTERISK */
-#line 915 "src/parser_proc.y"
-{
- yylhsminor.yy202 = yymsp[-1].minor.yy202+1;
+
+/** Pop items off stack #YYK of *YYSTACKP according to grammar rule YYRULE,
+ * and push back on the resulting nonterminal symbol. Perform the
+ * semantic action associated with YYRULE and store its value with the
+ * newly pushed state, if YYFORCEEVAL or if *YYSTACKP is currently
+ * unambiguous. Otherwise, store the deferred semantic action with
+ * the new state. If the new state would have an identical input
+ * position, LR state, and predecessor to an existing state on the stack,
+ * it is identified with that existing state, eliminating stack #YYK from
+ * *YYSTACKP. In this case, the semantic value is
+ * added to the options for the existing state's semantic value.
+ */
+static inline YYRESULTTAG
+yyglrReduce (yyGLRStack* yystackp, size_t yyk, yyRuleNum yyrule,
+ yybool yyforceEval, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ size_t yyposn = yystackp->yytops.yystates[yyk]->yyposn;
+
+ if (yyforceEval || yystackp->yysplitPoint == YY_NULLPTR)
+ {
+ YYSTYPE yysval;
+
+ YYRESULTTAG yyflag = yydoAction (yystackp, yyk, yyrule, &yysval, P, tokens, index);
+ if (yyflag == yyerr && yystackp->yysplitPoint != YY_NULLPTR)
+ {
+ YYDPRINTF ((stderr, "Parse on stack %lu rejected by rule #%d.\n",
+ (unsigned long int) yyk, yyrule - 1));
+ }
+ if (yyflag != yyok)
+ return yyflag;
+ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyrule], &yysval, &yyloc);
+ yyglrShift (yystackp, yyk,
+ yyLRgotoState (yystackp->yytops.yystates[yyk]->yylrState,
+ yylhsNonterm (yyrule)),
+ yyposn, &yysval);
+ }
+ else
+ {
+ size_t yyi;
+ int yyn;
+ yyGLRState* yys, *yys0 = yystackp->yytops.yystates[yyk];
+ yyStateNum yynewLRState;
+
+ for (yys = yystackp->yytops.yystates[yyk], yyn = yyrhsLength (yyrule);
+ 0 < yyn; yyn -= 1)
+ {
+ yys = yys->yypred;
+ YYASSERT (yys);
+ }
+ yyupdateSplit (yystackp, yys);
+ yynewLRState = yyLRgotoState (yys->yylrState, yylhsNonterm (yyrule));
+ YYDPRINTF ((stderr,
+ "Reduced stack %lu by rule #%d; action deferred. "
+ "Now in state %d.\n",
+ (unsigned long int) yyk, yyrule - 1, yynewLRState));
+ for (yyi = 0; yyi < yystackp->yytops.yysize; yyi += 1)
+ if (yyi != yyk && yystackp->yytops.yystates[yyi] != YY_NULLPTR)
+ {
+ yyGLRState *yysplit = yystackp->yysplitPoint;
+ yyGLRState *yyp = yystackp->yytops.yystates[yyi];
+ while (yyp != yys && yyp != yysplit && yyp->yyposn >= yyposn)
+ {
+ if (yyp->yylrState == yynewLRState && yyp->yypred == yys)
+ {
+ yyaddDeferredAction (yystackp, yyk, yyp, yys0, yyrule);
+ yymarkStackDeleted (yystackp, yyk);
+ YYDPRINTF ((stderr, "Merging stack %lu into stack %lu.\n",
+ (unsigned long int) yyk,
+ (unsigned long int) yyi));
+ return yyok;
+ }
+ yyp = yyp->yypred;
+ }
+ }
+ yystackp->yytops.yystates[yyk] = yys;
+ yyglrShiftDefer (yystackp, yyk, yynewLRState, yyposn, yys0, yyrule);
+ }
+ return yyok;
}
-#line 3249 "src/parser_proc.c"
- yy_destructor(yypParser,28,&yymsp[0].minor);
- yymsp[-1].minor.yy202 = yylhsminor.yy202;
- break;
- case 152: /* file ::= blocks */
-{ yy_destructor(yypParser,146,&yymsp[0].minor);
-#line 169 "src/parser_proc.y"
+
+static size_t
+yysplitStack (yyGLRStack* yystackp, size_t yyk)
{
+ if (yystackp->yysplitPoint == YY_NULLPTR)
+ {
+ YYASSERT (yyk == 0);
+ yystackp->yysplitPoint = yystackp->yytops.yystates[yyk];
+ }
+ if (yystackp->yytops.yysize >= yystackp->yytops.yycapacity)
+ {
+ yyGLRState** yynewStates;
+ yybool* yynewLookaheadNeeds;
+
+ yynewStates = YY_NULLPTR;
+
+ if (yystackp->yytops.yycapacity
+ > (YYSIZEMAX / (2 * sizeof yynewStates[0])))
+ yyMemoryExhausted (yystackp);
+ yystackp->yytops.yycapacity *= 2;
+
+ yynewStates =
+ (yyGLRState**) YYREALLOC (yystackp->yytops.yystates,
+ (yystackp->yytops.yycapacity
+ * sizeof yynewStates[0]));
+ if (yynewStates == YY_NULLPTR)
+ yyMemoryExhausted (yystackp);
+ yystackp->yytops.yystates = yynewStates;
+
+ yynewLookaheadNeeds =
+ (yybool*) YYREALLOC (yystackp->yytops.yylookaheadNeeds,
+ (yystackp->yytops.yycapacity
+ * sizeof yynewLookaheadNeeds[0]));
+ if (yynewLookaheadNeeds == YY_NULLPTR)
+ yyMemoryExhausted (yystackp);
+ yystackp->yytops.yylookaheadNeeds = yynewLookaheadNeeds;
+ }
+ yystackp->yytops.yystates[yystackp->yytops.yysize]
+ = yystackp->yytops.yystates[yyk];
+ yystackp->yytops.yylookaheadNeeds[yystackp->yytops.yysize]
+ = yystackp->yytops.yylookaheadNeeds[yyk];
+ yystackp->yytops.yysize += 1;
+ return yystackp->yytops.yysize-1;
}
-#line 3258 "src/parser_proc.c"
+
+/** True iff YYY0 and YYY1 represent identical options at the top level.
+ * That is, they represent the same rule applied to RHS symbols
+ * that produce the same terminal symbols. */
+static yybool
+yyidenticalOptions (yySemanticOption* yyy0, yySemanticOption* yyy1)
+{
+ if (yyy0->yyrule == yyy1->yyrule)
+ {
+ yyGLRState *yys0, *yys1;
+ int yyn;
+ for (yys0 = yyy0->yystate, yys1 = yyy1->yystate,
+ yyn = yyrhsLength (yyy0->yyrule);
+ yyn > 0;
+ yys0 = yys0->yypred, yys1 = yys1->yypred, yyn -= 1)
+ if (yys0->yyposn != yys1->yyposn)
+ return yyfalse;
+ return yytrue;
+ }
+ else
+ return yyfalse;
}
- break;
- case 153: /* blocks ::= block */
-{ yy_destructor(yypParser,147,&yymsp[0].minor);
-#line 170 "src/parser_proc.y"
-{
+
+/** Assuming identicalOptions (YYY0,YYY1), destructively merge the
+ * alternative semantic values for the RHS-symbols of YYY1 and YYY0. */
+static void
+yymergeOptionSets (yySemanticOption* yyy0, yySemanticOption* yyy1)
+{
+ yyGLRState *yys0, *yys1;
+ int yyn;
+ for (yys0 = yyy0->yystate, yys1 = yyy1->yystate,
+ yyn = yyrhsLength (yyy0->yyrule);
+ yyn > 0;
+ yys0 = yys0->yypred, yys1 = yys1->yypred, yyn -= 1)
+ {
+ if (yys0 == yys1)
+ break;
+ else if (yys0->yyresolved)
+ {
+ yys1->yyresolved = yytrue;
+ yys1->yysemantics.yysval = yys0->yysemantics.yysval;
+ }
+ else if (yys1->yyresolved)
+ {
+ yys0->yyresolved = yytrue;
+ yys0->yysemantics.yysval = yys1->yysemantics.yysval;
+ }
+ else
+ {
+ yySemanticOption** yyz0p = &yys0->yysemantics.yyfirstVal;
+ yySemanticOption* yyz1 = yys1->yysemantics.yyfirstVal;
+ while (yytrue)
+ {
+ if (yyz1 == *yyz0p || yyz1 == YY_NULLPTR)
+ break;
+ else if (*yyz0p == YY_NULLPTR)
+ {
+ *yyz0p = yyz1;
+ break;
+ }
+ else if (*yyz0p < yyz1)
+ {
+ yySemanticOption* yyz = *yyz0p;
+ *yyz0p = yyz1;
+ yyz1 = yyz1->yynext;
+ (*yyz0p)->yynext = yyz;
+ }
+ yyz0p = &(*yyz0p)->yynext;
+ }
+ yys1->yysemantics.yyfirstVal = yys0->yysemantics.yyfirstVal;
+ }
+ }
}
-#line 3266 "src/parser_proc.c"
+
+/** Y0 and Y1 represent two possible actions to take in a given
+ * parsing state; return 0 if no combination is possible,
+ * 1 if user-mergeable, 2 if Y0 is preferred, 3 if Y1 is preferred. */
+static int
+yypreference (yySemanticOption* y0, yySemanticOption* y1)
+{
+ yyRuleNum r0 = y0->yyrule, r1 = y1->yyrule;
+ int p0 = yydprec[r0], p1 = yydprec[r1];
+
+ if (p0 == p1)
+ {
+ if (yymerger[r0] == 0 || yymerger[r0] != yymerger[r1])
+ return 0;
+ else
+ return 1;
+ }
+ if (p0 == 0 || p1 == 0)
+ return 0;
+ if (p0 < p1)
+ return 3;
+ if (p1 < p0)
+ return 2;
+ return 0;
}
- break;
- case 154: /* blocks ::= blocks block */
-{ yy_destructor(yypParser,146,&yymsp[-1].minor);
-#line 171 "src/parser_proc.y"
-{
+
+static YYRESULTTAG yyresolveValue (yyGLRState* yys,
+ yyGLRStack* yystackp, struct psi_parser *P, struct psi_plist *tokens, size_t *index);
+
+
+/** Resolve the previous YYN states starting at and including state YYS
+ * on *YYSTACKP. If result != yyok, some states may have been left
+ * unresolved possibly with empty semantic option chains. Regardless
+ * of whether result = yyok, each state has been left with consistent
+ * data so that yydestroyGLRState can be invoked if necessary. */
+static YYRESULTTAG
+yyresolveStates (yyGLRState* yys, int yyn,
+ yyGLRStack* yystackp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ if (0 < yyn)
+ {
+ YYASSERT (yys->yypred);
+ YYCHK (yyresolveStates (yys->yypred, yyn-1, yystackp, P, tokens, index));
+ if (! yys->yyresolved)
+ YYCHK (yyresolveValue (yys, yystackp, P, tokens, index));
+ }
+ return yyok;
}
-#line 3274 "src/parser_proc.c"
- yy_destructor(yypParser,147,&yymsp[0].minor);
+
+/** Resolve the states for the RHS of YYOPT on *YYSTACKP, perform its
+ * user action, and return the semantic value and location in *YYVALP
+ * and *YYLOCP. Regardless of whether result = yyok, all RHS states
+ * have been destroyed (assuming the user action destroys all RHS
+ * semantic values if invoked). */
+static YYRESULTTAG
+yyresolveAction (yySemanticOption* yyopt, yyGLRStack* yystackp,
+ YYSTYPE* yyvalp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ yyGLRStackItem yyrhsVals[YYMAXRHS + YYMAXLEFT + 1];
+ int yynrhs = yyrhsLength (yyopt->yyrule);
+ YYRESULTTAG yyflag =
+ yyresolveStates (yyopt->yystate, yynrhs, yystackp, P, tokens, index);
+ if (yyflag != yyok)
+ {
+ yyGLRState *yys;
+ for (yys = yyopt->yystate; yynrhs > 0; yys = yys->yypred, yynrhs -= 1)
+ yydestroyGLRState ("Cleanup: popping", yys, P, tokens, index);
+ return yyflag;
+ }
+
+ yyrhsVals[YYMAXRHS + YYMAXLEFT].yystate.yypred = yyopt->yystate;
+ {
+ int yychar_current = yychar;
+ YYSTYPE yylval_current = yylval;
+ yychar = yyopt->yyrawchar;
+ yylval = yyopt->yyval;
+ yyflag = yyuserAction (yyopt->yyrule, yynrhs,
+ yyrhsVals + YYMAXRHS + YYMAXLEFT - 1,
+ yystackp, yyvalp, P, tokens, index);
+ yychar = yychar_current;
+ yylval = yylval_current;
+ }
+ return yyflag;
}
- break;
- case 155: /* block ::= EOF */
-{ yy_destructor(yypParser,62,&yymsp[0].minor);
-#line 172 "src/parser_proc.y"
+
+#if YYDEBUG
+static void
+yyreportTree (yySemanticOption* yyx, int yyindent)
+{
+ int yynrhs = yyrhsLength (yyx->yyrule);
+ int yyi;
+ yyGLRState* yys;
+ yyGLRState* yystates[1 + YYMAXRHS];
+ yyGLRState yyleftmost_state;
+
+ for (yyi = yynrhs, yys = yyx->yystate; 0 < yyi; yyi -= 1, yys = yys->yypred)
+ yystates[yyi] = yys;
+ if (yys == YY_NULLPTR)
+ {
+ yyleftmost_state.yyposn = 0;
+ yystates[0] = &yyleftmost_state;
+ }
+ else
+ yystates[0] = yys;
+
+ if (yyx->yystate->yyposn < yys->yyposn + 1)
+ YYFPRINTF (stderr, "%*s%s -> <Rule %d, empty>\n",
+ yyindent, "", yytokenName (yylhsNonterm (yyx->yyrule)),
+ yyx->yyrule - 1);
+ else
+ YYFPRINTF (stderr, "%*s%s -> <Rule %d, tokens %lu .. %lu>\n",
+ yyindent, "", yytokenName (yylhsNonterm (yyx->yyrule)),
+ yyx->yyrule - 1, (unsigned long int) (yys->yyposn + 1),
+ (unsigned long int) yyx->yystate->yyposn);
+ for (yyi = 1; yyi <= yynrhs; yyi += 1)
+ {
+ if (yystates[yyi]->yyresolved)
+ {
+ if (yystates[yyi-1]->yyposn+1 > yystates[yyi]->yyposn)
+ YYFPRINTF (stderr, "%*s%s <empty>\n", yyindent+2, "",
+ yytokenName (yystos[yystates[yyi]->yylrState]));
+ else
+ YYFPRINTF (stderr, "%*s%s <tokens %lu .. %lu>\n", yyindent+2, "",
+ yytokenName (yystos[yystates[yyi]->yylrState]),
+ (unsigned long int) (yystates[yyi-1]->yyposn + 1),
+ (unsigned long int) yystates[yyi]->yyposn);
+ }
+ else
+ yyreportTree (yystates[yyi]->yysemantics.yyfirstVal, yyindent+2);
+ }
+}
+#endif
+
+static YYRESULTTAG
+yyreportAmbiguity (yySemanticOption* yyx0,
+ yySemanticOption* yyx1, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
{
+ YYUSE (yyx0);
+ YYUSE (yyx1);
+
+#if YYDEBUG
+ YYFPRINTF (stderr, "Ambiguity detected.\n");
+ YYFPRINTF (stderr, "Option 1,\n");
+ yyreportTree (yyx0, 2);
+ YYFPRINTF (stderr, "\nOption 2,\n");
+ yyreportTree (yyx1, 2);
+ YYFPRINTF (stderr, "\n");
+#endif
+
+ yyerror (P, tokens, index, YY_("syntax is ambiguous"));
+ return yyabort;
}
-#line 3283 "src/parser_proc.c"
+
+/** Resolve the ambiguity represented in state YYS in *YYSTACKP,
+ * perform the indicated actions, and set the semantic value of YYS.
+ * If result != yyok, the chain of semantic options in YYS has been
+ * cleared instead or it has been left unmodified except that
+ * redundant options may have been removed. Regardless of whether
+ * result = yyok, YYS has been left with consistent data so that
+ * yydestroyGLRState can be invoked if necessary. */
+static YYRESULTTAG
+yyresolveValue (yyGLRState* yys, yyGLRStack* yystackp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ yySemanticOption* yyoptionList = yys->yysemantics.yyfirstVal;
+ yySemanticOption* yybest = yyoptionList;
+ yySemanticOption** yypp;
+ yybool yymerge = yyfalse;
+ YYSTYPE yysval;
+ YYRESULTTAG yyflag;
+
+ for (yypp = &yyoptionList->yynext; *yypp != YY_NULLPTR; )
+ {
+ yySemanticOption* yyp = *yypp;
+
+ if (yyidenticalOptions (yybest, yyp))
+ {
+ yymergeOptionSets (yybest, yyp);
+ *yypp = yyp->yynext;
+ }
+ else
+ {
+ switch (yypreference (yybest, yyp))
+ {
+ case 0:
+ return yyreportAmbiguity (yybest, yyp, P, tokens, index);
+ break;
+ case 1:
+ yymerge = yytrue;
+ break;
+ case 2:
+ break;
+ case 3:
+ yybest = yyp;
+ yymerge = yyfalse;
+ break;
+ default:
+ /* This cannot happen so it is not worth a YYASSERT (yyfalse),
+ but some compilers complain if the default case is
+ omitted. */
+ break;
+ }
+ yypp = &yyp->yynext;
+ }
+ }
+
+ if (yymerge)
+ {
+ yySemanticOption* yyp;
+ int yyprec = yydprec[yybest->yyrule];
+ yyflag = yyresolveAction (yybest, yystackp, &yysval, P, tokens, index);
+ if (yyflag == yyok)
+ for (yyp = yybest->yynext; yyp != YY_NULLPTR; yyp = yyp->yynext)
+ {
+ if (yyprec == yydprec[yyp->yyrule])
+ {
+ YYSTYPE yysval_other;
+ yyflag = yyresolveAction (yyp, yystackp, &yysval_other, P, tokens, index);
+ if (yyflag != yyok)
+ {
+ yydestruct ("Cleanup: discarding incompletely merged value for",
+ yystos[yys->yylrState],
+ &yysval, P, tokens, index);
+ break;
+ }
+ yyuserMerge (yymerger[yyp->yyrule], &yysval, &yysval_other);
+ }
+ }
+ }
+ else
+ yyflag = yyresolveAction (yybest, yystackp, &yysval, P, tokens, index);
+
+ if (yyflag == yyok)
+ {
+ yys->yyresolved = yytrue;
+ yys->yysemantics.yysval = yysval;
+ }
+ else
+ yys->yysemantics.yyfirstVal = YY_NULLPTR;
+ return yyflag;
}
- break;
- case 156: /* block ::= EOS */
-{ yy_destructor(yypParser,63,&yymsp[0].minor);
-#line 173 "src/parser_proc.y"
+
+static YYRESULTTAG
+yyresolveStack (yyGLRStack* yystackp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
{
+ if (yystackp->yysplitPoint != YY_NULLPTR)
+ {
+ yyGLRState* yys;
+ int yyn;
+
+ for (yyn = 0, yys = yystackp->yytops.yystates[0];
+ yys != yystackp->yysplitPoint;
+ yys = yys->yypred, yyn += 1)
+ continue;
+ YYCHK (yyresolveStates (yystackp->yytops.yystates[0], yyn, yystackp
+ , P, tokens, index));
+ }
+ return yyok;
}
-#line 3291 "src/parser_proc.c"
+
+static void
+yycompressStack (yyGLRStack* yystackp)
+{
+ yyGLRState* yyp, *yyq, *yyr;
+
+ if (yystackp->yytops.yysize != 1 || yystackp->yysplitPoint == YY_NULLPTR)
+ return;
+
+ for (yyp = yystackp->yytops.yystates[0], yyq = yyp->yypred, yyr = YY_NULLPTR;
+ yyp != yystackp->yysplitPoint;
+ yyr = yyp, yyp = yyq, yyq = yyp->yypred)
+ yyp->yypred = yyr;
+
+ yystackp->yyspaceLeft += yystackp->yynextFree - yystackp->yyitems;
+ yystackp->yynextFree = ((yyGLRStackItem*) yystackp->yysplitPoint) + 1;
+ yystackp->yyspaceLeft -= yystackp->yynextFree - yystackp->yyitems;
+ yystackp->yysplitPoint = YY_NULLPTR;
+ yystackp->yylastDeleted = YY_NULLPTR;
+
+ while (yyr != YY_NULLPTR)
+ {
+ yystackp->yynextFree->yystate = *yyr;
+ yyr = yyr->yypred;
+ yystackp->yynextFree->yystate.yypred = &yystackp->yynextFree[-1].yystate;
+ yystackp->yytops.yystates[0] = &yystackp->yynextFree->yystate;
+ yystackp->yynextFree += 1;
+ yystackp->yyspaceLeft -= 1;
+ }
}
- break;
- default:
- break;
-/********** End reduce actions ************************************************/
- };
- assert( yyruleno<sizeof(yyRuleInfo)/sizeof(yyRuleInfo[0]) );
- yygoto = yyRuleInfo[yyruleno].lhs;
- yysize = yyRuleInfo[yyruleno].nrhs;
- yyact = yy_find_reduce_action(yymsp[-yysize].stateno,(YYCODETYPE)yygoto);
- if( yyact <= YY_MAX_SHIFTREDUCE ){
- if( yyact>YY_MAX_SHIFT ){
- yyact += YY_MIN_REDUCE - YY_MIN_SHIFTREDUCE;
+
+static YYRESULTTAG
+yyprocessOneStack (yyGLRStack* yystackp, size_t yyk,
+ size_t yyposn, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ while (yystackp->yytops.yystates[yyk] != YY_NULLPTR)
+ {
+ yyStateNum yystate = yystackp->yytops.yystates[yyk]->yylrState;
+ YYDPRINTF ((stderr, "Stack %lu Entering state %d\n",
+ (unsigned long int) yyk, yystate));
+
+ YYASSERT (yystate != YYFINAL);
+
+ if (yyisDefaultedState (yystate))
+ {
+ YYRESULTTAG yyflag;
+ yyRuleNum yyrule = yydefaultAction (yystate);
+ if (yyrule == 0)
+ {
+ YYDPRINTF ((stderr, "Stack %lu dies.\n",
+ (unsigned long int) yyk));
+ yymarkStackDeleted (yystackp, yyk);
+ return yyok;
+ }
+ yyflag = yyglrReduce (yystackp, yyk, yyrule, yyimmediate[yyrule], P, tokens, index);
+ if (yyflag == yyerr)
+ {
+ YYDPRINTF ((stderr,
+ "Stack %lu dies "
+ "(predicate failure or explicit user error).\n",
+ (unsigned long int) yyk));
+ yymarkStackDeleted (yystackp, yyk);
+ return yyok;
+ }
+ if (yyflag != yyok)
+ return yyflag;
+ }
+ else
+ {
+ yySymbol yytoken;
+ int yyaction;
+ const short int* yyconflicts;
+
+ yystackp->yytops.yylookaheadNeeds[yyk] = yytrue;
+ if (yychar == YYEMPTY)
+ {
+ YYDPRINTF ((stderr, "Reading a token: "));
+ yychar = yylex (&yylval, P, tokens, index);
+ }
+
+ if (yychar <= YYEOF)
+ {
+ yychar = yytoken = YYEOF;
+ YYDPRINTF ((stderr, "Now at end of input.\n"));
+ }
+ else
+ {
+ yytoken = YYTRANSLATE (yychar);
+ YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
+ }
+
+ yygetLRActions (yystate, yytoken, &yyaction, &yyconflicts);
+
+ while (*yyconflicts != 0)
+ {
+ YYRESULTTAG yyflag;
+ size_t yynewStack = yysplitStack (yystackp, yyk);
+ YYDPRINTF ((stderr, "Splitting off stack %lu from %lu.\n",
+ (unsigned long int) yynewStack,
+ (unsigned long int) yyk));
+ yyflag = yyglrReduce (yystackp, yynewStack,
+ *yyconflicts,
+ yyimmediate[*yyconflicts], P, tokens, index);
+ if (yyflag == yyok)
+ YYCHK (yyprocessOneStack (yystackp, yynewStack,
+ yyposn, P, tokens, index));
+ else if (yyflag == yyerr)
+ {
+ YYDPRINTF ((stderr, "Stack %lu dies.\n",
+ (unsigned long int) yynewStack));
+ yymarkStackDeleted (yystackp, yynewStack);
+ }
+ else
+ return yyflag;
+ yyconflicts += 1;
+ }
+
+ if (yyisShiftAction (yyaction))
+ break;
+ else if (yyisErrorAction (yyaction))
+ {
+ YYDPRINTF ((stderr, "Stack %lu dies.\n",
+ (unsigned long int) yyk));
+ yymarkStackDeleted (yystackp, yyk);
+ break;
+ }
+ else
+ {
+ YYRESULTTAG yyflag = yyglrReduce (yystackp, yyk, -yyaction,
+ yyimmediate[-yyaction], P, tokens, index);
+ if (yyflag == yyerr)
+ {
+ YYDPRINTF ((stderr,
+ "Stack %lu dies "
+ "(predicate failure or explicit user error).\n",
+ (unsigned long int) yyk));
+ yymarkStackDeleted (yystackp, yyk);
+ break;
+ }
+ else if (yyflag != yyok)
+ return yyflag;
+ }
+ }
}
- yymsp -= yysize-1;
- yypParser->yytos = yymsp;
- yymsp->stateno = (YYACTIONTYPE)yyact;
- yymsp->major = (YYCODETYPE)yygoto;
- yyTraceShift(yypParser, yyact);
- }else{
- assert( yyact == YY_ACCEPT_ACTION );
- yypParser->yytos -= yysize;
- yy_accept(yypParser);
- }
+ return yyok;
}
-/*
-** The following code executes when the parse fails
-*/
-#ifndef YYNOERRORRECOVERY
-static void yy_parse_failed(
- yyParser *yypParser /* The parser */
-){
- ParseARG_FETCH;
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sFail!\n",yyTracePrompt);
- }
-#endif
- while( yypParser->yytos>yypParser->yystack ) yy_pop_parser_stack(yypParser);
- /* Here code is inserted which will be executed whenever the
- ** parser fails */
-/************ Begin %parse_failure code ***************************************/
-/************ End %parse_failure code *****************************************/
- ParseARG_STORE; /* Suppress warning about unused %extra_argument variable */
-}
-#endif /* YYNOERRORRECOVERY */
-
-/*
-** The following code executes when a syntax error first occurs.
-*/
-static void yy_syntax_error(
- yyParser *yypParser, /* The parser */
- int yymajor, /* The major type of the error token */
- ParseTOKENTYPE yyminor /* The minor type of the error token */
-){
- ParseARG_FETCH;
-#define TOKEN yyminor
-/************ Begin %syntax_error code ****************************************/
-#line 40 "src/parser_proc.y"
- ++P->errors; if (TOKEN && TOKEN->type != PSI_T_EOF) { psi_error(PSI_WARNING, TOKEN->file, TOKEN->line, "PSI syntax error: Unexpected token '%s' at pos %u", TOKEN->text, TOKEN->col); } else { psi_error(PSI_WARNING, P->file.fn, P->line, "PSI syntax error: Unexpected end of input"); }
-#line 3353 "src/parser_proc.c"
-/************ End %syntax_error code ******************************************/
- ParseARG_STORE; /* Suppress warning about unused %extra_argument variable */
-}
-
-/*
-** The following is executed when the parser accepts
-*/
-static void yy_accept(
- yyParser *yypParser /* The parser */
-){
- ParseARG_FETCH;
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sAccept!\n",yyTracePrompt);
+static void
+yyreportSyntaxError (yyGLRStack* yystackp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ if (yystackp->yyerrState != 0)
+ return;
+#if ! YYERROR_VERBOSE
+ yyerror (P, tokens, index, YY_("syntax error"));
+#else
+ {
+ yySymbol yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
+ size_t yysize0 = yytnamerr (YY_NULLPTR, yytokenName (yytoken));
+ size_t yysize = yysize0;
+ yybool yysize_overflow = yyfalse;
+ char* yymsg = YY_NULLPTR;
+ enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
+ /* Internationalized format string. */
+ const char *yyformat = YY_NULLPTR;
+ /* Arguments of yyformat. */
+ char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
+ /* Number of reported tokens (one for the "unexpected", one per
+ "expected"). */
+ int yycount = 0;
+
+ /* There are many possibilities here to consider:
+ - If this state is a consistent state with a default action, then
+ the only way this function was invoked is if the default action
+ is an error action. In that case, don't check for expected
+ tokens because there are none.
+ - The only way there can be no lookahead present (in yychar) is if
+ this state is a consistent state with a default action. Thus,
+ detecting the absence of a lookahead is sufficient to determine
+ that there is no unexpected or expected token to report. In that
+ case, just report a simple "syntax error".
+ - Don't assume there isn't a lookahead just because this state is a
+ consistent state with a default action. There might have been a
+ previous inconsistent state, consistent state with a non-default
+ action, or user semantic action that manipulated yychar.
+ - Of course, the expected token list depends on states to have
+ correct lookahead information, and it depends on the parser not
+ to perform extra reductions after fetching a lookahead from the
+ scanner and before detecting a syntax error. Thus, state merging
+ (from LALR or IELR) and default reductions corrupt the expected
+ token list. However, the list is correct for canonical LR with
+ one exception: it will still contain any token that will not be
+ accepted due to an error action in a later state.
+ */
+ if (yytoken != YYEMPTY)
+ {
+ int yyn = yypact[yystackp->yytops.yystates[0]->yylrState];
+ yyarg[yycount++] = yytokenName (yytoken);
+ if (!yypact_value_is_default (yyn))
+ {
+ /* Start YYX at -YYN if negative to avoid negative indexes in
+ YYCHECK. In other words, skip the first -YYN actions for this
+ state because they are default actions. */
+ int yyxbegin = yyn < 0 ? -yyn : 0;
+ /* Stay within bounds of both yycheck and yytname. */
+ int yychecklim = YYLAST - yyn + 1;
+ int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ int yyx;
+ for (yyx = yyxbegin; yyx < yyxend; ++yyx)
+ if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
+ && !yytable_value_is_error (yytable[yyx + yyn]))
+ {
+ if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
+ {
+ yycount = 1;
+ yysize = yysize0;
+ break;
+ }
+ yyarg[yycount++] = yytokenName (yyx);
+ {
+ size_t yysz = yysize + yytnamerr (YY_NULLPTR, yytokenName (yyx));
+ yysize_overflow |= yysz < yysize;
+ yysize = yysz;
+ }
+ }
+ }
+ }
+
+ switch (yycount)
+ {
+#define YYCASE_(N, S) \
+ case N: \
+ yyformat = S; \
+ break
+ YYCASE_(0, YY_("syntax error"));
+ YYCASE_(1, YY_("syntax error, unexpected %s"));
+ YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
+ YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
+ YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
+ YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
+#undef YYCASE_
+ }
+
+ {
+ size_t yysz = yysize + strlen (yyformat);
+ yysize_overflow |= yysz < yysize;
+ yysize = yysz;
}
-#endif
-#ifndef YYNOERRORRECOVERY
- yypParser->yyerrcnt = -1;
-#endif
- assert( yypParser->yytos==yypParser->yystack );
- /* Here code is inserted which will be executed whenever the
- ** parser accepts */
-/*********** Begin %parse_accept code *****************************************/
-/*********** End %parse_accept code *******************************************/
- ParseARG_STORE; /* Suppress warning about unused %extra_argument variable */
-}
-
-/* The main parser program.
-** The first argument is a pointer to a structure obtained from
-** "ParseAlloc" which describes the current state of the parser.
-** The second argument is the major token number. The third is
-** the minor token. The fourth optional argument is whatever the
-** user wants (and specified in the grammar) and is available for
-** use by the action routines.
-**
-** Inputs:
-** <ul>
-** <li> A pointer to the parser (an opaque structure.)
-** <li> The major token number.
-** <li> The minor token number.
-** <li> An option argument of a grammar-specified type.
-** </ul>
-**
-** Outputs:
-** None.
-*/
-void Parse(
- void *yyp, /* The parser */
- int yymajor, /* The major token code number */
- ParseTOKENTYPE yyminor /* The value for the token */
- ParseARG_PDECL /* Optional %extra_argument parameter */
-){
- YYMINORTYPE yyminorunion;
- unsigned int yyact; /* The parser action. */
-#if !defined(YYERRORSYMBOL) && !defined(YYNOERRORRECOVERY)
- int yyendofinput; /* True if we are at the end of input */
-#endif
-#ifdef YYERRORSYMBOL
- int yyerrorhit = 0; /* True if yymajor has invoked an error */
-#endif
- yyParser *yypParser; /* The parser */
- yypParser = (yyParser*)yyp;
- assert( yypParser->yytos!=0 );
-#if !defined(YYERRORSYMBOL) && !defined(YYNOERRORRECOVERY)
- yyendofinput = (yymajor==0);
-#endif
- ParseARG_STORE;
+ if (!yysize_overflow)
+ yymsg = (char *) YYMALLOC (yysize);
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sInput '%s'\n",yyTracePrompt,yyTokenName[yymajor]);
+ if (yymsg)
+ {
+ char *yyp = yymsg;
+ int yyi = 0;
+ while ((*yyp = *yyformat))
+ {
+ if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
+ {
+ yyp += yytnamerr (yyp, yyarg[yyi++]);
+ yyformat += 2;
+ }
+ else
+ {
+ yyp++;
+ yyformat++;
+ }
+ }
+ yyerror (P, tokens, index, yymsg);
+ YYFREE (yymsg);
+ }
+ else
+ {
+ yyerror (P, tokens, index, YY_("syntax error"));
+ yyMemoryExhausted (yystackp);
+ }
}
-#endif
+#endif /* YYERROR_VERBOSE */
+ yynerrs += 1;
+}
- do{
- yyact = yy_find_shift_action(yypParser,(YYCODETYPE)yymajor);
- if( yyact <= YY_MAX_SHIFTREDUCE ){
- yy_shift(yypParser,yyact,yymajor,yyminor);
-#ifndef YYNOERRORRECOVERY
- yypParser->yyerrcnt--;
-#endif
- yymajor = YYNOCODE;
- }else if( yyact <= YY_MAX_REDUCE ){
- yy_reduce(yypParser,yyact-YY_MIN_REDUCE);
- }else{
- assert( yyact == YY_ERROR_ACTION );
- yyminorunion.yy0 = yyminor;
-#ifdef YYERRORSYMBOL
- int yymx;
-#endif
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sSyntax Error!\n",yyTracePrompt);
- }
-#endif
-#ifdef YYERRORSYMBOL
- /* A syntax error has occurred.
- ** The response to an error depends upon whether or not the
- ** grammar defines an error token "ERROR".
- **
- ** This is what we do if the grammar does define ERROR:
- **
- ** * Call the %syntax_error function.
- **
- ** * Begin popping the stack until we enter a state where
- ** it is legal to shift the error symbol, then shift
- ** the error symbol.
- **
- ** * Set the error count to three.
- **
- ** * Begin accepting and shifting new tokens. No new error
- ** processing will occur until three tokens have been
- ** shifted successfully.
- **
- */
- if( yypParser->yyerrcnt<0 ){
- yy_syntax_error(yypParser,yymajor,yyminor);
+/* Recover from a syntax error on *YYSTACKP, assuming that *YYSTACKP->YYTOKENP,
+ yylval, and yylloc are the syntactic category, semantic value, and location
+ of the lookahead. */
+static void
+yyrecoverSyntaxError (yyGLRStack* yystackp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ size_t yyk;
+ int yyj;
+
+ if (yystackp->yyerrState == 3)
+ /* We just shifted the error token and (perhaps) took some
+ reductions. Skip tokens until we can proceed. */
+ while (yytrue)
+ {
+ yySymbol yytoken;
+ if (yychar == YYEOF)
+ yyFail (yystackp, P, tokens, index, YY_NULLPTR);
+ if (yychar != YYEMPTY)
+ {
+ yytoken = YYTRANSLATE (yychar);
+ yydestruct ("Error: discarding",
+ yytoken, &yylval, P, tokens, index);
+ }
+ YYDPRINTF ((stderr, "Reading a token: "));
+ yychar = yylex (&yylval, P, tokens, index);
+ if (yychar <= YYEOF)
+ {
+ yychar = yytoken = YYEOF;
+ YYDPRINTF ((stderr, "Now at end of input.\n"));
+ }
+ else
+ {
+ yytoken = YYTRANSLATE (yychar);
+ YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
+ }
+ yyj = yypact[yystackp->yytops.yystates[0]->yylrState];
+ if (yypact_value_is_default (yyj))
+ return;
+ yyj += yytoken;
+ if (yyj < 0 || YYLAST < yyj || yycheck[yyj] != yytoken)
+ {
+ if (yydefact[yystackp->yytops.yystates[0]->yylrState] != 0)
+ return;
+ }
+ else if (! yytable_value_is_error (yytable[yyj]))
+ return;
}
- yymx = yypParser->yytos->major;
- if( yymx==YYERRORSYMBOL || yyerrorhit ){
-#ifndef NDEBUG
- if( yyTraceFILE ){
- fprintf(yyTraceFILE,"%sDiscard input token %s\n",
- yyTracePrompt,yyTokenName[yymajor]);
+
+ /* Reduce to one stack. */
+ for (yyk = 0; yyk < yystackp->yytops.yysize; yyk += 1)
+ if (yystackp->yytops.yystates[yyk] != YY_NULLPTR)
+ break;
+ if (yyk >= yystackp->yytops.yysize)
+ yyFail (yystackp, P, tokens, index, YY_NULLPTR);
+ for (yyk += 1; yyk < yystackp->yytops.yysize; yyk += 1)
+ yymarkStackDeleted (yystackp, yyk);
+ yyremoveDeletes (yystackp);
+ yycompressStack (yystackp);
+
+ /* Now pop stack until we find a state that shifts the error token. */
+ yystackp->yyerrState = 3;
+ while (yystackp->yytops.yystates[0] != YY_NULLPTR)
+ {
+ yyGLRState *yys = yystackp->yytops.yystates[0];
+ yyj = yypact[yys->yylrState];
+ if (! yypact_value_is_default (yyj))
+ {
+ yyj += YYTERROR;
+ if (0 <= yyj && yyj <= YYLAST && yycheck[yyj] == YYTERROR
+ && yyisShiftAction (yytable[yyj]))
+ {
+ /* Shift the error token. */
+ YY_SYMBOL_PRINT ("Shifting", yystos[yytable[yyj]],
+ &yylval, &yyerrloc);
+ yyglrShift (yystackp, 0, yytable[yyj],
+ yys->yyposn, &yylval);
+ yys = yystackp->yytops.yystates[0];
+ break;
+ }
}
-#endif
- yy_destructor(yypParser, (YYCODETYPE)yymajor, &yyminorunion);
- yymajor = YYNOCODE;
- }else{
- while( yypParser->yytos >= yypParser->yystack
- && yymx != YYERRORSYMBOL
- && (yyact = yy_find_reduce_action(
- yypParser->yytos->stateno,
- YYERRORSYMBOL)) >= YY_MIN_REDUCE
- ){
- yy_pop_parser_stack(yypParser);
+ if (yys->yypred != YY_NULLPTR)
+ yydestroyGLRState ("Error: popping", yys, P, tokens, index);
+ yystackp->yytops.yystates[0] = yys->yypred;
+ yystackp->yynextFree -= 1;
+ yystackp->yyspaceLeft += 1;
+ }
+ if (yystackp->yytops.yystates[0] == YY_NULLPTR)
+ yyFail (yystackp, P, tokens, index, YY_NULLPTR);
+}
+
+#define YYCHK1(YYE) \
+ do { \
+ switch (YYE) { \
+ case yyok: \
+ break; \
+ case yyabort: \
+ goto yyabortlab; \
+ case yyaccept: \
+ goto yyacceptlab; \
+ case yyerr: \
+ goto yyuser_error; \
+ default: \
+ goto yybuglab; \
+ } \
+ } while (0)
+
+/*----------.
+| yyparse. |
+`----------*/
+
+int
+yyparse (struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ int yyresult;
+ yyGLRStack yystack;
+ yyGLRStack* const yystackp = &yystack;
+ size_t yyposn;
+
+ YYDPRINTF ((stderr, "Starting parse\n"));
+
+ yychar = YYEMPTY;
+ yylval = yyval_default;
+
+ /* User initialization code. */
+ #line 136 "src/parser_proc_grammar.y" /* glr.c:2270 */
+{
+}
+
+#line 7247 "src/parser_proc.c" /* glr.c:2270 */
+
+ if (! yyinitGLRStack (yystackp, YYINITDEPTH))
+ goto yyexhaustedlab;
+ switch (YYSETJMP (yystack.yyexception_buffer))
+ {
+ case 0: break;
+ case 1: goto yyabortlab;
+ case 2: goto yyexhaustedlab;
+ default: goto yybuglab;
+ }
+ yyglrShift (&yystack, 0, 0, 0, &yylval);
+ yyposn = 0;
+
+ while (yytrue)
+ {
+ /* For efficiency, we have two loops, the first of which is
+ specialized to deterministic operation (single stack, no
+ potential ambiguity). */
+ /* Standard mode */
+ while (yytrue)
+ {
+ yyRuleNum yyrule;
+ int yyaction;
+ const short int* yyconflicts;
+
+ yyStateNum yystate = yystack.yytops.yystates[0]->yylrState;
+ YYDPRINTF ((stderr, "Entering state %d\n", yystate));
+ if (yystate == YYFINAL)
+ goto yyacceptlab;
+ if (yyisDefaultedState (yystate))
+ {
+ yyrule = yydefaultAction (yystate);
+ if (yyrule == 0)
+ {
+
+ yyreportSyntaxError (&yystack, P, tokens, index);
+ goto yyuser_error;
+ }
+ YYCHK1 (yyglrReduce (&yystack, 0, yyrule, yytrue, P, tokens, index));
+ }
+ else
+ {
+ yySymbol yytoken;
+ if (yychar == YYEMPTY)
+ {
+ YYDPRINTF ((stderr, "Reading a token: "));
+ yychar = yylex (&yylval, P, tokens, index);
+ }
+
+ if (yychar <= YYEOF)
+ {
+ yychar = yytoken = YYEOF;
+ YYDPRINTF ((stderr, "Now at end of input.\n"));
+ }
+ else
+ {
+ yytoken = YYTRANSLATE (yychar);
+ YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
+ }
+
+ yygetLRActions (yystate, yytoken, &yyaction, &yyconflicts);
+ if (*yyconflicts != 0)
+ break;
+ if (yyisShiftAction (yyaction))
+ {
+ YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
+ yychar = YYEMPTY;
+ yyposn += 1;
+ yyglrShift (&yystack, 0, yyaction, yyposn, &yylval);
+ if (0 < yystack.yyerrState)
+ yystack.yyerrState -= 1;
+ }
+ else if (yyisErrorAction (yyaction))
+ {
+
+ yyreportSyntaxError (&yystack, P, tokens, index);
+ goto yyuser_error;
+ }
+ else
+ YYCHK1 (yyglrReduce (&yystack, 0, -yyaction, yytrue, P, tokens, index));
+ }
}
- if( yypParser->yytos < yypParser->yystack || yymajor==0 ){
- yy_destructor(yypParser,(YYCODETYPE)yymajor,&yyminorunion);
- yy_parse_failed(yypParser);
-#ifndef YYNOERRORRECOVERY
- yypParser->yyerrcnt = -1;
-#endif
- yymajor = YYNOCODE;
- }else if( yymx!=YYERRORSYMBOL ){
- yy_shift(yypParser,yyact,YYERRORSYMBOL,yyminor);
+
+ while (yytrue)
+ {
+ yySymbol yytoken_to_shift;
+ size_t yys;
+
+ for (yys = 0; yys < yystack.yytops.yysize; yys += 1)
+ yystackp->yytops.yylookaheadNeeds[yys] = yychar != YYEMPTY;
+
+ /* yyprocessOneStack returns one of three things:
+
+ - An error flag. If the caller is yyprocessOneStack, it
+ immediately returns as well. When the caller is finally
+ yyparse, it jumps to an error label via YYCHK1.
+
+ - yyok, but yyprocessOneStack has invoked yymarkStackDeleted
+ (&yystack, yys), which sets the top state of yys to NULL. Thus,
+ yyparse's following invocation of yyremoveDeletes will remove
+ the stack.
+
+ - yyok, when ready to shift a token.
+
+ Except in the first case, yyparse will invoke yyremoveDeletes and
+ then shift the next token onto all remaining stacks. This
+ synchronization of the shift (that is, after all preceding
+ reductions on all stacks) helps prevent double destructor calls
+ on yylval in the event of memory exhaustion. */
+
+ for (yys = 0; yys < yystack.yytops.yysize; yys += 1)
+ YYCHK1 (yyprocessOneStack (&yystack, yys, yyposn, P, tokens, index));
+ yyremoveDeletes (&yystack);
+ if (yystack.yytops.yysize == 0)
+ {
+ yyundeleteLastStack (&yystack);
+ if (yystack.yytops.yysize == 0)
+ yyFail (&yystack, P, tokens, index, YY_("syntax error"));
+ YYCHK1 (yyresolveStack (&yystack, P, tokens, index));
+ YYDPRINTF ((stderr, "Returning to deterministic operation.\n"));
+
+ yyreportSyntaxError (&yystack, P, tokens, index);
+ goto yyuser_error;
+ }
+
+ /* If any yyglrShift call fails, it will fail after shifting. Thus,
+ a copy of yylval will already be on stack 0 in the event of a
+ failure in the following loop. Thus, yychar is set to YYEMPTY
+ before the loop to make sure the user destructor for yylval isn't
+ called twice. */
+ yytoken_to_shift = YYTRANSLATE (yychar);
+ yychar = YYEMPTY;
+ yyposn += 1;
+ for (yys = 0; yys < yystack.yytops.yysize; yys += 1)
+ {
+ int yyaction;
+ const short int* yyconflicts;
+ yyStateNum yystate = yystack.yytops.yystates[yys]->yylrState;
+ yygetLRActions (yystate, yytoken_to_shift, &yyaction,
+ &yyconflicts);
+ /* Note that yyconflicts were handled by yyprocessOneStack. */
+ YYDPRINTF ((stderr, "On stack %lu, ", (unsigned long int) yys));
+ YY_SYMBOL_PRINT ("shifting", yytoken_to_shift, &yylval, &yylloc);
+ yyglrShift (&yystack, yys, yyaction, yyposn,
+ &yylval);
+ YYDPRINTF ((stderr, "Stack %lu now in state #%d\n",
+ (unsigned long int) yys,
+ yystack.yytops.yystates[yys]->yylrState));
+ }
+
+ if (yystack.yytops.yysize == 1)
+ {
+ YYCHK1 (yyresolveStack (&yystack, P, tokens, index));
+ YYDPRINTF ((stderr, "Returning to deterministic operation.\n"));
+ yycompressStack (&yystack);
+ break;
+ }
}
- }
- yypParser->yyerrcnt = 3;
- yyerrorhit = 1;
-#elif defined(YYNOERRORRECOVERY)
- /* If the YYNOERRORRECOVERY macro is defined, then do not attempt to
- ** do any kind of error recovery. Instead, simply invoke the syntax
- ** error routine and continue going as if nothing had happened.
- **
- ** Applications can set this macro (for example inside %include) if
- ** they intend to abandon the parse upon the first syntax error seen.
- */
- yy_syntax_error(yypParser,yymajor, yyminor);
- yy_destructor(yypParser,(YYCODETYPE)yymajor,&yyminorunion);
- yymajor = YYNOCODE;
-
-#else /* YYERRORSYMBOL is not defined */
- /* This is what we do if the grammar does not define ERROR:
- **
- ** * Report an error message, and throw away the input token.
- **
- ** * If the input token is $, then fail the parse.
- **
- ** As before, subsequent error messages are suppressed until
- ** three input tokens have been successfully shifted.
- */
- if( yypParser->yyerrcnt<=0 ){
- yy_syntax_error(yypParser,yymajor, yyminor);
- }
- yypParser->yyerrcnt = 3;
- yy_destructor(yypParser,(YYCODETYPE)yymajor,&yyminorunion);
- if( yyendofinput ){
- yy_parse_failed(yypParser);
-#ifndef YYNOERRORRECOVERY
- yypParser->yyerrcnt = -1;
-#endif
- }
- yymajor = YYNOCODE;
-#endif
+ continue;
+ yyuser_error:
+ yyrecoverSyntaxError (&yystack, P, tokens, index);
+ yyposn = yystack.yytops.yystates[0]->yyposn;
}
- }while( yymajor!=YYNOCODE && yypParser->yytos>yypParser->yystack );
-#ifndef NDEBUG
- if( yyTraceFILE ){
- yyStackEntry *i;
- char cDiv = '[';
- fprintf(yyTraceFILE,"%sReturn. Stack=",yyTracePrompt);
- for(i=&yypParser->yystack[1]; i<=yypParser->yytos; i++){
- fprintf(yyTraceFILE,"%c%s", cDiv, yyTokenName[i->major]);
- cDiv = ' ';
+
+ yyacceptlab:
+ yyresult = 0;
+ goto yyreturn;
+
+ yybuglab:
+ YYASSERT (yyfalse);
+ goto yyabortlab;
+
+ yyabortlab:
+ yyresult = 1;
+ goto yyreturn;
+
+ yyexhaustedlab:
+ yyerror (P, tokens, index, YY_("memory exhausted"));
+ yyresult = 2;
+ goto yyreturn;
+
+ yyreturn:
+ if (yychar != YYEMPTY)
+ yydestruct ("Cleanup: discarding lookahead",
+ YYTRANSLATE (yychar), &yylval, P, tokens, index);
+
+ /* If the stack is well-formed, pop the stack until it is empty,
+ destroying its entries as we go. But free the stack regardless
+ of whether it is well-formed. */
+ if (yystack.yyitems)
+ {
+ yyGLRState** yystates = yystack.yytops.yystates;
+ if (yystates)
+ {
+ size_t yysize = yystack.yytops.yysize;
+ size_t yyk;
+ for (yyk = 0; yyk < yysize; yyk += 1)
+ if (yystates[yyk])
+ {
+ while (yystates[yyk])
+ {
+ yyGLRState *yys = yystates[yyk];
+ if (yys->yypred != YY_NULLPTR)
+ yydestroyGLRState ("Cleanup: popping", yys, P, tokens, index);
+ yystates[yyk] = yys->yypred;
+ yystack.yynextFree -= 1;
+ yystack.yyspaceLeft += 1;
+ }
+ break;
+ }
+ }
+ yyfreeGLRStack (&yystack);
}
- fprintf(yyTraceFILE,"]\n");
- }
+
+ return yyresult;
+}
+
+/* DEBUGGING ONLY */
+#if YYDEBUG
+static void
+yy_yypstack (yyGLRState* yys)
+{
+ if (yys->yypred)
+ {
+ yy_yypstack (yys->yypred);
+ YYFPRINTF (stderr, " -> ");
+ }
+ YYFPRINTF (stderr, "%d@%lu", yys->yylrState,
+ (unsigned long int) yys->yyposn);
+}
+
+static void
+yypstates (yyGLRState* yyst)
+{
+ if (yyst == YY_NULLPTR)
+ YYFPRINTF (stderr, "<null>");
+ else
+ yy_yypstack (yyst);
+ YYFPRINTF (stderr, "\n");
+}
+
+static void
+yypstack (yyGLRStack* yystackp, size_t yyk)
+{
+ yypstates (yystackp->yytops.yystates[yyk]);
+}
+
+#define YYINDEX(YYX) \
+ ((YYX) == YY_NULLPTR ? -1 : (yyGLRStackItem*) (YYX) - yystackp->yyitems)
+
+
+static void
+yypdumpstack (yyGLRStack* yystackp)
+{
+ yyGLRStackItem* yyp;
+ size_t yyi;
+ for (yyp = yystackp->yyitems; yyp < yystackp->yynextFree; yyp += 1)
+ {
+ YYFPRINTF (stderr, "%3lu. ",
+ (unsigned long int) (yyp - yystackp->yyitems));
+ if (*(yybool *) yyp)
+ {
+ YYASSERT (yyp->yystate.yyisState);
+ YYASSERT (yyp->yyoption.yyisState);
+ YYFPRINTF (stderr, "Res: %d, LR State: %d, posn: %lu, pred: %ld",
+ yyp->yystate.yyresolved, yyp->yystate.yylrState,
+ (unsigned long int) yyp->yystate.yyposn,
+ (long int) YYINDEX (yyp->yystate.yypred));
+ if (! yyp->yystate.yyresolved)
+ YYFPRINTF (stderr, ", firstVal: %ld",
+ (long int) YYINDEX (yyp->yystate
+ .yysemantics.yyfirstVal));
+ }
+ else
+ {
+ YYASSERT (!yyp->yystate.yyisState);
+ YYASSERT (!yyp->yyoption.yyisState);
+ YYFPRINTF (stderr, "Option. rule: %d, state: %ld, next: %ld",
+ yyp->yyoption.yyrule - 1,
+ (long int) YYINDEX (yyp->yyoption.yystate),
+ (long int) YYINDEX (yyp->yyoption.yynext));
+ }
+ YYFPRINTF (stderr, "\n");
+ }
+ YYFPRINTF (stderr, "Tops:");
+ for (yyi = 0; yyi < yystackp->yytops.yysize; yyi += 1)
+ YYFPRINTF (stderr, "%lu: %ld; ", (unsigned long int) yyi,
+ (long int) YYINDEX (yystackp->yytops.yystates[yyi]));
+ YYFPRINTF (stderr, "\n");
+}
#endif
- return;
+
+#undef yylval
+#undef yychar
+#undef yynerrs
+
+/* Substitute the variable and function names. */
+#define yyparse psi_parser_proc_parse
+#define yylex psi_parser_proc_lex
+#define yyerror psi_parser_proc_error
+#define yylval psi_parser_proc_lval
+#define yychar psi_parser_proc_char
+#define yydebug psi_parser_proc_debug
+#define yynerrs psi_parser_proc_nerrs
+
+#line 2085 "src/parser_proc_grammar.y" /* glr.c:2584 */
+
+
+/* epilogue */
+
+static int psi_parser_proc_lex(YYSTYPE *lvalp, struct psi_parser *P, struct psi_plist *tokens, size_t *index)
+{
+ struct psi_token *token;
+
+ if (psi_plist_get(tokens, (*index)++, &token)) {
+ if (P->flags & PSI_DEBUG) {
+ psi_token_dump(2, token);
+ }
+
+ *((struct psi_token **)lvalp) = token;
+ return token->type;
+ } else {
+ (*index)--;
+ PSI_DEBUG_PRINT(P, "EOF(%d)\n", PSI_T_EOF);
+ }
+
+ return PSI_T_EOF;
+}
+
+static void psi_parser_proc_error(struct psi_parser *P, struct psi_plist *tokens, size_t *index, const char *msg)
+{
+ struct psi_token *T = NULL;
+ size_t last;
+
+ if (*index == 0) {
+ last = 0;
+ } else {
+ last = --(*index);
+ }
+
+ psi_plist_get(tokens, last, &T);
+ if (T) {
+ P->error(PSI_DATA(P), T, PSI_WARNING, "PSI %s at col %u", msg, T->col);
+ } else {
+ P->error(PSI_DATA(P), NULL, PSI_WARNING, "PSI %s", msg);
+ }
+ P->errors++;
}
+