OSDN Git Service

Add:
[pg-rex/syncrep.git] / src / include / parser / parse_func.h
1 /*-------------------------------------------------------------------------
2  *
3  * parse_func.h
4  *
5  *
6  *
7  * Portions Copyright (c) 1996-2000, PostgreSQL, Inc
8  * Portions Copyright (c) 1994, Regents of the University of California
9  *
10  * $Id: parse_func.h,v 1.22 2000/01/26 05:58:27 momjian Exp $
11  *
12  *-------------------------------------------------------------------------
13  */
14 #ifndef PARSER_FUNC_H
15 #define PARSER_FUNC_H
16
17 #include "parser/parse_node.h"
18
19 /*
20  *      This structure is used to explore the inheritance hierarchy above
21  *      nodes in the type tree in order to disambiguate among polymorphic
22  *      functions.
23  */
24 typedef struct _InhPaths
25 {
26         int                     nsupers;                /* number of superclasses */
27         Oid                     self;                   /* this class */
28         Oid                *supervec;           /* vector of superclasses */
29 } InhPaths;
30
31 /*
32  *      This structure holds a list of possible functions or operators that
33  *      agree with the known name and argument types of the function/operator.
34  */
35 typedef struct _CandidateList
36 {
37         Oid                *args;
38         struct _CandidateList *next;
39 }                  *CandidateList;
40
41 extern Node *ParseNestedFuncOrColumn(ParseState *pstate, Attr *attr,
42                                                 int *curr_resno, int precedence);
43 extern Node *ParseFuncOrColumn(ParseState *pstate,
44                                                            char *funcname, List *fargs,
45                                                            bool agg_star, bool agg_distinct,
46                                                            int *curr_resno, int precedence);
47
48 extern List *setup_base_tlist(Oid typeid);
49
50 extern void func_error(char *caller, char *funcname,
51                                            int nargs, Oid *argtypes, char *msg);
52
53 #endif   /* PARSE_FUNC_H */