mirror of
https://bitbucket.org/smil3y/kdelibs.git
synced 2025-02-24 02:42:48 +00:00
generic: regenerate parsers
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
7b84f8d11b
commit
3ae8b33409
6 changed files with 390 additions and 370 deletions
|
@ -1,6 +1,6 @@
|
|||
#line 1 "lex.c"
|
||||
#line 2 "lex.c"
|
||||
|
||||
#line 3 "lex.c"
|
||||
#line 4 "lex.c"
|
||||
|
||||
#define YY_INT_ALIGNED short int
|
||||
|
||||
|
@ -725,9 +725,9 @@ int yywrap();
|
|||
int kiotraderlex(YYSTYPE * yylval, yyscan_t scanner);
|
||||
void KTraderParse_initFlex( const char *_code, yyscan_t _scanner );
|
||||
|
||||
#line 728 "lex.c"
|
||||
#line 729 "lex.c"
|
||||
#define YY_NO_INPUT 1
|
||||
#line 730 "lex.c"
|
||||
#line 731 "lex.c"
|
||||
|
||||
#define INITIAL 0
|
||||
|
||||
|
@ -1002,7 +1002,7 @@ YY_DECL
|
|||
#line 29 "lex.l"
|
||||
|
||||
|
||||
#line 1005 "lex.c"
|
||||
#line 1006 "lex.c"
|
||||
|
||||
while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
|
||||
{
|
||||
|
@ -1212,7 +1212,7 @@ YY_RULE_SETUP
|
|||
#line 71 "lex.l"
|
||||
ECHO;
|
||||
YY_BREAK
|
||||
#line 1215 "lex.c"
|
||||
#line 1216 "lex.c"
|
||||
case YY_STATE_EOF(INITIAL):
|
||||
yyterminate();
|
||||
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
/* A Bison parser, made by GNU Bison 3.0.5. */
|
||||
/* A Bison parser, made by GNU Bison 3.3.2. */
|
||||
|
||||
/* Bison implementation for Yacc-like parsers in C
|
||||
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018 Free Software Foundation, Inc.
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 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
|
||||
|
@ -40,11 +41,14 @@
|
|||
define necessary library symbols; they are noted "INFRINGES ON
|
||||
USER NAME SPACE" below. */
|
||||
|
||||
/* Undocumented macros, especially those whose name start with YY_,
|
||||
are private implementation details. Do not rely on them. */
|
||||
|
||||
/* Identify Bison output. */
|
||||
#define YYBISON 1
|
||||
|
||||
/* Bison version. */
|
||||
#define YYBISON_VERSION "3.0.5"
|
||||
#define YYBISON_VERSION "3.3.2"
|
||||
|
||||
/* Skeleton name. */
|
||||
#define YYSKELETON_NAME "yacc.c"
|
||||
|
@ -67,8 +71,8 @@
|
|||
#define yynerrs kiotradernerrs
|
||||
|
||||
|
||||
/* Copy the first part of user declarations. */
|
||||
#line 1 "yacc.y" /* yacc.c:339 */
|
||||
/* First part of user prologue. */
|
||||
#line 1 "yacc.y" /* yacc.c:337 */
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
|
@ -86,13 +90,16 @@ int kiotraderlex_destroy(yyscan_t scanner);
|
|||
void KTraderParse_initFlex( const char *s, yyscan_t _scanner );
|
||||
|
||||
|
||||
#line 90 "yacc.c" /* yacc.c:339 */
|
||||
|
||||
#line 94 "yacc.c" /* yacc.c:337 */
|
||||
# ifndef YY_NULLPTR
|
||||
# if defined __cplusplus && 201103L <= __cplusplus
|
||||
# define YY_NULLPTR nullptr
|
||||
# if defined __cplusplus
|
||||
# if 201103L <= __cplusplus
|
||||
# define YY_NULLPTR nullptr
|
||||
# else
|
||||
# define YY_NULLPTR 0
|
||||
# endif
|
||||
# else
|
||||
# define YY_NULLPTR 0
|
||||
# define YY_NULLPTR ((void*)0)
|
||||
# endif
|
||||
# endif
|
||||
|
||||
|
@ -153,7 +160,7 @@ extern int kiotraderdebug;
|
|||
|
||||
union YYSTYPE
|
||||
{
|
||||
#line 20 "yacc.y" /* yacc.c:355 */
|
||||
#line 20 "yacc.y" /* yacc.c:352 */
|
||||
|
||||
char valb;
|
||||
int vali;
|
||||
|
@ -161,7 +168,7 @@ union YYSTYPE
|
|||
char *name;
|
||||
void *ptr;
|
||||
|
||||
#line 165 "yacc.c" /* yacc.c:355 */
|
||||
#line 172 "yacc.c" /* yacc.c:352 */
|
||||
};
|
||||
|
||||
typedef union YYSTYPE YYSTYPE;
|
||||
|
@ -175,9 +182,7 @@ int kiotraderparse (void *_scanner);
|
|||
|
||||
#endif /* !YY_KIOTRADER_YACC_H_INCLUDED */
|
||||
|
||||
/* Copy the second part of user declarations. */
|
||||
|
||||
#line 181 "yacc.c" /* yacc.c:358 */
|
||||
|
||||
#ifdef short
|
||||
# undef short
|
||||
|
@ -198,13 +203,13 @@ typedef signed char yytype_int8;
|
|||
#ifdef YYTYPE_UINT16
|
||||
typedef YYTYPE_UINT16 yytype_uint16;
|
||||
#else
|
||||
typedef unsigned short int yytype_uint16;
|
||||
typedef unsigned short yytype_uint16;
|
||||
#endif
|
||||
|
||||
#ifdef YYTYPE_INT16
|
||||
typedef YYTYPE_INT16 yytype_int16;
|
||||
#else
|
||||
typedef short int yytype_int16;
|
||||
typedef short yytype_int16;
|
||||
#endif
|
||||
|
||||
#ifndef YYSIZE_T
|
||||
|
@ -216,7 +221,7 @@ typedef short int yytype_int16;
|
|||
# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
|
||||
# define YYSIZE_T size_t
|
||||
# else
|
||||
# define YYSIZE_T unsigned int
|
||||
# define YYSIZE_T unsigned
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
@ -252,15 +257,6 @@ typedef short int yytype_int16;
|
|||
# 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))
|
||||
|
@ -268,7 +264,7 @@ typedef short int yytype_int16;
|
|||
# define YYUSE(E) /* empty */
|
||||
#endif
|
||||
|
||||
#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
|
||||
#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
|
||||
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
|
||||
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
|
||||
_Pragma ("GCC diagnostic push") \
|
||||
|
@ -430,16 +426,16 @@ union yyalloc
|
|||
/* YYNSTATES -- Number of states. */
|
||||
#define YYNSTATES 69
|
||||
|
||||
/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned
|
||||
by yylex, with out-of-bounds checking. */
|
||||
#define YYUNDEFTOK 2
|
||||
#define YYMAXUTOK 281
|
||||
|
||||
/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
|
||||
as returned by yylex, with out-of-bounds checking. */
|
||||
#define YYTRANSLATE(YYX) \
|
||||
((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
|
||||
((unsigned) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
|
||||
|
||||
/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
|
||||
as returned by yylex, without out-of-bounds checking. */
|
||||
as returned by yylex. */
|
||||
static const yytype_uint8 yytranslate[] =
|
||||
{
|
||||
0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
||||
|
@ -635,22 +631,22 @@ static const yytype_uint8 yyr2[] =
|
|||
|
||||
#define YYRECOVERING() (!!yyerrstatus)
|
||||
|
||||
#define YYBACKUP(Token, Value) \
|
||||
do \
|
||||
if (yychar == YYEMPTY) \
|
||||
{ \
|
||||
yychar = (Token); \
|
||||
yylval = (Value); \
|
||||
YYPOPSTACK (yylen); \
|
||||
yystate = *yyssp; \
|
||||
goto yybackup; \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
yyerror (_scanner, YY_("syntax error: cannot back up")); \
|
||||
YYERROR; \
|
||||
} \
|
||||
while (0)
|
||||
#define YYBACKUP(Token, Value) \
|
||||
do \
|
||||
if (yychar == YYEMPTY) \
|
||||
{ \
|
||||
yychar = (Token); \
|
||||
yylval = (Value); \
|
||||
YYPOPSTACK (yylen); \
|
||||
yystate = *yyssp; \
|
||||
goto yybackup; \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
yyerror (_scanner, YY_("syntax error: cannot back up")); \
|
||||
YYERROR; \
|
||||
} \
|
||||
while (0)
|
||||
|
||||
/* Error token number */
|
||||
#define YYTERROR 1
|
||||
|
@ -690,38 +686,38 @@ do { \
|
|||
} while (0)
|
||||
|
||||
|
||||
/*----------------------------------------.
|
||||
| Print this symbol's value on YYOUTPUT. |
|
||||
`----------------------------------------*/
|
||||
/*-----------------------------------.
|
||||
| Print this symbol's value on YYO. |
|
||||
`-----------------------------------*/
|
||||
|
||||
static void
|
||||
yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
{
|
||||
FILE *yyo = yyoutput;
|
||||
YYUSE (yyo);
|
||||
FILE *yyoutput = yyo;
|
||||
YYUSE (yyoutput);
|
||||
YYUSE (_scanner);
|
||||
if (!yyvaluep)
|
||||
return;
|
||||
# ifdef YYPRINT
|
||||
if (yytype < YYNTOKENS)
|
||||
YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
|
||||
YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
|
||||
# endif
|
||||
YYUSE (yytype);
|
||||
}
|
||||
|
||||
|
||||
/*--------------------------------.
|
||||
| Print this symbol on YYOUTPUT. |
|
||||
`--------------------------------*/
|
||||
/*---------------------------.
|
||||
| Print this symbol on YYO. |
|
||||
`---------------------------*/
|
||||
|
||||
static void
|
||||
yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
{
|
||||
YYFPRINTF (yyoutput, "%s %s (",
|
||||
YYFPRINTF (yyo, "%s %s (",
|
||||
yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
|
||||
|
||||
yy_symbol_value_print (yyoutput, yytype, yyvaluep, _scanner);
|
||||
YYFPRINTF (yyoutput, ")");
|
||||
yy_symbol_value_print (yyo, yytype, yyvaluep, _scanner);
|
||||
YYFPRINTF (yyo, ")");
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------.
|
||||
|
@ -755,7 +751,7 @@ do { \
|
|||
static void
|
||||
yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule, void *_scanner)
|
||||
{
|
||||
unsigned long int yylno = yyrline[yyrule];
|
||||
unsigned long yylno = yyrline[yyrule];
|
||||
int yynrhs = yyr2[yyrule];
|
||||
int yyi;
|
||||
YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
|
||||
|
@ -766,7 +762,7 @@ yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule, void *_scanner
|
|||
YYFPRINTF (stderr, " $%d = ", yyi + 1);
|
||||
yy_symbol_print (stderr,
|
||||
yystos[yyssp[yyi + 1 - yynrhs]],
|
||||
&(yyvsp[(yyi + 1) - (yynrhs)])
|
||||
&yyvsp[(yyi + 1) - (yynrhs)]
|
||||
, _scanner);
|
||||
YYFPRINTF (stderr, "\n");
|
||||
}
|
||||
|
@ -870,7 +866,10 @@ yytnamerr (char *yyres, const char *yystr)
|
|||
case '\\':
|
||||
if (*++yyp != '\\')
|
||||
goto do_not_strip_quotes;
|
||||
/* Fall through. */
|
||||
else
|
||||
goto append;
|
||||
|
||||
append:
|
||||
default:
|
||||
if (yyres)
|
||||
yyres[yyn] = *yyp;
|
||||
|
@ -888,7 +887,7 @@ yytnamerr (char *yyres, const char *yystr)
|
|||
if (! yyres)
|
||||
return yystrlen (yystr);
|
||||
|
||||
return yystpcpy (yyres, yystr) - yyres;
|
||||
return (YYSIZE_T) (yystpcpy (yyres, yystr) - yyres);
|
||||
}
|
||||
# endif
|
||||
|
||||
|
@ -966,10 +965,10 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
|
|||
yyarg[yycount++] = yytname[yyx];
|
||||
{
|
||||
YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
|
||||
if (! (yysize <= yysize1
|
||||
&& yysize1 <= YYSTACK_ALLOC_MAXIMUM))
|
||||
if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
|
||||
yysize = yysize1;
|
||||
else
|
||||
return 2;
|
||||
yysize = yysize1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -993,9 +992,10 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
|
|||
|
||||
{
|
||||
YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
|
||||
if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
|
||||
if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
|
||||
yysize = yysize1;
|
||||
else
|
||||
return 2;
|
||||
yysize = yysize1;
|
||||
}
|
||||
|
||||
if (*yymsg_alloc < yysize)
|
||||
|
@ -1045,61 +1045,60 @@ yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, void *_scanner)
|
|||
YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
|
||||
switch (yytype)
|
||||
{
|
||||
case 37: /* bool_or */
|
||||
#line 68 "yacc.y" /* yacc.c:1258 */
|
||||
case 37: /* bool_or */
|
||||
#line 68 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1052 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1052 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 38: /* bool_and */
|
||||
#line 69 "yacc.y" /* yacc.c:1258 */
|
||||
#line 69 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1058 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1058 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 39: /* bool_compare */
|
||||
#line 70 "yacc.y" /* yacc.c:1258 */
|
||||
#line 70 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1064 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1064 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 40: /* expr_in */
|
||||
#line 71 "yacc.y" /* yacc.c:1258 */
|
||||
#line 71 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1070 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1070 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 41: /* expr_twiddle */
|
||||
#line 72 "yacc.y" /* yacc.c:1258 */
|
||||
#line 72 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1076 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1076 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 42: /* expr */
|
||||
#line 73 "yacc.y" /* yacc.c:1258 */
|
||||
#line 73 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1082 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1082 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 43: /* term */
|
||||
#line 74 "yacc.y" /* yacc.c:1258 */
|
||||
#line 74 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1088 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1088 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 44: /* factor_non */
|
||||
#line 75 "yacc.y" /* yacc.c:1258 */
|
||||
#line 75 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1094 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1094 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 45: /* factor */
|
||||
#line 76 "yacc.y" /* yacc.c:1258 */
|
||||
#line 76 "yacc.y" /* yacc.c:1257 */
|
||||
{ KTraderParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1100 "yacc.c" /* yacc.c:1258 */
|
||||
#line 1100 "yacc.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -1185,23 +1184,31 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
yychar = YYEMPTY; /* Cause a token to be read. */
|
||||
goto yysetstate;
|
||||
|
||||
|
||||
/*------------------------------------------------------------.
|
||||
| yynewstate -- Push a new state, which is found in yystate. |
|
||||
| yynewstate -- push a new state, which is found in yystate. |
|
||||
`------------------------------------------------------------*/
|
||||
yynewstate:
|
||||
yynewstate:
|
||||
/* In all cases, when you get here, the value and location stacks
|
||||
have just been pushed. So pushing a state here evens the stacks. */
|
||||
yyssp++;
|
||||
|
||||
yysetstate:
|
||||
*yyssp = yystate;
|
||||
|
||||
/*--------------------------------------------------------------------.
|
||||
| yynewstate -- set current state (the top of the stack) to yystate. |
|
||||
`--------------------------------------------------------------------*/
|
||||
yysetstate:
|
||||
*yyssp = (yytype_int16) yystate;
|
||||
|
||||
if (yyss + yystacksize - 1 <= yyssp)
|
||||
#if !defined yyoverflow && !defined YYSTACK_RELOCATE
|
||||
goto yyexhaustedlab;
|
||||
#else
|
||||
{
|
||||
/* Get the current used size of the three stacks, in elements. */
|
||||
YYSIZE_T yysize = yyssp - yyss + 1;
|
||||
YYSIZE_T yysize = (YYSIZE_T) (yyssp - yyss + 1);
|
||||
|
||||
#ifdef yyoverflow
|
||||
# if defined yyoverflow
|
||||
{
|
||||
/* Give user a chance to reallocate the stack. Use copies of
|
||||
these so that the &'s don't force the real ones into
|
||||
|
@ -1217,14 +1224,10 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
&yyss1, yysize * sizeof (*yyssp),
|
||||
&yyvs1, yysize * sizeof (*yyvsp),
|
||||
&yystacksize);
|
||||
|
||||
yyss = yyss1;
|
||||
yyvs = yyvs1;
|
||||
}
|
||||
#else /* no yyoverflow */
|
||||
# ifndef YYSTACK_RELOCATE
|
||||
goto yyexhaustedlab;
|
||||
# else
|
||||
# else /* defined YYSTACK_RELOCATE */
|
||||
/* Extend the stack our own way. */
|
||||
if (YYMAXDEPTH <= yystacksize)
|
||||
goto yyexhaustedlab;
|
||||
|
@ -1240,22 +1243,22 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
goto yyexhaustedlab;
|
||||
YYSTACK_RELOCATE (yyss_alloc, yyss);
|
||||
YYSTACK_RELOCATE (yyvs_alloc, yyvs);
|
||||
# undef YYSTACK_RELOCATE
|
||||
# undef YYSTACK_RELOCATE
|
||||
if (yyss1 != yyssa)
|
||||
YYSTACK_FREE (yyss1);
|
||||
}
|
||||
# endif
|
||||
#endif /* no yyoverflow */
|
||||
|
||||
yyssp = yyss + yysize - 1;
|
||||
yyvsp = yyvs + yysize - 1;
|
||||
|
||||
YYDPRINTF ((stderr, "Stack size increased to %lu\n",
|
||||
(unsigned long int) yystacksize));
|
||||
(unsigned long) yystacksize));
|
||||
|
||||
if (yyss + yystacksize - 1 <= yyssp)
|
||||
YYABORT;
|
||||
}
|
||||
#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
|
||||
|
||||
YYDPRINTF ((stderr, "Entering state %d\n", yystate));
|
||||
|
||||
|
@ -1264,11 +1267,11 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
|
||||
goto yybackup;
|
||||
|
||||
|
||||
/*-----------.
|
||||
| yybackup. |
|
||||
`-----------*/
|
||||
yybackup:
|
||||
|
||||
/* Do appropriate processing given the current state. Read a
|
||||
lookahead token if we need one and don't already have one. */
|
||||
|
||||
|
@ -1341,7 +1344,7 @@ yydefault:
|
|||
|
||||
|
||||
/*-----------------------------.
|
||||
| yyreduce -- Do a reduction. |
|
||||
| yyreduce -- do a reduction. |
|
||||
`-----------------------------*/
|
||||
yyreduce:
|
||||
/* yyn is the number of a rule to reduce with. */
|
||||
|
@ -1362,253 +1365,253 @@ yyreduce:
|
|||
switch (yyn)
|
||||
{
|
||||
case 2:
|
||||
#line 84 "yacc.y" /* yacc.c:1648 */
|
||||
#line 84 "yacc.y" /* yacc.c:1652 */
|
||||
{ KTraderParse_setParseTree( 0L ); }
|
||||
#line 1368 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1371 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 3:
|
||||
#line 85 "yacc.y" /* yacc.c:1648 */
|
||||
#line 85 "yacc.y" /* yacc.c:1652 */
|
||||
{ KTraderParse_setParseTree( (yyvsp[0].ptr) ); }
|
||||
#line 1374 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1377 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 4:
|
||||
#line 88 "yacc.y" /* yacc.c:1648 */
|
||||
#line 88 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1380 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1383 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 5:
|
||||
#line 91 "yacc.y" /* yacc.c:1648 */
|
||||
#line 91 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newOR( (yyvsp[-2].ptr), (yyvsp[0].ptr) ); }
|
||||
#line 1386 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1389 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 6:
|
||||
#line 92 "yacc.y" /* yacc.c:1648 */
|
||||
#line 92 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1392 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1395 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 7:
|
||||
#line 95 "yacc.y" /* yacc.c:1648 */
|
||||
#line 95 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newAND( (yyvsp[-2].ptr), (yyvsp[0].ptr) ); }
|
||||
#line 1398 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1401 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 8:
|
||||
#line 96 "yacc.y" /* yacc.c:1648 */
|
||||
#line 96 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1404 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1407 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 9:
|
||||
#line 99 "yacc.y" /* yacc.c:1648 */
|
||||
#line 99 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 1 ); }
|
||||
#line 1410 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1413 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 10:
|
||||
#line 100 "yacc.y" /* yacc.c:1648 */
|
||||
#line 100 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 7 ); }
|
||||
#line 1416 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1419 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 11:
|
||||
#line 101 "yacc.y" /* yacc.c:1648 */
|
||||
#line 101 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 2 ); }
|
||||
#line 1422 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1425 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 12:
|
||||
#line 102 "yacc.y" /* yacc.c:1648 */
|
||||
#line 102 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 8 ); }
|
||||
#line 1428 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1431 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 13:
|
||||
#line 103 "yacc.y" /* yacc.c:1648 */
|
||||
#line 103 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 3 ); }
|
||||
#line 1434 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1437 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 14:
|
||||
#line 104 "yacc.y" /* yacc.c:1648 */
|
||||
#line 104 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 4 ); }
|
||||
#line 1440 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1443 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 15:
|
||||
#line 105 "yacc.y" /* yacc.c:1648 */
|
||||
#line 105 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 5 ); }
|
||||
#line 1446 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1449 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 16:
|
||||
#line 106 "yacc.y" /* yacc.c:1648 */
|
||||
#line 106 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCMP( (yyvsp[-2].ptr), (yyvsp[0].ptr), 6 ); }
|
||||
#line 1452 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1455 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 17:
|
||||
#line 107 "yacc.y" /* yacc.c:1648 */
|
||||
#line 107 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1458 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1461 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 18:
|
||||
#line 110 "yacc.y" /* yacc.c:1648 */
|
||||
#line 110 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newIN( (yyvsp[-2].ptr), KTraderParse_newID( (yyvsp[0].name) ), 1 ); }
|
||||
#line 1464 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1467 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 19:
|
||||
#line 111 "yacc.y" /* yacc.c:1648 */
|
||||
#line 111 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newIN( (yyvsp[-2].ptr), KTraderParse_newID( (yyvsp[0].name) ), 0 ); }
|
||||
#line 1470 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1473 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 20:
|
||||
#line 112 "yacc.y" /* yacc.c:1648 */
|
||||
#line 112 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newSubstringIN( (yyvsp[-2].ptr), KTraderParse_newID( (yyvsp[0].name) ), 1 ); }
|
||||
#line 1476 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1479 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 21:
|
||||
#line 113 "yacc.y" /* yacc.c:1648 */
|
||||
#line 113 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newSubstringIN( (yyvsp[-2].ptr), KTraderParse_newID( (yyvsp[0].name) ), 0 ); }
|
||||
#line 1482 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1485 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 22:
|
||||
#line 114 "yacc.y" /* yacc.c:1648 */
|
||||
#line 114 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1488 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1491 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 23:
|
||||
#line 117 "yacc.y" /* yacc.c:1648 */
|
||||
#line 117 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newMATCH( (yyvsp[-2].ptr), (yyvsp[0].ptr), 1 ); }
|
||||
#line 1494 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1497 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 24:
|
||||
#line 118 "yacc.y" /* yacc.c:1648 */
|
||||
#line 118 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newMATCH( (yyvsp[-2].ptr), (yyvsp[0].ptr), 0 ); }
|
||||
#line 1500 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1503 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 25:
|
||||
#line 119 "yacc.y" /* yacc.c:1648 */
|
||||
#line 119 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1506 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1509 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 26:
|
||||
#line 122 "yacc.y" /* yacc.c:1648 */
|
||||
#line 122 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCALC( (yyvsp[-2].ptr), (yyvsp[0].ptr), 1 ); }
|
||||
#line 1512 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1515 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 27:
|
||||
#line 123 "yacc.y" /* yacc.c:1648 */
|
||||
#line 123 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCALC( (yyvsp[-2].ptr), (yyvsp[0].ptr), 2 ); }
|
||||
#line 1518 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1521 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 28:
|
||||
#line 124 "yacc.y" /* yacc.c:1648 */
|
||||
#line 124 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1524 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1527 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 29:
|
||||
#line 127 "yacc.y" /* yacc.c:1648 */
|
||||
#line 127 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCALC( (yyvsp[-2].ptr), (yyvsp[0].ptr), 3 ); }
|
||||
#line 1530 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1533 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 30:
|
||||
#line 128 "yacc.y" /* yacc.c:1648 */
|
||||
#line 128 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newCALC( (yyvsp[-2].ptr), (yyvsp[0].ptr), 4 ); }
|
||||
#line 1536 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1539 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 31:
|
||||
#line 129 "yacc.y" /* yacc.c:1648 */
|
||||
#line 129 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1542 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1545 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 32:
|
||||
#line 132 "yacc.y" /* yacc.c:1648 */
|
||||
#line 132 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newNOT( (yyvsp[0].ptr) ); }
|
||||
#line 1548 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1551 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 33:
|
||||
#line 133 "yacc.y" /* yacc.c:1648 */
|
||||
#line 133 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1554 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1557 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 34:
|
||||
#line 136 "yacc.y" /* yacc.c:1648 */
|
||||
#line 136 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newBRACKETS( (yyvsp[-1].ptr) ); }
|
||||
#line 1560 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1563 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 35:
|
||||
#line 137 "yacc.y" /* yacc.c:1648 */
|
||||
#line 137 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newEXIST( (yyvsp[0].name) ); }
|
||||
#line 1566 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1569 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 36:
|
||||
#line 138 "yacc.y" /* yacc.c:1648 */
|
||||
#line 138 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newID( (yyvsp[0].name) ); }
|
||||
#line 1572 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1575 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 37:
|
||||
#line 139 "yacc.y" /* yacc.c:1648 */
|
||||
#line 139 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newNUM( (yyvsp[0].vali) ); }
|
||||
#line 1578 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1581 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 38:
|
||||
#line 140 "yacc.y" /* yacc.c:1648 */
|
||||
#line 140 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newFLOAT( (yyvsp[0].vald) ); }
|
||||
#line 1584 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1587 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 39:
|
||||
#line 141 "yacc.y" /* yacc.c:1648 */
|
||||
#line 141 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newSTRING( (yyvsp[0].name) ); }
|
||||
#line 1590 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1593 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 40:
|
||||
#line 142 "yacc.y" /* yacc.c:1648 */
|
||||
#line 142 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newBOOL( (yyvsp[0].valb) ); }
|
||||
#line 1596 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1599 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 41:
|
||||
#line 143 "yacc.y" /* yacc.c:1648 */
|
||||
#line 143 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newMAX2( (yyvsp[0].name) ); }
|
||||
#line 1602 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1605 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 42:
|
||||
#line 144 "yacc.y" /* yacc.c:1648 */
|
||||
#line 144 "yacc.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = KTraderParse_newMIN2( (yyvsp[0].name) ); }
|
||||
#line 1608 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1611 "yacc.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
|
||||
#line 1612 "yacc.c" /* yacc.c:1648 */
|
||||
#line 1615 "yacc.c" /* yacc.c:1652 */
|
||||
default: break;
|
||||
}
|
||||
/* User semantic actions sometimes alter yychar, and that requires
|
||||
|
@ -1633,14 +1636,13 @@ yyreduce:
|
|||
/* Now 'shift' the result of the reduction. Determine what state
|
||||
that goes to, based on the state we popped back to and the rule
|
||||
number reduced by. */
|
||||
|
||||
yyn = yyr1[yyn];
|
||||
|
||||
yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
|
||||
if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
|
||||
yystate = yytable[yystate];
|
||||
else
|
||||
yystate = yydefgoto[yyn - YYNTOKENS];
|
||||
{
|
||||
const int yylhs = yyr1[yyn] - YYNTOKENS;
|
||||
const int yyi = yypgoto[yylhs] + *yyssp;
|
||||
yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
|
||||
? yytable[yyi]
|
||||
: yydefgoto[yylhs]);
|
||||
}
|
||||
|
||||
goto yynewstate;
|
||||
|
||||
|
@ -1723,12 +1725,10 @@ yyerrlab:
|
|||
| yyerrorlab -- error raised explicitly by YYERROR. |
|
||||
`---------------------------------------------------*/
|
||||
yyerrorlab:
|
||||
|
||||
/* Pacify compilers like GCC when the user code never invokes
|
||||
YYERROR and the label yyerrorlab therefore never appears in user
|
||||
code. */
|
||||
if (/*CONSTCOND*/ 0)
|
||||
goto yyerrorlab;
|
||||
/* Pacify compilers when the user code never invokes YYERROR and the
|
||||
label yyerrorlab therefore never appears in user code. */
|
||||
if (0)
|
||||
YYERROR;
|
||||
|
||||
/* Do not reclaim the symbols of the rule whose action triggered
|
||||
this YYERROR. */
|
||||
|
@ -1790,6 +1790,7 @@ yyacceptlab:
|
|||
yyresult = 0;
|
||||
goto yyreturn;
|
||||
|
||||
|
||||
/*-----------------------------------.
|
||||
| yyabortlab -- YYABORT comes here. |
|
||||
`-----------------------------------*/
|
||||
|
@ -1797,6 +1798,7 @@ yyabortlab:
|
|||
yyresult = 1;
|
||||
goto yyreturn;
|
||||
|
||||
|
||||
#if !defined yyoverflow || YYERROR_VERBOSE
|
||||
/*-------------------------------------------------.
|
||||
| yyexhaustedlab -- memory exhaustion comes here. |
|
||||
|
@ -1807,6 +1809,10 @@ yyexhaustedlab:
|
|||
/* Fall through. */
|
||||
#endif
|
||||
|
||||
|
||||
/*-----------------------------------------------------.
|
||||
| yyreturn -- parsing is finished, return the result. |
|
||||
`-----------------------------------------------------*/
|
||||
yyreturn:
|
||||
if (yychar != YYEMPTY)
|
||||
{
|
||||
|
@ -1836,7 +1842,7 @@ yyreturn:
|
|||
#endif
|
||||
return yyresult;
|
||||
}
|
||||
#line 149 "yacc.y" /* yacc.c:1907 */
|
||||
#line 149 "yacc.y" /* yacc.c:1918 */
|
||||
|
||||
|
||||
void yyerror ( void *_scanner, const char *s ) /* Called by yyparse on error */
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
/* A Bison parser, made by GNU Bison 3.0.5. */
|
||||
/* A Bison parser, made by GNU Bison 3.3.2. */
|
||||
|
||||
/* Bison interface for Yacc-like parsers in C
|
||||
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018 Free Software Foundation, Inc.
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 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
|
||||
|
@ -30,6 +31,9 @@
|
|||
This special exception was added by the Free Software Foundation in
|
||||
version 2.2 of Bison. */
|
||||
|
||||
/* Undocumented macros, especially those whose name start with YY_,
|
||||
are private implementation details. Do not rely on them. */
|
||||
|
||||
#ifndef YY_KIOTRADER_YACC_H_INCLUDED
|
||||
# define YY_KIOTRADER_YACC_H_INCLUDED
|
||||
/* Debug traces. */
|
||||
|
@ -77,7 +81,7 @@ extern int kiotraderdebug;
|
|||
|
||||
union YYSTYPE
|
||||
{
|
||||
#line 20 "yacc.y" /* yacc.c:1910 */
|
||||
#line 20 "yacc.y" /* yacc.c:1921 */
|
||||
|
||||
char valb;
|
||||
int vali;
|
||||
|
@ -85,7 +89,7 @@ union YYSTYPE
|
|||
char *name;
|
||||
void *ptr;
|
||||
|
||||
#line 89 "yacc.h" /* yacc.c:1910 */
|
||||
#line 93 "yacc.h" /* yacc.c:1921 */
|
||||
};
|
||||
|
||||
typedef union YYSTYPE YYSTYPE;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#line 1 "predicate_lexer.c"
|
||||
#line 2 "predicate_lexer.c"
|
||||
|
||||
#line 3 "predicate_lexer.c"
|
||||
#line 4 "predicate_lexer.c"
|
||||
|
||||
#define YY_INT_ALIGNED short int
|
||||
|
||||
|
@ -679,9 +679,9 @@ char *PredicateParse_putSymbol( char *_name );
|
|||
char *PredicateParse_putString( char *_str );
|
||||
void PredicateParse_initFlex( const char *_code, yyscan_t _scanner );
|
||||
|
||||
#line 682 "predicate_lexer.c"
|
||||
#line 683 "predicate_lexer.c"
|
||||
#define YY_NO_INPUT 1
|
||||
#line 684 "predicate_lexer.c"
|
||||
#line 685 "predicate_lexer.c"
|
||||
|
||||
#define INITIAL 0
|
||||
|
||||
|
@ -956,7 +956,7 @@ YY_DECL
|
|||
#line 27 "predicate_lexer.l"
|
||||
|
||||
|
||||
#line 959 "predicate_lexer.c"
|
||||
#line 960 "predicate_lexer.c"
|
||||
|
||||
while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
|
||||
{
|
||||
|
@ -1091,7 +1091,7 @@ YY_RULE_SETUP
|
|||
#line 54 "predicate_lexer.l"
|
||||
ECHO;
|
||||
YY_BREAK
|
||||
#line 1094 "predicate_lexer.c"
|
||||
#line 1095 "predicate_lexer.c"
|
||||
case YY_STATE_EOF(INITIAL):
|
||||
yyterminate();
|
||||
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
/* A Bison parser, made by GNU Bison 3.0.5. */
|
||||
/* A Bison parser, made by GNU Bison 3.3.2. */
|
||||
|
||||
/* Bison implementation for Yacc-like parsers in C
|
||||
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018 Free Software Foundation, Inc.
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 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
|
||||
|
@ -40,11 +41,14 @@
|
|||
define necessary library symbols; they are noted "INFRINGES ON
|
||||
USER NAME SPACE" below. */
|
||||
|
||||
/* Undocumented macros, especially those whose name start with YY_,
|
||||
are private implementation details. Do not rely on them. */
|
||||
|
||||
/* Identify Bison output. */
|
||||
#define YYBISON 1
|
||||
|
||||
/* Bison version. */
|
||||
#define YYBISON_VERSION "3.0.5"
|
||||
#define YYBISON_VERSION "3.3.2"
|
||||
|
||||
/* Skeleton name. */
|
||||
#define YYSKELETON_NAME "yacc.c"
|
||||
|
@ -67,8 +71,8 @@
|
|||
#define yynerrs Solidnerrs
|
||||
|
||||
|
||||
/* Copy the first part of user declarations. */
|
||||
#line 1 "predicate_parser.y" /* yacc.c:339 */
|
||||
/* First part of user prologue. */
|
||||
#line 1 "predicate_parser.y" /* yacc.c:337 */
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
|
@ -88,13 +92,16 @@ void PredicateParse_initLexer( const char *s, yyscan_t scanner );
|
|||
void PredicateParse_mainParse( const char *_code );
|
||||
|
||||
|
||||
#line 92 "predicate_parser.c" /* yacc.c:339 */
|
||||
|
||||
#line 96 "predicate_parser.c" /* yacc.c:337 */
|
||||
# ifndef YY_NULLPTR
|
||||
# if defined __cplusplus && 201103L <= __cplusplus
|
||||
# define YY_NULLPTR nullptr
|
||||
# if defined __cplusplus
|
||||
# if 201103L <= __cplusplus
|
||||
# define YY_NULLPTR nullptr
|
||||
# else
|
||||
# define YY_NULLPTR 0
|
||||
# endif
|
||||
# else
|
||||
# define YY_NULLPTR 0
|
||||
# define YY_NULLPTR ((void*)0)
|
||||
# endif
|
||||
# endif
|
||||
|
||||
|
@ -141,7 +148,7 @@ extern int Soliddebug;
|
|||
|
||||
union YYSTYPE
|
||||
{
|
||||
#line 22 "predicate_parser.y" /* yacc.c:355 */
|
||||
#line 22 "predicate_parser.y" /* yacc.c:352 */
|
||||
|
||||
char valb;
|
||||
int vali;
|
||||
|
@ -149,7 +156,7 @@ union YYSTYPE
|
|||
char *name;
|
||||
void *ptr;
|
||||
|
||||
#line 153 "predicate_parser.c" /* yacc.c:355 */
|
||||
#line 160 "predicate_parser.c" /* yacc.c:352 */
|
||||
};
|
||||
|
||||
typedef union YYSTYPE YYSTYPE;
|
||||
|
@ -163,9 +170,7 @@ int Solidparse (void *_scanner);
|
|||
|
||||
#endif /* !YY_SOLID_PREDICATE_PARSER_H_INCLUDED */
|
||||
|
||||
/* Copy the second part of user declarations. */
|
||||
|
||||
#line 169 "predicate_parser.c" /* yacc.c:358 */
|
||||
|
||||
#ifdef short
|
||||
# undef short
|
||||
|
@ -186,13 +191,13 @@ typedef signed char yytype_int8;
|
|||
#ifdef YYTYPE_UINT16
|
||||
typedef YYTYPE_UINT16 yytype_uint16;
|
||||
#else
|
||||
typedef unsigned short int yytype_uint16;
|
||||
typedef unsigned short yytype_uint16;
|
||||
#endif
|
||||
|
||||
#ifdef YYTYPE_INT16
|
||||
typedef YYTYPE_INT16 yytype_int16;
|
||||
#else
|
||||
typedef short int yytype_int16;
|
||||
typedef short yytype_int16;
|
||||
#endif
|
||||
|
||||
#ifndef YYSIZE_T
|
||||
|
@ -204,7 +209,7 @@ typedef short int yytype_int16;
|
|||
# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
|
||||
# define YYSIZE_T size_t
|
||||
# else
|
||||
# define YYSIZE_T unsigned int
|
||||
# define YYSIZE_T unsigned
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
@ -240,15 +245,6 @@ typedef short int yytype_int16;
|
|||
# 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))
|
||||
|
@ -256,7 +252,7 @@ typedef short int yytype_int16;
|
|||
# define YYUSE(E) /* empty */
|
||||
#endif
|
||||
|
||||
#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
|
||||
#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
|
||||
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
|
||||
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
|
||||
_Pragma ("GCC diagnostic push") \
|
||||
|
@ -418,16 +414,16 @@ union yyalloc
|
|||
/* YYNSTATES -- Number of states. */
|
||||
#define YYNSTATES 34
|
||||
|
||||
/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned
|
||||
by yylex, with out-of-bounds checking. */
|
||||
#define YYUNDEFTOK 2
|
||||
#define YYMAXUTOK 267
|
||||
|
||||
/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
|
||||
as returned by yylex, with out-of-bounds checking. */
|
||||
#define YYTRANSLATE(YYX) \
|
||||
((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
|
||||
((unsigned) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
|
||||
|
||||
/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
|
||||
as returned by yylex, without out-of-bounds checking. */
|
||||
as returned by yylex. */
|
||||
static const yytype_uint8 yytranslate[] =
|
||||
{
|
||||
0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
||||
|
@ -588,22 +584,22 @@ static const yytype_uint8 yyr2[] =
|
|||
|
||||
#define YYRECOVERING() (!!yyerrstatus)
|
||||
|
||||
#define YYBACKUP(Token, Value) \
|
||||
do \
|
||||
if (yychar == YYEMPTY) \
|
||||
{ \
|
||||
yychar = (Token); \
|
||||
yylval = (Value); \
|
||||
YYPOPSTACK (yylen); \
|
||||
yystate = *yyssp; \
|
||||
goto yybackup; \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
yyerror (_scanner, YY_("syntax error: cannot back up")); \
|
||||
YYERROR; \
|
||||
} \
|
||||
while (0)
|
||||
#define YYBACKUP(Token, Value) \
|
||||
do \
|
||||
if (yychar == YYEMPTY) \
|
||||
{ \
|
||||
yychar = (Token); \
|
||||
yylval = (Value); \
|
||||
YYPOPSTACK (yylen); \
|
||||
yystate = *yyssp; \
|
||||
goto yybackup; \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
yyerror (_scanner, YY_("syntax error: cannot back up")); \
|
||||
YYERROR; \
|
||||
} \
|
||||
while (0)
|
||||
|
||||
/* Error token number */
|
||||
#define YYTERROR 1
|
||||
|
@ -643,38 +639,38 @@ do { \
|
|||
} while (0)
|
||||
|
||||
|
||||
/*----------------------------------------.
|
||||
| Print this symbol's value on YYOUTPUT. |
|
||||
`----------------------------------------*/
|
||||
/*-----------------------------------.
|
||||
| Print this symbol's value on YYO. |
|
||||
`-----------------------------------*/
|
||||
|
||||
static void
|
||||
yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
{
|
||||
FILE *yyo = yyoutput;
|
||||
YYUSE (yyo);
|
||||
FILE *yyoutput = yyo;
|
||||
YYUSE (yyoutput);
|
||||
YYUSE (_scanner);
|
||||
if (!yyvaluep)
|
||||
return;
|
||||
# ifdef YYPRINT
|
||||
if (yytype < YYNTOKENS)
|
||||
YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
|
||||
YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
|
||||
# endif
|
||||
YYUSE (yytype);
|
||||
}
|
||||
|
||||
|
||||
/*--------------------------------.
|
||||
| Print this symbol on YYOUTPUT. |
|
||||
`--------------------------------*/
|
||||
/*---------------------------.
|
||||
| Print this symbol on YYO. |
|
||||
`---------------------------*/
|
||||
|
||||
static void
|
||||
yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, void *_scanner)
|
||||
{
|
||||
YYFPRINTF (yyoutput, "%s %s (",
|
||||
YYFPRINTF (yyo, "%s %s (",
|
||||
yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
|
||||
|
||||
yy_symbol_value_print (yyoutput, yytype, yyvaluep, _scanner);
|
||||
YYFPRINTF (yyoutput, ")");
|
||||
yy_symbol_value_print (yyo, yytype, yyvaluep, _scanner);
|
||||
YYFPRINTF (yyo, ")");
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------.
|
||||
|
@ -708,7 +704,7 @@ do { \
|
|||
static void
|
||||
yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule, void *_scanner)
|
||||
{
|
||||
unsigned long int yylno = yyrline[yyrule];
|
||||
unsigned long yylno = yyrline[yyrule];
|
||||
int yynrhs = yyr2[yyrule];
|
||||
int yyi;
|
||||
YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
|
||||
|
@ -719,7 +715,7 @@ yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule, void *_scanner
|
|||
YYFPRINTF (stderr, " $%d = ", yyi + 1);
|
||||
yy_symbol_print (stderr,
|
||||
yystos[yyssp[yyi + 1 - yynrhs]],
|
||||
&(yyvsp[(yyi + 1) - (yynrhs)])
|
||||
&yyvsp[(yyi + 1) - (yynrhs)]
|
||||
, _scanner);
|
||||
YYFPRINTF (stderr, "\n");
|
||||
}
|
||||
|
@ -823,7 +819,10 @@ yytnamerr (char *yyres, const char *yystr)
|
|||
case '\\':
|
||||
if (*++yyp != '\\')
|
||||
goto do_not_strip_quotes;
|
||||
/* Fall through. */
|
||||
else
|
||||
goto append;
|
||||
|
||||
append:
|
||||
default:
|
||||
if (yyres)
|
||||
yyres[yyn] = *yyp;
|
||||
|
@ -841,7 +840,7 @@ yytnamerr (char *yyres, const char *yystr)
|
|||
if (! yyres)
|
||||
return yystrlen (yystr);
|
||||
|
||||
return yystpcpy (yyres, yystr) - yyres;
|
||||
return (YYSIZE_T) (yystpcpy (yyres, yystr) - yyres);
|
||||
}
|
||||
# endif
|
||||
|
||||
|
@ -919,10 +918,10 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
|
|||
yyarg[yycount++] = yytname[yyx];
|
||||
{
|
||||
YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
|
||||
if (! (yysize <= yysize1
|
||||
&& yysize1 <= YYSTACK_ALLOC_MAXIMUM))
|
||||
if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
|
||||
yysize = yysize1;
|
||||
else
|
||||
return 2;
|
||||
yysize = yysize1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -946,9 +945,10 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
|
|||
|
||||
{
|
||||
YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
|
||||
if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
|
||||
if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
|
||||
yysize = yysize1;
|
||||
else
|
||||
return 2;
|
||||
yysize = yysize1;
|
||||
}
|
||||
|
||||
if (*yymsg_alloc < yysize)
|
||||
|
@ -998,31 +998,30 @@ yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, void *_scanner)
|
|||
YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
|
||||
switch (yytype)
|
||||
{
|
||||
case 20: /* predicate */
|
||||
#line 54 "predicate_parser.y" /* yacc.c:1258 */
|
||||
case 20: /* predicate */
|
||||
#line 54 "predicate_parser.y" /* yacc.c:1257 */
|
||||
{ PredicateParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1005 "predicate_parser.c" /* yacc.c:1258 */
|
||||
#line 1005 "predicate_parser.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 21: /* predicate_atom */
|
||||
#line 55 "predicate_parser.y" /* yacc.c:1258 */
|
||||
#line 55 "predicate_parser.y" /* yacc.c:1257 */
|
||||
{ PredicateParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1011 "predicate_parser.c" /* yacc.c:1258 */
|
||||
#line 1011 "predicate_parser.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 22: /* predicate_or */
|
||||
#line 56 "predicate_parser.y" /* yacc.c:1258 */
|
||||
#line 56 "predicate_parser.y" /* yacc.c:1257 */
|
||||
{ PredicateParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1017 "predicate_parser.c" /* yacc.c:1258 */
|
||||
#line 1017 "predicate_parser.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
case 23: /* predicate_and */
|
||||
#line 57 "predicate_parser.y" /* yacc.c:1258 */
|
||||
#line 57 "predicate_parser.y" /* yacc.c:1257 */
|
||||
{ PredicateParse_destroy( ((*yyvaluep).ptr) ); }
|
||||
#line 1023 "predicate_parser.c" /* yacc.c:1258 */
|
||||
#line 1023 "predicate_parser.c" /* yacc.c:1257 */
|
||||
break;
|
||||
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -1108,23 +1107,31 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
yychar = YYEMPTY; /* Cause a token to be read. */
|
||||
goto yysetstate;
|
||||
|
||||
|
||||
/*------------------------------------------------------------.
|
||||
| yynewstate -- Push a new state, which is found in yystate. |
|
||||
| yynewstate -- push a new state, which is found in yystate. |
|
||||
`------------------------------------------------------------*/
|
||||
yynewstate:
|
||||
yynewstate:
|
||||
/* In all cases, when you get here, the value and location stacks
|
||||
have just been pushed. So pushing a state here evens the stacks. */
|
||||
yyssp++;
|
||||
|
||||
yysetstate:
|
||||
*yyssp = yystate;
|
||||
|
||||
/*--------------------------------------------------------------------.
|
||||
| yynewstate -- set current state (the top of the stack) to yystate. |
|
||||
`--------------------------------------------------------------------*/
|
||||
yysetstate:
|
||||
*yyssp = (yytype_int16) yystate;
|
||||
|
||||
if (yyss + yystacksize - 1 <= yyssp)
|
||||
#if !defined yyoverflow && !defined YYSTACK_RELOCATE
|
||||
goto yyexhaustedlab;
|
||||
#else
|
||||
{
|
||||
/* Get the current used size of the three stacks, in elements. */
|
||||
YYSIZE_T yysize = yyssp - yyss + 1;
|
||||
YYSIZE_T yysize = (YYSIZE_T) (yyssp - yyss + 1);
|
||||
|
||||
#ifdef yyoverflow
|
||||
# if defined yyoverflow
|
||||
{
|
||||
/* Give user a chance to reallocate the stack. Use copies of
|
||||
these so that the &'s don't force the real ones into
|
||||
|
@ -1140,14 +1147,10 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
&yyss1, yysize * sizeof (*yyssp),
|
||||
&yyvs1, yysize * sizeof (*yyvsp),
|
||||
&yystacksize);
|
||||
|
||||
yyss = yyss1;
|
||||
yyvs = yyvs1;
|
||||
}
|
||||
#else /* no yyoverflow */
|
||||
# ifndef YYSTACK_RELOCATE
|
||||
goto yyexhaustedlab;
|
||||
# else
|
||||
# else /* defined YYSTACK_RELOCATE */
|
||||
/* Extend the stack our own way. */
|
||||
if (YYMAXDEPTH <= yystacksize)
|
||||
goto yyexhaustedlab;
|
||||
|
@ -1163,22 +1166,22 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
goto yyexhaustedlab;
|
||||
YYSTACK_RELOCATE (yyss_alloc, yyss);
|
||||
YYSTACK_RELOCATE (yyvs_alloc, yyvs);
|
||||
# undef YYSTACK_RELOCATE
|
||||
# undef YYSTACK_RELOCATE
|
||||
if (yyss1 != yyssa)
|
||||
YYSTACK_FREE (yyss1);
|
||||
}
|
||||
# endif
|
||||
#endif /* no yyoverflow */
|
||||
|
||||
yyssp = yyss + yysize - 1;
|
||||
yyvsp = yyvs + yysize - 1;
|
||||
|
||||
YYDPRINTF ((stderr, "Stack size increased to %lu\n",
|
||||
(unsigned long int) yystacksize));
|
||||
(unsigned long) yystacksize));
|
||||
|
||||
if (yyss + yystacksize - 1 <= yyssp)
|
||||
YYABORT;
|
||||
}
|
||||
#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
|
||||
|
||||
YYDPRINTF ((stderr, "Entering state %d\n", yystate));
|
||||
|
||||
|
@ -1187,11 +1190,11 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
|
|||
|
||||
goto yybackup;
|
||||
|
||||
|
||||
/*-----------.
|
||||
| yybackup. |
|
||||
`-----------*/
|
||||
yybackup:
|
||||
|
||||
/* Do appropriate processing given the current state. Read a
|
||||
lookahead token if we need one and don't already have one. */
|
||||
|
||||
|
@ -1264,7 +1267,7 @@ yydefault:
|
|||
|
||||
|
||||
/*-----------------------------.
|
||||
| yyreduce -- Do a reduction. |
|
||||
| yyreduce -- do a reduction. |
|
||||
`-----------------------------*/
|
||||
yyreduce:
|
||||
/* yyn is the number of a rule to reduce with. */
|
||||
|
@ -1285,109 +1288,109 @@ yyreduce:
|
|||
switch (yyn)
|
||||
{
|
||||
case 2:
|
||||
#line 63 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 63 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ PredicateParse_setResult( (yyvsp[0].ptr) ); (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1291 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1294 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 3:
|
||||
#line 64 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 64 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ PredicateParse_setResult( (yyvsp[-1].ptr) ); (yyval.ptr) = (yyvsp[-1].ptr); }
|
||||
#line 1297 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1300 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 4:
|
||||
#line 65 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 65 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ PredicateParse_setResult( (yyvsp[-1].ptr) ); (yyval.ptr) = (yyvsp[-1].ptr); }
|
||||
#line 1303 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1306 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 5:
|
||||
#line 67 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 67 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newAtom( (yyvsp[-4].name), (yyvsp[-2].name), (yyvsp[0].ptr) ); }
|
||||
#line 1309 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1312 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 6:
|
||||
#line 68 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 68 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newMaskAtom( (yyvsp[-4].name), (yyvsp[-2].name), (yyvsp[0].ptr) ); }
|
||||
#line 1315 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1318 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 7:
|
||||
#line 69 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 69 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newIsAtom( (yyvsp[0].name) ); }
|
||||
#line 1321 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1324 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 8:
|
||||
#line 71 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 71 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newOr( (yyvsp[-2].ptr), (yyvsp[0].ptr) ); }
|
||||
#line 1327 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1330 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 9:
|
||||
#line 73 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 73 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newAnd( (yyvsp[-2].ptr), (yyvsp[0].ptr) ); }
|
||||
#line 1333 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1336 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 10:
|
||||
#line 75 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 75 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newStringValue( (yyvsp[0].name) ); }
|
||||
#line 1339 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1342 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 11:
|
||||
#line 76 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 76 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newBoolValue( (yyvsp[0].valb) ); }
|
||||
#line 1345 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1348 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 12:
|
||||
#line 77 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 77 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newNumValue( (yyvsp[0].vali) ); }
|
||||
#line 1351 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1354 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 13:
|
||||
#line 78 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 78 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newDoubleValue( (yyvsp[0].vald) ); }
|
||||
#line 1357 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1360 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 14:
|
||||
#line 79 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 79 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[0].ptr); }
|
||||
#line 1363 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1366 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 15:
|
||||
#line 81 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 81 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = (yyvsp[-2].ptr); }
|
||||
#line 1369 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1372 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 16:
|
||||
#line 83 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 83 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newEmptyStringListValue(); }
|
||||
#line 1375 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1378 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 17:
|
||||
#line 84 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 84 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_newStringListValue( (yyvsp[0].ptr) ); }
|
||||
#line 1381 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1384 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
case 18:
|
||||
#line 85 "predicate_parser.y" /* yacc.c:1648 */
|
||||
#line 85 "predicate_parser.y" /* yacc.c:1652 */
|
||||
{ (yyval.ptr) = PredicateParse_appendStringListValue( (yyvsp[-2].name), (yyvsp[0].ptr) ); }
|
||||
#line 1387 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1390 "predicate_parser.c" /* yacc.c:1652 */
|
||||
break;
|
||||
|
||||
|
||||
#line 1391 "predicate_parser.c" /* yacc.c:1648 */
|
||||
#line 1394 "predicate_parser.c" /* yacc.c:1652 */
|
||||
default: break;
|
||||
}
|
||||
/* User semantic actions sometimes alter yychar, and that requires
|
||||
|
@ -1412,14 +1415,13 @@ yyreduce:
|
|||
/* Now 'shift' the result of the reduction. Determine what state
|
||||
that goes to, based on the state we popped back to and the rule
|
||||
number reduced by. */
|
||||
|
||||
yyn = yyr1[yyn];
|
||||
|
||||
yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
|
||||
if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
|
||||
yystate = yytable[yystate];
|
||||
else
|
||||
yystate = yydefgoto[yyn - YYNTOKENS];
|
||||
{
|
||||
const int yylhs = yyr1[yyn] - YYNTOKENS;
|
||||
const int yyi = yypgoto[yylhs] + *yyssp;
|
||||
yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
|
||||
? yytable[yyi]
|
||||
: yydefgoto[yylhs]);
|
||||
}
|
||||
|
||||
goto yynewstate;
|
||||
|
||||
|
@ -1502,12 +1504,10 @@ yyerrlab:
|
|||
| yyerrorlab -- error raised explicitly by YYERROR. |
|
||||
`---------------------------------------------------*/
|
||||
yyerrorlab:
|
||||
|
||||
/* Pacify compilers like GCC when the user code never invokes
|
||||
YYERROR and the label yyerrorlab therefore never appears in user
|
||||
code. */
|
||||
if (/*CONSTCOND*/ 0)
|
||||
goto yyerrorlab;
|
||||
/* Pacify compilers when the user code never invokes YYERROR and the
|
||||
label yyerrorlab therefore never appears in user code. */
|
||||
if (0)
|
||||
YYERROR;
|
||||
|
||||
/* Do not reclaim the symbols of the rule whose action triggered
|
||||
this YYERROR. */
|
||||
|
@ -1569,6 +1569,7 @@ yyacceptlab:
|
|||
yyresult = 0;
|
||||
goto yyreturn;
|
||||
|
||||
|
||||
/*-----------------------------------.
|
||||
| yyabortlab -- YYABORT comes here. |
|
||||
`-----------------------------------*/
|
||||
|
@ -1576,6 +1577,7 @@ yyabortlab:
|
|||
yyresult = 1;
|
||||
goto yyreturn;
|
||||
|
||||
|
||||
#if !defined yyoverflow || YYERROR_VERBOSE
|
||||
/*-------------------------------------------------.
|
||||
| yyexhaustedlab -- memory exhaustion comes here. |
|
||||
|
@ -1586,6 +1588,10 @@ yyexhaustedlab:
|
|||
/* Fall through. */
|
||||
#endif
|
||||
|
||||
|
||||
/*-----------------------------------------------------.
|
||||
| yyreturn -- parsing is finished, return the result. |
|
||||
`-----------------------------------------------------*/
|
||||
yyreturn:
|
||||
if (yychar != YYEMPTY)
|
||||
{
|
||||
|
@ -1615,7 +1621,7 @@ yyreturn:
|
|||
#endif
|
||||
return yyresult;
|
||||
}
|
||||
#line 87 "predicate_parser.y" /* yacc.c:1907 */
|
||||
#line 87 "predicate_parser.y" /* yacc.c:1918 */
|
||||
|
||||
|
||||
void Soliderror ( void *_scanner, const char *s ) /* Called by Solidparse on error */
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
/* A Bison parser, made by GNU Bison 3.0.5. */
|
||||
/* A Bison parser, made by GNU Bison 3.3.2. */
|
||||
|
||||
/* Bison interface for Yacc-like parsers in C
|
||||
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018 Free Software Foundation, Inc.
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 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
|
||||
|
@ -30,6 +31,9 @@
|
|||
This special exception was added by the Free Software Foundation in
|
||||
version 2.2 of Bison. */
|
||||
|
||||
/* Undocumented macros, especially those whose name start with YY_,
|
||||
are private implementation details. Do not rely on them. */
|
||||
|
||||
#ifndef YY_SOLID_PREDICATE_PARSER_H_INCLUDED
|
||||
# define YY_SOLID_PREDICATE_PARSER_H_INCLUDED
|
||||
/* Debug traces. */
|
||||
|
@ -63,7 +67,7 @@ extern int Soliddebug;
|
|||
|
||||
union YYSTYPE
|
||||
{
|
||||
#line 22 "predicate_parser.y" /* yacc.c:1910 */
|
||||
#line 22 "predicate_parser.y" /* yacc.c:1921 */
|
||||
|
||||
char valb;
|
||||
int vali;
|
||||
|
@ -71,7 +75,7 @@ union YYSTYPE
|
|||
char *name;
|
||||
void *ptr;
|
||||
|
||||
#line 75 "predicate_parser.h" /* yacc.c:1910 */
|
||||
#line 79 "predicate_parser.h" /* yacc.c:1921 */
|
||||
};
|
||||
|
||||
typedef union YYSTYPE YYSTYPE;
|
||||
|
|
Loading…
Add table
Reference in a new issue