📄 pl_gram.c
字号:
N elements. */# define PLPGSQL_YYSTACK_BYTES(N) \ ((N) * (sizeof (short) + sizeof (PLPGSQL_YYSTYPE)) \ + PLPGSQL_YYSTACK_GAP_MAXIMUM)/* Copy COUNT objects from FROM to TO. The source and destination do not overlap. */# ifndef PLPGSQL_YYCOPY# if 1 < __GNUC__# define PLPGSQL_YYCOPY(To, From, Count) \ __builtin_memcpy (To, From, (Count) * sizeof (*(From)))# else# define PLPGSQL_YYCOPY(To, From, Count) \ do \ { \ register PLPGSQL_YYSIZE_T plpgsql_yyi; \ for (plpgsql_yyi = 0; plpgsql_yyi < (Count); plpgsql_yyi++) \ (To)[plpgsql_yyi] = (From)[plpgsql_yyi]; \ } \ while (0)# endif# endif/* Relocate STACK from its old location to the new one. The local variables PLPGSQL_YYSIZE and PLPGSQL_YYSTACKSIZE give the old and new number of elements in the stack, and PLPGSQL_YYPTR gives the new location of the stack. Advance PLPGSQL_YYPTR to a properly aligned location for the next stack. */# define PLPGSQL_YYSTACK_RELOCATE(Stack) \ do \ { \ PLPGSQL_YYSIZE_T plpgsql_yynewbytes; \ PLPGSQL_YYCOPY (&plpgsql_yyptr->Stack, Stack, plpgsql_yysize); \ Stack = &plpgsql_yyptr->Stack; \ plpgsql_yynewbytes = plpgsql_yystacksize * sizeof (*Stack) + PLPGSQL_YYSTACK_GAP_MAXIMUM; \ plpgsql_yyptr += plpgsql_yynewbytes / sizeof (*plpgsql_yyptr); \ } \ while (0)#endif#if defined (__STDC__) || defined (__cplusplus) typedef signed char plpgsql_yysigned_char;#else typedef short plpgsql_yysigned_char;#endif/* PLPGSQL_YYFINAL -- State number of the termination state. */#define PLPGSQL_YYFINAL 9/* PLPGSQL_YYLAST -- Last index in PLPGSQL_YYTABLE. */#define PLPGSQL_YYLAST 400/* PLPGSQL_YYNTOKENS -- Number of terminals. */#define PLPGSQL_YYNTOKENS 73/* PLPGSQL_YYNNTS -- Number of nonterminals. */#define PLPGSQL_YYNNTS 76/* PLPGSQL_YYNRULES -- Number of rules. */#define PLPGSQL_YYNRULES 139/* PLPGSQL_YYNRULES -- Number of states. */#define PLPGSQL_YYNSTATES 232/* PLPGSQL_YYTRANSLATE(PLPGSQL_YYLEX) -- Bison symbol number corresponding to PLPGSQL_YYLEX. */#define PLPGSQL_YYUNDEFTOK 2#define PLPGSQL_YYMAXUTOK 320#define PLPGSQL_YYTRANSLATE(PLPGSQL_YYX) \ ((unsigned int) (PLPGSQL_YYX) <= PLPGSQL_YYMAXUTOK ? plpgsql_yytranslate[PLPGSQL_YYX] : PLPGSQL_YYUNDEFTOK)/* PLPGSQL_YYTRANSLATE[PLPGSQL_YYLEX] -- Bison symbol number corresponding to PLPGSQL_YYLEX. */static const unsigned char plpgsql_yytranslate[] ={ 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 69, 70, 2, 2, 71, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 66, 67, 2, 68, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 72, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65};#if PLPGSQL_YYDEBUG/* PLPGSQL_YYPRHS[PLPGSQL_YYN] -- Index of the first RHS symbol of rule number PLPGSQL_YYN in PLPGSQL_YYRHS. */static const unsigned short plpgsql_yyprhs[] ={ 0, 0, 3, 8, 13, 14, 16, 19, 21, 24, 25, 27, 35, 37, 40, 44, 46, 49, 51, 57, 59, 61, 67, 73, 79, 80, 87, 88, 89, 93, 95, 99, 102, 104, 106, 108, 110, 112, 113, 115, 116, 117, 120, 122, 124, 126, 128, 129, 131, 134, 136, 139, 141, 143, 145, 147, 149, 151, 153, 155, 157, 159, 161, 163, 165, 167, 169, 171, 173, 175, 179, 184, 190, 194, 196, 200, 202, 204, 206, 208, 210, 212, 216, 225, 226, 232, 235, 240, 246, 251, 255, 257, 259, 261, 263, 266, 271, 273, 275, 278, 281, 286, 288, 290, 292, 294, 296, 298, 300, 306, 309, 312, 316, 321, 326, 329, 331, 333, 335, 337, 338, 339, 344, 347, 349, 355, 359, 361, 362, 363, 364, 365, 366, 372, 373, 375, 377, 379, 382, 384};/* PLPGSQL_YYRHS -- A `-1'-separated list of the rules' RHS. */static const short plpgsql_yyrhs[] ={ 74, 0, -1, 53, 75, 79, 78, -1, 54, 75, 79, 78, -1, -1, 76, -1, 76, 77, -1, 77, -1, 64, 65, -1, -1, 66, -1, 80, 5, 148, 99, 135, 17, 145, -1, 144, -1, 144, 81, -1, 144, 81, 82, -1, 11, -1, 82, 83, -1, 83, -1, 67, 67, 147, 68, 68, -1, 11, -1, 84, -1, 92, 94, 95, 96, 97, -1, 92, 3, 21, 91, 66, -1, 41, 93, 48, 93, 66, -1, -1, 92, 9, 85, 87, 90, 86, -1, -1, -1, 69, 88, 70, -1, 89, -1, 88, 71, 89, -1, 92, 95, -1, 29, -1, 21, -1, 62, -1, 62, -1, 62, -1, -1, 7, -1, -1, -1, 33, 35, -1, 66, -1, 98, -1, 4, -1, 12, -1, -1, 100, -1, 100, 101, -1, 101, -1, 79, 66, -1, 103, -1, 110, -1, 112, -1, 113, -1, 114, -1, 117, -1, 118, -1, 120, -1, 121, -1, 122, -1, 126, -1, 127, -1, 102, -1, 104, -1, 128, -1, 129, -1, 130, -1, 131, -1, 38, 148, 140, -1, 109, 148, 4, 140, -1, 24, 13, 148, 105, 66, -1, 105, 71, 106, -1, 106, -1, 108, 4, 107, -1, 39, -1, 42, -1, 57, -1, 57, -1, 58, -1, 59, -1, 109, 72, 141, -1, 25, 148, 142, 99, 111, 17, 25, 66, -1, -1, 16, 148, 142, 99, 111, -1, 15, 99, -1, 144, 31, 148, 125, -1, 144, 52, 148, 143, 125, -1, 144, 21, 115, 125, -1, 148, 116, 26, -1, 57, -1, 62, -1, 59, -1, 58, -1, 46, 148, -1, 119, 148, 145, 146, -1, 20, -1, 8, -1, 43, 148, -1, 44, 148, -1, 40, 148, 124, 123, -1, 55, -1, 18, -1, 50, -1, 34, -1, 27, -1, 30, -1, 10, -1, 99, 17, 31, 145, 66, -1, 134, 148, -1, 19, 148, -1, 36, 148, 132, -1, 22, 148, 133, 28, -1, 6, 148, 133, 66, -1, 35, 66, -1, 57, -1, 57, -1, 62, -1, 63, -1, -1, -1, 18, 148, 136, 137, -1, 137, 138, -1, 138, -1, 51, 148, 139, 47, 99, -1, 139, 37, 147, -1, 147, -1, -1, -1, -1, -1, -1, 67, 67, 147, 68, 68, -1, -1, 61, -1, 62, -1, 66, -1, 51, 140, -1, 62, -1, -1};/* PLPGSQL_YYRLINE[PLPGSQL_YYN] -- source line where rule number PLPGSQL_YYN was defined. */static const unsigned short plpgsql_yyrline[] ={ 0, 230, 230, 234, 240, 241, 244, 245, 248, 254, 255, 258, 280, 288, 296, 307, 313, 315, 319, 321, 323, 327, 361, 366, 371, 370, 417, 429, 432, 461, 465, 471, 478, 479, 481, 509, 519, 530, 531, 536, 547, 548, 552, 554, 562, 563, 567, 570, 574, 581, 590, 592, 594, 596, 598, 600, 602, 604, 606, 608, 610, 612, 614, 616, 618, 620, 622, 624, 626, 630, 643, 657, 670, 674, 680, 692, 696, 702, 710, 715, 720, 725, 740, 756, 759, 788, 794, 811, 829, 868, 1005, 1015, 1025, 1035, 1047, 1054, 1069, 1073, 1079, 1142, 1187, 1230, 1236, 1240, 1244, 1248, 1252, 1256, 1262, 1269, 1282, 1337, 1454, 1466, 1479, 1486, 1503, 1520, 1522, 1527, 1529, 1528, 1561, 1565, 1571, 1584, 1594, 1601, 1605, 1609, 1613, 1617, 1621, 1629, 1632, 1638, 1645, 1647, 1651, 1661};#endif#if PLPGSQL_YYDEBUG || PLPGSQL_YYERROR_VERBOSE/* PLPGSQL_YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. First, the terminals, then, starting at PLPGSQL_YYNTOKENS, nonterminals. */static const char *const plpgsql_yytname[] ={ "$end", "error", "$undefined", "K_ALIAS", "K_ASSIGN", "K_BEGIN", "K_CLOSE", "K_CONSTANT", "K_CONTINUE", "K_CURSOR", "K_DEBUG", "K_DECLARE", "K_DEFAULT", "K_DIAGNOSTICS", "K_DOTDOT", "K_ELSE", "K_ELSIF", "K_END", "K_EXCEPTION", "K_EXECUTE", "K_EXIT", "K_FOR", "K_FETCH", "K_FROM", "K_GET", "K_IF", "K_IN", "K_INFO", "K_INTO", "K_IS", "K_LOG", "K_LOOP", "K_NEXT", "K_NOT", "K_NOTICE", "K_NULL", "K_OPEN", "K_OR", "K_PERFORM", "K_ROW_COUNT", "K_RAISE", "K_RENAME", "K_RESULT_OID", "K_RETURN", "K_RETURN_NEXT", "K_REVERSE", "K_SELECT", "K_THEN", "K_TO", "K_TYPE", "K_WARNING", "K_WHEN", "K_WHILE", "T_FUNCTION", "T_TRIGGER", "T_STRING", "T_NUMBER", "T_SCALAR", "T_ROW", "T_RECORD", "T_DTYPE", "T_LABEL", "T_WORD", "T_ERROR", "O_OPTION", "O_DUMP", "';'", "'<'", "'>'", "'('", "')'", "','", "'['", "$accept", "pl_function", "comp_optsect", "comp_options", "comp_option", "opt_semi", "pl_block", "decl_sect", "decl_start", "decl_stmts", "decl_stmt", "decl_statement", "@1", "decl_cursor_query", "decl_cursor_args", "decl_cursor_arglist", "decl_cursor_arg", "decl_is_from", "decl_aliasitem", "decl_varname", "decl_renname", "decl_const", "decl_datatype", "decl_notnull", "decl_defval", "decl_defkey", "proc_sect", "proc_stmts", "proc_stmt", "stmt_perform", "stmt_assign", "stmt_getdiag", "getdiag_list", "getdiag_list_item", "getdiag_kind", "getdiag_target", "assign_var", "stmt_if", "stmt_else", "stmt_loop", "stmt_while", "stmt_for", "for_control", "for_variable", "stmt_select", "stmt_exit", "exit_type", "stmt_return", "stmt_return_next", "stmt_raise", "raise_msg", "raise_level", "loop_body", "stmt_execsql", "stmt_dynexecute", "stmt_open", "stmt_fetch", "stmt_close", "stmt_null", "cursor_varptr", "cursor_variable", "execsql_start", "exception_sect", "@2", "proc_exceptions", "proc_exception", "proc_conditions", "expr_until_semi", "expr_until_rightbracket", "expr_until_then", "expr_until_loop", "opt_block_label", "opt_label", "opt_exitcond", "opt_lblname", "lno", 0};#endif# ifdef PLPGSQL_YYPRINT/* PLPGSQL_YYTOKNUM[PLPGSQL_YYLEX-NUM] -- Internal token number corresponding to token PLPGSQL_YYLEX-NUM. */static const unsigned short plpgsql_yytoknum[] ={ 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 320, 59, 60, 62, 40, 41, 44, 91};# endif/* PLPGSQL_YYR1[PLPGSQL_YYN] -- Symbol number of symbol that rule PLPGSQL_YYN derives. */static const unsigned char plpgsql_yyr1[] ={ 0, 73, 74, 74, 75, 75, 76, 76, 77, 78, 78, 79, 80, 80, 80, 81, 82, 82, 83, 83, 83, 84, 84, 84, 85, 84, 86, 87, 87, 88, 88, 89, 90, 90, 91, 92, 93, 94, 94, 95, 96, 96, 97, 97, 98, 98, 99, 99, 100, 100, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, 102, 103, 104, 105, 105, 106, 107, 107, 108, 109, 109, 109, 109, 110, 111, 111, 111, 112, 113, 114, 115, 116, 116, 116, 116, 117, 118, 119, 119, 120, 121, 122, 123, 124, 124, 124, 124, 124, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 134, 135, 136, 135, 137, 137, 138, 139, 139, 140, 141, 142, 143, 144, 144, 145, 145, 145, 146, 146, 147, 148};/* PLPGSQL_YYR2[PLPGSQL_YYN] -- Number of symbols composing right hand side of rule PLPGSQL_YYN. */static const unsigned char plpgsql_yyr2[] ={ 0, 2, 4, 4, 0, 1, 2, 1, 2, 0, 1, 7, 1, 2, 3, 1, 2, 1, 5, 1, 1, 5, 5, 5, 0, 6, 0, 0, 3, 1, 3, 2, 1, 1, 1, 1, 1, 0, 1, 0, 0, 2, 1, 1, 1, 1, 0, 1, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 4, 5, 3, 1, 3, 1, 1, 1, 1, 1, 1, 3, 8, 0, 5, 2, 4, 5, 4, 3, 1, 1, 1, 1, 2, 4, 1, 1, 2, 2, 4, 1, 1, 1, 1, 1, 1, 1, 5, 2, 2, 3, 4, 4, 2, 1, 1, 1, 1, 0, 0, 4, 2, 1, 5, 3, 1, 0, 0, 0, 0, 0, 5, 0, 1, 1, 1, 2, 1, 0};/* PLPGSQL_YYDEFACT[STATE-NAME] -- Default rule to reduce with in state STATE-NUM when PLPGSQL_YYTABLE doesn't specify something else to do. Zero means the default is an error. */static const unsigned char plpgsql_yydefact[] ={ 0, 4, 4, 0, 0, 131, 5, 7, 131, 1, 8, 0, 9, 0, 12, 6, 9, 0, 10, 2, 139, 15, 13, 3, 138, 0, 131, 19, 0, 35, 0, 14, 17, 20, 37, 0, 139, 97, 139, 96, 139, 0, 139, 0, 139, 139, 139, 139, 139, 139, 78, 79, 80, 117, 118, 0, 119, 47, 49, 63, 51, 64, 139, 52, 53, 54, 55, 56, 57, 139, 58, 59, 60, 61, 62, 65, 66, 67, 68, 139, 12, 36, 0, 0, 16, 0, 38, 24, 39, 132, 0, 110, 0, 139, 129, 114, 0, 127, 0, 98, 99, 94, 50, 139, 0, 48, 128, 0, 133, 109, 139, 139, 139, 0, 0, 0, 27, 40, 116, 0, 0, 0, 131, 115, 111, 69, 107, 102, 105, 106, 104, 103, 0, 120, 133, 81, 127, 134, 135, 0, 131, 0, 131, 130, 0, 0, 34, 0, 0, 0, 0, 0, 113, 112, 77, 0, 73, 0, 83, 101, 100, 0, 11, 70, 127, 136, 95, 0, 88, 90, 93, 92, 91, 0, 86, 131, 23, 18, 22, 0, 29, 39, 33, 32, 26, 41, 44, 45, 42, 21, 43, 71, 0, 0, 131, 139, 0, 139, 121, 123, 137, 0, 89, 87, 28, 0, 31, 25, 72, 75, 76, 74, 85, 129, 0, 0, 122, 133, 30, 131, 0, 0, 126, 0, 83, 82, 0, 131, 108, 84, 125, 124};/* PLPGSQL_YYDEFGOTO[NTERM-NUM]. */static const short plpgsql_yydefgoto[] ={ -1, 3, 5, 6, 7, 19, 55, 13, 22, 31, 32, 33, 116, 207, 149, 179, 180, 184, 147, 34, 82, 88, 117, 151, 189, 190, 167, 57, 58, 59, 60, 61, 155, 156, 211, 157, 62, 63, 196, 64, 65, 66, 140, 173, 67, 68, 69, 70, 71, 72, 160, 132, 168, 73, 74, 75, 76, 77, 78, 124, 119, 79, 104, 161, 198, 199, 221, 125, 135, 122, 175, 80, 139, 166, 25, 26};/* PLPGSQL_YYPACT[STATE-NUM] -- Index in PLPGSQL_YYTABLE of the portion describing STATE-NUM. */#define PLPGSQL_YYPACT_NINF -143static const short plpgsql_yypact[] ={ -29, -31, -31, 51, -10, -6, -31, -143, -6, -143, -143, 7, 3, 80, 75, -143, 3, 26, -143, -143, -143, -143, 4, -143, -143, 21, 217, -143, 29, -143, 25, 4, -143, -143, 45, 30, -143, -143, -143, -143, -143, 87, -143, 27, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, 38, 83, 59, -143, -143, -143, -143, 34, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, 5, -143, 62, 26, -143, 92, -143, -143, -143, -143, 57, -143, 57, -143, -143, -143, 58, -143, 12, -143, -143, -143, -143, -143, 102, -143, -143, 116, -12, -143, -143, -143, -143, 29, 55, 63, 60, 91, -143, 61, 100, 73, 159, -143, -143, -143, -143, -143, -143, -143, -143, -143, 76, -143, -12, -143, -143, -143, -143, -34, 333, 50, 333, -143, 66, 65, -143, 69, 74, 8, 103, 16, -143, -143, -143, -48, -143, 133, 44, -143, -143, 88, -143, -143, -143, -143, -143, 123, -143, -143, -143, -143, -143, 115, -143, 333, -143, -143, -143, 2, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, 73, -4, 333, -143, 125, -143, 88, -143, -143, 112, -143, -143, -143, 74, -143, -143, -143, -143, -143, -143, -143, -143, 119, 26, -143, -12, -143, 159, 81, -16, -143, 82, 44, -143, 26, 275, -143, -143, -143, -143};/* PLPGSQL_YYPGOTO[NTERM-NUM]. */static const short plpgsql_yypgoto[] ={ -143, -143, 144, -143, 143, 134, 35, -143, -143, -143, 120, -143, -143, -143, -143, -143, -53, -143, -143, -142, 40, -143, -27, -143, -143, -143, -26, -143, 98, -143, -143, -143, -143, -36, -143, -143, -143, -143, -67, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -143, -134, -143, -143, -143, -143, -143, -143, -143, 67, -143, -143, -143, -143, -40, -143, -117, -143, -52, -143, 48, -130, -143, -81, -35};
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -