]> granicus.if.org Git - postgresql/commit
Mark operator implementation functions as such in their comments.
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 3 Mar 2011 06:33:19 +0000 (01:33 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 3 Mar 2011 06:34:17 +0000 (01:34 -0500)
commit94133a935414407920a47d06a6e22734c974c3b8
tree81b4f4025150f5b498938fef0612e9f863116398
parent091bda0188250c9802cebca066b4ca9e049616e6
Mark operator implementation functions as such in their comments.

Historically, we've not had separate comments for built-in pg_operator
entries, but relied on the comments for the underlying functions.  The
trouble with this approach is that there isn't much of anything to suggest
to users that they'd be better off using the operators instead.  So, move
all the relevant comments into pg_operator, and give each underlying
function a comment that just says "implementation of XXX operator".
There are only about half a dozen cases where it seems reasonable to use
the underlying function interchangeably with the operator; in these cases
I left the same comment in place on the function as on the operator.

While at it, establish a policy that every built-in function and operator
entry should have a comment: there are now queries in the opr_sanity
regression test that will complain if one doesn't.  This only required
adding a dozen or two more entries than would have been there anyway.

I also spent some time trying to eliminate gratuitous inconsistencies in
the style of the comments, though it's hopeless to suppose that more won't
creep in soon enough.

Per my proposal of 2010-10-15.
src/bin/psql/describe.c
src/include/catalog/catversion.h
src/include/catalog/pg_operator.h
src/include/catalog/pg_proc.h
src/test/regress/expected/opr_sanity.out
src/test/regress/sql/opr_sanity.sql