Right now builtins and user defined scripts are stored in different data structures. I'd rather see them in the same.
They already are in the same array (sql_script) when pre-processed and executed, there is no distinction beyond initialization.
The builtin_script array contains the equivalent of the external custom file (name, lines of code), so that they can be processed by process_builtin and addScript to build the SQLScript ready for execution, while for external files it relies on process_file and addScript.
-- Fabien. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers