summaryrefslogtreecommitdiff
path: root/src/include/nodes/makefuncs.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2006-03-14 22:48:25 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2006-03-14 22:48:25 +0000
commit20ab467d76d78271006818d2baf4c9c8658d1f38 (patch)
tree7a536111b5cc4e494ac75558aad5655dfc8ab964 /src/include/nodes/makefuncs.h
parent48fb696753e267447f99914c7968d0b4ffb5c5dc (diff)
Improve parser so that we can show an error cursor position for errors
during parse analysis, not only errors detected in the flex/bison stages. This is per my earlier proposal. This commit includes all the basic infrastructure, but locations are only tracked and reported for errors involving column references, function calls, and operators. More could be done later but this seems like a good set to start with. I've also moved the ReportSyntaxErrorPosition logic out of psql and into libpq, which should make it available to more people --- even within psql this is an improvement because warnings weren't handled by ReportSyntaxErrorPosition.
Diffstat (limited to 'src/include/nodes/makefuncs.h')
-rw-r--r--src/include/nodes/makefuncs.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/include/nodes/makefuncs.h b/src/include/nodes/makefuncs.h
index ad8607cf6bf..23cb0029c0d 100644
--- a/src/include/nodes/makefuncs.h
+++ b/src/include/nodes/makefuncs.h
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/nodes/makefuncs.h,v 1.54 2006/03/05 15:58:56 momjian Exp $
+ * $PostgreSQL: pgsql/src/include/nodes/makefuncs.h,v 1.55 2006/03/14 22:48:22 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -18,10 +18,10 @@
extern A_Expr *makeA_Expr(A_Expr_Kind kind, List *name,
- Node *lexpr, Node *rexpr);
+ Node *lexpr, Node *rexpr, int location);
extern A_Expr *makeSimpleA_Expr(A_Expr_Kind kind, const char *name,
- Node *lexpr, Node *rexpr);
+ Node *lexpr, Node *rexpr, int location);
extern Var *makeVar(Index varno,
AttrNumber varattno,
@@ -56,6 +56,8 @@ extern RelabelType *makeRelabelType(Expr *arg, Oid rtype, int32 rtypmod,
extern RangeVar *makeRangeVar(char *schemaname, char *relname);
extern TypeName *makeTypeName(char *typnam);
+extern TypeName *makeTypeNameFromNameList(List *names);
+extern TypeName *makeTypeNameFromOid(Oid typeid, int32 typmod);
extern FuncExpr *makeFuncExpr(Oid funcid, Oid rettype,
List *args, CoercionForm fformat);