aboutsummaryrefslogtreecommitdiff
path: root/gdb/breakpoint.c
diff options
context:
space:
mode:
authorDaniel Jacobowitz <drow@false.org>2006-02-06 21:55:06 +0000
committerDaniel Jacobowitz <drow@false.org>2006-02-06 21:55:06 +0000
commit38fcd64c3aab38859abfe7bbef7ced8942bfa74d (patch)
treec58586ac9e8b7c217120575fef4242bb1d42254b /gdb/breakpoint.c
parent37debb04b8e41ac7ece23f806c73fd16b92372ca (diff)
downloadfsf-binutils-gdb-38fcd64c3aab38859abfe7bbef7ced8942bfa74d.zip
fsf-binutils-gdb-38fcd64c3aab38859abfe7bbef7ced8942bfa74d.tar.gz
fsf-binutils-gdb-38fcd64c3aab38859abfe7bbef7ced8942bfa74d.tar.bz2
From Vladimir Prus <ghost@cs.msu.su>:
gdb/ * breakpoint.c (print_one_breakpoint): For MI-like UI, output fullname field. gdb/doc/ * gdb.texinfo (Breakpoint table commands): Document the fullname field in -break-list output. gdb/testsuite/ * gdb.mi/mi-break.exp, gdb.mi/mi2-break.exp: Test for the fullname field.
Diffstat (limited to 'gdb/breakpoint.c')
-rw-r--r--gdb/breakpoint.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
index 064762d..ddca4df 100644
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -1,7 +1,7 @@
/* Everything about breakpoints, for GDB.
Copyright (C) 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994,
- 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
+ 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
Free Software Foundation, Inc.
This file is part of GDB.
@@ -3506,6 +3506,16 @@ print_one_breakpoint (struct breakpoint *b,
}
ui_out_field_string (uiout, "file", b->source_file);
ui_out_text (uiout, ":");
+
+ if (ui_out_is_mi_like_p (uiout))
+ {
+ struct symtab_and_line sal = find_pc_line (b->loc->address, 0);
+ char *fullname = symtab_to_fullname (sal.symtab);
+
+ if (fullname)
+ ui_out_field_string (uiout, "fullname", fullname);
+ }
+
ui_out_field_int (uiout, "line", b->line_number);
}
else if (b->pending)