This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Add fullname field for MI -break-info command
- From: Vladimir Prus <ghost at cs dot msu dot su>
- To: Nick Roberts <nickrob at snap dot net dot nz>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Thu, 26 Jan 2006 14:44:09 +0300
- Subject: Re: [PATCH] Add fullname field for MI -break-info command
- References: <17368.45539.671403.826516@kahikatea.snap.net.nz>
On Thursday 26 January 2006 14:26, Nick Roberts wrote:
> + if (ui_out_is_mi_like_p (uiout))
> + {
> + if (b->loc->loc_type == bp_loc_software_breakpoint ||
> + b->loc->loc_type == bp_loc_hardware_watchpoint)
> ^^^^^^^^^^
> Should this be bp_loc_hardware_breakpoint?
You're right, it's a typo.
> + }
> + }
> +
>
> Also, I would move it up breakpoint.c (without the call to annotate_field)
> to here:
>
> if (b->source_file)
> {
> sym = find_pc_sect_function (b->loc->address, b->loc->section);
> if (sym)
> {
> ui_out_text (uiout, "in ");
> ui_out_field_string (uiout, "func",
> SYMBOL_PRINT_NAME (sym));
> ui_out_wrap_hint (uiout, wrap_indent);
> ui_out_text (uiout, " at ");
> }
> ui_out_field_string (uiout, "file", b->source_file);
> ui_out_text (uiout, ":");
>
> --->
>
> ui_out_field_int (uiout, "line", b->line_number);
> }
>
> to be consistent with the output of print_frame, where the order is
> file, fullname, line.
Makes sense.
> Putting it here might also mean that the test for b->loc->loc_type isn't
> needed, but I don't really know.
Can anybody comment on this?
Thanks,
Volodya