[RFC/RFA] Set current language when dumping symtab
Daniel Jacobowitz
drow@false.org
Mon May 30 20:06:00 GMT 2005
On Tue, May 31, 2005 at 05:53:39AM +1000, Joel Brobecker wrote:
> +static void
> +dump_symtab (struct objfile *objfile, struct symtab *symtab,
> + struct ui_file *outfile)
> +{
> + enum language saved_lang;
> + volatile struct gdb_exception except;
> +
> + /* Set the current language to the language of the symtab we're dumping
> + because certain routines used during dump_symtab() use the current
> + language to print an image of the symbol. We'll restore it later. */
> + saved_lang = set_language (symtab->language);
> +
> + dump_symtab_1 (objfile, symtab, outfile);
> +
> + set_language (saved_lang);
> +}
> +
Except now except is unused, and there's no reason not to fold this
into dump_symtab.
--
Daniel Jacobowitz
CodeSourcery, LLC
More information about the Gdb-patches
mailing list