Add language validator
authorPeter Eisentraut <peter@eisentraut.org>
Thu, 31 Jan 2013 15:01:32 +0000 (10:01 -0500)
committerPeter Eisentraut <peter@eisentraut.org>
Thu, 31 Jan 2013 19:00:43 +0000 (14:00 -0500)
commit06d7f616872ba68330212a886ee4357338321e50
tree3da2684b6b028f8d3ca4f8328e2d748a8fe8b372
parentd85d48490b88c99f0ab328fabd0bba69db24ed62
Add language validator

Refactor some internals to make this possible.  Mainly, FunctionCallInfo
is not available when validating, so avoid accessing that if not
required.  Rename plproxy_compile() to plproxy_compile_and_cache() and
the previously internal fn_compile() to plproxy_compile().  This matches
their purpose better and allows the validator to call plproxy_compile()
without invoking execution-time dependent code.

Many error test cases have changed because the validator catches errors
when the function is created, not when it is called.

Raise the extension version to 2.5.1 to be able to upgrade from
non-validator installations.
14 files changed:
META.json
Makefile
plproxy.control
sql/ext_update_validator.sql [new file with mode: 0644]
sql/plproxy_lang.sql
src/function.c
src/main.c
src/plproxy.h
test/expected/plproxy_dynamic_record.out
test/expected/plproxy_errors.out
test/expected/plproxy_select.out
test/expected/plproxy_split.out
test/expected/plproxy_target.out
test/sql/plproxy_errors.sql