diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2002-11-26 03:01:59 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2002-11-26 03:01:59 +0000 |
commit | ea0b5c856922c08ef2ce6e2eb26f6c68d20bf957 (patch) | |
tree | d4e59a1b466aaf615adc9d513fbd5d00e87cd388 /src/backend/parser/parse_coerce.c | |
parent | ac47950238480321862c3a0b66cb01c40af801db (diff) |
Use Params, rather than run-time-modified Const nodes, to handle
sublink results and COPY's domain constraint checking. A Const that
isn't really constant is just a Bad Idea(tm). Remove hacks in
parse_coerce and other places that were needed because of the former
klugery.
Diffstat (limited to 'src/backend/parser/parse_coerce.c')
-rw-r--r-- | src/backend/parser/parse_coerce.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/backend/parser/parse_coerce.c b/src/backend/parser/parse_coerce.c index e6559086286..2809a9a17f1 100644 --- a/src/backend/parser/parse_coerce.c +++ b/src/backend/parser/parse_coerce.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/parser/parse_coerce.c,v 2.87 2002/11/25 21:29:41 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/parser/parse_coerce.c,v 2.88 2002/11/26 03:01:58 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -241,14 +241,8 @@ coerce_type(Node *node, Oid inputTypeId, Oid targetTypeId, * * Note that no folding will occur if the conversion function is * not marked 'immutable'. - * - * HACK: if constant is NULL, don't fold it here. This is needed - * by make_subplan(), which calls this routine on placeholder - * Const nodes that mustn't be collapsed. (It'd be a lot - * cleaner to make a separate node type for that purpose...) */ - if (IsA(node, Const) && - !((Const *) node)->constisnull) + if (IsA(node, Const)) result = eval_const_expressions(result); } else |