pgsql: Use pg_assume() to avoid compiler warning below exec_set_found() - Mailing list pgsql-committers

From Andres Freund
Subject pgsql: Use pg_assume() to avoid compiler warning below exec_set_found()
Date
Msg-id E1uZe5R-005Ukb-1k@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Use pg_assume() to avoid compiler warning below exec_set_found()

The warning, visible when building with -O3 and a recent-ish gcc, is due to
gcc not realizing that found is a byvalue type and therefore will never be
interpreted as a varlena type.

Discussion: https://postgr.es/m/3prdb6hkep3duglhsujrn52bkvnlkvhc54fzvph2emrsm4vodl@77yy6j4hkemb
Discussion: https://postgr.es/m/20230316172818.x6375uvheom3ibt2%40awork3.anarazel.de
Discussion: https://postgr.es/m/20240207203138.sknifhlppdtgtxnk%40awork3.anarazel.de

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/48a23f6eae710d2c5c29f38e66d76e7919117e4d

Modified Files
--------------
src/pl/plpgsql/src/pl_exec.c | 9 +++++++++
1 file changed, 9 insertions(+)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Link libpq with libdl if the platform needs that.
Next
From: Michael Paquier
Date:
Subject: pgsql: injection_points: Add injection_points_list()