Lines Matching +full:2 +full:-

3 /* Skeleton implementation for Bison's Yacc-like parsers in C
10 the Free Software Foundation; either version 2, or (at your option)
21 Boston, MA 02110-1301, USA. */
37 simplifying the original so-called "semantic" parser. */
96 * Copyright (c) 1998 - 2000 Kungliga Tekniska Högskolan
107 * 2. Redistributions in binary form must reproduce the above copyright
233 #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
239 # define YY_(msgid) dgettext ("bison-runtime", msgid)
247 /* Suppress unused-variable warnings by "using" E. */
301 /* Pacify GCC's `empty if-body' warning. */
307 to allow for a few compiler-allocated temporary stack slots. */
354 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
389 YYCOPY (&yyptr->Stack, Stack, yysize); \
390 Stack = &yyptr->Stack; \
398 /* YYFINAL -- State number of the termination state. */
400 /* YYLAST -- Last index in YYTABLE. */
403 /* YYNTOKENS -- Number of terminals. */
405 /* YYNNTS -- Number of nonterminals. */
407 /* YYNRULES -- Number of rules. */
409 /* YYNRULES -- Number of states. */
412 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
413 #define YYUNDEFTOK 2
419 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
422 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
423 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
424 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
425 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
426 2, 2, 2, 2, 11, 2, 2, 2, 2, 2,
427 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
428 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
429 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
430 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
431 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
432 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
433 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
434 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
435 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
436 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
437 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
438 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
439 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
440 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
441 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
442 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
443 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
444 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
445 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
446 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
447 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
452 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
460 /* YYRHS -- A `-1'-separated list of the rules' RHS. */
463 13, 0, -1, -1, 14, 17, -1, 15, 16, -1,
464 16, -1, 7, 9, -1, 3, 9, -1, 3, 9,
465 9, -1, 18, -1, 17, 18, -1, 4, 10, -1,
466 5, 9, -1, 5, -1, 6, 9, 11, 9, -1,
467 8, -1
470 /* YYRLINE[YYN] -- source line where rule number YYN was defined. */
479 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
490 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
491 token YYLEX-NUM. */
499 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
506 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
509 0, 2, 0, 2, 2, 1, 2, 2, 3, 1,
510 2, 2, 2, 1, 4, 1
513 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
514 STATE-NUM when YYTABLE doesn't specify something else to do. Zero
518 2, 0, 0, 0, 0, 0, 5, 7, 6, 1,
523 /* YYDEFGOTO[NTERM-NUM]. */
526 -1, 3, 4, 5, 6, 14, 15
529 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
530 STATE-NUM. */
531 #define YYPACT_NINF -5
534 0, -3, -1, 5, -4, 6, -5, 1, -5, -5,
535 2, 4, 7, -5, -4, -5, -5, -5, -5, -5,
536 3, -5, 8, -5
539 /* YYPGOTO[NTERM-NUM]. */
542 -5, -5, -5, -5, 10, -5, 9
545 /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
549 #define YYTABLE_NINF -1
552 10, 11, 12, 1, 13, 9, 7, 2, 8, 1,
560 9, -1, 10, 9, 11, 5, 9, 9, -1, -1,
561 -1, -1, -1, 14
564 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
565 symbol of state STATE-NUM. */
575 #define YYEMPTY (-2)
585 Once GCC version 2 has supplanted version 1, this can go. */
613 /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
639 /* YY_LOCATION_PRINT -- Print the location on the stream.
646 fprintf (File, "%d.%d-%d.%d", \
655 /* YYLEX -- calling `yylex' with the right arguments. */
689 /*--------------------------------.
691 `--------------------------------*/
722 /*--------------------------------.
724 `--------------------------------*/
747 /*------------------------------------------------------------------.
748 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
750 `------------------------------------------------------------------*/
776 /*------------------------------------------------.
778 `------------------------------------------------*/
795 yyrule - 1, yylno);
801 &(yyvsp[(yyi + 1) - (yynrhs)])
824 /* YYINITDEPTH -- initial size of the parser's stacks. */
829 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
830 if the built-in stack extension method is used).
834 evaluated with infinite-precision integer arithmetic. */
890 return yyd - 1;
898 heuristic is that double-quoting is unnecessary unless the string
900 backslash-backslash). YYSTR is taken from yytname. If YYRES is
939 return yystpcpy (yyres, yystr) - yyres; in yytnamerr()
983 + sizeof yyexpecting - 1 in yysyntax_error()
984 + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) in yysyntax_error()
985 * (sizeof yyor - 1))]; in yysyntax_error()
988 /* Start YYX at -YYN if negative to avoid negative indexes in in yysyntax_error()
990 int yyxbegin = yyn < 0 ? -yyn : 0; in yysyntax_error()
993 int yychecklim = YYLAST - yyn + 1; in yysyntax_error()
1007 yyformat[sizeof yyunexpected - 1] = '\0'; in yysyntax_error()
1038 yyf += 2; in yysyntax_error()
1053 /*-----------------------------------------------.
1055 `-----------------------------------------------*/
1085 /* Prevent warnings from -Wmissing-prototypes. */
1103 /* The look-ahead symbol. */
1106 /* The semantic value of the look-ahead symbol. */
1114 /*----------.
1116 `----------*/
1146 /* Look-ahead token as an internal (translated) token number. */
1175 #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))
1205 /*------------------------------------------------------------.
1206 | yynewstate -- Push a new state, which is found in yystate. |
1207 `------------------------------------------------------------*/
1216 if (yyss + yystacksize - 1 <= yyssp)
1219 YYSIZE_T yysize = yyssp - yyss + 1;
1250 yystacksize *= 2;
1270 yyssp = yyss + yysize - 1;
1271 yyvsp = yyvs + yysize - 1;
1277 if (yyss + yystacksize - 1 <= yyssp)
1285 /*-----------.
1287 `-----------*/
1291 look-ahead token if we need one and don't already have one. */
1293 /* First try to decide what to do without reference to look-ahead token. */
1298 /* Not known => get a look-ahead token if don't already have one. */
1300 /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol. */
1328 yyn = -yyn;
1338 yyerrstatus--;
1340 /* Shift the look-ahead token. */
1353 /*-----------------------------------------------------------.
1354 | yydefault -- do the default action for the current state. |
1355 `-----------------------------------------------------------*/
1363 /*-----------------------------.
1364 | yyreduce -- Do a reduction. |
1365 `-----------------------------*/
1378 yyval = yyvsp[1-yylen];
1387 id_str = (yyvsp[(2) - (2)].string);
1394 base_id = name2number((yyvsp[(2) - (2)].string));
1395 strlcpy(name, (yyvsp[(2) - (2)].string), sizeof(name));
1396 free((yyvsp[(2) - (2)].string));
1403 base_id = name2number((yyvsp[(2) - (3)].string));
1404 strlcpy(name, (yyvsp[(3) - (3)].string), sizeof(name));
1405 free((yyvsp[(2) - (3)].string));
1406 free((yyvsp[(3) - (3)].string));
1413 number = (yyvsp[(2) - (2)].number);
1421 asprintf (&prefix, "%s_", (yyvsp[(2) - (2)].string));
1424 free((yyvsp[(2) - (2)].string));
1446 ec->next = NULL;
1447 ec->number = number;
1449 asprintf (&ec->name, "%s%s", prefix, (yyvsp[(2) - (4)].string));
1450 if (ec->name == NULL)
1452 free((yyvsp[(2) - (4)].string));
1454 ec->name = (yyvsp[(2) - (4)].string);
1455 ec->string = (yyvsp[(4) - (4)].string);
1473 YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
1488 yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
1492 yystate = yydefgoto[yyn - YYNTOKENS];
1497 /*------------------------------------.
1498 | yyerrlab -- here on detecting error |
1499 `------------------------------------*/
1512 YYSIZE_T yyalloc = 2 * yysize;
1546 /* If just tried and failed to reuse look-ahead token after an
1563 /* Else will try to reuse look-ahead token after shifting the error
1568 /*---------------------------------------------------.
1569 | yyerrorlab -- error raised explicitly by YYERROR. |
1570 `---------------------------------------------------*/
1588 /*-------------------------------------------------------------.
1589 | yyerrlab1 -- common code for both syntax error and YYERROR. |
1590 `-------------------------------------------------------------*/
1633 /*-------------------------------------.
1634 | yyacceptlab -- YYACCEPT comes here. |
1635 `-------------------------------------*/
1640 /*-----------------------------------.
1641 | yyabortlab -- YYABORT comes here. |
1642 `-----------------------------------*/
1648 /*-------------------------------------------------.
1649 | yyexhaustedlab -- memory exhaustion comes here. |
1650 `-------------------------------------------------*/
1653 yyresult = 2;
1704 num = (num << 6) + (q - x) + 1; in name2number()
1708 num = -(0xffffffff - num + 1); in name2number()