This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC] New language-method to print local symbol?
- From: Tom Tromey <tromey at redhat dot com>
- To: Joel Brobecker <brobecker at adacore dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Wed, 22 Apr 2009 14:14:22 -0600
- Subject: Re: [RFC] New language-method to print local symbol?
- References: <20081001020923.GB3665@adacore.com>
- Reply-to: tromey at redhat dot com
>>>>> "Joel" == Joel Brobecker <brobecker@adacore.com> writes:
I never saw a reply to this...
Joel> My suggestion is to define a new language method called
Joel> la_print_block_frame_local_sym (struct symbol *sym,
Joel> struct block *b,
Joel> struct frame_info *frame,
Joel> struct ui_file *stream)
Joel> I would define a "default_print_block_frame_local_sym" that simply
Joel> calls "print_variable_value" while the Ada version would check for
Joel> renamings first, and fallback on the default print version if not.
Sounds ok to me.
Joel> Given that we use the current_language to print variables, regardless
Joel> of whether the language matches the frame or not, I think we want to
Joel> do the same here.
Doesn't this seem a bit strange? If the language is auto, it seems
like we should use the frame's language.
Tom