2 /* A Bison parser, made by GNU Bison 2.4.1. */
4 /* Skeleton implementation for Bison's Yacc-like parsers in C
6 Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
7 Free Software Foundation, Inc.
9 This program is free software: you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation, either version 3 of the License, or
12 (at your option) any later version.
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License for more details.
19 You should have received a copy of the GNU General Public License
20 along with this program. If not, see <http://www.gnu.org/licenses/>. */
22 /* As a special exception, you may create a larger work that contains
23 part or all of the Bison parser skeleton and distribute that work
24 under terms of your choice, so long as that work isn't itself a
25 parser generator using the skeleton or a modified version thereof
26 as a parser skeleton. Alternatively, if you modify or redistribute
27 the parser skeleton itself, you may (at your option) remove this
28 special exception, which will cause the skeleton and the resulting
29 Bison output files to be licensed under the GNU General Public
30 License without this special exception.
32 This special exception was added by the Free Software Foundation in
33 version 2.2 of Bison. */
35 /* C LALR(1) parser skeleton written by Richard Stallman, by
36 simplifying the original so-called "semantic" parser. */
38 /* All symbols defined below should begin with yy or YY, to avoid
39 infringing on user name space. This should be done even for local
40 variables, as they might otherwise be expanded by user macros.
41 There are some unavoidable exceptions within include files to
42 define necessary library symbols; they are noted "INFRINGES ON
43 USER NAME SPACE" below. */
45 /* Identify Bison output. */
49 #define YYBISON_VERSION "2.4.1"
52 #define YYSKELETON_NAME "yacc.c"
63 /* Using locations. */
64 #define YYLSP_NEEDED 1
66 /* Substitute the variable and function names. */
67 #define yyparse scdocparse
68 #define yylex scdoclex
69 #define yyerror scdocerror
70 #define yylval scdoclval
71 #define yychar scdocchar
72 #define yydebug scdocdebug
73 #define yynerrs scdocnerrs
74 #define yylloc scdoclloc
76 /* Copy the first part of user declarations. */
78 /* Line 189 of yacc.c */
81 /************************************************************************
83 * Copyright 2012 Jonatan Liljedahl <lijon@kymatica.com>
85 * This program is free software: you can redistribute it and/or modify
86 * it under the terms of the GNU General Public License as published by
87 * the Free Software Foundation, either version 3 of the License, or
88 * (at your option) any later version.
90 * This program is distributed in the hope that it will be useful,
91 * but WITHOUT ANY WARRANTY; without even the implied warranty of
92 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
93 * GNU General Public License for more details.
95 * You should have received a copy of the GNU General Public License
96 * along with this program. If not, see <http://www.gnu.org/licenses/>.
98 ************************************************************************/
105 //#define YYLEX_PARAM &yylval, &yylloc
109 extern int scdoclineno
;
110 extern char *scdoctext
;
111 extern int scdoc_start_token
;
112 extern FILE *scdocin
;
113 //extern struct YYLTYPE scdoclloc;
115 //int scdoc_metadata_mode;
117 static const char * method_type
= NULL
;
119 static DocNode
* topnode
;
121 void scdocerror(const char *str
);
123 extern void error(const char *fmt
, ...);
124 extern void post(const char *fmt
, ...);
128 /* Line 189 of yacc.c */
129 #line 130 "SCDoc.tab.cpp"
131 /* Enabling traces. */
136 /* Enabling verbose error messages. */
137 #ifdef YYERROR_VERBOSE
138 # undef YYERROR_VERBOSE
139 # define YYERROR_VERBOSE 1
141 # define YYERROR_VERBOSE 1
144 /* Enabling the token table. */
145 #ifndef YYTOKEN_TABLE
146 # define YYTOKEN_TABLE 0
153 /* Put the tokens into the symbol table, so that GDB and other debuggers
173 INSTANCEMETHODS
= 274,
180 DEFINITIONLIST
= 281,
207 BAD_METHODNAME
= 308,
216 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
217 typedef union YYSTYPE
220 /* Line 214 of yacc.c */
230 /* Line 214 of yacc.c */
231 #line 232 "SCDoc.tab.cpp"
233 # define YYSTYPE_IS_TRIVIAL 1
234 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
235 # define YYSTYPE_IS_DECLARED 1
238 #if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
239 typedef struct YYLTYPE
246 # define yyltype YYLTYPE /* obsolescent; will be withdrawn */
247 # define YYLTYPE_IS_DECLARED 1
248 # define YYLTYPE_IS_TRIVIAL 1
252 /* Copy the second part of user declarations. */
254 /* Line 264 of yacc.c */
257 //int scdoclex (YYSTYPE * yylval_param, struct YYLTYPE * yylloc_param );
261 /* Line 264 of yacc.c */
262 #line 263 "SCDoc.tab.cpp"
269 typedef YYTYPE_UINT8 yytype_uint8
;
271 typedef unsigned char yytype_uint8
;
275 typedef YYTYPE_INT8 yytype_int8
;
276 #elif (defined __STDC__ || defined __C99__FUNC__ \
277 || defined __cplusplus || defined _MSC_VER)
278 typedef signed char yytype_int8
;
280 typedef short int yytype_int8
;
284 typedef YYTYPE_UINT16 yytype_uint16
;
286 typedef unsigned short int yytype_uint16
;
290 typedef YYTYPE_INT16 yytype_int16
;
292 typedef short int yytype_int16
;
296 # ifdef __SIZE_TYPE__
297 # define YYSIZE_T __SIZE_TYPE__
298 # elif defined size_t
299 # define YYSIZE_T size_t
300 # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
301 || defined __cplusplus || defined _MSC_VER)
302 # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
303 # define YYSIZE_T size_t
305 # define YYSIZE_T unsigned int
309 #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
314 # include <libintl.h> /* INFRINGES ON USER NAME SPACE */
315 # define YY_(msgid) dgettext ("bison-runtime", msgid)
319 # define YY_(msgid) msgid
323 /* Suppress unused-variable warnings by "using" E. */
324 #if ! defined lint || defined __GNUC__
325 # define YYUSE(e) ((void) (e))
327 # define YYUSE(e) /* empty */
330 /* Identity function, used to suppress warnings about constant conditions. */
334 #if (defined __STDC__ || defined __C99__FUNC__ \
335 || defined __cplusplus || defined _MSC_VER)
348 #if ! defined yyoverflow || YYERROR_VERBOSE
350 /* The parser invokes alloca or malloc; define the necessary symbols. */
352 # ifdef YYSTACK_USE_ALLOCA
353 # if YYSTACK_USE_ALLOCA
355 # define YYSTACK_ALLOC __builtin_alloca
356 # elif defined __BUILTIN_VA_ARG_INCR
357 # include <alloca.h> /* INFRINGES ON USER NAME SPACE */
359 # define YYSTACK_ALLOC __alloca
360 # elif defined _MSC_VER
361 # include <malloc.h> /* INFRINGES ON USER NAME SPACE */
362 # define alloca _alloca
364 # define YYSTACK_ALLOC alloca
365 # if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
366 || defined __cplusplus || defined _MSC_VER)
367 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
376 # ifdef YYSTACK_ALLOC
377 /* Pacify GCC's `empty if-body' warning. */
378 # define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
379 # ifndef YYSTACK_ALLOC_MAXIMUM
380 /* The OS might guarantee only one guard page at the bottom of the stack,
381 and a page size can be as small as 4096 bytes. So we cannot safely
382 invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
383 to allow for a few compiler-allocated temporary stack slots. */
384 # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
387 # define YYSTACK_ALLOC YYMALLOC
388 # define YYSTACK_FREE YYFREE
389 # ifndef YYSTACK_ALLOC_MAXIMUM
390 # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
392 # if (defined __cplusplus && ! defined _STDLIB_H \
393 && ! ((defined YYMALLOC || defined malloc) \
394 && (defined YYFREE || defined free)))
395 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
401 # define YYMALLOC malloc
402 # if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
403 || defined __cplusplus || defined _MSC_VER)
404 void *malloc (YYSIZE_T
); /* INFRINGES ON USER NAME SPACE */
409 # if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
410 || defined __cplusplus || defined _MSC_VER)
411 void free (void *); /* INFRINGES ON USER NAME SPACE */
415 #endif /* ! defined yyoverflow || YYERROR_VERBOSE */
418 #if (! defined yyoverflow \
419 && (! defined __cplusplus \
420 || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
421 && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
423 /* A type that is properly aligned for any stack member. */
426 yytype_int16 yyss_alloc
;
431 /* The size of the maximum gap between one aligned stack and the next. */
432 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
434 /* The size of an array large to enough to hold all stacks, each with
436 # define YYSTACK_BYTES(N) \
437 ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
438 + 2 * YYSTACK_GAP_MAXIMUM)
440 /* Copy COUNT objects from FROM to TO. The source and destination do
443 # if defined __GNUC__ && 1 < __GNUC__
444 # define YYCOPY(To, From, Count) \
445 __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
447 # define YYCOPY(To, From, Count) \
451 for (yyi = 0; yyi < (Count); yyi++) \
452 (To)[yyi] = (From)[yyi]; \
458 /* Relocate STACK from its old location to the new one. The
459 local variables YYSIZE and YYSTACKSIZE give the old and new number of
460 elements in the stack, and YYPTR gives the new location of the
461 stack. Advance YYPTR to a properly aligned location for the next
463 # define YYSTACK_RELOCATE(Stack_alloc, Stack) \
466 YYSIZE_T yynewbytes; \
467 YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
468 Stack = &yyptr->Stack_alloc; \
469 yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
470 yyptr += yynewbytes / sizeof (*yyptr); \
476 /* YYFINAL -- State number of the termination state. */
478 /* YYLAST -- Last index in YYTABLE. */
481 /* YYNTOKENS -- Number of terminals. */
483 /* YYNNTS -- Number of nonterminals. */
485 /* YYNRULES -- Number of rules. */
487 /* YYNRULES -- Number of states. */
488 #define YYNSTATES 192
490 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
492 #define YYMAXUTOK 311
494 #define YYTRANSLATE(YYX) \
495 ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
497 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
498 static const yytype_uint8 yytranslate
[] =
500 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
501 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
502 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
503 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
504 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
505 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
506 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
507 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
508 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
509 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
510 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
511 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
512 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
513 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
514 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
515 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
516 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
517 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
518 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
519 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
520 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
521 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
522 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
523 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
524 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
525 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
526 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
527 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
528 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
529 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
530 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
535 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
537 static const yytype_uint16 yyprhs
[] =
539 0, 0, 3, 5, 8, 13, 16, 20, 22, 23,
540 26, 28, 32, 36, 40, 42, 44, 46, 48, 50,
541 52, 54, 56, 58, 59, 62, 64, 66, 67, 73,
542 76, 78, 79, 82, 84, 86, 91, 93, 94, 97,
543 99, 101, 107, 111, 115, 116, 118, 120, 124, 126,
544 131, 133, 134, 136, 137, 140, 142, 147, 151, 154,
545 155, 158, 159, 161, 163, 166, 169, 171, 174, 176,
546 180, 184, 188, 192, 196, 200, 204, 206, 210, 213,
547 215, 217, 219, 223, 227, 229, 231, 233, 235, 237,
548 239, 241, 243, 245, 247, 249, 251, 253, 255, 257,
549 259, 261, 265, 268, 271, 274, 276, 280, 282, 286,
550 289, 293, 296, 298, 300, 302, 304, 306, 309, 311,
551 314, 316, 318, 320, 322, 324, 326, 329, 331, 334,
555 /* YYRHS -- A `-1'-separated list of the rules' RHS. */
556 static const yytype_int8 yyrhs
[] =
558 58, 0, -1, 59, -1, 59, 1, -1, 54, 60,
559 61, 65, -1, 55, 66, -1, 56, 61, 65, -1,
560 106, -1, -1, 61, 62, -1, 62, -1, 63, 105,
561 106, -1, 7, 110, 106, -1, 6, 110, 106, -1,
562 3, -1, 4, -1, 5, -1, 8, -1, 18, -1,
563 19, -1, 17, -1, 20, -1, 66, -1, -1, 66,
564 67, -1, 67, -1, 73, -1, -1, 13, 68, 105,
565 106, 69, -1, 64, 69, -1, 70, -1, -1, 70,
566 71, -1, 71, -1, 73, -1, 14, 105, 106, 72,
567 -1, 73, -1, -1, 73, 74, -1, 74, -1, 85,
568 -1, 15, 77, 75, 106, 78, -1, 10, 104, 106,
569 -1, 12, 110, 106, -1, -1, 50, -1, 49, -1,
570 77, 48, 76, -1, 76, -1, 79, 80, 83, 84,
571 -1, 85, -1, -1, 81, -1, -1, 81, 82, -1,
572 82, -1, 16, 104, 106, 79, -1, 16, 106, 85,
573 -1, 21, 85, -1, -1, 22, 85, -1, -1, 86,
574 -1, 87, -1, 87, 88, -1, 86, 88, -1, 88,
575 -1, 86, 89, -1, 89, -1, 94, 85, 43, -1,
576 93, 95, 43, -1, 27, 97, 43, -1, 26, 101,
577 43, -1, 92, 108, 43, -1, 9, 104, 106, -1,
578 11, 110, 106, -1, 52, -1, 35, 105, 43, -1,
579 89, 90, -1, 90, -1, 103, -1, 47, -1, 91,
580 104, 43, -1, 28, 85, 43, -1, 51, -1, 32,
581 -1, 38, -1, 34, -1, 39, -1, 31, -1, 36,
582 -1, 37, -1, 33, -1, 40, -1, 41, -1, 42,
583 -1, 23, -1, 24, -1, 25, -1, 30, -1, 29,
584 -1, 95, 45, 85, -1, 45, 85, -1, 45, 98,
585 -1, 97, 96, -1, 96, -1, 98, 44, 79, -1,
586 79, -1, 99, 45, 85, -1, 45, 85, -1, 99,
587 44, 79, -1, 101, 100, -1, 100, -1, 103, -1,
588 47, -1, 46, -1, 48, -1, 104, 103, -1, 103,
589 -1, 105, 102, -1, 102, -1, 51, -1, 52, -1,
590 0, -1, 103, -1, 106, -1, 108, 107, -1, 107,
591 -1, 109, 46, -1, 109, 47, -1, 46, -1, 47,
592 -1, 110, 48, 109, -1, 109, -1
595 /* YYRLINE[YYN] -- source line where rule number YYN was defined. */
596 static const yytype_uint16 yyrline
[] =
598 0, 102, 102, 103, 106, 112, 116, 124, 125, 128,
599 129, 132, 133, 134, 137, 138, 139, 140, 143, 144,
600 145, 146, 149, 150, 153, 154, 155, 158, 158, 159,
601 162, 163, 166, 167, 168, 171, 174, 175, 178, 179,
602 180, 183, 190, 194, 197, 198, 209, 220, 221, 224,
603 233, 234, 237, 238, 241, 242, 245, 246, 249, 250,
604 253, 254, 262, 263, 266, 267, 268, 271, 272, 275,
605 276, 277, 278, 279, 280, 281, 284, 285, 288, 289,
606 292, 293, 294, 295, 296, 299, 300, 301, 302, 303,
607 304, 305, 306, 309, 310, 311, 314, 315, 316, 319,
608 320, 323, 324, 327, 330, 331, 334, 335, 338, 339,
609 342, 349, 350, 353, 354, 357, 358, 361, 362, 365,
610 366, 369, 370, 371, 374, 375, 378, 379, 382, 383,
615 #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
616 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
617 First, the terminals, then, starting at YYNTOKENS, nonterminals. */
618 static const char *const yytname
[] =
620 "\"end of file\"", "error", "$undefined", "CLASS", "TITLE", "SUMMARY",
621 "RELATED", "CATEGORIES", "REDIRECT", "CLASSTREE", "COPYMETHOD",
622 "KEYWORD", "PRIVATE", "SECTION", "SUBSECTION", "METHOD", "ARGUMENT",
623 "DESCRIPTION", "CLASSMETHODS", "INSTANCEMETHODS", "EXAMPLES", "RETURNS",
624 "DISCUSSION", "LIST", "TREE", "NUMBEREDLIST", "DEFINITIONLIST", "TABLE",
625 "FOOTNOTE", "NOTE", "WARNING", "CODE", "LINK", "ANCHOR", "SOFT", "IMAGE",
626 "TELETYPE", "MATH", "STRONG", "EMPHASIS", "\"CODE block\"",
627 "\"TELETYPE block\"", "\"MATH block\"", "\"::\"", "\"||\"", "\"##\"",
628 "\"text\"", "URL", "COMMA", "\"method name\"", "\"arguments string\"",
629 "\"newline\"", "\"empty lines\"", "\"bad method name\"", "START_FULL",
630 "START_PARTIAL", "START_METADATA", "$accept", "start", "document",
631 "eateol", "dochead", "headline", "headtag", "sectiontag", "optsections",
632 "sections", "section", "$@1", "optsubsections", "subsections",
633 "subsection", "optsubsubsections", "subsubsections", "subsubsection",
634 "optMETHODARGS", "methodname", "methnames", "methodbody", "optbody",
635 "optargs", "args", "arg", "optreturns", "optdiscussion", "body",
636 "blockA", "blockB", "bodyelem", "prose", "proseelem", "inlinetag",
637 "blocktag", "listtag", "rangetag", "listbody", "tablerow", "tablebody",
638 "tablecells", "defterms", "deflistrow", "deflistbody", "anywordurl",
639 "anyword", "words", "words2", "eol", "anywordnl", "wordsnl",
640 "nocommawords", "commalist", 0
645 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
647 static const yytype_uint16 yytoknum
[] =
649 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
650 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
651 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
652 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
653 295, 296, 297, 298, 299, 300, 301, 302, 303, 304,
654 305, 306, 307, 308, 309, 310, 311
658 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
659 static const yytype_uint8 yyr1
[] =
661 0, 57, 58, 58, 59, 59, 59, 60, 60, 61,
662 61, 62, 62, 62, 63, 63, 63, 63, 64, 64,
663 64, 64, 65, 65, 66, 66, 66, 68, 67, 67,
664 69, 69, 70, 70, 70, 71, 72, 72, 73, 73,
665 73, 74, 74, 74, 75, 75, 76, 77, 77, 78,
666 79, 79, 80, 80, 81, 81, 82, 82, 83, 83,
667 84, 84, 85, 85, 86, 86, 86, 87, 87, 88,
668 88, 88, 88, 88, 88, 88, 88, 88, 89, 89,
669 90, 90, 90, 90, 90, 91, 91, 91, 91, 91,
670 91, 91, 91, 92, 92, 92, 93, 93, 93, 94,
671 94, 95, 95, 96, 97, 97, 98, 98, 99, 99,
672 100, 101, 101, 102, 102, 103, 103, 104, 104, 105,
673 105, 106, 106, 106, 107, 107, 108, 108, 109, 109,
677 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
678 static const yytype_uint8 yyr2
[] =
680 0, 2, 1, 2, 4, 2, 3, 1, 0, 2,
681 1, 3, 3, 3, 1, 1, 1, 1, 1, 1,
682 1, 1, 1, 0, 2, 1, 1, 0, 5, 2,
683 1, 0, 2, 1, 1, 4, 1, 0, 2, 1,
684 1, 5, 3, 3, 0, 1, 1, 3, 1, 4,
685 1, 0, 1, 0, 2, 1, 4, 3, 2, 0,
686 2, 0, 1, 1, 2, 2, 1, 2, 1, 3,
687 3, 3, 3, 3, 3, 3, 1, 3, 2, 1,
688 1, 1, 3, 3, 1, 1, 1, 1, 1, 1,
689 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
690 1, 3, 2, 2, 2, 1, 3, 1, 3, 2,
691 3, 2, 1, 1, 1, 1, 1, 2, 1, 2,
692 1, 1, 1, 1, 1, 1, 2, 1, 2, 2,
696 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
697 STATE-NUM when YYTABLE doesn't specify something else to do. Zero
698 means the default is an error. */
699 static const yytype_uint8 yydefact
[] =
701 0, 8, 0, 0, 0, 0, 123, 121, 122, 0,
702 7, 0, 0, 0, 0, 27, 0, 20, 18, 19,
703 21, 96, 97, 98, 0, 0, 0, 100, 99, 89,
704 85, 92, 87, 0, 90, 91, 86, 88, 93, 94,
705 95, 115, 81, 116, 84, 76, 31, 5, 25, 26,
706 39, 40, 62, 63, 66, 68, 79, 0, 0, 0,
707 0, 80, 14, 15, 16, 0, 0, 17, 23, 10,
708 0, 1, 3, 23, 118, 0, 0, 130, 131, 133,
709 0, 0, 0, 46, 48, 44, 0, 0, 112, 0,
710 51, 105, 0, 0, 114, 120, 113, 0, 0, 29,
711 30, 33, 34, 24, 38, 65, 67, 64, 78, 0,
712 124, 125, 127, 0, 0, 0, 0, 0, 0, 9,
713 6, 22, 0, 4, 117, 74, 42, 128, 129, 0,
714 75, 43, 0, 0, 45, 0, 109, 51, 0, 72,
715 111, 107, 50, 103, 71, 104, 83, 77, 119, 0,
716 32, 82, 73, 126, 102, 70, 0, 69, 13, 12,
717 11, 132, 31, 47, 51, 110, 108, 51, 37, 101,
718 28, 41, 53, 106, 35, 36, 0, 59, 52, 55,
719 0, 0, 0, 61, 54, 51, 57, 58, 0, 49,
723 /* YYDEFGOTO[NTERM-NUM]. */
724 static const yytype_int16 yydefgoto
[] =
726 -1, 4, 5, 9, 68, 69, 70, 46, 120, 121,
727 48, 82, 99, 100, 101, 174, 49, 50, 135, 84,
728 85, 171, 141, 177, 178, 179, 183, 189, 51, 52,
729 53, 54, 55, 56, 57, 58, 59, 60, 115, 91,
730 92, 143, 87, 88, 89, 95, 61, 75, 97, 111,
734 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
736 #define YYPACT_NINF -113
737 static const yytype_int16 yypact
[] =
739 64, 18, 221, 101, 8, 31, -113, -113, -113, 101,
740 -113, -34, -34, 96, 96, -113, -14, -113, -113, -113,
741 -113, -113, -113, -113, 1, 5, 343, -113, -113, -113,
742 -113, -113, -113, 78, -113, -113, -113, -113, -113, -113,
743 -113, -113, -113, -113, -113, -113, 265, 2, -113, 24,
744 -113, -113, 343, 377, -113, 394, -113, -34, 38, 9,
745 343, -113, -113, -113, -113, 96, 96, -113, 177, -113,
746 78, -113, -113, 177, -113, 38, 38, -113, -113, 99,
747 44, 44, 78, -113, -113, 50, 343, 105, -113, 68,
748 343, -113, 85, -32, -113, -113, -113, -19, 78, -113,
749 12, -113, 24, -113, -113, -113, 394, -113, -113, -3,
750 -113, -113, -113, 10, 343, 92, 14, 44, 44, -113,
751 -113, 2, 30, -113, -113, -113, -113, -113, -113, 96,
752 -113, -113, 30, -14, -113, 18, -113, 343, 343, -113,
753 -113, -113, -113, 27, -113, -113, -113, -113, -113, 30,
754 -113, -113, -113, -113, -113, -113, 343, -113, -113, -113,
755 -113, 99, 265, -113, 343, -113, -113, 343, 309, -113,
756 -113, -113, 69, -113, -113, 24, 38, 80, 69, -113,
757 38, 343, 343, 88, -113, 343, -113, -113, 343, -113,
761 /* YYPGOTO[NTERM-NUM]. */
762 static const yytype_int16 yypgoto
[] =
764 -113, -113, -113, -113, 118, 29, -113, -113, 63, 136,
765 -38, -113, -22, -113, 47, -113, -39, -43, -113, 21,
766 -113, -113, -112, -113, -113, -27, -113, -113, -23, -113,
767 -113, 100, 103, -42, -113, -113, -113, -113, -113, 65,
768 -113, -113, -113, 67, -113, -81, -10, -8, -65, -1,
772 /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
773 positive, shift that token. If negative, reduce the rule which
774 number is the opposite. If zero, do what YYDEFACT says.
775 If YYTABLE_NINF, syntax error. */
776 #define YYTABLE_NINF -3
777 static const yytype_int16 yytable
[] =
779 10, 74, 74, 93, 76, 122, 104, 102, 71, 103,
780 6, 146, 41, 108, 43, 15, 148, 132, 6, 17,
781 18, 19, 20, 96, 147, 165, 98, 41, 94, 43,
782 6, -2, 72, 149, 12, 83, 14, 116, 6, 16,
783 151, 148, 81, 41, 6, 43, 86, 74, 110, 109,
784 90, 148, 172, 152, 114, 173, 41, 157, 43, 104,
785 96, 7, 8, 136, 108, 124, 124, 142, 148, 7,
786 8, 167, 96, 190, 125, 126, 41, 94, 43, 130,
787 131, 7, 8, 103, 41, 176, 43, 96, 96, 7,
788 8, 154, 129, 117, 118, 7, 8, 119, 133, 124,
789 134, 182, 119, 110, 62, 63, 64, 65, 66, 67,
790 188, 139, 96, 86, 142, 166, 158, 159, 1, 2,
791 3, 160, 96, 102, 41, 94, 43, 73, 144, 175,
792 90, 162, 104, 169, 164, 155, 123, 156, 47, 96,
793 170, 142, 77, 78, 142, 127, 128, 150, 168, 137,
794 138, 184, 105, 107, 163, 106, 140, 145, 186, 187,
795 0, 153, 142, 161, 0, 191, 74, 0, 180, 0,
796 124, 0, 0, 0, 0, 181, 0, 0, 0, 185,
797 62, 63, 64, 65, 66, 67, 11, 12, 13, 14,
798 15, 0, 16, 0, 17, 18, 19, 20, 0, 0,
799 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
800 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
801 0, 0, 0, 41, 42, 43, 0, 0, 44, 45,
802 11, 12, 13, 14, 15, 0, 16, 0, 17, 18,
803 19, 20, 0, 0, 21, 22, 23, 24, 25, 26,
804 27, 28, 29, 30, 31, 32, 33, 34, 35, 36,
805 37, 38, 39, 40, 0, 0, 0, 41, 42, 43,
806 0, 0, 44, 45, 11, 12, 13, 14, 0, 98,
807 16, 0, 0, 0, 0, 0, 0, 0, 21, 22,
808 23, 24, 25, 26, 27, 28, 29, 30, 31, 32,
809 33, 34, 35, 36, 37, 38, 39, 40, 0, 0,
810 0, 41, 42, 43, 0, 0, 44, 45, 11, 12,
811 13, 14, 0, 0, 16, 0, 0, 0, 0, 0,
812 0, 0, 21, 22, 23, 24, 25, 26, 27, 28,
813 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
814 39, 40, 11, 0, 13, 41, 42, 43, 0, 0,
815 44, 45, 0, 0, 0, 0, 21, 22, 23, 24,
816 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
817 35, 36, 37, 38, 39, 40, 11, 0, 13, 41,
818 42, 43, 0, 0, 44, 45, 0, 0, 0, 0,
819 21, 22, 23, 24, 25, 0, 27, 28, 0, 0,
820 0, 0, 33, 0, 0, 0, 0, 38, 39, 40,
821 0, 0, 26, 0, 0, 29, 30, 31, 32, 45,
822 34, 35, 36, 37, 0, 0, 0, 0, 0, 0,
826 static const yytype_int16 yycheck
[] =
828 1, 11, 12, 26, 12, 70, 49, 46, 0, 47,
829 0, 43, 46, 55, 48, 13, 97, 82, 0, 17,
830 18, 19, 20, 33, 43, 137, 14, 46, 47, 48,
831 0, 0, 1, 98, 10, 49, 12, 60, 0, 15,
832 43, 122, 14, 46, 0, 48, 45, 57, 58, 57,
833 45, 132, 164, 43, 45, 167, 46, 43, 48, 102,
834 70, 51, 52, 86, 106, 75, 76, 90, 149, 51,
835 52, 44, 82, 185, 75, 76, 46, 47, 48, 80,
836 81, 51, 52, 121, 46, 16, 48, 97, 98, 51,
837 52, 114, 48, 65, 66, 51, 52, 68, 48, 109,
838 50, 21, 73, 113, 3, 4, 5, 6, 7, 8,
839 22, 43, 122, 45, 137, 138, 117, 118, 54, 55,
840 56, 122, 132, 162, 46, 47, 48, 9, 43, 168,
841 45, 132, 175, 156, 135, 43, 73, 45, 2, 149,
842 162, 164, 46, 47, 167, 46, 47, 100, 149, 44,
843 45, 178, 52, 53, 133, 52, 89, 92, 181, 182,
844 -1, 113, 185, 129, -1, 188, 176, -1, 176, -1,
845 180, -1, -1, -1, -1, 176, -1, -1, -1, 180,
846 3, 4, 5, 6, 7, 8, 9, 10, 11, 12,
847 13, -1, 15, -1, 17, 18, 19, 20, -1, -1,
848 23, 24, 25, 26, 27, 28, 29, 30, 31, 32,
849 33, 34, 35, 36, 37, 38, 39, 40, 41, 42,
850 -1, -1, -1, 46, 47, 48, -1, -1, 51, 52,
851 9, 10, 11, 12, 13, -1, 15, -1, 17, 18,
852 19, 20, -1, -1, 23, 24, 25, 26, 27, 28,
853 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
854 39, 40, 41, 42, -1, -1, -1, 46, 47, 48,
855 -1, -1, 51, 52, 9, 10, 11, 12, -1, 14,
856 15, -1, -1, -1, -1, -1, -1, -1, 23, 24,
857 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
858 35, 36, 37, 38, 39, 40, 41, 42, -1, -1,
859 -1, 46, 47, 48, -1, -1, 51, 52, 9, 10,
860 11, 12, -1, -1, 15, -1, -1, -1, -1, -1,
861 -1, -1, 23, 24, 25, 26, 27, 28, 29, 30,
862 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
863 41, 42, 9, -1, 11, 46, 47, 48, -1, -1,
864 51, 52, -1, -1, -1, -1, 23, 24, 25, 26,
865 27, 28, 29, 30, 31, 32, 33, 34, 35, 36,
866 37, 38, 39, 40, 41, 42, 9, -1, 11, 46,
867 47, 48, -1, -1, 51, 52, -1, -1, -1, -1,
868 23, 24, 25, 26, 27, -1, 29, 30, -1, -1,
869 -1, -1, 35, -1, -1, -1, -1, 40, 41, 42,
870 -1, -1, 28, -1, -1, 31, 32, 33, 34, 52,
871 36, 37, 38, 39, -1, -1, -1, -1, -1, -1,
872 46, 47, 48, -1, -1, 51
875 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
876 symbol of state STATE-NUM. */
877 static const yytype_uint8 yystos
[] =
879 0, 54, 55, 56, 58, 59, 0, 51, 52, 60,
880 106, 9, 10, 11, 12, 13, 15, 17, 18, 19,
881 20, 23, 24, 25, 26, 27, 28, 29, 30, 31,
882 32, 33, 34, 35, 36, 37, 38, 39, 40, 41,
883 42, 46, 47, 48, 51, 52, 64, 66, 67, 73,
884 74, 85, 86, 87, 88, 89, 90, 91, 92, 93,
885 94, 103, 3, 4, 5, 6, 7, 8, 61, 62,
886 63, 0, 1, 61, 103, 104, 104, 46, 47, 109,
887 110, 110, 68, 49, 76, 77, 45, 99, 100, 101,
888 45, 96, 97, 85, 47, 102, 103, 105, 14, 69,
889 70, 71, 73, 67, 74, 88, 89, 88, 90, 104,
890 103, 106, 107, 108, 45, 95, 85, 110, 110, 62,
891 65, 66, 105, 65, 103, 106, 106, 46, 47, 48,
892 106, 106, 105, 48, 50, 75, 85, 44, 45, 43,
893 100, 79, 85, 98, 43, 96, 43, 43, 102, 105,
894 71, 43, 43, 107, 85, 43, 45, 43, 106, 106,
895 106, 109, 106, 76, 106, 79, 85, 44, 106, 85,
896 69, 78, 79, 79, 72, 73, 16, 80, 81, 82,
897 104, 106, 21, 83, 82, 106, 85, 85, 22, 84,
901 #define yyerrok (yyerrstatus = 0)
902 #define yyclearin (yychar = YYEMPTY)
906 #define YYACCEPT goto yyacceptlab
907 #define YYABORT goto yyabortlab
908 #define YYERROR goto yyerrorlab
911 /* Like YYERROR except do call yyerror. This remains here temporarily
912 to ease the transition to the new meaning of YYERROR, for GCC.
913 Once GCC version 2 has supplanted version 1, this can go. */
915 #define YYFAIL goto yyerrlab
917 #define YYRECOVERING() (!!yyerrstatus)
919 #define YYBACKUP(Token, Value) \
921 if (yychar == YYEMPTY && yylen == 1) \
925 yytoken = YYTRANSLATE (yychar); \
931 yyerror (YY_("syntax error: cannot back up")); \
938 #define YYERRCODE 256
941 /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
942 If N is 0, then set CURRENT to the empty location which ends
943 the previous symbol: RHS[0] (always defined). */
945 #define YYRHSLOC(Rhs, K) ((Rhs)[K])
946 #ifndef YYLLOC_DEFAULT
947 # define YYLLOC_DEFAULT(Current, Rhs, N) \
951 (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
952 (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
953 (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
954 (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
958 (Current).first_line = (Current).last_line = \
959 YYRHSLOC (Rhs, 0).last_line; \
960 (Current).first_column = (Current).last_column = \
961 YYRHSLOC (Rhs, 0).last_column; \
967 /* YY_LOCATION_PRINT -- Print the location on the stream.
968 This macro was not mandated originally: define only if we know
969 we won't break user code: when these are the locations we know. */
971 #ifndef YY_LOCATION_PRINT
972 # if YYLTYPE_IS_TRIVIAL
973 # define YY_LOCATION_PRINT(File, Loc) \
974 fprintf (File, "%d.%d-%d.%d", \
975 (Loc).first_line, (Loc).first_column, \
976 (Loc).last_line, (Loc).last_column)
978 # define YY_LOCATION_PRINT(File, Loc) ((void) 0)
983 /* YYLEX -- calling `yylex' with the right arguments. */
986 # define YYLEX yylex (YYLEX_PARAM)
988 # define YYLEX yylex ()
991 /* Enable debugging if requested. */
995 # include <stdio.h> /* INFRINGES ON USER NAME SPACE */
996 # define YYFPRINTF fprintf
999 # define YYDPRINTF(Args) \
1005 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
1009 YYFPRINTF (stderr, "%s ", Title); \
1010 yy_symbol_print (stderr, \
1011 Type, Value, Location); \
1012 YYFPRINTF (stderr, "\n"); \
1017 /*--------------------------------.
1018 | Print this symbol on YYOUTPUT. |
1019 `--------------------------------*/
1022 #if (defined __STDC__ || defined __C99__FUNC__ \
1023 || defined __cplusplus || defined _MSC_VER)
1025 yy_symbol_value_print (FILE *yyoutput
, int yytype
, YYSTYPE
const * const yyvaluep
, YYLTYPE
const * const yylocationp
)
1028 yy_symbol_value_print (yyoutput
, yytype
, yyvaluep
, yylocationp
)
1031 YYSTYPE
const * const yyvaluep
;
1032 YYLTYPE
const * const yylocationp
;
1037 YYUSE (yylocationp
);
1039 if (yytype
< YYNTOKENS
)
1040 YYPRINT (yyoutput
, yytoknum
[yytype
], *yyvaluep
);
1052 /*--------------------------------.
1053 | Print this symbol on YYOUTPUT. |
1054 `--------------------------------*/
1056 #if (defined __STDC__ || defined __C99__FUNC__ \
1057 || defined __cplusplus || defined _MSC_VER)
1059 yy_symbol_print (FILE *yyoutput
, int yytype
, YYSTYPE
const * const yyvaluep
, YYLTYPE
const * const yylocationp
)
1062 yy_symbol_print (yyoutput
, yytype
, yyvaluep
, yylocationp
)
1065 YYSTYPE
const * const yyvaluep
;
1066 YYLTYPE
const * const yylocationp
;
1069 if (yytype
< YYNTOKENS
)
1070 YYFPRINTF (yyoutput
, "token %s (", yytname
[yytype
]);
1072 YYFPRINTF (yyoutput
, "nterm %s (", yytname
[yytype
]);
1074 YY_LOCATION_PRINT (yyoutput
, *yylocationp
);
1075 YYFPRINTF (yyoutput
, ": ");
1076 yy_symbol_value_print (yyoutput
, yytype
, yyvaluep
, yylocationp
);
1077 YYFPRINTF (yyoutput
, ")");
1080 /*------------------------------------------------------------------.
1081 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
1083 `------------------------------------------------------------------*/
1085 #if (defined __STDC__ || defined __C99__FUNC__ \
1086 || defined __cplusplus || defined _MSC_VER)
1088 yy_stack_print (yytype_int16
*yybottom
, yytype_int16
*yytop
)
1091 yy_stack_print (yybottom
, yytop
)
1092 yytype_int16
*yybottom
;
1093 yytype_int16
*yytop
;
1096 YYFPRINTF (stderr
, "Stack now");
1097 for (; yybottom
<= yytop
; yybottom
++)
1099 int yybot
= *yybottom
;
1100 YYFPRINTF (stderr
, " %d", yybot
);
1102 YYFPRINTF (stderr
, "\n");
1105 # define YY_STACK_PRINT(Bottom, Top) \
1108 yy_stack_print ((Bottom), (Top)); \
1112 /*------------------------------------------------.
1113 | Report that the YYRULE is going to be reduced. |
1114 `------------------------------------------------*/
1116 #if (defined __STDC__ || defined __C99__FUNC__ \
1117 || defined __cplusplus || defined _MSC_VER)
1119 yy_reduce_print (YYSTYPE
*yyvsp
, YYLTYPE
*yylsp
, int yyrule
)
1122 yy_reduce_print (yyvsp
, yylsp
, yyrule
)
1128 int yynrhs
= yyr2
[yyrule
];
1130 unsigned long int yylno
= yyrline
[yyrule
];
1131 YYFPRINTF (stderr
, "Reducing stack by rule %d (line %lu):\n",
1133 /* The symbols being reduced. */
1134 for (yyi
= 0; yyi
< yynrhs
; yyi
++)
1136 YYFPRINTF (stderr
, " $%d = ", yyi
+ 1);
1137 yy_symbol_print (stderr
, yyrhs
[yyprhs
[yyrule
] + yyi
],
1138 &(yyvsp
[(yyi
+ 1) - (yynrhs
)])
1139 , &(yylsp
[(yyi
+ 1) - (yynrhs
)]) );
1140 YYFPRINTF (stderr
, "\n");
1144 # define YY_REDUCE_PRINT(Rule) \
1147 yy_reduce_print (yyvsp, yylsp, Rule); \
1150 /* Nonzero means print parse trace. It is left uninitialized so that
1151 multiple parsers can coexist. */
1153 #else /* !YYDEBUG */
1154 # define YYDPRINTF(Args)
1155 # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
1156 # define YY_STACK_PRINT(Bottom, Top)
1157 # define YY_REDUCE_PRINT(Rule)
1158 #endif /* !YYDEBUG */
1161 /* YYINITDEPTH -- initial size of the parser's stacks. */
1163 # define YYINITDEPTH 200
1166 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
1167 if the built-in stack extension method is used).
1169 Do not make this value too large; the results are undefined if
1170 YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
1171 evaluated with infinite-precision integer arithmetic. */
1174 # define YYMAXDEPTH 10000
1182 # if defined __GLIBC__ && defined _STRING_H
1183 # define yystrlen strlen
1185 /* Return the length of YYSTR. */
1186 #if (defined __STDC__ || defined __C99__FUNC__ \
1187 || defined __cplusplus || defined _MSC_VER)
1189 yystrlen (const char *yystr
)
1197 for (yylen
= 0; yystr
[yylen
]; yylen
++)
1205 # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
1206 # define yystpcpy stpcpy
1208 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
1210 #if (defined __STDC__ || defined __C99__FUNC__ \
1211 || defined __cplusplus || defined _MSC_VER)
1213 yystpcpy (char *yydest
, const char *yysrc
)
1216 yystpcpy (yydest
, yysrc
)
1222 const char *yys
= yysrc
;
1224 while ((*yyd
++ = *yys
++) != '\0')
1233 /* Copy to YYRES the contents of YYSTR after stripping away unnecessary
1234 quotes and backslashes, so that it's suitable for yyerror. The
1235 heuristic is that double-quoting is unnecessary unless the string
1236 contains an apostrophe, a comma, or backslash (other than
1237 backslash-backslash). YYSTR is taken from yytname. If YYRES is
1238 null, do not copy; instead, return the length of what the result
1241 yytnamerr (char *yyres
, const char *yystr
)
1246 char const *yyp
= yystr
;
1253 goto do_not_strip_quotes
;
1257 goto do_not_strip_quotes
;
1270 do_not_strip_quotes
: ;
1274 return yystrlen (yystr
);
1276 return yystpcpy (yyres
, yystr
) - yyres
;
1280 /* Copy into YYRESULT an error message about the unexpected token
1281 YYCHAR while in state YYSTATE. Return the number of bytes copied,
1282 including the terminating null byte. If YYRESULT is null, do not
1283 copy anything; just return the number of bytes that would be
1284 copied. As a special case, return 0 if an ordinary "syntax error"
1285 message will do. Return YYSIZE_MAXIMUM if overflow occurs during
1286 size calculation. */
1288 yysyntax_error (char *yyresult
, int yystate
, int yychar
)
1290 int yyn
= yypact
[yystate
];
1292 if (! (YYPACT_NINF
< yyn
&& yyn
<= YYLAST
))
1296 int yytype
= YYTRANSLATE (yychar
);
1297 YYSIZE_T yysize0
= yytnamerr (0, yytname
[yytype
]);
1298 YYSIZE_T yysize
= yysize0
;
1300 int yysize_overflow
= 0;
1301 enum { YYERROR_VERBOSE_ARGS_MAXIMUM
= 5 };
1302 char const *yyarg
[YYERROR_VERBOSE_ARGS_MAXIMUM
];
1306 /* This is so xgettext sees the translatable formats that are
1307 constructed on the fly. */
1308 YY_("syntax error, unexpected %s");
1309 YY_("syntax error, unexpected %s, expecting %s");
1310 YY_("syntax error, unexpected %s, expecting %s or %s");
1311 YY_("syntax error, unexpected %s, expecting %s or %s or %s");
1312 YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
1316 static char const yyunexpected
[] = "syntax error, unexpected %s";
1317 static char const yyexpecting
[] = ", expecting %s";
1318 static char const yyor
[] = " or %s";
1319 char yyformat
[sizeof yyunexpected
1320 + sizeof yyexpecting
- 1
1321 + ((YYERROR_VERBOSE_ARGS_MAXIMUM
- 2)
1322 * (sizeof yyor
- 1))];
1323 char const *yyprefix
= yyexpecting
;
1325 /* Start YYX at -YYN if negative to avoid negative indexes in
1327 int yyxbegin
= yyn
< 0 ? -yyn
: 0;
1329 /* Stay within bounds of both yycheck and yytname. */
1330 int yychecklim
= YYLAST
- yyn
+ 1;
1331 int yyxend
= yychecklim
< YYNTOKENS
? yychecklim
: YYNTOKENS
;
1334 yyarg
[0] = yytname
[yytype
];
1335 yyfmt
= yystpcpy (yyformat
, yyunexpected
);
1337 for (yyx
= yyxbegin
; yyx
< yyxend
; ++yyx
)
1338 if (yycheck
[yyx
+ yyn
] == yyx
&& yyx
!= YYTERROR
)
1340 if (yycount
== YYERROR_VERBOSE_ARGS_MAXIMUM
)
1344 yyformat
[sizeof yyunexpected
- 1] = '\0';
1347 yyarg
[yycount
++] = yytname
[yyx
];
1348 yysize1
= yysize
+ yytnamerr (0, yytname
[yyx
]);
1349 yysize_overflow
|= (yysize1
< yysize
);
1351 yyfmt
= yystpcpy (yyfmt
, yyprefix
);
1355 yyf
= YY_(yyformat
);
1356 yysize1
= yysize
+ yystrlen (yyf
);
1357 yysize_overflow
|= (yysize1
< yysize
);
1360 if (yysize_overflow
)
1361 return YYSIZE_MAXIMUM
;
1365 /* Avoid sprintf, as that infringes on the user's name space.
1366 Don't have undefined behavior even if the translation
1367 produced a string with the wrong number of "%s"s. */
1368 char *yyp
= yyresult
;
1370 while ((*yyp
= *yyf
) != '\0')
1372 if (*yyp
== '%' && yyf
[1] == 's' && yyi
< yycount
)
1374 yyp
+= yytnamerr (yyp
, yyarg
[yyi
++]);
1387 #endif /* YYERROR_VERBOSE */
1390 /*-----------------------------------------------.
1391 | Release the memory associated to this symbol. |
1392 `-----------------------------------------------*/
1395 #if (defined __STDC__ || defined __C99__FUNC__ \
1396 || defined __cplusplus || defined _MSC_VER)
1398 yydestruct (const char *yymsg
, int yytype
, YYSTYPE
*yyvaluep
, YYLTYPE
*yylocationp
)
1401 yydestruct (yymsg
, yytype
, yyvaluep
, yylocationp
)
1405 YYLTYPE
*yylocationp
;
1409 YYUSE (yylocationp
);
1413 YY_SYMBOL_PRINT (yymsg
, yytype
, yyvaluep
, yylocationp
);
1417 case 46: /* "\"text\"" */
1419 /* Line 1000 of yacc.c */
1421 { free((yyvaluep
->str
)); };
1423 /* Line 1000 of yacc.c */
1424 #line 1425 "SCDoc.tab.cpp"
1426 case 47: /* "URL" */
1428 /* Line 1000 of yacc.c */
1430 { free((yyvaluep
->str
)); };
1432 /* Line 1000 of yacc.c */
1433 #line 1434 "SCDoc.tab.cpp"
1435 case 48: /* "COMMA" */
1437 /* Line 1000 of yacc.c */
1439 { free((yyvaluep
->str
)); };
1441 /* Line 1000 of yacc.c */
1442 #line 1443 "SCDoc.tab.cpp"
1444 case 49: /* "\"method name\"" */
1446 /* Line 1000 of yacc.c */
1448 { free((yyvaluep
->str
)); };
1450 /* Line 1000 of yacc.c */
1451 #line 1452 "SCDoc.tab.cpp"
1453 case 50: /* "\"arguments string\"" */
1455 /* Line 1000 of yacc.c */
1457 { free((yyvaluep
->str
)); };
1459 /* Line 1000 of yacc.c */
1460 #line 1461 "SCDoc.tab.cpp"
1462 case 59: /* "document" */
1464 /* Line 1000 of yacc.c */
1466 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1468 /* Line 1000 of yacc.c */
1469 #line 1470 "SCDoc.tab.cpp"
1471 case 61: /* "dochead" */
1473 /* Line 1000 of yacc.c */
1475 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1477 /* Line 1000 of yacc.c */
1478 #line 1479 "SCDoc.tab.cpp"
1480 case 62: /* "headline" */
1482 /* Line 1000 of yacc.c */
1484 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1486 /* Line 1000 of yacc.c */
1487 #line 1488 "SCDoc.tab.cpp"
1489 case 65: /* "optsections" */
1491 /* Line 1000 of yacc.c */
1493 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1495 /* Line 1000 of yacc.c */
1496 #line 1497 "SCDoc.tab.cpp"
1498 case 66: /* "sections" */
1500 /* Line 1000 of yacc.c */
1502 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1504 /* Line 1000 of yacc.c */
1505 #line 1506 "SCDoc.tab.cpp"
1507 case 67: /* "section" */
1509 /* Line 1000 of yacc.c */
1511 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1513 /* Line 1000 of yacc.c */
1514 #line 1515 "SCDoc.tab.cpp"
1516 case 69: /* "optsubsections" */
1518 /* Line 1000 of yacc.c */
1520 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1522 /* Line 1000 of yacc.c */
1523 #line 1524 "SCDoc.tab.cpp"
1525 case 70: /* "subsections" */
1527 /* Line 1000 of yacc.c */
1529 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1531 /* Line 1000 of yacc.c */
1532 #line 1533 "SCDoc.tab.cpp"
1534 case 71: /* "subsection" */
1536 /* Line 1000 of yacc.c */
1538 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1540 /* Line 1000 of yacc.c */
1541 #line 1542 "SCDoc.tab.cpp"
1543 case 72: /* "optsubsubsections" */
1545 /* Line 1000 of yacc.c */
1547 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1549 /* Line 1000 of yacc.c */
1550 #line 1551 "SCDoc.tab.cpp"
1552 case 73: /* "subsubsections" */
1554 /* Line 1000 of yacc.c */
1556 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1558 /* Line 1000 of yacc.c */
1559 #line 1560 "SCDoc.tab.cpp"
1561 case 74: /* "subsubsection" */
1563 /* Line 1000 of yacc.c */
1565 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1567 /* Line 1000 of yacc.c */
1568 #line 1569 "SCDoc.tab.cpp"
1570 case 75: /* "optMETHODARGS" */
1572 /* Line 1000 of yacc.c */
1574 { free((yyvaluep
->str
)); };
1576 /* Line 1000 of yacc.c */
1577 #line 1578 "SCDoc.tab.cpp"
1579 case 76: /* "methodname" */
1581 /* Line 1000 of yacc.c */
1583 { free((yyvaluep
->str
)); };
1585 /* Line 1000 of yacc.c */
1586 #line 1587 "SCDoc.tab.cpp"
1588 case 77: /* "methnames" */
1590 /* Line 1000 of yacc.c */
1592 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1594 /* Line 1000 of yacc.c */
1595 #line 1596 "SCDoc.tab.cpp"
1597 case 78: /* "methodbody" */
1599 /* Line 1000 of yacc.c */
1601 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1603 /* Line 1000 of yacc.c */
1604 #line 1605 "SCDoc.tab.cpp"
1606 case 79: /* "optbody" */
1608 /* Line 1000 of yacc.c */
1610 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1612 /* Line 1000 of yacc.c */
1613 #line 1614 "SCDoc.tab.cpp"
1615 case 80: /* "optargs" */
1617 /* Line 1000 of yacc.c */
1619 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1621 /* Line 1000 of yacc.c */
1622 #line 1623 "SCDoc.tab.cpp"
1624 case 81: /* "args" */
1626 /* Line 1000 of yacc.c */
1628 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1630 /* Line 1000 of yacc.c */
1631 #line 1632 "SCDoc.tab.cpp"
1633 case 82: /* "arg" */
1635 /* Line 1000 of yacc.c */
1637 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1639 /* Line 1000 of yacc.c */
1640 #line 1641 "SCDoc.tab.cpp"
1642 case 83: /* "optreturns" */
1644 /* Line 1000 of yacc.c */
1646 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1648 /* Line 1000 of yacc.c */
1649 #line 1650 "SCDoc.tab.cpp"
1651 case 84: /* "optdiscussion" */
1653 /* Line 1000 of yacc.c */
1655 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1657 /* Line 1000 of yacc.c */
1658 #line 1659 "SCDoc.tab.cpp"
1660 case 85: /* "body" */
1662 /* Line 1000 of yacc.c */
1664 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1666 /* Line 1000 of yacc.c */
1667 #line 1668 "SCDoc.tab.cpp"
1669 case 86: /* "blockA" */
1671 /* Line 1000 of yacc.c */
1673 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1675 /* Line 1000 of yacc.c */
1676 #line 1677 "SCDoc.tab.cpp"
1678 case 87: /* "blockB" */
1680 /* Line 1000 of yacc.c */
1682 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1684 /* Line 1000 of yacc.c */
1685 #line 1686 "SCDoc.tab.cpp"
1687 case 88: /* "bodyelem" */
1689 /* Line 1000 of yacc.c */
1691 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1693 /* Line 1000 of yacc.c */
1694 #line 1695 "SCDoc.tab.cpp"
1696 case 89: /* "prose" */
1698 /* Line 1000 of yacc.c */
1700 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1702 /* Line 1000 of yacc.c */
1703 #line 1704 "SCDoc.tab.cpp"
1705 case 90: /* "proseelem" */
1707 /* Line 1000 of yacc.c */
1709 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1711 /* Line 1000 of yacc.c */
1712 #line 1713 "SCDoc.tab.cpp"
1714 case 95: /* "listbody" */
1716 /* Line 1000 of yacc.c */
1718 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1720 /* Line 1000 of yacc.c */
1721 #line 1722 "SCDoc.tab.cpp"
1723 case 96: /* "tablerow" */
1725 /* Line 1000 of yacc.c */
1727 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1729 /* Line 1000 of yacc.c */
1730 #line 1731 "SCDoc.tab.cpp"
1732 case 97: /* "tablebody" */
1734 /* Line 1000 of yacc.c */
1736 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1738 /* Line 1000 of yacc.c */
1739 #line 1740 "SCDoc.tab.cpp"
1741 case 98: /* "tablecells" */
1743 /* Line 1000 of yacc.c */
1745 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1747 /* Line 1000 of yacc.c */
1748 #line 1749 "SCDoc.tab.cpp"
1750 case 99: /* "defterms" */
1752 /* Line 1000 of yacc.c */
1754 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1756 /* Line 1000 of yacc.c */
1757 #line 1758 "SCDoc.tab.cpp"
1759 case 100: /* "deflistrow" */
1761 /* Line 1000 of yacc.c */
1763 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1765 /* Line 1000 of yacc.c */
1766 #line 1767 "SCDoc.tab.cpp"
1768 case 101: /* "deflistbody" */
1770 /* Line 1000 of yacc.c */
1772 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1774 /* Line 1000 of yacc.c */
1775 #line 1776 "SCDoc.tab.cpp"
1777 case 102: /* "anywordurl" */
1779 /* Line 1000 of yacc.c */
1781 { free((yyvaluep
->str
)); };
1783 /* Line 1000 of yacc.c */
1784 #line 1785 "SCDoc.tab.cpp"
1786 case 103: /* "anyword" */
1788 /* Line 1000 of yacc.c */
1790 { free((yyvaluep
->str
)); };
1792 /* Line 1000 of yacc.c */
1793 #line 1794 "SCDoc.tab.cpp"
1795 case 104: /* "words" */
1797 /* Line 1000 of yacc.c */
1799 { free((yyvaluep
->str
)); };
1801 /* Line 1000 of yacc.c */
1802 #line 1803 "SCDoc.tab.cpp"
1804 case 105: /* "words2" */
1806 /* Line 1000 of yacc.c */
1808 { free((yyvaluep
->str
)); };
1810 /* Line 1000 of yacc.c */
1811 #line 1812 "SCDoc.tab.cpp"
1813 case 107: /* "anywordnl" */
1815 /* Line 1000 of yacc.c */
1817 { free((yyvaluep
->str
)); };
1819 /* Line 1000 of yacc.c */
1820 #line 1821 "SCDoc.tab.cpp"
1822 case 108: /* "wordsnl" */
1824 /* Line 1000 of yacc.c */
1826 { free((yyvaluep
->str
)); };
1828 /* Line 1000 of yacc.c */
1829 #line 1830 "SCDoc.tab.cpp"
1831 case 109: /* "nocommawords" */
1833 /* Line 1000 of yacc.c */
1835 { free((yyvaluep
->str
)); };
1837 /* Line 1000 of yacc.c */
1838 #line 1839 "SCDoc.tab.cpp"
1840 case 110: /* "commalist" */
1842 /* Line 1000 of yacc.c */
1844 { doc_node_free_tree((yyvaluep
->doc_node
)); };
1846 /* Line 1000 of yacc.c */
1847 #line 1848 "SCDoc.tab.cpp"
1855 /* Prevent warnings from -Wmissing-prototypes. */
1856 #ifdef YYPARSE_PARAM
1857 #if defined __STDC__ || defined __cplusplus
1858 int yyparse (void *YYPARSE_PARAM
);
1862 #else /* ! YYPARSE_PARAM */
1863 #if defined __STDC__ || defined __cplusplus
1868 #endif /* ! YYPARSE_PARAM */
1871 /* The lookahead symbol. */
1874 /* The semantic value of the lookahead symbol. */
1877 /* Location data for the lookahead symbol. */
1880 /* Number of syntax errors so far. */
1885 /*-------------------------.
1886 | yyparse or yypush_parse. |
1887 `-------------------------*/
1889 #ifdef YYPARSE_PARAM
1890 #if (defined __STDC__ || defined __C99__FUNC__ \
1891 || defined __cplusplus || defined _MSC_VER)
1893 yyparse (void *YYPARSE_PARAM
)
1896 yyparse (YYPARSE_PARAM
)
1897 void *YYPARSE_PARAM
;
1899 #else /* ! YYPARSE_PARAM */
1900 #if (defined __STDC__ || defined __C99__FUNC__ \
1901 || defined __cplusplus || defined _MSC_VER)
1914 /* Number of tokens to shift before error messages enabled. */
1917 /* The stacks and their tools:
1918 `yyss': related to states.
1919 `yyvs': related to semantic values.
1920 `yyls': related to locations.
1922 Refer to the stacks thru separate pointers, to allow yyoverflow
1923 to reallocate them elsewhere. */
1925 /* The state stack. */
1926 yytype_int16 yyssa
[YYINITDEPTH
];
1928 yytype_int16
*yyssp
;
1930 /* The semantic value stack. */
1931 YYSTYPE yyvsa
[YYINITDEPTH
];
1935 /* The location stack. */
1936 YYLTYPE yylsa
[YYINITDEPTH
];
1940 /* The locations where the error started and ended. */
1941 YYLTYPE yyerror_range
[2];
1943 YYSIZE_T yystacksize
;
1947 /* Lookahead token as an internal (translated) token number. */
1949 /* The variables used to return semantic value and location from the
1955 /* Buffer for error messages, and its allocated size. */
1957 char *yymsg
= yymsgbuf
;
1958 YYSIZE_T yymsg_alloc
= sizeof yymsgbuf
;
1961 #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
1963 /* The number of symbols on the RHS of the reduced rule.
1964 Keep to zero when no symbol should be popped. */
1971 yystacksize
= YYINITDEPTH
;
1973 YYDPRINTF ((stderr
, "Starting parse\n"));
1978 yychar
= YYEMPTY
; /* Cause a token to be read. */
1980 /* Initialize stack pointers.
1981 Waste one element of value and location stack
1982 so that they stay on the same level as the state stack.
1983 The wasted elements are never initialized. */
1988 #if YYLTYPE_IS_TRIVIAL
1989 /* Initialize the default location before parsing starts. */
1990 yylloc
.first_line
= yylloc
.last_line
= 1;
1991 yylloc
.first_column
= yylloc
.last_column
= 1;
1996 /*------------------------------------------------------------.
1997 | yynewstate -- Push a new state, which is found in yystate. |
1998 `------------------------------------------------------------*/
2000 /* In all cases, when you get here, the value and location stacks
2001 have just been pushed. So pushing a state here evens the stacks. */
2007 if (yyss
+ yystacksize
- 1 <= yyssp
)
2009 /* Get the current used size of the three stacks, in elements. */
2010 YYSIZE_T yysize
= yyssp
- yyss
+ 1;
2014 /* Give user a chance to reallocate the stack. Use copies of
2015 these so that the &'s don't force the real ones into
2017 YYSTYPE
*yyvs1
= yyvs
;
2018 yytype_int16
*yyss1
= yyss
;
2019 YYLTYPE
*yyls1
= yyls
;
2021 /* Each stack pointer address is followed by the size of the
2022 data in use in that stack, in bytes. This used to be a
2023 conditional around just the two extra args, but that might
2024 be undefined if yyoverflow is a macro. */
2025 yyoverflow (YY_("memory exhausted"),
2026 &yyss1
, yysize
* sizeof (*yyssp
),
2027 &yyvs1
, yysize
* sizeof (*yyvsp
),
2028 &yyls1
, yysize
* sizeof (*yylsp
),
2035 #else /* no yyoverflow */
2036 # ifndef YYSTACK_RELOCATE
2037 goto yyexhaustedlab
;
2039 /* Extend the stack our own way. */
2040 if (YYMAXDEPTH
<= yystacksize
)
2041 goto yyexhaustedlab
;
2043 if (YYMAXDEPTH
< yystacksize
)
2044 yystacksize
= YYMAXDEPTH
;
2047 yytype_int16
*yyss1
= yyss
;
2048 union yyalloc
*yyptr
=
2049 (union yyalloc
*) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize
));
2051 goto yyexhaustedlab
;
2052 YYSTACK_RELOCATE (yyss_alloc
, yyss
);
2053 YYSTACK_RELOCATE (yyvs_alloc
, yyvs
);
2054 YYSTACK_RELOCATE (yyls_alloc
, yyls
);
2055 # undef YYSTACK_RELOCATE
2057 YYSTACK_FREE (yyss1
);
2060 #endif /* no yyoverflow */
2062 yyssp
= yyss
+ yysize
- 1;
2063 yyvsp
= yyvs
+ yysize
- 1;
2064 yylsp
= yyls
+ yysize
- 1;
2066 YYDPRINTF ((stderr
, "Stack size increased to %lu\n",
2067 (unsigned long int) yystacksize
));
2069 if (yyss
+ yystacksize
- 1 <= yyssp
)
2073 YYDPRINTF ((stderr
, "Entering state %d\n", yystate
));
2075 if (yystate
== YYFINAL
)
2085 /* Do appropriate processing given the current state. Read a
2086 lookahead token if we need one and don't already have one. */
2088 /* First try to decide what to do without reference to lookahead token. */
2089 yyn
= yypact
[yystate
];
2090 if (yyn
== YYPACT_NINF
)
2093 /* Not known => get a lookahead token if don't already have one. */
2095 /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
2096 if (yychar
== YYEMPTY
)
2098 YYDPRINTF ((stderr
, "Reading a token: "));
2102 if (yychar
<= YYEOF
)
2104 yychar
= yytoken
= YYEOF
;
2105 YYDPRINTF ((stderr
, "Now at end of input.\n"));
2109 yytoken
= YYTRANSLATE (yychar
);
2110 YY_SYMBOL_PRINT ("Next token is", yytoken
, &yylval
, &yylloc
);
2113 /* If the proper action on seeing token YYTOKEN is to reduce or to
2114 detect an error, take that action. */
2116 if (yyn
< 0 || YYLAST
< yyn
|| yycheck
[yyn
] != yytoken
)
2121 if (yyn
== 0 || yyn
== YYTABLE_NINF
)
2127 /* Count tokens shifted since error; after three, turn off error
2132 /* Shift the lookahead token. */
2133 YY_SYMBOL_PRINT ("Shifting", yytoken
, &yylval
, &yylloc
);
2135 /* Discard the shifted token. */
2144 /*-----------------------------------------------------------.
2145 | yydefault -- do the default action for the current state. |
2146 `-----------------------------------------------------------*/
2148 yyn
= yydefact
[yystate
];
2154 /*-----------------------------.
2155 | yyreduce -- Do a reduction. |
2156 `-----------------------------*/
2158 /* yyn is the number of a rule to reduce with. */
2161 /* If YYLEN is nonzero, implement the default value of the action:
2164 Otherwise, the following line sets YYVAL to garbage.
2165 This behavior is undocumented and Bison
2166 users should not rely upon it. Assigning to YYVAL
2167 unconditionally makes the parser a bit smaller, and it avoids a
2168 GCC warning that YYVAL may be used uninitialized. */
2169 yyval
= yyvsp
[1-yylen
];
2171 /* Default location. */
2172 YYLLOC_DEFAULT (yyloc
, (yylsp
- yylen
), yylen
);
2173 YY_REDUCE_PRINT (yyn
);
2178 /* Line 1455 of yacc.c */
2180 { topnode
= (yyvsp
[(1) - (1)].doc_node
); ;}
2185 /* Line 1455 of yacc.c */
2187 { topnode
= NULL
; doc_node_free_tree((yyvsp
[(1) - (2)].doc_node
)); ;}
2192 /* Line 1455 of yacc.c */
2195 (yyval
.doc_node
) = doc_node_create("DOCUMENT");
2196 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(3) - (4)].doc_node
));
2197 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(4) - (4)].doc_node
));
2203 /* Line 1455 of yacc.c */
2206 (yyval
.doc_node
) = doc_node_make_take_children("BODY",NULL
,(yyvsp
[(2) - (2)].doc_node
));
2212 /* Line 1455 of yacc.c */
2215 (yyval
.doc_node
) = doc_node_create("DOCUMENT");
2216 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(2) - (3)].doc_node
));
2217 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(3) - (3)].doc_node
));
2223 /* Line 1455 of yacc.c */
2225 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2230 /* Line 1455 of yacc.c */
2232 { (yyval
.doc_node
) = doc_node_make("HEADER",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2237 /* Line 1455 of yacc.c */
2239 { (yyval
.doc_node
) = doc_node_make((yyvsp
[(1) - (3)].id
),(yyvsp
[(2) - (3)].str
),NULL
); ;}
2244 /* Line 1455 of yacc.c */
2246 { (yyval
.doc_node
) = doc_node_make_take_children("CATEGORIES",NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2251 /* Line 1455 of yacc.c */
2253 { (yyval
.doc_node
) = doc_node_make_take_children("RELATED",NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2258 /* Line 1455 of yacc.c */
2260 { (yyval
.id
) = "TITLE"; ;}
2265 /* Line 1455 of yacc.c */
2267 { (yyval
.id
) = "TITLE"; ;}
2272 /* Line 1455 of yacc.c */
2274 { (yyval
.id
) = "SUMMARY"; ;}
2279 /* Line 1455 of yacc.c */
2281 { (yyval
.id
) = "REDIRECT"; ;}
2286 /* Line 1455 of yacc.c */
2288 { (yyval
.id
) = "CLASSMETHODS"; method_type
= "CMETHOD"; ;}
2293 /* Line 1455 of yacc.c */
2295 { (yyval
.id
) = "INSTANCEMETHODS"; method_type
= "IMETHOD"; ;}
2300 /* Line 1455 of yacc.c */
2302 { (yyval
.id
) = "DESCRIPTION"; method_type
= "METHOD"; ;}
2307 /* Line 1455 of yacc.c */
2309 { (yyval
.id
) = "EXAMPLES"; method_type
= "METHOD"; ;}
2314 /* Line 1455 of yacc.c */
2316 { (yyval
.doc_node
) = doc_node_make("BODY",NULL
,NULL
); ;}
2321 /* Line 1455 of yacc.c */
2323 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2328 /* Line 1455 of yacc.c */
2330 { (yyval
.doc_node
) = doc_node_make("BODY",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2335 /* Line 1455 of yacc.c */
2337 { (yyval
.doc_node
) = doc_node_make_take_children("BODY",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2342 /* Line 1455 of yacc.c */
2344 { method_type
= "METHOD"; ;}
2349 /* Line 1455 of yacc.c */
2351 { (yyval
.doc_node
) = doc_node_make_take_children("SECTION",(yyvsp
[(3) - (5)].str
),(yyvsp
[(5) - (5)].doc_node
)); ;}
2356 /* Line 1455 of yacc.c */
2358 { (yyval
.doc_node
) = doc_node_make_take_children((yyvsp
[(1) - (2)].id
), NULL
,(yyvsp
[(2) - (2)].doc_node
)); ;}
2363 /* Line 1455 of yacc.c */
2365 { (yyval
.doc_node
) = NULL
; ;}
2370 /* Line 1455 of yacc.c */
2372 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2377 /* Line 1455 of yacc.c */
2379 { (yyval
.doc_node
) = doc_node_make("(SUBSECTIONS)",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2384 /* Line 1455 of yacc.c */
2386 { (yyval
.doc_node
) = doc_node_make_take_children("SUBSECTION", (yyvsp
[(2) - (4)].str
), (yyvsp
[(4) - (4)].doc_node
)); ;}
2391 /* Line 1455 of yacc.c */
2393 { (yyval
.doc_node
) = NULL
; ;}
2398 /* Line 1455 of yacc.c */
2400 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2405 /* Line 1455 of yacc.c */
2407 { (yyval
.doc_node
) = doc_node_make("(SUBSUBSECTIONS)",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2412 /* Line 1455 of yacc.c */
2414 { (yyval
.doc_node
) = doc_node_make_take_children("(SUBSUBSECTIONS)",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2419 /* Line 1455 of yacc.c */
2422 (yyvsp
[(2) - (5)].doc_node
)->id
= "METHODNAMES";
2423 (yyval
.doc_node
) = doc_node_make(method_type
,(yyvsp
[(3) - (5)].str
),(yyvsp
[(2) - (5)].doc_node
));
2424 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(5) - (5)].doc_node
));
2425 // doc_node_add_child($2, $3);
2431 /* Line 1455 of yacc.c */
2433 { (yyval
.doc_node
) = doc_node_make(
2434 method_type
=="CMETHOD"?"CCOPYMETHOD":(method_type
=="IMETHOD"?"ICOPYMETHOD":"COPYMETHOD"),
2435 (yyvsp
[(2) - (3)].str
),NULL
2441 /* Line 1455 of yacc.c */
2443 { (yyval
.doc_node
) = doc_node_make_take_children(method_type
=="CMETHOD"?"CPRIVATE":"IPRIVATE",NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2448 /* Line 1455 of yacc.c */
2450 { (yyval
.str
) = NULL
; ;}
2455 /* Line 1455 of yacc.c */
2458 // $$ = doc_node_make("ARGSTRING",$1,NULL);
2459 (yyval
.str
) = (yyvsp
[(1) - (1)].str
);
2460 if(method_type
!="METHOD") {
2461 yyerror("METHOD argument string is not allowed inside CLASSMETHODS or INSTANCEMETHODS");
2469 /* Line 1455 of yacc.c */
2472 char *p
= (yyvsp
[(1) - (1)].str
)+strlen((yyvsp
[(1) - (1)].str
))-1;
2474 post("WARNING: SCDoc: In %s\n Property setter %s should be documented without underscore.\n", scdoc_current_file
, (yyvsp
[(1) - (1)].str
));
2477 (yyval
.str
) = (yyvsp
[(1) - (1)].str
);
2483 /* Line 1455 of yacc.c */
2485 { free((yyvsp
[(2) - (3)].str
)); (yyvsp
[(2) - (3)].str
) = NULL
; (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (3)].doc_node
), doc_node_make("STRING",(yyvsp
[(3) - (3)].str
),NULL
)); ;}
2490 /* Line 1455 of yacc.c */
2492 { (yyval
.doc_node
) = doc_node_make("(METHODNAMES)",NULL
,doc_node_make("STRING",(yyvsp
[(1) - (1)].str
),NULL
)); ;}
2497 /* Line 1455 of yacc.c */
2500 (yyval
.doc_node
) = doc_node_make_take_children("METHODBODY",NULL
,(yyvsp
[(1) - (4)].doc_node
));
2501 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(2) - (4)].doc_node
));
2502 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(3) - (4)].doc_node
));
2503 doc_node_add_child((yyval
.doc_node
), (yyvsp
[(4) - (4)].doc_node
));
2509 /* Line 1455 of yacc.c */
2511 { (yyval
.doc_node
) = NULL
; ;}
2516 /* Line 1455 of yacc.c */
2518 { (yyval
.doc_node
) = NULL
; ;}
2523 /* Line 1455 of yacc.c */
2525 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2530 /* Line 1455 of yacc.c */
2532 { (yyval
.doc_node
) = doc_node_make("ARGUMENTS",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2537 /* Line 1455 of yacc.c */
2539 { (yyval
.doc_node
) = doc_node_make_take_children("ARGUMENT", (yyvsp
[(2) - (4)].str
), (yyvsp
[(4) - (4)].doc_node
)); ;}
2544 /* Line 1455 of yacc.c */
2546 { (yyval
.doc_node
) = doc_node_make_take_children("ARGUMENT", NULL
, (yyvsp
[(3) - (3)].doc_node
)); ;}
2551 /* Line 1455 of yacc.c */
2553 { (yyval
.doc_node
) = doc_node_make_take_children("RETURNS",NULL
,(yyvsp
[(2) - (2)].doc_node
)); ;}
2558 /* Line 1455 of yacc.c */
2560 { (yyval
.doc_node
) = NULL
; ;}
2565 /* Line 1455 of yacc.c */
2567 { (yyval
.doc_node
) = doc_node_make_take_children("DISCUSSION",NULL
,(yyvsp
[(2) - (2)].doc_node
)); ;}
2572 /* Line 1455 of yacc.c */
2574 { (yyval
.doc_node
) = NULL
; ;}
2579 /* Line 1455 of yacc.c */
2581 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2586 /* Line 1455 of yacc.c */
2588 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2593 /* Line 1455 of yacc.c */
2595 { (yyval
.doc_node
) = doc_node_make("(SECTIONBODY)",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2600 /* Line 1455 of yacc.c */
2602 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2607 /* Line 1455 of yacc.c */
2609 { (yyval
.doc_node
) = doc_node_make("(SECTIONBODY)",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2614 /* Line 1455 of yacc.c */
2616 { (yyval
.doc_node
) = doc_node_make_take_children((yyvsp
[(1) - (3)].id
),NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2621 /* Line 1455 of yacc.c */
2623 { (yyval
.doc_node
) = doc_node_make_take_children((yyvsp
[(1) - (3)].id
),NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2628 /* Line 1455 of yacc.c */
2630 { (yyval
.doc_node
) = doc_node_make_take_children("TABLE",NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2635 /* Line 1455 of yacc.c */
2637 { (yyval
.doc_node
) = doc_node_make_take_children("DEFINITIONLIST",NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2642 /* Line 1455 of yacc.c */
2644 { (yyval
.doc_node
) = doc_node_make((yyvsp
[(1) - (3)].id
),(yyvsp
[(2) - (3)].str
),NULL
); ;}
2649 /* Line 1455 of yacc.c */
2651 { (yyval
.doc_node
) = doc_node_make("CLASSTREE",(yyvsp
[(2) - (3)].str
),NULL
); ;}
2656 /* Line 1455 of yacc.c */
2658 { (yyval
.doc_node
) = doc_node_make_take_children("KEYWORD",NULL
,(yyvsp
[(2) - (3)].doc_node
));
2659 // printf("keyword '%s'\n",$2->children[0]->text);
2665 /* Line 1455 of yacc.c */
2667 { (yyval
.doc_node
) = NULL
; ;}
2672 /* Line 1455 of yacc.c */
2674 { (yyval
.doc_node
) = doc_node_make("IMAGE",(yyvsp
[(2) - (3)].str
),NULL
); ;}
2679 /* Line 1455 of yacc.c */
2681 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
), (yyvsp
[(2) - (2)].doc_node
)); ;}
2686 /* Line 1455 of yacc.c */
2688 { (yyval
.doc_node
) = doc_node_make("PROSE",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2693 /* Line 1455 of yacc.c */
2695 { (yyval
.doc_node
) = doc_node_make("TEXT",(yyvsp
[(1) - (1)].str
),NULL
); ;}
2700 /* Line 1455 of yacc.c */
2702 { (yyval
.doc_node
) = doc_node_make("LINK",(yyvsp
[(1) - (1)].str
),NULL
); ;}
2707 /* Line 1455 of yacc.c */
2709 { (yyval
.doc_node
) = doc_node_make((yyvsp
[(1) - (3)].id
),(yyvsp
[(2) - (3)].str
),NULL
); ;}
2714 /* Line 1455 of yacc.c */
2716 { (yyval
.doc_node
) = doc_node_make_take_children("FOOTNOTE",NULL
,(yyvsp
[(2) - (3)].doc_node
)); ;}
2721 /* Line 1455 of yacc.c */
2723 { (yyval
.doc_node
) = doc_node_create("NL"); ;}
2728 /* Line 1455 of yacc.c */
2730 { (yyval
.id
) = "LINK"; ;}
2735 /* Line 1455 of yacc.c */
2737 { (yyval
.id
) = "STRONG"; ;}
2742 /* Line 1455 of yacc.c */
2744 { (yyval
.id
) = "SOFT"; ;}
2749 /* Line 1455 of yacc.c */
2751 { (yyval
.id
) = "EMPHASIS"; ;}
2756 /* Line 1455 of yacc.c */
2758 { (yyval
.id
) = "CODE"; ;}
2763 /* Line 1455 of yacc.c */
2765 { (yyval
.id
) = "TELETYPE"; ;}
2770 /* Line 1455 of yacc.c */
2772 { (yyval
.id
) = "MATH"; ;}
2777 /* Line 1455 of yacc.c */
2779 { (yyval
.id
) = "ANCHOR"; ;}
2784 /* Line 1455 of yacc.c */
2786 { (yyval
.id
) = "CODEBLOCK"; ;}
2791 /* Line 1455 of yacc.c */
2793 { (yyval
.id
) = "TELETYPEBLOCK"; ;}
2798 /* Line 1455 of yacc.c */
2800 { (yyval
.id
) = "MATHBLOCK"; ;}
2805 /* Line 1455 of yacc.c */
2807 { (yyval
.id
) = "LIST"; ;}
2812 /* Line 1455 of yacc.c */
2814 { (yyval
.id
) = "TREE"; ;}
2819 /* Line 1455 of yacc.c */
2821 { (yyval
.id
) = "NUMBEREDLIST"; ;}
2826 /* Line 1455 of yacc.c */
2828 { (yyval
.id
) = "WARNING"; ;}
2833 /* Line 1455 of yacc.c */
2835 { (yyval
.id
) = "NOTE"; ;}
2840 /* Line 1455 of yacc.c */
2842 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (3)].doc_node
), doc_node_make_take_children("ITEM",NULL
,(yyvsp
[(3) - (3)].doc_node
))); ;}
2847 /* Line 1455 of yacc.c */
2849 { (yyval
.doc_node
) = doc_node_make("(LISTBODY)",NULL
, doc_node_make_take_children("ITEM",NULL
,(yyvsp
[(2) - (2)].doc_node
))); ;}
2854 /* Line 1455 of yacc.c */
2856 { (yyval
.doc_node
) = doc_node_make_take_children("TABROW",NULL
,(yyvsp
[(2) - (2)].doc_node
)); ;}
2861 /* Line 1455 of yacc.c */
2863 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2868 /* Line 1455 of yacc.c */
2870 { (yyval
.doc_node
) = doc_node_make("(TABLEBODY)",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2875 /* Line 1455 of yacc.c */
2877 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (3)].doc_node
), doc_node_make_take_children("TABCOL",NULL
,(yyvsp
[(3) - (3)].doc_node
))); ;}
2882 /* Line 1455 of yacc.c */
2884 { (yyval
.doc_node
) = doc_node_make("(TABLECELLS)",NULL
, doc_node_make_take_children("TABCOL",NULL
,(yyvsp
[(1) - (1)].doc_node
))); ;}
2889 /* Line 1455 of yacc.c */
2891 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (3)].doc_node
),doc_node_make_take_children("TERM",NULL
,(yyvsp
[(3) - (3)].doc_node
))); ;}
2896 /* Line 1455 of yacc.c */
2898 { (yyval
.doc_node
) = doc_node_make("(TERMS)",NULL
,doc_node_make_take_children("TERM",NULL
,(yyvsp
[(2) - (2)].doc_node
))); ;}
2903 /* Line 1455 of yacc.c */
2906 (yyval
.doc_node
) = doc_node_make_take_children("DEFLISTITEM", NULL
, (yyvsp
[(1) - (3)].doc_node
));
2907 doc_node_add_child((yyval
.doc_node
), doc_node_make_take_children("DEFINITION", NULL
, (yyvsp
[(3) - (3)].doc_node
)));
2913 /* Line 1455 of yacc.c */
2915 { (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (2)].doc_node
),(yyvsp
[(2) - (2)].doc_node
)); ;}
2920 /* Line 1455 of yacc.c */
2922 { (yyval
.doc_node
) = doc_node_make("(DEFLISTBODY)",NULL
,(yyvsp
[(1) - (1)].doc_node
)); ;}
2927 /* Line 1455 of yacc.c */
2929 { (yyval
.str
) = strmerge((yyvsp
[(1) - (2)].str
),(yyvsp
[(2) - (2)].str
)); ;}
2934 /* Line 1455 of yacc.c */
2936 { (yyval
.str
) = strmerge((yyvsp
[(1) - (2)].str
),(yyvsp
[(2) - (2)].str
)); ;}
2941 /* Line 1455 of yacc.c */
2943 { (yyval
.str
) = strdup("\n"); ;}
2948 /* Line 1455 of yacc.c */
2950 { (yyval
.str
) = strmerge((yyvsp
[(1) - (2)].str
),(yyvsp
[(2) - (2)].str
)); ;}
2955 /* Line 1455 of yacc.c */
2957 { (yyval
.str
) = strmerge((yyvsp
[(1) - (2)].str
),(yyvsp
[(2) - (2)].str
)); ;}
2962 /* Line 1455 of yacc.c */
2964 { (yyval
.str
) = strmerge((yyvsp
[(1) - (2)].str
),(yyvsp
[(2) - (2)].str
)); ;}
2969 /* Line 1455 of yacc.c */
2971 { free((yyvsp
[(2) - (3)].str
)); (yyvsp
[(2) - (3)].str
)=NULL
; (yyval
.doc_node
) = doc_node_add_child((yyvsp
[(1) - (3)].doc_node
),doc_node_make("STRING",(yyvsp
[(3) - (3)].str
),NULL
)); ;}
2976 /* Line 1455 of yacc.c */
2978 { (yyval
.doc_node
) = doc_node_make("(COMMALIST)",NULL
,doc_node_make("STRING",(yyvsp
[(1) - (1)].str
),NULL
)); ;}
2983 /* Line 1455 of yacc.c */
2984 #line 2985 "SCDoc.tab.cpp"
2987 YY_SYMBOL_PRINT ("-> $$ =", yyr1
[yyn
], &yyval
, &yyloc
);
2991 YY_STACK_PRINT (yyss
, yyssp
);
2996 /* Now `shift' the result of the reduction. Determine what state
2997 that goes to, based on the state we popped back to and the rule
2998 number reduced by. */
3002 yystate
= yypgoto
[yyn
- YYNTOKENS
] + *yyssp
;
3003 if (0 <= yystate
&& yystate
<= YYLAST
&& yycheck
[yystate
] == *yyssp
)
3004 yystate
= yytable
[yystate
];
3006 yystate
= yydefgoto
[yyn
- YYNTOKENS
];
3011 /*------------------------------------.
3012 | yyerrlab -- here on detecting error |
3013 `------------------------------------*/
3015 /* If not already recovering from an error, report this error. */
3019 #if ! YYERROR_VERBOSE
3020 yyerror (YY_("syntax error"));
3023 YYSIZE_T yysize
= yysyntax_error (0, yystate
, yychar
);
3024 if (yymsg_alloc
< yysize
&& yymsg_alloc
< YYSTACK_ALLOC_MAXIMUM
)
3026 YYSIZE_T yyalloc
= 2 * yysize
;
3027 if (! (yysize
<= yyalloc
&& yyalloc
<= YYSTACK_ALLOC_MAXIMUM
))
3028 yyalloc
= YYSTACK_ALLOC_MAXIMUM
;
3029 if (yymsg
!= yymsgbuf
)
3030 YYSTACK_FREE (yymsg
);
3031 yymsg
= (char *) YYSTACK_ALLOC (yyalloc
);
3033 yymsg_alloc
= yyalloc
;
3037 yymsg_alloc
= sizeof yymsgbuf
;
3041 if (0 < yysize
&& yysize
<= yymsg_alloc
)
3043 (void) yysyntax_error (yymsg
, yystate
, yychar
);
3048 yyerror (YY_("syntax error"));
3050 goto yyexhaustedlab
;
3056 yyerror_range
[0] = yylloc
;
3058 if (yyerrstatus
== 3)
3060 /* If just tried and failed to reuse lookahead token after an
3061 error, discard it. */
3063 if (yychar
<= YYEOF
)
3065 /* Return failure if at end of input. */
3066 if (yychar
== YYEOF
)
3071 yydestruct ("Error: discarding",
3072 yytoken
, &yylval
, &yylloc
);
3077 /* Else will try to reuse lookahead token after shifting the error
3082 /*---------------------------------------------------.
3083 | yyerrorlab -- error raised explicitly by YYERROR. |
3084 `---------------------------------------------------*/
3087 /* Pacify compilers like GCC when the user code never invokes
3088 YYERROR and the label yyerrorlab therefore never appears in user
3090 if (/*CONSTCOND*/ 0)
3093 yyerror_range
[0] = yylsp
[1-yylen
];
3094 /* Do not reclaim the symbols of the rule which action triggered
3098 YY_STACK_PRINT (yyss
, yyssp
);
3103 /*-------------------------------------------------------------.
3104 | yyerrlab1 -- common code for both syntax error and YYERROR. |
3105 `-------------------------------------------------------------*/
3107 yyerrstatus
= 3; /* Each real token shifted decrements this. */
3111 yyn
= yypact
[yystate
];
3112 if (yyn
!= YYPACT_NINF
)
3115 if (0 <= yyn
&& yyn
<= YYLAST
&& yycheck
[yyn
] == YYTERROR
)
3123 /* Pop the current state because it cannot handle the error token. */
3127 yyerror_range
[0] = *yylsp
;
3128 yydestruct ("Error: popping",
3129 yystos
[yystate
], yyvsp
, yylsp
);
3132 YY_STACK_PRINT (yyss
, yyssp
);
3137 yyerror_range
[1] = yylloc
;
3138 /* Using YYLLOC is tempting, but would change the location of
3139 the lookahead. YYLOC is available though. */
3140 YYLLOC_DEFAULT (yyloc
, (yyerror_range
- 1), 2);
3143 /* Shift the error token. */
3144 YY_SYMBOL_PRINT ("Shifting", yystos
[yyn
], yyvsp
, yylsp
);
3150 /*-------------------------------------.
3151 | yyacceptlab -- YYACCEPT comes here. |
3152 `-------------------------------------*/
3157 /*-----------------------------------.
3158 | yyabortlab -- YYABORT comes here. |
3159 `-----------------------------------*/
3164 #if !defined(yyoverflow) || YYERROR_VERBOSE
3165 /*-------------------------------------------------.
3166 | yyexhaustedlab -- memory exhaustion comes here. |
3167 `-------------------------------------------------*/
3169 yyerror (YY_("memory exhausted"));
3175 if (yychar
!= YYEMPTY
)
3176 yydestruct ("Cleanup: discarding lookahead",
3177 yytoken
, &yylval
, &yylloc
);
3178 /* Do not reclaim the symbols of the rule which action triggered
3179 this YYABORT or YYACCEPT. */
3181 YY_STACK_PRINT (yyss
, yyssp
);
3182 while (yyssp
!= yyss
)
3184 yydestruct ("Cleanup: popping",
3185 yystos
[*yyssp
], yyvsp
, yylsp
);
3190 YYSTACK_FREE (yyss
);
3193 if (yymsg
!= yymsgbuf
)
3194 YYSTACK_FREE (yymsg
);
3196 /* Make sure YYID is used. */
3197 return YYID (yyresult
);
3202 /* Line 1675 of yacc.c */
3206 DocNode
* scdoc_parse_run(int mode
) {
3207 int modes
[] = {START_FULL
, START_PARTIAL
, START_METADATA
};
3208 if(mode
<0 || mode
>=sizeof(modes
)) {
3209 error("scdoc_parse_run(): unknown mode: %d\n",mode
);
3211 scdoc_start_token
= modes
[mode
];
3212 /* scdoc_start_token = START_FULL;
3213 scdoc_metadata_mode = 0;
3214 if(mode==SCDOC_PARSE_PARTIAL) {
3215 scdoc_start_token = START_PARTIAL;
3217 if(mode==SCDOC_PARSE_METADATA) {
3218 scdoc_metadata_mode = 1;
3221 method_type
= "METHOD";
3222 if(scdocparse()!=0) {
3228 void scdocerror(const char *str
)
3230 error("In %s:\n At line %d: %s\n\n",scdoc_current_file
,scdoclineno
,str
);
3232 /* FIXME: this does not work well, since the reported linenumber is often *after* the actual error line
3233 fseek(scdocin, 0, SEEK_SET);
3236 while(line!=scdoclineno && !feof(scdocin)) {
3237 int c = fgetc(scdocin);
3240 txt = fgets(buf, 256, scdocin);
3242 fprintf(stderr," %s\n-------------------\n", txt);