aboutsummaryrefslogtreecommitdiff
path: root/src/include/parser
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2003-05-26 00:11:29 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2003-05-26 00:11:29 +0000
commitf45df8c0144005739d09387cb594baaaa08295a6 (patch)
tree45bf02ceab43e8eb24ff7c961cff9a89e3db2770 /src/include/parser
parent297c1658ed35dc0ac4a13c190f29cc5e2ad49a0b (diff)
downloadpostgresql-f45df8c0144005739d09387cb594baaaa08295a6.tar.gz
postgresql-f45df8c0144005739d09387cb594baaaa08295a6.zip
Cause CHAR(n) to TEXT or VARCHAR conversion to automatically strip trailing
blanks, in hopes of reducing the surprise factor for newbies. Remove redundant operators for VARCHAR (it depends wholly on TEXT operations now). Clean up resolution of ambiguous operators/functions to avoid surprising choices for domains: domains are treated as equivalent to their base types and binary-coercibility is no longer considered a preference item when choosing among multiple operators/functions. IsBinaryCoercible now correctly reflects the notion that you need *only* relabel the type to get from type A to type B: that is, a domain is binary-coercible to its base type, but not vice versa. Various marginal cleanup, including merging the essentially duplicate resolution code in parse_func.c and parse_oper.c. Improve opr_sanity regression test to understand about binary compatibility (using pg_cast), and fix a couple of small errors in the catalogs revealed thereby. Restructure "special operator" handling to fetch operators via index opclasses rather than hardwiring assumptions about names (cleans up the pattern_ops stuff a little).
Diffstat (limited to 'src/include/parser')
-rw-r--r--src/include/parser/parse_func.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/include/parser/parse_func.h b/src/include/parser/parse_func.h
index 2b1a1fad4b9..5f2adf5c4a1 100644
--- a/src/include/parser/parse_func.h
+++ b/src/include/parser/parse_func.h
@@ -7,13 +7,14 @@
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Id: parse_func.h,v 1.45 2003/04/29 22:13:11 tgl Exp $
+ * $Id: parse_func.h,v 1.46 2003/05/26 00:11:28 tgl Exp $
*
*-------------------------------------------------------------------------
*/
#ifndef PARSER_FUNC_H
#define PARSER_FUNC_H
+#include "catalog/namespace.h"
#include "parser/parse_node.h"
@@ -48,6 +49,15 @@ extern FuncDetailCode func_get_detail(List *funcname, List *fargs,
Oid *funcid, Oid *rettype,
bool *retset, Oid **true_typeids);
+extern int func_match_argtypes(int nargs,
+ Oid *input_typeids,
+ FuncCandidateList raw_candidates,
+ FuncCandidateList *candidates);
+
+extern FuncCandidateList func_select_candidate(int nargs,
+ Oid *input_typeids,
+ FuncCandidateList candidates);
+
extern bool typeInheritsFrom(Oid subclassTypeId, Oid superclassTypeId);
extern void make_fn_arguments(ParseState *pstate,