On 03.06.21 12:54, Bharath Rupireddy wrote:
> It looks like for some of the fsm_set_and_search calls whose return
> value is ignored (in fsm_search and RecordPageWithFreeSpace), there's
> no (void). Is it intentional? In the code base, we generally have
> (void) when non-void return value of a function is ignored.
I don't think that is correct. I don't see anyone writing
(void) printf(...);
so this is not a generally applicable strategy.
We have pg_nodiscard for functions where you explicitly want callers to
check the return value. In all other cases, callers are free to ignore
return values.