Re: [PATCH 4/8] gdb/xcoffread: remove xcoff_symfile_info::{symtbl, symtbl_num_syms}

Tom Tromey
2026-01-08T20:36:42Z

>>>>> "Simon" == Simon Marchi <simon.marchi@efficios.com> writes:

Simon> It is not necessary to save the symbol table content and number of
Simon> symbols in xcoff_symfile_info, because they are only needed for the
Simon> duration of scan_xcoff_symtab.

Simon> Move the reading of the symbol table content to scan_xcoff_symtab, and
Simon> keep everything as local variables.

Simon> + /* Seek to symbol table location. */
Simon> + if (int ret = bfd_seek (abfd, symtab_offset, SEEK_SET);
Simon> + ret < 0)
Simon> + error (_("Error reading symbols from %s: %s"),
Simon> + objfile_name (objfile), bfd_errmsg (bfd_get_error ()));

'ret' doesn't really seem to be needed here.

Otherwise looks good.
Approved-By: Tom Tromey <tom@tromey.com>

Tom