This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] Fix "ambiguous linespec" regression: break lineno
- From: Tom Tromey <tromey at redhat dot com>
- To: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Fri, 08 Jun 2012 14:40:55 -0600
- Subject: Re: [patch] Fix "ambiguous linespec" regression: break lineno
- References: <20120608193958.GA10296@host2.jankratochvil.net>
>>>>> "Jan" == Jan Kratochvil <jan.kratochvil@redhat.com> writes:
Jan> It seems somehow clear to me, OK to check it in?
I agree it is an improvement.
However, why should this apply to linespecs used by 'break' but not by
other ones?
Jan> + if (last_displayed_sal_is_valid ()
linespec.c:initialize_defaults has:
struct symtab_and_line cursal =
get_current_source_symtab_and_line ();
It seems like we have two similar notions here -- the "current" source
line and the "last displayed" source line.
This doesn't make sense to me. Can we not just have a single notion and
use it everywhere?
If we really need two, can we do the processing in linespec.c?
I realize you're just reverting a bit of code - but is that ObjC hack
really needed? I'd like us to get away from this kind of thing.
Tom