1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-28 23:42:10 +03:00

Small refactoring of makeVar() from a TargetEntry

This commit is contained in:
Peter Eisentraut
2010-08-27 20:30:08 +00:00
parent c10575ff00
commit 2355b69b1e
8 changed files with 37 additions and 56 deletions

View File

@ -7,7 +7,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/optimizer/plan/subselect.c,v 1.163 2010/07/12 17:01:06 tgl Exp $
* $PostgreSQL: pgsql/src/backend/optimizer/plan/subselect.c,v 1.164 2010/08/27 20:30:08 petere Exp $
*
*-------------------------------------------------------------------------
*/
@ -737,11 +737,7 @@ generate_subquery_vars(PlannerInfo *root, List *tlist, Index varno)
if (tent->resjunk)
continue;
var = makeVar(varno,
tent->resno,
exprType((Node *) tent->expr),
exprTypmod((Node *) tent->expr),
0);
var = makeVarFromTargetEntry(varno, tent);
result = lappend(result, var);
}