* [rfa] Stabs documentation tweak for pointers to members
@ 2006-08-02 3:26 Daniel Jacobowitz
2006-08-02 3:30 ` Eli Zaretskii
2006-08-02 21:00 ` Mark Kettenis
0 siblings, 2 replies; 5+ messages in thread
From: Daniel Jacobowitz @ 2006-08-02 3:26 UTC (permalink / raw)
To: gdb-patches
When working on pointers to members I encountered only one place in
GDB that seemed to need an actual "member" type, instead of just "pointer to
member" (which is not really a pointer at all). That was in the stabs
reader. The documentation says that stabs has a "member" construct, and
represents pointers to members as pointers to that construct. The reader
code matches this.
But if this was ever the case for GCC, it hasn't been for a while. Now
the @ descriptor means pointer to member. This patch corrects the manual;
the final patch will correct the stabs reader.
OK to commit?
--
Daniel Jacobowitz
CodeSourcery
2006-08-01 Daniel Jacobowitz <dan@codesourcery.com>
* stabs.texinfo (Member Type Descriptor): Correct example for
pointer to member types.
Index: src/gdb/doc/stabs.texinfo
===================================================================
--- src.orig/gdb/doc/stabs.texinfo 2006-08-01 23:13:43.000000000 -0400
+++ src/gdb/doc/stabs.texinfo 2006-08-01 23:17:44.000000000 -0400
@@ -2742,8 +2742,8 @@ compiler it can also be used in other co
@node Member Type Descriptor
@section The @samp{@@} Type Descriptor
-The @samp{@@} type descriptor is used together with the @samp{*} type
-descriptor for a pointer-to-non-static-member-data type. It is followed
+The @samp{@@} type descriptor is used for a
+pointer-to-non-static-member-data type. It is followed
by type information for the class (or union), a comma, and type
information for the member data.
@@ -2756,7 +2756,7 @@ typedef int A::*int_in_a;
generates the following stab:
@smallexample
-.stabs "int_in_a:t20=*21=@@19,1",128,0,0,0
+.stabs "int_in_a:t20=21=@@19,1",128,0,0,0
@end smallexample
Note that there is a conflict between this and type attributes
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [rfa] Stabs documentation tweak for pointers to members
2006-08-02 3:26 [rfa] Stabs documentation tweak for pointers to members Daniel Jacobowitz
@ 2006-08-02 3:30 ` Eli Zaretskii
2006-08-02 3:31 ` Daniel Jacobowitz
2006-08-02 21:00 ` Mark Kettenis
1 sibling, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2006-08-02 3:30 UTC (permalink / raw)
To: gdb-patches
> Date: Tue, 1 Aug 2006 23:26:55 -0400
> From: Daniel Jacobowitz <drow@false.org>
>
> OK to commit?
Yes, thanks.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [rfa] Stabs documentation tweak for pointers to members
2006-08-02 3:30 ` Eli Zaretskii
@ 2006-08-02 3:31 ` Daniel Jacobowitz
0 siblings, 0 replies; 5+ messages in thread
From: Daniel Jacobowitz @ 2006-08-02 3:31 UTC (permalink / raw)
To: gdb-patches
On Wed, Aug 02, 2006 at 06:30:06AM +0300, Eli Zaretskii wrote:
> > Date: Tue, 1 Aug 2006 23:26:55 -0400
> > From: Daniel Jacobowitz <drow@false.org>
> >
> > OK to commit?
>
> Yes, thanks.
Thanks, committed.
--
Daniel Jacobowitz
CodeSourcery
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [rfa] Stabs documentation tweak for pointers to members
2006-08-02 3:26 [rfa] Stabs documentation tweak for pointers to members Daniel Jacobowitz
2006-08-02 3:30 ` Eli Zaretskii
@ 2006-08-02 21:00 ` Mark Kettenis
2006-08-02 21:02 ` Daniel Jacobowitz
1 sibling, 1 reply; 5+ messages in thread
From: Mark Kettenis @ 2006-08-02 21:00 UTC (permalink / raw)
To: drow; +Cc: gdb-patches
> Date: Tue, 1 Aug 2006 23:26:55 -0400
> From: Daniel Jacobowitz <drow@false.org>
>
> When working on pointers to members I encountered only one place in
> GDB that seemed to need an actual "member" type, instead of just "pointer to
> member" (which is not really a pointer at all). That was in the stabs
> reader. The documentation says that stabs has a "member" construct, and
> represents pointers to members as pointers to that construct. The reader
> code matches this.
>
> But if this was ever the case for GCC, it hasn't been for a while. Now
> the @ descriptor means pointer to member. This patch corrects the manual;
> the final patch will correct the stabs reader.
For what it is worth, I couldn't find any refernce to @@ in the Sun
"Stabs Interface Manual", so it's indeed very likely this is a gcc
invention.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [rfa] Stabs documentation tweak for pointers to members
2006-08-02 21:00 ` Mark Kettenis
@ 2006-08-02 21:02 ` Daniel Jacobowitz
0 siblings, 0 replies; 5+ messages in thread
From: Daniel Jacobowitz @ 2006-08-02 21:02 UTC (permalink / raw)
To: Mark Kettenis; +Cc: gdb-patches
On Wed, Aug 02, 2006 at 10:59:26PM +0200, Mark Kettenis wrote:
> > Date: Tue, 1 Aug 2006 23:26:55 -0400
> > From: Daniel Jacobowitz <drow@false.org>
> >
> > When working on pointers to members I encountered only one place in
> > GDB that seemed to need an actual "member" type, instead of just "pointer to
> > member" (which is not really a pointer at all). That was in the stabs
> > reader. The documentation says that stabs has a "member" construct, and
> > represents pointers to members as pointers to that construct. The reader
> > code matches this.
> >
> > But if this was ever the case for GCC, it hasn't been for a while. Now
> > the @ descriptor means pointer to member. This patch corrects the manual;
> > the final patch will correct the stabs reader.
>
> For what it is worth, I couldn't find any refernce to @@ in the Sun
> "Stabs Interface Manual", so it's indeed very likely this is a gcc
> invention.
Yes, that's correct. The Sun manual documents a different solution to
this problem, starting with 'Y' (I think it's 'YM'). The two
"standards" diverged when there was no C++ support in Sun's; I suspect
GCC got C++ first, but Sun got it better. But I don't actually know
any of the history here so I'm just guessing.
--
Daniel Jacobowitz
CodeSourcery
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2006-08-02 21:02 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-08-02 3:26 [rfa] Stabs documentation tweak for pointers to members Daniel Jacobowitz
2006-08-02 3:30 ` Eli Zaretskii
2006-08-02 3:31 ` Daniel Jacobowitz
2006-08-02 21:00 ` Mark Kettenis
2006-08-02 21:02 ` Daniel Jacobowitz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox