diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2004-06-06 00:41:28 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2004-06-06 00:41:28 +0000 |
commit | c541bb86e9ec8fed37b23df6a0df703d0bde4dfa (patch) | |
tree | b4cff96eecc86e338274ec5d7355918efe9c149e /src/backend/executor/spi.c | |
parent | c3a153afed84e29dac664bdc6123724a9e3a906f (diff) |
Infrastructure for I/O of composite types: arrange for the I/O routines
of a composite type to get that type's OID as their second parameter,
in place of typelem which is useless. The actual changes are mostly
centralized in getTypeInputInfo and siblings, but I had to fix a few
places that were fetching pg_type.typelem for themselves instead of
using the lsyscache.c routines. Also, I renamed all the related variables
from 'typelem' to 'typioparam' to discourage people from assuming that
they necessarily contain array element types.
Diffstat (limited to 'src/backend/executor/spi.c')
-rw-r--r-- | src/backend/executor/spi.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/backend/executor/spi.c b/src/backend/executor/spi.c index 047b8fa2aae..f5f2850b982 100644 --- a/src/backend/executor/spi.c +++ b/src/backend/executor/spi.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/executor/spi.c,v 1.116 2004/06/04 20:35:21 tgl Exp $ + * $PostgreSQL: pgsql/src/backend/executor/spi.c,v 1.117 2004/06/06 00:41:26 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -538,7 +538,7 @@ SPI_getvalue(HeapTuple tuple, TupleDesc tupdesc, int fnumber) bool isnull; Oid typoid, foutoid, - typelem; + typioparam; int32 typmod; bool typisvarlena; @@ -566,7 +566,7 @@ SPI_getvalue(HeapTuple tuple, TupleDesc tupdesc, int fnumber) typmod = -1; } - getTypeOutputInfo(typoid, &foutoid, &typelem, &typisvarlena); + getTypeOutputInfo(typoid, &foutoid, &typioparam, &typisvarlena); /* * If we have a toasted datum, forcibly detoast it here to avoid @@ -579,7 +579,7 @@ SPI_getvalue(HeapTuple tuple, TupleDesc tupdesc, int fnumber) result = OidFunctionCall3(foutoid, val, - ObjectIdGetDatum(typelem), + ObjectIdGetDatum(typioparam), Int32GetDatum(typmod)); /* Clean up detoasted copy, if any */ |