Skip to content

Commit 2031e16

Browse files
committed
Doc: fix confusion about LEAKPROOF in syntax summaries.
The syntax summaries for CREATE FUNCTION and allied commands made it look like LEAKPROOF is an alternative to IMMUTABLE/STABLE/VOLATILE, when of course it is an orthogonal option. Improve that. Per gripe from aazamrafeeque0. Thanks to David Johnston for suggestions. Discussion: https://postgr.es/m/162444349581.694.5818572718530259025@wrigleys.postgresql.org
1 parent 126cdaf commit 2031e16

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

doc/src/sgml/ref/alter_function.sgml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ ALTER FUNCTION <replaceable>name</replaceable> [ ( [ [ <replaceable class="param
3535
<phrase>where <replaceable class="parameter">action</replaceable> is one of:</phrase>
3636

3737
CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT
38-
IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF
38+
IMMUTABLE | STABLE | VOLATILE
39+
[ NOT ] LEAKPROOF
3940
[ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER
4041
PARALLEL { UNSAFE | RESTRICTED | SAFE }
4142
COST <replaceable class="parameter">execution_cost</replaceable>

doc/src/sgml/ref/alter_routine.sgml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ ALTER ROUTINE <replaceable>name</replaceable> [ ( [ [ <replaceable class="parame
3434

3535
<phrase>where <replaceable class="parameter">action</replaceable> is one of:</phrase>
3636

37-
IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF
37+
IMMUTABLE | STABLE | VOLATILE
38+
[ NOT ] LEAKPROOF
3839
[ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER
3940
PARALLEL { UNSAFE | RESTRICTED | SAFE }
4041
COST <replaceable class="parameter">execution_cost</replaceable>

doc/src/sgml/ref/create_function.sgml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,10 @@ CREATE [ OR REPLACE ] FUNCTION
2828
{ LANGUAGE <replaceable class="parameter">lang_name</replaceable>
2929
| TRANSFORM { FOR TYPE <replaceable class="parameter">type_name</replaceable> } [, ... ]
3030
| WINDOW
31-
| IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF
32-
| CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT
33-
| [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER
31+
| { IMMUTABLE | STABLE | VOLATILE }
32+
| [ NOT ] LEAKPROOF
33+
| { CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT }
34+
| { [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER }
3435
| PARALLEL { UNSAFE | RESTRICTED | SAFE }
3536
| COST <replaceable class="parameter">execution_cost</replaceable>
3637
| ROWS <replaceable class="parameter">result_rows</replaceable>

0 commit comments

Comments
 (0)