diff options
author | Tom Lane | 2010-05-30 18:10:41 +0000 |
---|---|---|
committer | Tom Lane | 2010-05-30 18:10:41 +0000 |
commit | b12b7a9038259967098159cf0ccce0e77327a4d1 (patch) | |
tree | e6ff349cfd79edf3d06a76fac70c247a56e997cb /src/backend/parser/parse_func.c | |
parent | 2bde07c198a4995a4a756c58ee65d030a0e6ee02 (diff) |
Change the notation for calling functions with named parameters from
"val AS name" to "name := val", as per recent discussion.
This patch catches everything in the original named-parameters patch,
but I'm not certain that no other dependencies snuck in later (grepping
the source tree for all uses of AS soon proved unworkable).
In passing I note that we've dropped the ball at least once on keeping
ecpg's lexer (as opposed to parser) in sync with the backend. It would
be a good idea to go through all of pgc.l and see if it's in sync now.
I didn't attempt that at the moment.
Diffstat (limited to 'src/backend/parser/parse_func.c')
-rw-r--r-- | src/backend/parser/parse_func.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/parser/parse_func.c b/src/backend/parser/parse_func.c index 8a2663c232c..5de08dc78c8 100644 --- a/src/backend/parser/parse_func.c +++ b/src/backend/parser/parse_func.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/parser/parse_func.c,v 1.223 2010/03/17 16:52:38 tgl Exp $ + * $PostgreSQL: pgsql/src/backend/parser/parse_func.c,v 1.224 2010/05/30 18:10:40 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -1386,12 +1386,12 @@ funcname_signature_string(const char *funcname, int nargs, { if (i) appendStringInfoString(&argbuf, ", "); - appendStringInfoString(&argbuf, format_type_be(argtypes[i])); if (i >= numposargs) { - appendStringInfo(&argbuf, " AS %s", (char *) lfirst(lc)); + appendStringInfo(&argbuf, "%s := ", (char *) lfirst(lc)); lc = lnext(lc); } + appendStringInfoString(&argbuf, format_type_be(argtypes[i])); } appendStringInfoChar(&argbuf, ')'); |