PageRenderTime 75ms CodeModel.GetById 30ms RepoModel.GetById 1ms app.codeStats 1ms

/lib_pq/src/pl/plpgsql/src/pl_gram.c

https://bitbucket.org/xixs/lua
C | 6391 lines | 4633 code | 840 blank | 918 comment | 773 complexity | e753f34dd85997bb4304029f3d6863b3 MD5 | raw file
Possible License(s): Zlib, BSD-3-Clause, CC0-1.0, GPL-3.0, GPL-2.0, CPL-1.0, MPL-2.0-no-copyleft-exception, LGPL-2.0, LGPL-2.1, LGPL-3.0, 0BSD, Cube

Large files files are truncated, but you can click here to view the full file

  1. /* A Bison parser, made by GNU Bison 2.5. */
  2. /* Bison implementation for Yacc-like parsers in C
  3. Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc.
  4. This program is free software: you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation, either version 3 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program. If not, see <http://www.gnu.org/licenses/>. */
  14. /* As a special exception, you may create a larger work that contains
  15. part or all of the Bison parser skeleton and distribute that work
  16. under terms of your choice, so long as that work isn't itself a
  17. parser generator using the skeleton or a modified version thereof
  18. as a parser skeleton. Alternatively, if you modify or redistribute
  19. the parser skeleton itself, you may (at your option) remove this
  20. special exception, which will cause the skeleton and the resulting
  21. Bison output files to be licensed under the GNU General Public
  22. License without this special exception.
  23. This special exception was added by the Free Software Foundation in
  24. version 2.2 of Bison. */
  25. /* C LALR(1) parser skeleton written by Richard Stallman, by
  26. simplifying the original so-called "semantic" parser. */
  27. /* All symbols defined below should begin with yy or YY, to avoid
  28. infringing on user name space. This should be done even for local
  29. variables, as they might otherwise be expanded by user macros.
  30. There are some unavoidable exceptions within include files to
  31. define necessary library symbols; they are noted "INFRINGES ON
  32. USER NAME SPACE" below. */
  33. /* Identify Bison output. */
  34. #define YYBISON 1
  35. /* Bison version. */
  36. #define YYBISON_VERSION "2.5"
  37. /* Skeleton name. */
  38. #define YYSKELETON_NAME "yacc.c"
  39. /* Pure parsers. */
  40. #define YYPURE 0
  41. /* Push parsers. */
  42. #define YYPUSH 0
  43. /* Pull parsers. */
  44. #define YYPULL 1
  45. /* Using locations. */
  46. #define YYLSP_NEEDED 1
  47. /* Substitute the variable and function names. */
  48. #define yyparse plpgsql_yyparse
  49. #define yylex plpgsql_yylex
  50. #define yyerror plpgsql_yyerror
  51. #define yylval plpgsql_yylval
  52. #define yychar plpgsql_yychar
  53. #define yydebug plpgsql_yydebug
  54. #define yynerrs plpgsql_yynerrs
  55. #define yylloc plpgsql_yylloc
  56. /* Copy the first part of user declarations. */
  57. /* Line 268 of yacc.c */
  58. #line 1 "pl_gram.y"
  59. /*-------------------------------------------------------------------------
  60. *
  61. * pl_gram.y - Parser for the PL/pgSQL procedural language
  62. *
  63. * Portions Copyright (c) 1996-2014, PostgreSQL Global Development Group
  64. * Portions Copyright (c) 1994, Regents of the University of California
  65. *
  66. *
  67. * IDENTIFICATION
  68. * src/pl/plpgsql/src/pl_gram.y
  69. *
  70. *-------------------------------------------------------------------------
  71. */
  72. #include "plpgsql.h"
  73. #include "catalog/namespace.h"
  74. #include "catalog/pg_type.h"
  75. #include "parser/parser.h"
  76. #include "parser/parse_type.h"
  77. #include "parser/scanner.h"
  78. #include "parser/scansup.h"
  79. #include "utils/builtins.h"
  80. /* Location tracking support --- simpler than bison's default */
  81. #define YYLLOC_DEFAULT(Current, Rhs, N) \
  82. do { \
  83. if (N) \
  84. (Current) = (Rhs)[1]; \
  85. else \
  86. (Current) = (Rhs)[0]; \
  87. } while (0)
  88. /*
  89. * Bison doesn't allocate anything that needs to live across parser calls,
  90. * so we can easily have it use palloc instead of malloc. This prevents
  91. * memory leaks if we error out during parsing. Note this only works with
  92. * bison >= 2.0. However, in bison 1.875 the default is to use alloca()
  93. * if possible, so there's not really much problem anyhow, at least if
  94. * you're building with gcc.
  95. */
  96. #define YYMALLOC palloc
  97. #define YYFREE pfree
  98. typedef struct
  99. {
  100. int location;
  101. int leaderlen;
  102. } sql_error_callback_arg;
  103. #define parser_errposition(pos) plpgsql_scanner_errposition(pos)
  104. union YYSTYPE; /* need forward reference for tok_is_keyword */
  105. static bool tok_is_keyword(int token, union YYSTYPE *lval,
  106. int kw_token, const char *kw_str);
  107. static void word_is_not_variable(PLword *word, int location);
  108. static void cword_is_not_variable(PLcword *cword, int location);
  109. static void current_token_is_not_variable(int tok);
  110. static PLpgSQL_expr *read_sql_construct(int until,
  111. int until2,
  112. int until3,
  113. const char *expected,
  114. const char *sqlstart,
  115. bool isexpression,
  116. bool valid_sql,
  117. bool trim,
  118. int *startloc,
  119. int *endtoken);
  120. static PLpgSQL_expr *read_sql_expression(int until,
  121. const char *expected);
  122. static PLpgSQL_expr *read_sql_expression2(int until, int until2,
  123. const char *expected,
  124. int *endtoken);
  125. static PLpgSQL_expr *read_sql_stmt(const char *sqlstart);
  126. static PLpgSQL_type *read_datatype(int tok);
  127. static PLpgSQL_stmt *make_execsql_stmt(int firsttoken, int location);
  128. static PLpgSQL_stmt_fetch *read_fetch_direction(void);
  129. static void complete_direction(PLpgSQL_stmt_fetch *fetch,
  130. bool *check_FROM);
  131. static PLpgSQL_stmt *make_return_stmt(int location);
  132. static PLpgSQL_stmt *make_return_next_stmt(int location);
  133. static PLpgSQL_stmt *make_return_query_stmt(int location);
  134. static PLpgSQL_stmt *make_case(int location, PLpgSQL_expr *t_expr,
  135. List *case_when_list, List *else_stmts);
  136. static char *NameOfDatum(PLwdatum *wdatum);
  137. static void check_assignable(PLpgSQL_datum *datum, int location);
  138. static void read_into_target(PLpgSQL_rec **rec, PLpgSQL_row **row,
  139. bool *strict);
  140. static PLpgSQL_row *read_into_scalar_list(char *initial_name,
  141. PLpgSQL_datum *initial_datum,
  142. int initial_location);
  143. static PLpgSQL_row *make_scalar_list1(char *initial_name,
  144. PLpgSQL_datum *initial_datum,
  145. int lineno, int location);
  146. static void check_sql_expr(const char *stmt, int location,
  147. int leaderlen);
  148. static void plpgsql_sql_error_callback(void *arg);
  149. static PLpgSQL_type *parse_datatype(const char *string, int location);
  150. static void check_labels(const char *start_label,
  151. const char *end_label,
  152. int end_location);
  153. static PLpgSQL_expr *read_cursor_args(PLpgSQL_var *cursor,
  154. int until, const char *expected);
  155. static List *read_raise_options(void);
  156. /* Line 268 of yacc.c */
  157. #line 191 "pl_gram.c"
  158. /* Enabling traces. */
  159. #ifndef YYDEBUG
  160. # define YYDEBUG 0
  161. #endif
  162. /* Enabling verbose error messages. */
  163. #ifdef YYERROR_VERBOSE
  164. # undef YYERROR_VERBOSE
  165. # define YYERROR_VERBOSE 1
  166. #else
  167. # define YYERROR_VERBOSE 0
  168. #endif
  169. /* Enabling the token table. */
  170. #ifndef YYTOKEN_TABLE
  171. # define YYTOKEN_TABLE 0
  172. #endif
  173. /* Tokens. */
  174. #ifndef YYTOKENTYPE
  175. # define YYTOKENTYPE
  176. /* Put the tokens into the symbol table, so that GDB and other debuggers
  177. know about them. */
  178. enum yytokentype {
  179. IDENT = 258,
  180. FCONST = 259,
  181. SCONST = 260,
  182. BCONST = 261,
  183. XCONST = 262,
  184. Op = 263,
  185. ICONST = 264,
  186. PARAM = 265,
  187. TYPECAST = 266,
  188. DOT_DOT = 267,
  189. COLON_EQUALS = 268,
  190. T_WORD = 269,
  191. T_CWORD = 270,
  192. T_DATUM = 271,
  193. LESS_LESS = 272,
  194. GREATER_GREATER = 273,
  195. K_ABSOLUTE = 274,
  196. K_ALIAS = 275,
  197. K_ALL = 276,
  198. K_ARRAY = 277,
  199. K_BACKWARD = 278,
  200. K_BEGIN = 279,
  201. K_BY = 280,
  202. K_CASE = 281,
  203. K_CLOSE = 282,
  204. K_COLLATE = 283,
  205. K_COLUMN = 284,
  206. K_COLUMN_NAME = 285,
  207. K_CONSTANT = 286,
  208. K_CONSTRAINT = 287,
  209. K_CONSTRAINT_NAME = 288,
  210. K_CONTINUE = 289,
  211. K_CURRENT = 290,
  212. K_CURSOR = 291,
  213. K_DATATYPE = 292,
  214. K_DEBUG = 293,
  215. K_DECLARE = 294,
  216. K_DEFAULT = 295,
  217. K_DETAIL = 296,
  218. K_DIAGNOSTICS = 297,
  219. K_DUMP = 298,
  220. K_ELSE = 299,
  221. K_ELSIF = 300,
  222. K_END = 301,
  223. K_ERRCODE = 302,
  224. K_ERROR = 303,
  225. K_EXCEPTION = 304,
  226. K_EXECUTE = 305,
  227. K_EXIT = 306,
  228. K_FETCH = 307,
  229. K_FIRST = 308,
  230. K_FOR = 309,
  231. K_FOREACH = 310,
  232. K_FORWARD = 311,
  233. K_FROM = 312,
  234. K_GET = 313,
  235. K_HINT = 314,
  236. K_IF = 315,
  237. K_IN = 316,
  238. K_INFO = 317,
  239. K_INSERT = 318,
  240. K_INTO = 319,
  241. K_IS = 320,
  242. K_LAST = 321,
  243. K_LOG = 322,
  244. K_LOOP = 323,
  245. K_MESSAGE = 324,
  246. K_MESSAGE_TEXT = 325,
  247. K_MOVE = 326,
  248. K_NEXT = 327,
  249. K_NO = 328,
  250. K_NOT = 329,
  251. K_NOTICE = 330,
  252. K_NULL = 331,
  253. K_OPEN = 332,
  254. K_OPTION = 333,
  255. K_OR = 334,
  256. K_PERFORM = 335,
  257. K_PG_CONTEXT = 336,
  258. K_PG_DATATYPE_NAME = 337,
  259. K_PG_EXCEPTION_CONTEXT = 338,
  260. K_PG_EXCEPTION_DETAIL = 339,
  261. K_PG_EXCEPTION_HINT = 340,
  262. K_PRINT_STRICT_PARAMS = 341,
  263. K_PRIOR = 342,
  264. K_QUERY = 343,
  265. K_RAISE = 344,
  266. K_RELATIVE = 345,
  267. K_RESULT_OID = 346,
  268. K_RETURN = 347,
  269. K_RETURNED_SQLSTATE = 348,
  270. K_REVERSE = 349,
  271. K_ROWTYPE = 350,
  272. K_ROW_COUNT = 351,
  273. K_SCHEMA = 352,
  274. K_SCHEMA_NAME = 353,
  275. K_SCROLL = 354,
  276. K_SLICE = 355,
  277. K_SQLSTATE = 356,
  278. K_STACKED = 357,
  279. K_STRICT = 358,
  280. K_TABLE = 359,
  281. K_TABLE_NAME = 360,
  282. K_THEN = 361,
  283. K_TO = 362,
  284. K_TYPE = 363,
  285. K_USE_COLUMN = 364,
  286. K_USE_VARIABLE = 365,
  287. K_USING = 366,
  288. K_VARIABLE_CONFLICT = 367,
  289. K_WARNING = 368,
  290. K_WHEN = 369,
  291. K_WHILE = 370
  292. };
  293. #endif
  294. #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
  295. typedef union YYSTYPE
  296. {
  297. /* Line 293 of yacc.c */
  298. #line 116 "pl_gram.y"
  299. core_YYSTYPE core_yystype;
  300. /* these fields must match core_YYSTYPE: */
  301. int ival;
  302. char *str;
  303. const char *keyword;
  304. PLword word;
  305. PLcword cword;
  306. PLwdatum wdatum;
  307. bool boolean;
  308. Oid oid;
  309. struct
  310. {
  311. char *name;
  312. int lineno;
  313. } varname;
  314. struct
  315. {
  316. char *name;
  317. int lineno;
  318. PLpgSQL_datum *scalar;
  319. PLpgSQL_rec *rec;
  320. PLpgSQL_row *row;
  321. } forvariable;
  322. struct
  323. {
  324. char *label;
  325. int n_initvars;
  326. int *initvarnos;
  327. } declhdr;
  328. struct
  329. {
  330. List *stmts;
  331. char *end_label;
  332. int end_label_location;
  333. } loop_body;
  334. List *list;
  335. PLpgSQL_type *dtype;
  336. PLpgSQL_datum *datum;
  337. PLpgSQL_var *var;
  338. PLpgSQL_expr *expr;
  339. PLpgSQL_stmt *stmt;
  340. PLpgSQL_condition *condition;
  341. PLpgSQL_exception *exception;
  342. PLpgSQL_exception_block *exception_block;
  343. PLpgSQL_nsitem *nsitem;
  344. PLpgSQL_diag_item *diagitem;
  345. PLpgSQL_stmt_fetch *fetch;
  346. PLpgSQL_case_when *casewhen;
  347. /* Line 293 of yacc.c */
  348. #line 396 "pl_gram.c"
  349. } YYSTYPE;
  350. # define YYSTYPE_IS_TRIVIAL 1
  351. # define yystype YYSTYPE /* obsolescent; will be withdrawn */
  352. # define YYSTYPE_IS_DECLARED 1
  353. #endif
  354. #if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
  355. typedef struct YYLTYPE
  356. {
  357. int first_line;
  358. int first_column;
  359. int last_line;
  360. int last_column;
  361. } YYLTYPE;
  362. # define yyltype YYLTYPE /* obsolescent; will be withdrawn */
  363. # define YYLTYPE_IS_DECLARED 1
  364. # define YYLTYPE_IS_TRIVIAL 1
  365. #endif
  366. /* Copy the second part of user declarations. */
  367. /* Line 343 of yacc.c */
  368. #line 421 "pl_gram.c"
  369. #ifdef short
  370. # undef short
  371. #endif
  372. #ifdef YYTYPE_UINT8
  373. typedef YYTYPE_UINT8 yytype_uint8;
  374. #else
  375. typedef unsigned char yytype_uint8;
  376. #endif
  377. #ifdef YYTYPE_INT8
  378. typedef YYTYPE_INT8 yytype_int8;
  379. #elif (defined __STDC__ || defined __C99__FUNC__ \
  380. || defined __cplusplus || defined _MSC_VER)
  381. typedef signed char yytype_int8;
  382. #else
  383. typedef short int yytype_int8;
  384. #endif
  385. #ifdef YYTYPE_UINT16
  386. typedef YYTYPE_UINT16 yytype_uint16;
  387. #else
  388. typedef unsigned short int yytype_uint16;
  389. #endif
  390. #ifdef YYTYPE_INT16
  391. typedef YYTYPE_INT16 yytype_int16;
  392. #else
  393. typedef short int yytype_int16;
  394. #endif
  395. #ifndef YYSIZE_T
  396. # ifdef __SIZE_TYPE__
  397. # define YYSIZE_T __SIZE_TYPE__
  398. # elif defined size_t
  399. # define YYSIZE_T size_t
  400. # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
  401. || defined __cplusplus || defined _MSC_VER)
  402. # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
  403. # define YYSIZE_T size_t
  404. # else
  405. # define YYSIZE_T unsigned int
  406. # endif
  407. #endif
  408. #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
  409. #ifndef YY_
  410. # if defined YYENABLE_NLS && YYENABLE_NLS
  411. # if ENABLE_NLS
  412. # include <libintl.h> /* INFRINGES ON USER NAME SPACE */
  413. # define YY_(msgid) dgettext ("bison-runtime", msgid)
  414. # endif
  415. # endif
  416. # ifndef YY_
  417. # define YY_(msgid) msgid
  418. # endif
  419. #endif
  420. /* Suppress unused-variable warnings by "using" E. */
  421. #if ! defined lint || defined __GNUC__
  422. # define YYUSE(e) ((void) (e))
  423. #else
  424. # define YYUSE(e) /* empty */
  425. #endif
  426. /* Identity function, used to suppress warnings about constant conditions. */
  427. #ifndef lint
  428. # define YYID(n) (n)
  429. #else
  430. #if (defined __STDC__ || defined __C99__FUNC__ \
  431. || defined __cplusplus || defined _MSC_VER)
  432. static int
  433. YYID (int yyi)
  434. #else
  435. static int
  436. YYID (yyi)
  437. int yyi;
  438. #endif
  439. {
  440. return yyi;
  441. }
  442. #endif
  443. #if ! defined yyoverflow || YYERROR_VERBOSE
  444. /* The parser invokes alloca or malloc; define the necessary symbols. */
  445. # ifdef YYSTACK_USE_ALLOCA
  446. # if YYSTACK_USE_ALLOCA
  447. # ifdef __GNUC__
  448. # define YYSTACK_ALLOC __builtin_alloca
  449. # elif defined __BUILTIN_VA_ARG_INCR
  450. # include <alloca.h> /* INFRINGES ON USER NAME SPACE */
  451. # elif defined _AIX
  452. # define YYSTACK_ALLOC __alloca
  453. # elif defined _MSC_VER
  454. # include <malloc.h> /* INFRINGES ON USER NAME SPACE */
  455. # define alloca _alloca
  456. # else
  457. # define YYSTACK_ALLOC alloca
  458. # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
  459. || defined __cplusplus || defined _MSC_VER)
  460. # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
  461. # ifndef EXIT_SUCCESS
  462. # define EXIT_SUCCESS 0
  463. # endif
  464. # endif
  465. # endif
  466. # endif
  467. # endif
  468. # ifdef YYSTACK_ALLOC
  469. /* Pacify GCC's `empty if-body' warning. */
  470. # define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
  471. # ifndef YYSTACK_ALLOC_MAXIMUM
  472. /* The OS might guarantee only one guard page at the bottom of the stack,
  473. and a page size can be as small as 4096 bytes. So we cannot safely
  474. invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
  475. to allow for a few compiler-allocated temporary stack slots. */
  476. # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
  477. # endif
  478. # else
  479. # define YYSTACK_ALLOC YYMALLOC
  480. # define YYSTACK_FREE YYFREE
  481. # ifndef YYSTACK_ALLOC_MAXIMUM
  482. # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
  483. # endif
  484. # if (defined __cplusplus && ! defined EXIT_SUCCESS \
  485. && ! ((defined YYMALLOC || defined malloc) \
  486. && (defined YYFREE || defined free)))
  487. # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
  488. # ifndef EXIT_SUCCESS
  489. # define EXIT_SUCCESS 0
  490. # endif
  491. # endif
  492. # ifndef YYMALLOC
  493. # define YYMALLOC malloc
  494. # if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
  495. || defined __cplusplus || defined _MSC_VER)
  496. void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
  497. # endif
  498. # endif
  499. # ifndef YYFREE
  500. # define YYFREE free
  501. # if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
  502. || defined __cplusplus || defined _MSC_VER)
  503. void free (void *); /* INFRINGES ON USER NAME SPACE */
  504. # endif
  505. # endif
  506. # endif
  507. #endif /* ! defined yyoverflow || YYERROR_VERBOSE */
  508. #if (! defined yyoverflow \
  509. && (! defined __cplusplus \
  510. || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
  511. && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
  512. /* A type that is properly aligned for any stack member. */
  513. union yyalloc
  514. {
  515. yytype_int16 yyss_alloc;
  516. YYSTYPE yyvs_alloc;
  517. YYLTYPE yyls_alloc;
  518. };
  519. /* The size of the maximum gap between one aligned stack and the next. */
  520. # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
  521. /* The size of an array large to enough to hold all stacks, each with
  522. N elements. */
  523. # define YYSTACK_BYTES(N) \
  524. ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
  525. + 2 * YYSTACK_GAP_MAXIMUM)
  526. # define YYCOPY_NEEDED 1
  527. /* Relocate STACK from its old location to the new one. The
  528. local variables YYSIZE and YYSTACKSIZE give the old and new number of
  529. elements in the stack, and YYPTR gives the new location of the
  530. stack. Advance YYPTR to a properly aligned location for the next
  531. stack. */
  532. # define YYSTACK_RELOCATE(Stack_alloc, Stack) \
  533. do \
  534. { \
  535. YYSIZE_T yynewbytes; \
  536. YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
  537. Stack = &yyptr->Stack_alloc; \
  538. yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
  539. yyptr += yynewbytes / sizeof (*yyptr); \
  540. } \
  541. while (YYID (0))
  542. #endif
  543. #if defined YYCOPY_NEEDED && YYCOPY_NEEDED
  544. /* Copy COUNT objects from FROM to TO. The source and destination do
  545. not overlap. */
  546. # ifndef YYCOPY
  547. # if defined __GNUC__ && 1 < __GNUC__
  548. # define YYCOPY(To, From, Count) \
  549. __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
  550. # else
  551. # define YYCOPY(To, From, Count) \
  552. do \
  553. { \
  554. YYSIZE_T yyi; \
  555. for (yyi = 0; yyi < (Count); yyi++) \
  556. (To)[yyi] = (From)[yyi]; \
  557. } \
  558. while (YYID (0))
  559. # endif
  560. # endif
  561. #endif /* !YYCOPY_NEEDED */
  562. /* YYFINAL -- State number of the termination state. */
  563. #define YYFINAL 3
  564. /* YYLAST -- Last index in YYTABLE. */
  565. #define YYLAST 1042
  566. /* YYNTOKENS -- Number of terminals. */
  567. #define YYNTOKENS 123
  568. /* YYNNTS -- Number of nonterminals. */
  569. #define YYNNTS 84
  570. /* YYNRULES -- Number of rules. */
  571. #define YYNRULES 217
  572. /* YYNRULES -- Number of states. */
  573. #define YYNSTATES 295
  574. /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
  575. #define YYUNDEFTOK 2
  576. #define YYMAXUTOK 370
  577. #define YYTRANSLATE(YYX) \
  578. ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
  579. /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
  580. static const yytype_uint8 yytranslate[] =
  581. {
  582. 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  583. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  584. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  585. 2, 2, 2, 2, 2, 116, 2, 2, 2, 2,
  586. 118, 119, 2, 2, 120, 2, 2, 2, 2, 2,
  587. 2, 2, 2, 2, 2, 2, 2, 2, 2, 117,
  588. 2, 121, 2, 2, 2, 2, 2, 2, 2, 2,
  589. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  590. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  591. 2, 122, 2, 2, 2, 2, 2, 2, 2, 2,
  592. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  593. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  594. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  595. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  596. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  597. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  598. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  599. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  600. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  601. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  602. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  603. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  604. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  605. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  606. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  607. 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
  608. 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
  609. 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
  610. 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
  611. 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
  612. 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
  613. 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
  614. 65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
  615. 75, 76, 77, 78, 79, 80, 81, 82, 83, 84,
  616. 85, 86, 87, 88, 89, 90, 91, 92, 93, 94,
  617. 95, 96, 97, 98, 99, 100, 101, 102, 103, 104,
  618. 105, 106, 107, 108, 109, 110, 111, 112, 113, 114,
  619. 115
  620. };
  621. #if YYDEBUG
  622. /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
  623. YYRHS. */
  624. static const yytype_uint16 yyprhs[] =
  625. {
  626. 0, 0, 3, 7, 8, 11, 15, 19, 23, 27,
  627. 31, 33, 35, 36, 38, 45, 47, 50, 54, 56,
  628. 59, 61, 63, 65, 69, 76, 82, 83, 91, 92,
  629. 95, 97, 98, 99, 103, 105, 109, 112, 114, 116,
  630. 118, 120, 122, 124, 126, 127, 129, 130, 131, 134,
  631. 137, 140, 141, 144, 146, 148, 150, 152, 154, 156,
  632. 157, 159, 162, 164, 167, 169, 171, 173, 175, 177,
  633. 179, 181, 183, 185, 187, 189, 191, 193, 195, 197,
  634. 199, 201, 203, 205, 208, 212, 218, 219, 221, 223,
  635. 227, 229, 233, 234, 236, 238, 240, 242, 246, 255,
  636. 256, 261, 262, 265, 273, 274, 277, 279, 283, 284,
  637. 287, 291, 296, 301, 304, 306, 308, 310, 319, 320,
  638. 323, 327, 329, 331, 333, 335, 341, 343, 345, 347,
  639. 349, 352, 357, 362, 363, 367, 370, 372, 374, 376,
  640. 377, 378, 382, 385, 387, 392, 396, 398, 400, 401,
  641. 402, 403, 404, 405, 409, 410, 412, 414, 417, 419,
  642. 421, 423, 425, 427, 429, 431, 433, 435, 437, 439,
  643. 441, 443, 445, 447, 449, 451, 453, 455, 457, 459,
  644. 461, 463, 465, 467, 469, 471, 473, 475, 477, 479,
  645. 481, 483, 485, 487, 489, 491, 493, 495, 497, 499,
  646. 501, 503, 505, 507, 509, 511, 513, 515, 517, 519,
  647. 521, 523, 525, 527, 529, 531, 533, 535
  648. };
  649. /* YYRHS -- A `-1'-separated list of the rules' RHS. */
  650. static const yytype_int16 yyrhs[] =
  651. {
  652. 124, 0, -1, 125, 129, 128, -1, -1, 125, 126,
  653. -1, 116, 78, 43, -1, 116, 86, 127, -1, 116,
  654. 112, 48, -1, 116, 112, 110, -1, 116, 112, 109,
  655. -1, 14, -1, 206, -1, -1, 117, -1, 130, 24,
  656. 151, 192, 46, 203, -1, 202, -1, 202, 131, -1,
  657. 202, 131, 132, -1, 39, -1, 132, 133, -1, 133,
  658. -1, 134, -1, 39, -1, 17, 205, 18, -1, 143,
  659. 144, 145, 146, 147, 148, -1, 143, 20, 54, 142,
  660. 117, -1, -1, 143, 136, 36, 135, 138, 141, 137,
  661. -1, -1, 73, 99, -1, 99, -1, -1, -1, 118,
  662. 139, 119, -1, 140, -1, 139, 120, 140, -1, 143,
  663. 145, -1, 65, -1, 54, -1, 14, -1, 206, -1,
  664. 15, -1, 14, -1, 206, -1, -1, 31, -1, -1,
  665. -1, 28, 14, -1, 28, 206, -1, 28, 15, -1,
  666. -1, 74, 76, -1, 117, -1, 149, -1, 150, -1,
  667. 40, -1, 121, -1, 13, -1, -1, 152, -1, 152,
  668. 153, -1, 153, -1, 129, 117, -1, 155, -1, 163,
  669. -1, 166, -1, 171, -1, 172, -1, 173, -1, 176,
  670. -1, 178, -1, 180, -1, 181, -1, 183, -1, 184,
  671. -1, 154, -1, 156, -1, 185, -1, 186, -1, 187,
  672. -1, 189, -1, 190, -1, 80, 198, -1, 162, 150,
  673. 198, -1, 58, 157, 42, 158, 117, -1, -1, 35,
  674. -1, 102, -1, 158, 120, 159, -1, 159, -1, 161,
  675. 150, 160, -1, -1, 16, -1, 14, -1, 15, -1,
  676. 16, -1, 162, 122, 199, -1, 60, 200, 151, 164,
  677. 165, 46, 60, 117, -1, -1, 164, 45, 200, 151,
  678. -1, -1, 44, 151, -1, 26, 167, 168, 170, 46,
  679. 26, 117, -1, -1, 168, 169, -1, 169, -1, 114,
  680. 200, 151, -1, -1, 44, 151, -1, 202, 68, 182,
  681. -1, 202, 115, 201, 182, -1, 202, 54, 174, 182,
  682. -1, 175, 61, -1, 16, -1, 14, -1, 15, -1,
  683. 202, 55, 175, 177, 61, 22, 201, 182, -1, -1,
  684. 100, 9, -1, 179, 203, 204, -1, 51, -1, 34,
  685. -1, 92, -1, 89, -1, 151, 46, 68, 203, 117,
  686. -1, 63, -1, 14, -1, 15, -1, 50, -1, 77,
  687. 191, -1, 52, 188, 191, 64, -1, 71, 188, 191,
  688. 117, -1, -1, 27, 191, 117, -1, 76, 117, -1,
  689. 16, -1, 14, -1, 15, -1, -1, -1, 49, 193,
  690. 194, -1, 194, 195, -1, 195, -1, 114, 196, 106,
  691. 151, -1, 196, 79, 197, -1, 197, -1, 205, -1,
  692. -1, -1, -1, -1, -1, 17, 205, 18, -1, -1,
  693. 205, -1, 117, -1, 114, 198, -1, 14, -1, 206,
  694. -1, 16, -1, 19, -1, 20, -1, 22, -1, 23,
  695. -1, 29, -1, 30, -1, 31, -1, 32, -1, 33,
  696. -1, 35, -1, 36, -1, 37, -1, 38, -1, 41,
  697. -1, 43, -1, 47, -1, 48, -1, 53, -1, 56,
  698. -1, 59, -1, 62, -1, 65, -1, 66, -1, 67,
  699. -1, 69, -1, 70, -1, 72, -1, 73, -1, 75,
  700. -1, 78, -1, 81, -1, 82, -1, 83, -1, 84,
  701. -1, 85, -1, 87, -1, 86, -1, 88, -1, 90,
  702. -1, 91, -1, 93, -1, 94, -1, 96, -1, 95,
  703. -1, 97, -1, 98, -1, 99, -1, 100, -1, 101,
  704. -1, 102, -1, 104, -1, 105, -1, 108, -1, 109,
  705. -1, 110, -1, 112, -1, 113, -1
  706. };
  707. /* YYRLINE[YYN] -- source line where rule number YYN was defined. */
  708. static const yytype_uint16 yyrline[] =
  709. {
  710. 0, 344, 344, 350, 351, 354, 358, 367, 371, 375,
  711. 381, 385, 390, 391, 394, 416, 424, 431, 440, 452,
  712. 453, 456, 457, 461, 474, 529, 535, 534, 587, 590,
  713. 594, 601, 607, 610, 639, 643, 649, 657, 658, 660,
  714. 675, 690, 718, 746, 777, 778, 783, 794, 795, 800,
  715. 805, 812, 813, 817, 819, 825, 826, 834, 835, 839,
  716. 840, 844, 851, 860, 862, 864, 866, 868, 870, 872,
  717. 874, 876, 878, 880, 882, 884, 886, 888, 890, 892,
  718. 894, 896, 898, 902, 915, 929, 992, 995, 999, 1005,
  719. 1009, 1015, 1028, 1075, 1087, 1092, 1100, 1105, 1122, 1139,
  720. 1142, 1156, 1159, 1165, 1172, 1186, 1190, 1196, 1208, 1211,
  721. 1226, 1243, 1261, 1295, 1557, 1589, 1604, 1611, 1654, 1657,
  722. 1663, 1678, 1682, 1688, 1714, 1856, 1874, 1878, 1888, 1900,
  723. 1964, 2041, 2073, 2086, 2091, 2104, 2111, 2127, 2132, 2140,
  724. 2142, 2141, 2181, 2185, 2191, 2204, 2213, 2219, 2256, 2260,
  725. 2264, 2268, 2272, 2276, 2284, 2287, 2295, 2297, 2304, 2308,
  726. 2312, 2321, 2322, 2323, 2324, 2325, 2326, 2327, 2328, 2329,
  727. 2330, 2331, 2332, 2333, 2334, 2335, 2336, 2337, 2338, 2339,
  728. 2340, 2341, 2342, 2343, 2344, 2345, 2346, 2347, 2348, 2349,
  729. 2350, 2351, 2352, 2353, 2354, 2355, 2356, 2357, 2358, 2359,
  730. 2360, 2361, 2362, 2363, 2364, 2365, 2366, 2367, 2368, 2369,
  731. 2370, 2371, 2372, 2373, 2374, 2375, 2376, 2377
  732. };
  733. #endif
  734. #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
  735. /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
  736. First, the terminals, then, starting at YYNTOKENS, nonterminals. */
  737. static const char *const yytname[] =
  738. {
  739. "$end", "error", "$undefined", "IDENT", "FCONST", "SCONST", "BCONST",
  740. "XCONST", "Op", "ICONST", "PARAM", "TYPECAST", "DOT_DOT", "COLON_EQUALS",
  741. "T_WORD", "T_CWORD", "T_DATUM", "LESS_LESS", "GREATER_GREATER",
  742. "K_ABSOLUTE", "K_ALIAS", "K_ALL", "K_ARRAY", "K_BACKWARD", "K_BEGIN",
  743. "K_BY", "K_CASE", "K_CLOSE", "K_COLLATE", "K_COLUMN", "K_COLUMN_NAME",
  744. "K_CONSTANT", "K_CONSTRAINT", "K_CONSTRAINT_NAME", "K_CONTINUE",
  745. "K_CURRENT", "K_CURSOR", "K_DATATYPE", "K_DEBUG", "K_DECLARE",
  746. "K_DEFAULT", "K_DETAIL", "K_DIAGNOSTICS", "K_DUMP", "K_ELSE", "K_ELSIF",
  747. "K_END", "K_ERRCODE", "K_ERROR", "K_EXCEPTION", "K_EXECUTE", "K_EXIT",
  748. "K_FETCH", "K_FIRST", "K_FOR", "K_FOREACH", "K_FORWARD", "K_FROM",
  749. "K_GET", "K_HINT", "K_IF", "K_IN", "K_INFO", "K_INSERT", "K_INTO",
  750. "K_IS", "K_LAST", "K_LOG", "K_LOOP", "K_MESSAGE", "K_MESSAGE_TEXT",
  751. "K_MOVE", "K_NEXT", "K_NO", "K_NOT", "K_NOTICE", "K_NULL", "K_OPEN",
  752. "K_OPTION", "K_OR", "K_PERFORM", "K_PG_CONTEXT", "K_PG_DATATYPE_NAME",
  753. "K_PG_EXCEPTION_CONTEXT", "K_PG_EXCEPTION_DETAIL", "K_PG_EXCEPTION_HINT",
  754. "K_PRINT_STRICT_PARAMS", "K_PRIOR", "K_QUERY", "K_RAISE", "K_RELATIVE",
  755. "K_RESULT_OID", "K_RETURN", "K_RETURNED_SQLSTATE", "K_REVERSE",
  756. "K_ROWTYPE", "K_ROW_COUNT", "K_SCHEMA", "K_SCHEMA_NAME", "K_SCROLL",
  757. "K_SLICE", "K_SQLSTATE", "K_STACKED", "K_STRICT", "K_TABLE",
  758. "K_TABLE_NAME", "K_THEN", "K_TO", "K_TYPE", "K_USE_COLUMN",
  759. "K_USE_VARIABLE", "K_USING", "K_VARIABLE_CONFLICT", "K_WARNING",
  760. "K_WHEN", "K_WHILE", "'#'", "';'", "'('", "')'", "','", "'='", "'['",
  761. "$accept", "pl_function", "comp_options", "comp_option", "option_value",
  762. "opt_semi", "pl_block", "decl_sect", "decl_start", "decl_stmts",
  763. "decl_stmt", "decl_statement", "$@1", "opt_scrollable",
  764. "decl_cursor_query", "decl_cursor_args", "decl_cursor_arglist",
  765. "decl_cursor_arg", "decl_is_for", "decl_aliasitem", "decl_varname",
  766. "decl_const", "decl_datatype", "decl_collate", "decl_notnull",
  767. "decl_defval", "decl_defkey", "assign_operator", "proc_sect",
  768. "proc_stmts", "proc_stmt", "stmt_perform", "stmt_assign", "stmt_getdiag",
  769. "getdiag_area_opt", "getdiag_list", "getdiag_list_item", "getdiag_item",
  770. "getdiag_target", "assign_var", "stmt_if", "stmt_elsifs", "stmt_else",
  771. "stmt_case", "opt_expr_until_when", "case_when_list", "case_when",
  772. "opt_case_else", "stmt_loop", "stmt_while", "stmt_for", "for_control",
  773. "for_variable", "stmt_foreach_a", "foreach_slice", "stmt_exit",
  774. "exit_type", "stmt_return", "stmt_raise", "loop_body", "stmt_execsql",
  775. "stmt_dynexecute", "stmt_open", "stmt_fetch", "stmt_move",
  776. "opt_fetch_direction", "stmt_close", "stmt_null", "cursor_variable",
  777. "exception_sect", "@2", "proc_exceptions", "proc_exception",
  778. "proc_conditions", "proc_condition", "expr_until_semi",
  779. "expr_until_rightbracket", "expr_until_then", "expr_until_loop",
  780. "opt_block_label", "opt_label", "opt_exitcond", "any_identifier",
  781. "unreserved_keyword", 0
  782. };
  783. #endif
  784. # ifdef YYPRINT
  785. /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
  786. token YYLEX-NUM. */
  787. static const yytype_uint16 yytoknum[] =
  788. {
  789. 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
  790. 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
  791. 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
  792. 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
  793. 295, 296, 297, 298, 299, 300, 301, 302, 303, 304,
  794. 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
  795. 315, 316, 317, 318, 319, 320, 321, 322, 323, 324,
  796. 325, 326, 327, 328, 329, 330, 331, 332, 333, 334,
  797. 335, 336, 337, 338, 339, 340, 341, 342, 343, 344,
  798. 345, 346, 347, 348, 349, 350, 351, 352, 353, 354,
  799. 355, 356, 357, 358, 359, 360, 361, 362, 363, 364,
  800. 365, 366, 367, 368, 369, 370, 35, 59, 40, 41,
  801. 44, 61, 91
  802. };
  803. # endif
  804. /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
  805. static const yytype_uint8 yyr1[] =
  806. {
  807. 0, 123, 124, 125, 125, 126, 126, 126, 126, 126,
  808. 127, 127, 128, 128, 129, 130, 130, 130, 131, 132,
  809. 132, 133, 133, 133, 134, 134, 135, 134, 136, 136,
  810. 136, 137, 138, 138, 139, 139, 140, 141, 141, 142,
  811. 142, 142, 143, 143, 144, 144, 145, 146, 146, 146,
  812. 146, 147, 147, 148, 148, 149, 149, 150, 150, 151,
  813. 151, 152, 152, 153, 153, 153, 153, 153, 153, 153,
  814. 153, 153, 153, 153, 153, 153, 153, 153, 153, 153,
  815. 153, 153, 153, 154, 155, 156, 157, 157, 157, 158,
  816. 158, 159, 160, 161, 161, 161, 162, 162, 163, 164,
  817. 164, 165, 165, 166, 167, 168, 168, 169, 170, 170,
  818. 171, 172, 173, 174, 175, 175, 175, 176, 177, 177,
  819. 178, 179, 179, 180, 181, 182, 183, 183, 183, 184,
  820. 185, 186, 187, 188, 189, 190, 191, 191, 191, 192,
  821. 193, 192, 194, 194, 195, 196, 196, 197, 198, 199,
  822. 200, 201, 202, 202, 203, 203, 204, 204, 205, 205,
  823. 205, 206, 206, 206, 206, 206, 206, 206, 206, 206,
  824. 206, 206, 206, 206, 206, 206, 206, 206, 206, 206,
  825. 206, 206, 206, 206, 206, 206, 206, 206, 206, 206,
  826. 206, 206, 206, 206, 206, 206, 206, 206, 206, 206,
  827. 206, 206, 206, 206, 206, 206, 206, 206, 206, 206,
  828. 206, 206, 206, 206, 206, 206, 206, 206
  829. };
  830. /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
  831. static const yytype_uint8 yyr2[] =
  832. {
  833. 0, 2, 3, 0, 2, 3, 3, 3, 3, 3,
  834. 1, 1, 0, 1, 6, 1, 2, 3, 1, 2,
  835. 1, 1, 1, 3, 6, 5, 0, 7, 0, 2,
  836. 1, 0, 0, 3, 1, 3, 2, 1, 1, 1,
  837. 1, 1, 1, 1, 0, 1, 0, 0, 2, 2,
  838. 2, 0, 2, 1, 1, 1, 1, 1, 1, 0,
  839. 1, 2, 1, 2, 1, 1, 1, 1, 1, 1,
  840. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  841. 1, 1, 1, 2, 3, 5, 0, 1, 1, 3,
  842. 1, 3, 0, 1, 1, 1, 1, 3, 8, 0,
  843. 4, 0, 2, 7, 0, 2, 1, 3, 0, 2,
  844. 3, 4, 4, 2, 1, 1, 1, 8, 0, 2,
  845. 3, 1, 1, 1, 1, 5, 1, 1, 1, 1,
  846. 2, 4, 4, 0, 3, 2, 1, 1, 1, 0,
  847. 0, 3, 2, 1, 4, 3, 1, 1, 0, 0,
  848. 0, 0, 0, 3, 0, 1, 1, 2, 1, 1,
  849. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  850. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  851. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  852. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  853. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  854. 1, 1, 1, 1, 1, 1, 1, 1
  855. };
  856. /* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM.
  857. Performed when YYTABLE doesn't specify something else to do. Zero
  858. means the default is an error. */
  859. static const yytype_uint8 yydefact[] =
  860. {
  861. 3, 0, 152, 1, 0, 0, 4, 12, 0, 15,
  862. 158, 160, 161, 162, 163, 164, 165, 166, 167, 168,
  863. 169, 170, 171, 172, 173, 174, 175, 176, 177, 178,
  864. 179, 180, 181, 182, 183, 184, 185, 186, 187, 188,
  865. 189, 190, 191, 192, 193, 194, 195, 197, 196, 198,
  866. 199, 200, 201, 202, 204, 203, 205, 206, 207, 208,
  867. 209, 210, 211, 212, 213, 214, 215, 216, 217, 0,
  868. 159, 0, 0, 0, 13, 2, 152, 18, 16, 153,
  869. 5, 10, 6, 11, 7, 9, 8, 127, 128, 96,
  870. 104, 0, 122, 129, 121, 133, 86, 150, 126, 133,
  871. 0, 0, 148, 124, 123, 0, 139, 152, 62, 76,
  872. 64, 77, 0, 65, 66, 67, 68, 69, 70, 71,
  873. 154, 72, 73, 74, 75, 78, 79, 80, 81, 82,
  874. 15, 42, 0, 22, 17, 20, 21, 44, 43, 0,
  875. 137, 138, 136, 0, 0, 87, 88, 0, 152, 0,
  876. 135, 130, 83, 63, 140, 0, 61, 58, 57, 149,
  877. 148, 0, 155, 0, 0, 152, 151, 0, 19, 0,
  878. 45, 0, 30, 0, 46, 150, 108, 106, 134, 0,
  879. 0, 99, 0, 0, 154, 97, 84, 148, 156, 120,
  880. 115, 116, 114, 152, 0, 118, 0, 110, 152, 23,
  881. 0, 29, 26, 47, 152, 152, 105, 0, 131, 94,
  882. 95, 93, 0, 90, 0, 101, 132, 0, 141, 143,
  883. 14, 157, 112, 113, 0, 0, 0, 111, 39, 41,
  884. 0, 40, 32, 0, 51, 107, 109, 0, 85, 0,
  885. 92, 152, 150, 0, 0, 146, 147, 142, 119, 0,
  886. 154, 25, 0, 0, 48, 50, 49, 0, 0, 0,
  887. 89, 91, 102, 152, 0, 0, 152, 151, 0, 0,
  888. 34, 46, 38, 37, 31, 52, 56, 53, 24, 54,
  889. 55, 103, 100, 0, 145, 144, 152, 125, 33, 0,
  890. 36, 27, 98, 117, 35
  891. };
  892. /* YYDEFGOTO[NTERM-NUM]. */
  893. static const yytype_int16 yydefgoto[] =
  894. {
  895. -1, 1, 2, 6, 82, 75, 105, 8, 78, 134,
  896. 135, 136, 232, 173, 291, 253, 269, 270, 274, 230,
  897. 137, 174, 203, 234, 258, 278, 279, 160, 196, 107,
  898. 108, 109, 110, 111, 147, 212, 213, 261, 214, 112,
  899. 113, 215, 243, 114, 139, 176, 177, 207, 115, 116,
  900. 117, 193, 194, 118, 225, 119, 120, 121, 122, 197,
  901. 123, 124, 125, 126, 127, 144, 128, 129, 143, 155,
  902. 183, 218, 219, 244, 245, 152, 185, 148, 198, 130,
  903. 161, 189, 162, 70
  904. };
  905. /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
  906. STATE-NUM. */
  907. #define YYPACT_NINF -223
  908. static const yytype_int16 yypact[] =
  909. {
  910. -223, 14, -13, -223, 352, -52, -223, -93, 13, 0,
  911. -223, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  912. -223, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  913. -223, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  914. -223, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  915. -223, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  916. -223, -223, -223, -223, -223, -223, -223, -223, -223, 36,
  917. -223, 32, 649, -26, -223, -223, 898, -223, 252, -223,
  918. -223, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  919. -223, 28, -223, -223, -223, -223, -23, -223, -223, -223,
  920. -35, 28, -223, -223, -223, -32, 40, 1, -223, -223,
  921. -223, -223, -10, -223, -223, -223, -223, -223, -223, -223,
  922. 352, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  923. 2, -223, 352, -223, 252, -223, -223, -11, -223, -22,
  924. -223, -223, -223, -17, 28, -223, -223, 49, 846, 28,
  925. -223, -223, -223, -223, -223, 56, -223, -223, -223, -223,
  926. -223, -81, -223, 80, 80, 950, -223, 86, -223, 51,
  927. -223, 7, -223, 71, -223, -223, -34, -223, -223, 44,
  928. 83, -223, -1, 5, 352, -223, -223, -223, -223, -223,
  929. -223, -223, -223, 950, 57, 10, 78, -223, 950, -223,
  930. 452, -223, -223, 97, 106, 950, -223, 81, -223, -223,
  931. -223, -223, -44, -223, -7, 4, -223, 352, 5, -223,
  932. -223, -223, -223, -223, 117, 73, 67, -223, -223, -223,
  933. 19, -223, 20, 552, 63, -223, -223, 113, -223, 83,
  934. -223, 950, -223, 95, -48, -223, -223, -223, -223, 120,
  935. 352, -223, 746, -25, -223, -223, -223, 68, -8, 26,
  936. -223, -223, -223, 846, 85, 352, 188, -223, 29, -51,
  937. -223, -223, -223, -223, -223, -223, -223, -223, -223, -223,
  938. -223, -223, -223, 30, -223, -223, 950, -223, -223, 746,
  939. -223, -223, -223, -223, -223
  940. };
  941. /* YYPGOTO[NTERM-NUM]. */
  942. static const yytype_int16 yypgoto[] =
  943. {
  944. -223, -223, -223, -223, -223, -223, 146, -223, -223, -223,
  945. 15, -223, -223, -223, -223, -223, -223, -138, -223, -223,
  946. -222, -223, -118, -223, -223, -223, -223, -203, -74, -223,
  947. 47, -223, -223, -223, -223, -223, -84, -223, -223, -223,
  948. -223, -223, -223, -223, -223, -223, -16, -223, -223, -223,
  949. -223, -223, -5, -223, -223, -223, -223, -223, -223, -185,
  950. -223, -223, -223, -223, -223, 62, -223, -223, -78, -223,
  951. -223, -223, -55, -223, -100, -122, -223, -156, -99, 168,
  952. -163, -223, -4, -71
  953. };
  954. /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
  955. positive, shift that token. If negative, reduce the rule which
  956. number is the opposite. If YYTABLE_NINF, syntax error. */
  957. #define YYTABLE_NINF -61
  958. static const yytype_int16 yytable[] =
  959. {
  960. 69, 83, 106, 157, 4, 157, 157, 138, 222, 169,
  961. 205, 240, 145, 227, 3, 87, 88, 89, 4, 204,
  962. 170, 220, 84, 151, 74, -28, 71, 90, 91, 272,
  963. 271, 265, 276, 187, 72, 92, 188, 76, 186, 77,
  964. 273, 77, 140, 141, 142, -60, -60, -60, 241, 242,
  965. -60, 93, 94, 95, 79, 280, 163, 164, 266, 96,
  966. 73, 97, 171, 138, 98, 221, 179, 271, 288, 289,
  967. 165, 182, 99, 238, 181, 80, 239, 100, 101, 146,
  968. 175, 102, 150, 85, 86, 153, 263, 268, 172, 154,
  969. 103, 180, 175, 104, 190, 191, 192, 209, 210, 211,
  970. 178, 293, 184, 5, 199, 200, 201, 202, 208, 277,
  971. 224, 158, 159, 158, 158, -60, 216, 166, 223, 217,
  972. 87, 88, 89, 4, 226, 233, 248, 237, 167, 231,
  973. 235, 236, 90, 91, 249, 250, 251, 257, 252, 259,
  974. 92, 264, 267, 281, 275, 283, 287, 292, 7, 168,
  975. -59, 294, -59, 290, 156, 260, 93, 94, 95, 195,
  976. 206, 149, 256, 247, 96, 284, 97, 262, 286, 98,
  977. 9, 0, 0, 0, 0, 0, 0, 99, 0, 0,
  978. 0, 138, 100, 101, 0, 0, 102, 0, 0, 282,
  979. 0, 0, 285, 0, 0, 103, 0, 0, 104, 0,
  980. 0, 0, 87, 88, 89, 4, 0, 0, 0, 0,
  981. 0, 0, 0, 246, 90, 91, 0, 0, 138, 0,
  982. -59, 0, 92, 0, 0, 0, 0, 0, 0, 0,
  983. 0, 0, 0, 0, -59, 0, 0, 0, 93, 94,
  984. 95, 0, 0, 0, 0, 0, 96, 0, 97, 0,
  985. 0, 98, 0, 0, 0, 0, 0, 0, 0, 99,
  986. 0, 246, 0, 0, 100, 101, 131, 0, 102, 132,
  987. 0, 12, 13, 0, 14, 15, 0, 103, 0, 0,
  988. 104, 16, 17, 18, 19, 20, 0, 21, 22, 23,
  989. 24, 133, 0, 25, 0, 26, 0, 0, 0, 27,
  990. 28, 0, -59, 0, 0, 29, 0, 0, 30, 0,
  991. 0, 31, 0, 0, 32, 0, 0, 33, 34, 35,
  992. 0, 36, 37, 0, 38, 39, 0, 40, 0, 0,
  993. 41, 0, 0, 42, 43, 44, 45, 46, 47, 48,
  994. 49, 0, 50, 51, 0, 52, 53, 54, 55, 56,
  995. 57, 58, 59, 60, 61, 0, 62, 63, 0, 0,
  996. 64, 65, 66, 0, 67, 68, 10, 0, 11, 0,
  997. 0, 12, 13, 0, 14, 15, 0, 0, 0, 0,
  998. 0, 16, 17, 18, 19, 20, 0, 21, 22, 23,
  999. 24, 0, 0, 25, 0, 26, 0, 0, 0, 27,
  1000. 28, 0, 0, 0, 0, 29, 0, 0, 30, 0,
  1001. 0, 31, 0, 0, 32, 0, 0, 33, 34, 35,
  1002. 0, 36, 37, 0, 38, 39, 0, 40, 0, 0,
  1003. 41, 0, 0, 42, 43, 44, 45, 46, 47, 48,
  1004. 49, 0, 50, 51, 0, 52, 53, 54, 55, 56,
  1005. 57, 58, 59, 60, 61, 0, 62, 63, 0, 0,
  1006. 64, 65, 66, 0, 67, 68, 228, 229, 0, 0,
  1007. 0, 12, 13, 0, 14, 15, 0, 0, 0, 0,
  1008. 0, 16, 17, 18, 19, 20, 0, 21, 22, 23,
  1009. 24, 0, 0, 25, 0, 26, 0, 0, 0, 27,
  1010. 28, 0, 0, 0, 0, 29, 0, 0, 30, 0,
  1011. 0, 31, 0, 0, 32, 0, 0, 33, 34, 35,
  1012. 0, 36, 37, 0, 38, 39, 0, 40, 0, 0,
  1013. 41, 0, 0, 42, 43, 44, 45, 46, 47, 48,
  1014. 49, 0, 50, 51, 0, 52, 53, 54, 55, 56,
  1015. 57, 58, 59, 60, 61, 0, 62, 63, 0, 0,
  1016. 64, 65, 66, 0, 67, 68, 254, 255, 0, 0,
  1017. 0, 12, 13, 0, 14, 15, 0, 0, 0, 0,
  1018. 0, 16, 17, 18, 19, 20, 0, 21, 22, 23,
  1019. 24, 0, 0, 25, 0, 26, 0, 0, 0, 27,
  1020. 28, 0, 0, 0, 0, 29, 0, 0, 30, 0,
  1021. 0, 31, 0, 0, 32, 0, 0, 33, 34, 35,
  1022. 0, 36, 37, 0, 38, 39, 0, 40, 0, 0,
  1023. 41, 0, 0, 42, 43, 44, 45, 46, 47, 48,
  1024. 49, 0, 50, 51, 0, 52, 53, 54, 55, 56,
  1025. 57, 58, 59, 60, 61, 0, 62, 63, 0, 0,
  1026. 64, 65, 66, 81, 67, 68, 0, 0, 12, 13,
  1027. 0, 14, 15, 0, 0, 0, 0, 0, 16, 17,
  1028. 18, 19, 20, 0, 21, 22, 23, 24, 0, 0,
  1029. 25, 0, 26, 0, 0, 0, 27, 28, 0, 0,
  1030. 0, 0, 29, 0, 0, 30, 0, 0, 31, 0,
  1031. 0, 32, 0, 0, 33, 34, 35, 0, 36, 37,
  1032. 0, 38, 39, 0, 40, 0, 0, 41, 0, 0,
  1033. 42, 43, 44, 45, 46, 47, 48, 49, 0, 50,
  1034. 51, 0, 52, 53, 54, 55, 56, 57, 58, 59,
  1035. 60, 61, 0, 62, 63, 0, 0, 64, 65, 66,
  1036. 131, 67, 68, 0, 0, 12, 13, 0, 14, 15,
  1037. 0, 0, 0, 0, 0, 16, 17, 18, 19, 20,
  1038. 0, 21, 22, 23, 24, 0, 0, 25, 0, 26,
  1039. 0, 0, 0, 27, 28, 0, 0, 0, 0, 29,
  1040. 0, 0, 30, 0, 0, 31, 0, 0, 32, 0,
  1041. 0, 33, 34, 35, 0, 36, 37, 0, 38, 39,
  1042. 0, 40, 0, 0, 41, 0, 0, 42, 43, 44,
  1043. 45, 46, 47, 48, 49, 0, 50, 51, 0, 52,
  1044. 53, 54, 55, 56, 57, 58, 59, 60, 61, 0,
  1045. 62, 63, 0, 0, 64, 65, 66, 0, 67, 68,
  1046. 87, 88, 89, 4, 0, 0, 0, 0, 0, 0,
  1047. 0, 0, 90, 91, 0, 0, 0, 0, 0, 0,
  1048. 92, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  1049. -59, -59, -59, 0, 0, 0, 93, 94, 95, 0,
  1050. 0, 0, 0, 0, 96, 0, 97, 0, 0, 98,
  1051. 0, 0, 87, 88, 89, 4, 0, 99, 0, 0,
  1052. 0, 0, 100, 101, 90, 91, 102, 0, 0, 0,
  1053. 0, 0, 92, 0, 0, 103, 0, 0, 104, 0,
  1054. 0, 0, 0, 0, -59, 0, 0, -59, 93, 94,
  1055. 95, 0, 0, 0, 0, 0, 96, 0, 97, 0,
  1056. 0, 98, 0, 0, 87, 88, 89, 4, 0, 99,
  1057. 0, 0, 0, 0, 100, 101, 90, 91, 102, 0,
  1058. 0, 0, 0, 0, 92, 0, 0, 103, 0, 0,
  1059. 104, 0, 0, 0, 0, 0, -59, 0, 0, 0,
  1060. 93, 94, 95, 0, 0, 0, 0, 0, 96, 0,
  1061. 97, 0, 0, 98, 0, 0, 0, 0, 0, 0,
  1062. 0, 99, 0, 0, 0, 0, 100, 101, 0, 0,
  1063. 102, 0, 0, 0, 0, 0, 0, 0, 0, 103,
  1064. 0, 0, 104
  1065. };
  1066. #define yypact_value_is

Large files files are truncated, but you can click here to view the full file