1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-30 21:42:05 +03:00

Allow functions and operators on internally-identical types to succeed.

This commit is contained in:
Bruce Momjian
1997-08-22 00:02:19 +00:00
parent 0ab2921290
commit 3dd23aadf0
5 changed files with 33 additions and 8 deletions

View File

@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.34 1997/08/19 21:32:11 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.35 1997/08/22 00:02:04 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -1345,7 +1345,7 @@ make_targetlist_expr(ParseState *pstate,
} else
if (attrtype != type_id) {
if ((attrtype == INT2OID) && (type_id == INT4OID))
lfirst(expr) = lispInteger (INT2OID);
lfirst(expr) = lispInteger (INT2OID); do CASHOID too
else if ((attrtype == FLOAT4OID) && (type_id == FLOAT8OID))
lfirst(expr) = lispInteger (FLOAT4OID);
else