1997-11-25 23:07:18 +01:00
|
|
|
/*-------------------------------------------------------------------------
|
|
|
|
*
|
1999-02-14 00:22:53 +01:00
|
|
|
* parse_func.h
|
1997-11-25 23:07:18 +01:00
|
|
|
*
|
|
|
|
*
|
|
|
|
*
|
2000-01-26 06:58:53 +01:00
|
|
|
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
|
|
|
|
* Portions Copyright (c) 1994, Regents of the University of California
|
1997-11-25 23:07:18 +01:00
|
|
|
*
|
2000-08-08 17:43:12 +02:00
|
|
|
* $Id: parse_func.h,v 1.25 2000/08/08 15:42:59 tgl Exp $
|
1997-11-25 23:07:18 +01:00
|
|
|
*
|
|
|
|
*-------------------------------------------------------------------------
|
|
|
|
*/
|
|
|
|
#ifndef PARSER_FUNC_H
|
|
|
|
#define PARSER_FUNC_H
|
|
|
|
|
1999-07-16 01:04:24 +02:00
|
|
|
#include "parser/parse_node.h"
|
1997-11-25 23:07:18 +01:00
|
|
|
|
|
|
|
/*
|
|
|
|
* This structure is used to explore the inheritance hierarchy above
|
|
|
|
* nodes in the type tree in order to disambiguate among polymorphic
|
|
|
|
* functions.
|
|
|
|
*/
|
|
|
|
typedef struct _InhPaths
|
|
|
|
{
|
|
|
|
int nsupers; /* number of superclasses */
|
|
|
|
Oid self; /* this class */
|
|
|
|
Oid *supervec; /* vector of superclasses */
|
|
|
|
} InhPaths;
|
|
|
|
|
|
|
|
/*
|
|
|
|
* This structure holds a list of possible functions or operators that
|
|
|
|
* agree with the known name and argument types of the function/operator.
|
|
|
|
*/
|
|
|
|
typedef struct _CandidateList
|
|
|
|
{
|
|
|
|
Oid *args;
|
|
|
|
struct _CandidateList *next;
|
|
|
|
} *CandidateList;
|
|
|
|
|
1999-05-25 18:15:34 +02:00
|
|
|
extern Node *ParseNestedFuncOrColumn(ParseState *pstate, Attr *attr,
|
1998-02-26 05:46:47 +01:00
|
|
|
int *curr_resno, int precedence);
|
1999-12-10 08:37:35 +01:00
|
|
|
extern Node *ParseFuncOrColumn(ParseState *pstate,
|
2000-04-12 19:17:23 +02:00
|
|
|
char *funcname, List *fargs,
|
|
|
|
bool agg_star, bool agg_distinct,
|
|
|
|
int *curr_resno, int precedence);
|
1997-11-25 23:07:18 +01:00
|
|
|
|
2000-03-16 07:35:07 +01:00
|
|
|
extern bool typeInheritsFrom(Oid subclassTypeId, Oid superclassTypeId);
|
|
|
|
|
1999-06-18 00:21:41 +02:00
|
|
|
extern void func_error(char *caller, char *funcname,
|
2000-04-12 19:17:23 +02:00
|
|
|
int nargs, Oid *argtypes, char *msg);
|
1997-11-25 23:07:18 +01:00
|
|
|
|
1998-09-01 06:40:42 +02:00
|
|
|
#endif /* PARSE_FUNC_H */
|