summaryrefslogtreecommitdiff
path: root/gdb/ui-out.c
diff options
context:
space:
mode:
authorJeff Johnston <jjohnstn@redhat.com>2002-10-03 22:34:58 +0000
committerJeff Johnston <jjohnstn@redhat.com>2002-10-03 22:34:58 +0000
commit9fce65fced11546a20ca0cf57fdbe3fe628faa6b (patch)
tree27f4d2b4ea49632ecea100b86671d88bda2db3fe /gdb/ui-out.c
parente0310b2c66735907a0cf21cc1066a6eeee2820f3 (diff)
downloadgdb-9fce65fced11546a20ca0cf57fdbe3fe628faa6b.tar.gz
2002-10-03 Jeff Johnston <jjohnstn@redhat.com>
* ui-out.h (ui_out_field_fmt_int): New prototype. * ui-out.c (ui_out_field_fmt_int): New function allowing specification of field width and alignment. * stack.c (print_frame_info_base): When printing frame level, use ui_out_field_fmt_int with a width of 2 and left alignment. Fix for PR gdb/192
Diffstat (limited to 'gdb/ui-out.c')
-rw-r--r--gdb/ui-out.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/gdb/ui-out.c b/gdb/ui-out.c
index 4a4a9228540..da7740f4ca6 100644
--- a/gdb/ui-out.c
+++ b/gdb/ui-out.c
@@ -486,6 +486,23 @@ ui_out_field_int (struct ui_out *uiout,
}
void
+ui_out_field_fmt_int (struct ui_out *uiout,
+ int input_width,
+ enum ui_align input_align,
+ const char *fldname,
+ int value)
+{
+ int fldno;
+ int width;
+ int align;
+ struct ui_out_level *current = current_level (uiout);
+
+ verify_field (uiout, &fldno, &width, &align);
+
+ uo_field_int (uiout, fldno, input_width, input_align, fldname, value);
+}
+
+void
ui_out_field_core_addr (struct ui_out *uiout,
const char *fldname,
CORE_ADDR address)