52 #define YYBISON_VERSION "3.8.2"
55 #define YYSKELETON_NAME "yacc.c"
68 #define yyparse cql_parse
70 #define yyerror cql_error
71 #define yydebug cql_debug
72 #define yynerrs cql_nerrs
124 #define YYSTYPE token
134 # define YY_CAST(Type, Val) static_cast<Type> (Val)
135 # define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast<Type> (Val)
137 # define YY_CAST(Type, Val) ((Type) (Val))
138 # define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val))
142 # if defined __cplusplus
143 # if 201103L <= __cplusplus
144 # define YY_NULLPTR nullptr
146 # define YY_NULLPTR 0
149 # define YY_NULLPTR ((void*)0)
159 extern int cql_debug;
190 #define PREFIX_NAME 258
191 #define SIMPLE_STRING 259
203 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
205 # define YYSTYPE_IS_TRIVIAL 1
206 # define YYSTYPE_IS_DECLARED 1
276 #ifndef __PTRDIFF_MAX__
278 # if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
289 #ifdef __INT_LEAST8_MAX__
291 #elif defined YY_STDINT_H
297 #ifdef __INT_LEAST16_MAX__
299 #elif defined YY_STDINT_H
311 # undef UINT_LEAST8_MAX
312 # undef UINT_LEAST16_MAX
313 # define UINT_LEAST8_MAX 255
314 # define UINT_LEAST16_MAX 65535
317 #if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__
319 #elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \
320 && UINT_LEAST8_MAX <= INT_MAX)
322 #elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX
328 #if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__
330 #elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \
331 && UINT_LEAST16_MAX <= INT_MAX)
333 #elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX
340 # if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__
341 # define YYPTRDIFF_T __PTRDIFF_TYPE__
342 # define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__
343 # elif defined PTRDIFF_MAX
347 # define YYPTRDIFF_T ptrdiff_t
348 # define YYPTRDIFF_MAXIMUM PTRDIFF_MAX
350 # define YYPTRDIFF_T long
351 # define YYPTRDIFF_MAXIMUM LONG_MAX
356 # ifdef __SIZE_TYPE__
357 # define YYSIZE_T __SIZE_TYPE__
358 # elif defined size_t
359 # define YYSIZE_T size_t
360 # elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
362 # define YYSIZE_T size_t
364 # define YYSIZE_T unsigned
368 #define YYSIZE_MAXIMUM \
369 YY_CAST (YYPTRDIFF_T, \
370 (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1) \
371 ? YYPTRDIFF_MAXIMUM \
372 : YY_CAST (YYSIZE_T, -1)))
374 #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X))
384 # if defined YYENABLE_NLS && YYENABLE_NLS
386 # include <libintl.h>
387 # define YY_(Msgid) dgettext ("bison-runtime", Msgid)
391 # define YY_(Msgid) Msgid
396 #ifndef YY_ATTRIBUTE_PURE
397 # if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__)
398 # define YY_ATTRIBUTE_PURE __attribute__ ((__pure__))
400 # define YY_ATTRIBUTE_PURE
404 #ifndef YY_ATTRIBUTE_UNUSED
405 # if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__)
406 # define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__))
408 # define YY_ATTRIBUTE_UNUSED
413 #if ! defined lint || defined __GNUC__
414 # define YY_USE(E) ((void) (E))
420 #if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
421 # if __GNUC__ * 100 + __GNUC_MINOR__ < 407
422 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
423 _Pragma ("GCC diagnostic push") \
424 _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
426 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
427 _Pragma ("GCC diagnostic push") \
428 _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
429 _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
431 # define YY_IGNORE_MAYBE_UNINITIALIZED_END \
432 _Pragma ("GCC diagnostic pop")
434 # define YY_INITIAL_VALUE(Value) Value
436 #ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
437 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
438 # define YY_IGNORE_MAYBE_UNINITIALIZED_END
440 #ifndef YY_INITIAL_VALUE
441 # define YY_INITIAL_VALUE(Value)
444 #if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__
445 # define YY_IGNORE_USELESS_CAST_BEGIN \
446 _Pragma ("GCC diagnostic push") \
447 _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"")
448 # define YY_IGNORE_USELESS_CAST_END \
449 _Pragma ("GCC diagnostic pop")
451 #ifndef YY_IGNORE_USELESS_CAST_BEGIN
452 # define YY_IGNORE_USELESS_CAST_BEGIN
453 # define YY_IGNORE_USELESS_CAST_END
457 #define YY_ASSERT(E) ((void) (0 && (E)))
459 #if !defined yyoverflow
463 # ifdef YYSTACK_USE_ALLOCA
464 # if YYSTACK_USE_ALLOCA
466 # define YYSTACK_ALLOC __builtin_alloca
467 # elif defined __BUILTIN_VA_ARG_INCR
470 # define YYSTACK_ALLOC __alloca
471 # elif defined _MSC_VER
473 # define alloca _alloca
475 # define YYSTACK_ALLOC alloca
476 # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
479 # ifndef EXIT_SUCCESS
480 # define EXIT_SUCCESS 0
487 # ifdef YYSTACK_ALLOC
489 # define YYSTACK_FREE(Ptr) do { ; } while (0)
490 # ifndef YYSTACK_ALLOC_MAXIMUM
495 # define YYSTACK_ALLOC_MAXIMUM 4032
498 # define YYSTACK_ALLOC YYMALLOC
499 # define YYSTACK_FREE YYFREE
500 # ifndef YYSTACK_ALLOC_MAXIMUM
501 # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
503 # if (defined __cplusplus && ! defined EXIT_SUCCESS \
504 && ! ((defined YYMALLOC || defined malloc) \
505 && (defined YYFREE || defined free)))
507 # ifndef EXIT_SUCCESS
508 # define EXIT_SUCCESS 0
512 # define YYMALLOC malloc
513 # if ! defined malloc && ! defined EXIT_SUCCESS
519 # if ! defined free && ! defined EXIT_SUCCESS
526 #if (! defined yyoverflow \
527 && (! defined __cplusplus \
528 || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
538 # define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1)
542 # define YYSTACK_BYTES(N) \
543 ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \
544 + YYSTACK_GAP_MAXIMUM)
546 # define YYCOPY_NEEDED 1
553 # define YYSTACK_RELOCATE(Stack_alloc, Stack) \
556 YYPTRDIFF_T yynewbytes; \
557 YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
558 Stack = &yyptr->Stack_alloc; \
559 yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \
560 yyptr += yynewbytes / YYSIZEOF (*yyptr); \
566 #if defined YYCOPY_NEEDED && YYCOPY_NEEDED
570 # if defined __GNUC__ && 1 < __GNUC__
571 # define YYCOPY(Dst, Src, Count) \
572 __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src)))
574 # define YYCOPY(Dst, Src, Count) \
578 for (yyi = 0; yyi < (Count); yyi++) \
579 (Dst)[yyi] = (Src)[yyi]; \
601 #define YYMAXUTOK 268
606 #define YYTRANSLATE(YYX) \
607 (0 <= (YYX) && (YYX) <= YYMAXUTOK \
608 ? YY_CAST (yysymbol_kind_t, yytranslate[YYX]) \
615 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
616 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
617 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
618 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
619 16, 17, 2, 2, 2, 2, 2, 18, 2, 2,
620 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
621 19, 15, 14, 2, 2, 2, 2, 2, 2, 2,
622 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
623 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
624 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
625 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
626 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
627 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
628 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
629 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
630 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
631 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
632 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
633 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
634 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
635 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
636 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
637 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
638 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
639 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
640 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
641 5, 6, 7, 8, 9, 10, 11, 12, 13
648 0, 69, 69, 69, 86, 87, 91, 95, 100, 105,
649 106, 113, 115, 115, 121, 121, 130, 132, 132, 147,
650 147, 154, 161, 161, 171, 178, 185, 185, 185, 185,
651 187, 196, 205, 210, 210, 213, 214, 215, 216, 217,
652 218, 219, 223, 226, 227, 228, 229, 230, 231, 232
657 #define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State])
666 static const char *
const yytname[] =
668 "\"end of file\"",
"error",
"\"invalid token\"",
"PREFIX_NAME",
669 "SIMPLE_STRING",
"AND",
"OR",
"NOT",
"PROX",
"GE",
"LE",
"NE",
"EXACT",
670 "SORTBY",
"'>'",
"'='",
"'('",
"')'",
"'/'",
"'<'",
"$accept",
"top",
671 "@1",
"sortby",
"sortSpec",
"singleSpec",
"cqlQuery1",
"cqlQuery",
"@2",
672 "@3",
"scopedClause",
"@4",
"searchClause",
"@5",
"@6",
"extraTerms",
673 "boolean",
"modifiers",
"relation",
"relation_symbol",
"index",
680 return yytname[yysymbol];
684 #define YYPACT_NINF (-34)
686 #define yypact_value_is_default(Yyn) \
687 ((Yyn) == YYPACT_NINF)
689 #define YYTABLE_NINF (-43)
691 #define yytable_value_is_error(Yyn) \
698 -34, 4, 51, -34, -34, -34, -34, -34, -34, -34,
699 -34, 79, -34, 6, 7, 31, -34, 32, 2, -13,
700 51, 79, -34, -34, -34, -34, -34, -34, -34, -34,
701 -34, -34, -34, -34, -34, -34, -34, -34, -34, 11,
702 -34, 79, 51, 5, 79, -34, -34, -34, 9, 9,
703 -34, -34, -34, -34, -34, 9, 79, 65, 65, 51,
704 84, -34, -34, -34, 79, -34
712 2, 0, 0, 1, 44, 43, 45, 46, 47, 48,
713 49, 0, 19, 4, 0, 11, 16, 0, 25, 14,
714 0, 0, 3, 10, 26, 27, 28, 29, 32, 33,
715 38, 39, 40, 41, 36, 35, 37, 32, 34, 25,
716 21, 0, 0, 0, 5, 7, 32, 42, 17, 22,
717 24, 12, 15, 20, 6, 8, 0, 0, 0, 0,
718 30, 18, 23, 13, 0, 31
724 -34, -34, -34, -34, -34, -16, -34, -19, -34, -34,
725 -34, -34, -33, -34, -34, -10, -34, -28, -34, -29,
732 0, 1, 2, 22, 44, 45, 13, 14, 59, 42,
733 15, 57, 16, 20, 58, 40, 28, 48, 37, 38,
742 19, 43, 41, 46, 3, -42, 39, -9, 23, 49,
743 47, -42, -42, -42, -42, 39, -42, -42, 55, 21,
744 -9, -42, 53, 52, 61, 62, 46, 56, 54, 50,
745 51, 64, 0, 47, 0, 29, 24, 25, 26, 27,
746 63, 30, 31, 32, 33, 60, 34, 35, 0, 0,
747 0, 36, 0, 65, 4, 5, 6, 7, 8, 9,
748 0, 0, 0, 0, 10, 11, 0, 12, 4, 5,
749 6, 7, 8, 9, 0, 0, 0, 0, 10, 0,
750 0, 12, 4, 5, 6, 7, 8, 9, 0, 0,
751 0, 0, 10, 30, 31, 32, 33, 0, 34, 35,
757 11, 20, 15, 21, 0, 3, 4, 0, 1, 37,
758 21, 9, 10, 11, 12, 4, 14, 15, 46, 13,
759 13, 19, 17, 42, 57, 58, 44, 18, 44, 39,
760 41, 60, -1, 44, -1, 3, 5, 6, 7, 8,
761 59, 9, 10, 11, 12, 56, 14, 15, -1, -1,
762 -1, 19, -1, 64, 3, 4, 5, 6, 7, 8,
763 -1, -1, -1, -1, 13, 14, -1, 16, 3, 4,
764 5, 6, 7, 8, -1, -1, -1, -1, 13, -1,
765 -1, 16, 3, 4, 5, 6, 7, 8, -1, -1,
766 -1, -1, 13, 9, 10, 11, 12, -1, 14, 15,
774 0, 21, 22, 0, 3, 4, 5, 6, 7, 8,
775 13, 14, 16, 26, 27, 30, 32, 40, 41, 41,
776 33, 13, 23, 1, 5, 6, 7, 8, 36, 3,
777 9, 10, 11, 12, 14, 15, 19, 38, 39, 4,
778 35, 15, 29, 27, 24, 25, 40, 41, 37, 37,
779 35, 41, 27, 17, 25, 37, 18, 31, 34, 28,
780 41, 32, 32, 27, 39, 41
786 0, 20, 22, 21, 23, 23, 24, 24, 25, 26,
787 26, 27, 28, 27, 29, 27, 30, 31, 30, 33,
788 32, 32, 34, 32, 35, 35, 36, 36, 36, 36,
789 37, 37, 37, 38, 38, 39, 39, 39, 39, 39,
790 39, 39, 40, 41, 41, 41, 41, 41, 41, 41
796 0, 2, 0, 3, 0, 2, 2, 1, 2, 1,
797 2, 1, 0, 6, 0, 4, 1, 0, 5, 0,
798 4, 2, 0, 5, 2, 0, 1, 1, 1, 1,
799 3, 5, 0, 1, 1, 1, 1, 1, 1, 1,
800 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
806 #define yyerrok (yyerrstatus = 0)
807 #define yyclearin (yychar = YYEMPTY)
809 #define YYACCEPT goto yyacceptlab
810 #define YYABORT goto yyabortlab
811 #define YYERROR goto yyerrorlab
812 #define YYNOMEM goto yyexhaustedlab
815 #define YYRECOVERING() (!!yyerrstatus)
817 #define YYBACKUP(Token, Value) \
819 if (yychar == YYEMPTY) \
823 YYPOPSTACK (yylen); \
829 yyerror (parm, YY_("syntax error: cannot back up")); \
836 #define YYERRCODE YYUNDEF
844 # define YYFPRINTF fprintf
847 # define YYDPRINTF(Args) \
856 # define YY_SYMBOL_PRINT(Title, Kind, Value, Location) \
860 YYFPRINTF (stderr, "%s ", Title); \
861 yy_symbol_print (stderr, \
862 Kind, Value, parm); \
863 YYFPRINTF (stderr, "\n"); \
873 yy_symbol_value_print (FILE *yyo,
876 FILE *yyoutput = yyo;
892 yy_symbol_print (FILE *yyo,
895 YYFPRINTF (yyo,
"%s %s (",
896 yykind <
YYNTOKENS ?
"token" :
"nterm", yysymbol_name (yykind));
898 yy_symbol_value_print (yyo, yykind, yyvaluep, parm);
899 YYFPRINTF (yyo,
")");
910 YYFPRINTF (stderr,
"Stack now");
911 for (; yybottom <= yytop; yybottom++)
913 int yybot = *yybottom;
914 YYFPRINTF (stderr,
" %d", yybot);
916 YYFPRINTF (stderr,
"\n");
919 # define YY_STACK_PRINT(Bottom, Top) \
922 yy_stack_print ((Bottom), (Top)); \
932 int yyrule,
void *parm)
934 int yylno = yyrline[yyrule];
935 int yynrhs =
yyr2[yyrule];
937 YYFPRINTF (stderr,
"Reducing stack by rule %d (line %d):\n",
940 for (yyi = 0; yyi < yynrhs; yyi++)
942 YYFPRINTF (stderr,
" $%d = ", yyi + 1);
943 yy_symbol_print (stderr,
945 &yyvsp[(yyi + 1) - (yynrhs)], parm);
946 YYFPRINTF (stderr,
"\n");
950 # define YY_REDUCE_PRINT(Rule) \
953 yy_reduce_print (yyssp, yyvsp, Rule, parm); \
960 # define YYDPRINTF(Args) ((void) 0)
961 # define YY_SYMBOL_PRINT(Title, Kind, Value, Location)
962 # define YY_STACK_PRINT(Bottom, Top)
963 # define YY_REDUCE_PRINT(Rule)
969 # define YYINITDEPTH 200
980 # define YYMAXDEPTH 10000
1034 int yyerrstatus = 0;
1063 #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))
1069 YYDPRINTF ((stderr,
"Starting parse\n"));
1089 YYDPRINTF ((stderr,
"Entering state %d\n", yystate));
1096 if (yyss + yystacksize - 1 <= yyssp)
1097 #if !defined yyoverflow && !defined YYSTACK_RELOCATE
1104 # if defined yyoverflow
1116 yyoverflow (
YY_(
"memory exhausted"),
1117 &yyss1, yysize *
YYSIZEOF (*yyssp),
1118 &yyvs1, yysize *
YYSIZEOF (*yyvsp),
1140 # undef YYSTACK_RELOCATE
1146 yyssp = yyss + yysize - 1;
1147 yyvsp = yyvs + yysize - 1;
1150 YYDPRINTF ((stderr,
"Stack size increased to %ld\n",
1151 YY_CAST (
long, yystacksize)));
1154 if (yyss + yystacksize - 1 <= yyssp)
1183 YYDPRINTF ((stderr,
"Reading a token\n"));
1184 yychar =
yylex (&yylval, parm);
1187 if (yychar <=
YYEOF)
1191 YYDPRINTF ((stderr,
"Now at end of input.\n"));
1265 yyval = yyvsp[1-yylen];
1275 "cql.serverChoice",
"=", 0);
1287 yyvsp[0].cql->u.sort.search = yyvsp[-1].cql;
1305 yyval.cql = yyvsp[0].cql;
1313 yyval.cql = yyvsp[-1].cql;
1314 yyval.cql->u.sort.next = yyvsp[0].cql;
1322 yyval.cql = yyvsp[0].cql;
1347 yyval.rel = yyvsp[-4].rel;
1356 yyvsp[0].cql, yyvsp[-4].buf, yyvsp[-2].buf);
1364 yyval.rel = yyvsp[-2].rel;
1373 yyvsp[0].cql, 0, yyvsp[-2].buf);
1381 yyval.rel = yyvsp[-3].rel;
1392 cn->
u.
boolean.modifiers = yyvsp[-2].cql;
1393 cn->
u.
boolean.left = yyvsp[-4].cql;
1394 cn->
u.
boolean.right = yyvsp[0].cql;
1404 yyval.rel = yyvsp[-1].rel;
1413 yyval.cql = yyvsp[-1].cql;
1422 st->u.st.extra_terms = yyvsp[0].cql;
1433 yyval.rel->u.st.modifiers = yyvsp[0].cql;
1441 yyval.cql = yyvsp[0].cql;
1451 0, 0, yyvsp[-1].buf);
1452 st->u.st.extra_terms = yyvsp[0].cql;
1468 yyvsp[0].buf, 0, 0);
1470 mod->
u.
st.modifiers = yyvsp[-2].cql;
1480 yyvsp[-2].buf, yyvsp[-1].buf, yyvsp[0].buf);
1482 mod->
u.
st.modifiers = yyvsp[-4].cql;
1524 const int yyi =
yypgoto[yylhs] + *yyssp;
1525 yystate = (0 <= yyi && yyi <=
YYLAST &&
yycheck[yyi] == *yyssp
1547 if (yyerrstatus == 3)
1552 if (yychar <=
YYEOF)
1555 if (yychar ==
YYEOF)
1561 yytoken, &yylval, parm);
1670 yytoken, &yylval, parm);
1676 while (yyssp != yyss)
1706 if (lval->len+1 >= lval->size)
1710 memcpy(nb, lval->buf, lval->len);
1714 lval->buf[lval->len++] = c;
1715 lval->buf[lval->len] =
'\0';
1732 lval->buf[0] =
'\0';
1741 if (strchr(
"()=></", c))
1803 int relation_like = 0;
1804 while (c != 0 && !strchr(
" \n()=<>/", c))
1820 printf (
"got %s\n", lval->buf);
1846 lval->buf =
"sortby";
1865 int (*getbyte)(
void *client_data),
1866 void (*ungetbyte)(
int b,
void *client_data),
#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
static const yytype_int8 yytranslate[]
@ YYSYMBOL_relation_symbol
#define YY_IGNORE_MAYBE_UNINITIALIZED_END
static const yytype_int8 yydefact[]
#define YY_IGNORE_USELESS_CAST_END
static void yydestruct(const char *yymsg, yysymbol_kind_t yykind, YYSTYPE *yyvaluep, void *parm)
static const yytype_int8 yycheck[]
void cql_parser_strict(CQL_parser cp, int mode)
configures strict mode
#define YY_REDUCE_PRINT(Rule)
#define YY_CAST(Type, Val)
static const yytype_int8 yypact[]
#define YY_ACCESSING_SYMBOL(State)
#define YY_SYMBOL_PRINT(Title, Kind, Value, Location)
#define YY_INITIAL_VALUE(Value)
unsigned char yytype_uint8
#define YY_STACK_PRINT(Bottom, Top)
#define YY_IGNORE_USELESS_CAST_BEGIN
static void putb(YYSTYPE *lval, CQL_parser cp, int c)
static const yytype_int8 yyr2[]
static const yytype_int8 yytable[]
#define yytable_value_is_error(Yyn)
static const yytype_int8 yystos[]
int cql_parser_stream(CQL_parser cp, int(*getbyte)(void *client_data), void(*ungetbyte)(int b, void *client_data), void *client_data)
parses CQL query (query stream)
#define YY_ATTRIBUTE_UNUSED
int cql_parse(void *parm)
struct cql_node * cql_parser_result(CQL_parser cp)
returns the parse tree of the most recently parsed CQL query.
static const yytype_int8 yypgoto[]
void cql_parser_destroy(CQL_parser cp)
destroys a CQL parser.
static const yytype_int8 yyr1[]
enum yytokentype yytoken_kind_t
CQL_parser cql_parser_create(void)
creates a CQL parser.
unsigned short yytype_uint16
static const yytype_int8 yydefgoto[]
#define YYSTACK_RELOCATE(Stack_alloc, Stack)
#define yypact_value_is_default(Yyn)
Header with public definitions about CQL.
struct cql_parser * CQL_parser
CQL parser handle (opaque pointer)
int cql_strcmp(const char *s1, const char *s2)
compares two CQL strings (ala strcmp)
struct cql_node * cql_node_mk_sort(NMEM nmem, const char *index, struct cql_node *modifiers)
creates a sort single spec node.
struct cql_node * cql_node_mk_sc(NMEM nmem, const char *index, const char *relation, const char *term)
creates a search clause node (st).
struct cql_node * cql_node_dup(NMEM nmem, struct cql_node *cp)
void cql_node_destroy(struct cql_node *cn)
destroys a node and its children.
struct cql_node * cql_apply_prefix(NMEM nmem, struct cql_node *n, const char *prefix, const char *uri)
applies a prefix+uri to "unresolved" index and relation URIs. "unresolved" URIs are those nodes where...
struct cql_node * cql_node_mk_boolean(NMEM nmem, const char *op)
creates a boolean node.
void nmem_reset(NMEM n)
releases memory associaged with an NMEM handle
NMEM nmem_create(void)
returns new NMEM handle
void * nmem_malloc(NMEM n, size_t size)
allocates memory block on NMEM handle
void nmem_destroy(NMEM n)
destroys NMEM handle and memory associated with it
Header for Nibble Memory functions.
char * nmem_strdup(NMEM mem, const char *src)
allocates string on NMEM handle (similar strdup)
struct cql_node::@10::@12 boolean
struct cql_node::@10::@11 st
void(* ungetbyte)(int b, void *client_data)
int(* getbyte)(void *client_data)
Header for memory handling functions.
#define xfree(x)
utility macro which calls xfree_f
#define xmalloc(x)
utility macro which calls malloc_f
Header for YAZ iconv interface.