Paint some PG_USED_FOR_ASSERTS_ONLY in inline functions of ilist.h and bufpage.h - Mailing list pgsql-hackers

From Michael Paquier
Subject Paint some PG_USED_FOR_ASSERTS_ONLY in inline functions of ilist.h and bufpage.h
Date
Msg-id YAY7boLRgOlkFZgi@paquier.xyz
Whole thread Raw
Responses Re: Paint some PG_USED_FOR_ASSERTS_ONLY in inline functions of ilist.h and bufpage.h
List pgsql-hackers
Hi all,

The following functions in ilist.h and bufpage.h use some arguments
only in assertions:
- dlist_next_node
- dlist_prev_node
- slist_has_next
- slist_next_node
- PageValidateSpecialPointer

Without PG_USED_FOR_ASSERTS_ONLY, this can lead to compilation
warnings when not using assertions, and one example of that is
plpgsql_check.  We don't have examples on HEAD where
PG_USED_FOR_ASSERTS_ONLY is used on arguments, but that looks to work
properly with gcc.

Thoughts?
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: "tsunakawa.takay@fujitsu.com"
Date:
Subject: RE: POC: postgres_fdw insert batching
Next
From: "tsunakawa.takay@fujitsu.com"
Date:
Subject: RE: POC: postgres_fdw insert batching