Re: generating function default settings from pg_proc.dat

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andrew Dunstan <andrew@dunslane.net>
Cc: Andres Freund <andres@anarazel.de>, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2026-02-17T21:59:46Z
Lists: pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> That makes sense. I haven't tested it, but the code looks pretty sane. 
> Nice job. I guess if we ever want to specify a default that's not a 
> Const for some reason we'd have to fall back on the system_views 
> mechanism. But that's not very likely.

Right, the idea of this patch is to make the common cases easy
without making uncommon cases any worse than they were.  We have
enough experience now with default arguments to be pretty sure
that this will cover 90%-plus of the need.

			regards, tom lane



Commits

  1. Simplify creation of built-in functions with non-default ACLs.

  2. Be more wary of false matches in initdb's replace_token().

  3. Simplify creation of built-in functions with default arguments.