]> granicus.if.org Git - postgresql/commit
Modify all callers of datatype input and receive functions so that if these
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 4 Apr 2006 19:35:37 +0000 (19:35 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 4 Apr 2006 19:35:37 +0000 (19:35 +0000)
commit147d4bf3e5e3da2ee0f0cc132718ab1c4912a877
treee02e6a191197edb5224ab5f831146854fde7d460
parenteaef111396ef7e70c88979c7a82f6a8f918d9651
Modify all callers of datatype input and receive functions so that if these
functions are not strict, they will be called (passing a NULL first parameter)
during any attempt to input a NULL value of their datatype.  Currently, all
our input functions are strict and so this commit does not change any
behavior.  However, this will make it possible to build domain input functions
that centralize checking of domain constraints, thereby closing numerous holes
in our domain support, as per previous discussion.

While at it, I took the opportunity to introduce convenience functions
InputFunctionCall, OutputFunctionCall, etc to use in code that calls I/O
functions.  This eliminates a lot of grotty-looking casts, but the main
motivation is to make it easier to grep for these places if we ever need
to touch them again.
23 files changed:
doc/src/sgml/ref/create_type.sgml
src/backend/access/common/printtup.c
src/backend/bootstrap/bootstrap.c
src/backend/commands/copy.c
src/backend/executor/execTuples.c
src/backend/executor/nodeAgg.c
src/backend/executor/spi.c
src/backend/nodes/print.c
src/backend/parser/parse_coerce.c
src/backend/parser/parse_type.c
src/backend/tcop/fastpath.c
src/backend/tcop/postgres.c
src/backend/utils/adt/arrayfuncs.c
src/backend/utils/adt/rowtypes.c
src/backend/utils/adt/ruleutils.c
src/backend/utils/adt/varlena.c
src/backend/utils/cache/lsyscache.c
src/backend/utils/fmgr/fmgr.c
src/include/fmgr.h
src/pl/plperl/plperl.c
src/pl/plpgsql/src/pl_exec.c
src/pl/plpython/plpython.c
src/pl/tcl/pltcl.c