From: "J. Johnston" <jjohnstn@redhat.com>
To: Andrew Cagney <ac131313@redhat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: Patch for gdb/mi problem 192
Date: Thu, 03 Oct 2002 13:21:00 -0000 [thread overview]
Message-ID: <3D9CA6C1.DC9B0F35@redhat.com> (raw)
In-Reply-To: <3D9B72E8.1080300@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 1350 bytes --]
Andrew Cagney wrote:
>
> > gdb/ChangeLog:
> >
> > 2002-09-30 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
>
> Ok, so instead of:
> frame="2 "
> it outputs
> frame="2"
> I think this is a straight bug that can't (?) affect old parsers (...).
>
> So, yes, ok.
>
> Can you just add a NEWS entry pointing out that this was fixed. You'll
> now also need to update both mi-*.exp and mi1-*.exp.
>
> > gdb/testsuite/gdb.mi/ChangeLog:
> >
> > 2002-09-30 Jeff Johnston <jjohnstn@redhat.com>
> >
> > * mi-stack.exp: Change testcases that print frame to not expect "level" field
> > to have extraneous right space. Fix for PR gdb/192.
> > * mi-return.exp: Ditto.
> >
>
> Also (independant patch) can you please mention this new
> ui_out_field_fmt_int() function in the gdbint.texinfo doco (look for
> ui_out_field_int()). If Eli is ok with it, then it is approved.
>
Ok, additional doc patches added to this note. Eli, I will wait for your
approval.
-- Jeff J.
[-- Attachment #2: 192.doc.patch --]
[-- Type: text/plain, Size: 5063 bytes --]
Index: doc/gdbint.texinfo
===================================================================
RCS file: /cvs/src/src/gdb/doc/gdbint.texinfo,v
retrieving revision 1.102
diff -u -r1.102 gdbint.texinfo
--- doc/gdbint.texinfo 19 Sep 2002 15:43:49 -0000 1.102
+++ doc/gdbint.texinfo 3 Oct 2002 20:19:31 -0000
@@ -1011,6 +1011,13 @@
the name of the field.
@end deftypefun
+@deftypefun void ui_out_field_fmt_int (struct ui_out *@var{uiout}, int @var{width}, enum ui_align @var{alignment}, const char *@var{fldname}, int @var{value})
+This function outputs a value of an @code{int} variable. It differs from
+@code{ui_out_field_int} in that the caller specifies the desired @var{width} and @var{alignment} of the output.
+@var{fldname} specifies
+the name of the field.
+@end deftypefun
+
@deftypefun void ui_out_field_core_addr (struct ui_out *@var{uiout}, const char *@var{fldname}, CORE_ADDR @var{address})
This function outputs an address.
@end deftypefun
Index: mi/gdbmi.texinfo
===================================================================
RCS file: /cvs/src/src/gdb/mi/gdbmi.texinfo,v
retrieving revision 1.28
diff -u -r1.28 gdbmi.texinfo
--- mi/gdbmi.texinfo 27 Sep 2002 18:09:27 -0000 1.28
+++ mi/gdbmi.texinfo 3 Oct 2002 20:19:31 -0000
@@ -2034,7 +2034,7 @@
205^done
(@value{GDBP})
111-exec-return
-111^done,frame=@{level="0 ",func="callee3",
+111^done,frame=@{level="0",func="callee3",
args=[@{name="strarg",
value="0x11940 \"A string argument.\""@}],
file="../../../devo/gdb/testsuite/gdb.mi/basics.c",line="18"@}
@@ -2641,15 +2641,15 @@
-stack-list-frames
^done,
stack=[
-frame=@{level="0 ",addr="0x00010734",func="callee4",
+frame=@{level="0",addr="0x00010734",func="callee4",
file="../../../devo/gdb/testsuite/gdb.mi/basics.c",line="8"@},
-frame=@{level="1 ",addr="0x0001076c",func="callee3",
+frame=@{level="1",addr="0x0001076c",func="callee3",
file="../../../devo/gdb/testsuite/gdb.mi/basics.c",line="17"@},
-frame=@{level="2 ",addr="0x0001078c",func="callee2",
+frame=@{level="2",addr="0x0001078c",func="callee2",
file="../../../devo/gdb/testsuite/gdb.mi/basics.c",line="22"@},
-frame=@{level="3 ",addr="0x000107b4",func="callee1",
+frame=@{level="3",addr="0x000107b4",func="callee1",
file="../../../devo/gdb/testsuite/gdb.mi/basics.c",line="27"@},
-frame=@{level="4 ",addr="0x000107e0",func="main",
+frame=@{level="4",addr="0x000107e0",func="main",
file="../../../devo/gdb/testsuite/gdb.mi/basics.c",line="32"@}]
(@value{GDBP})
-stack-list-arguments 0
@@ -2731,25 +2731,25 @@
(@value{GDBP})
-stack-list-frames
^done,stack=
-[frame=@{level="0 ",addr="0x0001076c",func="foo",
+[frame=@{level="0",addr="0x0001076c",func="foo",
file="recursive2.c",line="11"@},
-frame=@{level="1 ",addr="0x000107a4",func="foo",
+frame=@{level="1",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="2 ",addr="0x000107a4",func="foo",
+frame=@{level="2",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="3 ",addr="0x000107a4",func="foo",
+frame=@{level="3",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="4 ",addr="0x000107a4",func="foo",
+frame=@{level="4",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="5 ",addr="0x000107a4",func="foo",
+frame=@{level="5",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="6 ",addr="0x000107a4",func="foo",
+frame=@{level="6",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="7 ",addr="0x000107a4",func="foo",
+frame=@{level="7",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="8 ",addr="0x000107a4",func="foo",
+frame=@{level="8",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="9 ",addr="0x000107a4",func="foo",
+frame=@{level="9",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
frame=@{level="10",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
@@ -2764,11 +2764,11 @@
(@value{GDBP})
-stack-list-frames 3 5
^done,stack=
-[frame=@{level="3 ",addr="0x000107a4",func="foo",
+[frame=@{level="3",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="4 ",addr="0x000107a4",func="foo",
+frame=@{level="4",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@},
-frame=@{level="5 ",addr="0x000107a4",func="foo",
+frame=@{level="5",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@}]
(@value{GDBP})
@end smallexample
@@ -2779,7 +2779,7 @@
(@value{GDBP})
-stack-list-frames 3 3
^done,stack=
-[frame=@{level="3 ",addr="0x000107a4",func="foo",
+[frame=@{level="3",addr="0x000107a4",func="foo",
file="recursive2.c",line="14"@}]
(@value{GDBP})
@end smallexample
@@ -3442,7 +3442,7 @@
(@value{GDBP})
-thread-select 3
^done,new-thread-id="3",
-frame=@{level="0 ",func="vprintf",
+frame=@{level="0",func="vprintf",
args=[@{name="format",value="0x8048e9c \"%*s%c %d %c\\n\""@},
@{name="arg",value="0x2"@}],file="vprintf.c",line="31"@}
(@value{GDBP})
next prev parent reply other threads:[~2002-10-03 20:21 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-09-30 14:06 J. Johnston
2002-10-02 15:27 ` Andrew Cagney
2002-10-03 13:21 ` J. Johnston [this message]
2002-10-03 13:33 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3D9CA6C1.DC9B0F35@redhat.com \
--to=jjohnstn@redhat.com \
--cc=ac131313@redhat.com \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox