[PATCH 0/5] readelf: reduce code duplication a little

Jan Beulich <[email protected]> Mon, 27 Jul 2026 11:17:43 +0200
Newsgroups gmane.comp.gnu.binutils
Message-ID <[email protected]>
In the grand scheme of things this isn't much of an improvement
(reduction is only by about 1% LoC), yet avoiding the need to always
edit two places when making a change to certain functionality is
perhaps still a good thing.

The last patch really is mostly RFC for now; see remark there.

1: fold get_{32,64}bit_program_headers()
2: fold get_{32,64}bit_section_headers()
3: fold get_{32,64}bit_elf_symbols()
4: fold get_{32,64}bit_dynamic_section()
5: move code around

Jan