Re: Document that PG_TRY block cannot have a return statement - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Document that PG_TRY block cannot have a return statement
Date
Msg-id 2796288.1694528966@sss.pgh.pa.us
Whole thread Raw
In response to Document that PG_TRY block cannot have a return statement  (Serpent <serpent7776@gmail.com>)
List pgsql-hackers
Serpent <serpent7776@gmail.com> writes:
> I created a tiny patch that documents that the code block following
> PG_TRY() cannot have any return statement.

AFAIK, this is wrong.  The actual requirement is already stated
in the comment:

 * ... The error recovery code
 * can either do PG_RE_THROW to propagate the error outwards, or do a
 * (sub)transaction abort.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Alexander Kukushkin
Date:
Subject: Re: pg_rewind WAL segments deletion pitfall
Next
From: Tom Lane
Date:
Subject: Re: Adding a pg_get_owned_sequence function?