Message ID | 52AA842A.8050109@redhat.com |
---|---|
State | New |
Headers | show |
On Dec 12, 2013, at 7:51 PM, Jason Merrill <jason@redhat.com> wrote:
> I often use input_line in breakpoint conditions when debugging the compiler, and losing the macro complicates that. Any objection to adding it to gdbinit.in?
That'd be wonderful.
On Thu, 2013-12-12 at 22:51 -0500, Jason Merrill wrote: > I often use input_line in breakpoint conditions when debugging the > compiler, and losing the macro complicates that. Any objection to > adding it to gdbinit.in? Fine by me.
commit 5bee3eed904bb31ffcca5330f2c36e5aa1c35cb0 Author: Jason Merrill <jason@redhat.com> Date: Wed Dec 11 11:29:37 2013 -0500 * gdbinit.in (input_line, input_filename): Define. diff --git a/gcc/gdbinit.in b/gcc/gdbinit.in index aa0bf9b..79361a5 100644 --- a/gcc/gdbinit.in +++ b/gcc/gdbinit.in @@ -195,6 +195,8 @@ macro define __FILE__ "gdb" macro define __LINE__ 1 macro define __FUNCTION__ "gdb" macro define __null 0 +macro define input_line expand_location(input_location).line +macro define input_filename expand_location(input_location).file # Gracefully handle aborts in functions used from gdb. set unwindonsignal on