Re: Safer hash table initialization macro
Jelte Fennema <postgres@jeltef.nl>
From: "Jelte Fennema-Nio" <postgres@jeltef.nl>
To: "Chao Li" <li.evan.chao@gmail.com>
Cc: "Bertrand Drouvot" <bertranddrouvot.pg@gmail.com>, "Thomas Munro"
<thomas.munro@gmail.com>, <pgsql-hackers@lists.postgresql.org>
Date: 2026-03-14T13:48:58Z
Lists: pgsql-hackers
Attachments
- v11-0001-Add-hash_make-macros.patch (text/x-patch) patch v11-0001
- v11-0002-Add-foreach_hash-macro.patch (text/x-patch) patch v11-0002
- v11-0003-Use-hash_make-macros-throughout-the-codebase.patch (text/x-patch) patch v11-0003
- v11-0004-Use-foreach_hash-macro-throughout-the-codebase.patch (text/x-patch) patch v11-0004
- v11-0005-Inline-functions-that-have-now-become-trivial.patch (text/x-patch) patch v11-0005
On Tue Jan 27, 2026 at 7:10 PM CET, Jelte Fennema-Nio wrote: > Good suggestion. Done. Newly attached version that fixes a rebase conclict. Including a few small additions: 1. Use foreach_hash in async.c (in recently introduced code from 282b1cde9ded) 2. Reference foreach_hash in code comments instead of hash_seq_search 3. Add a note about the reason for the double for loop in foreach_hash macro code comment (same comment as for foreach_internal in pg_list.h)