From: Daniel Jacobowitz <drow@mvista.com>
To: "Peter.Schauer" <Peter.Schauer@Regent.E-Technik.TU-Muenchen.DE>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] Fix calling of static C++ member functions
Date: Sun, 12 May 2002 12:54:00 -0000 [thread overview]
Message-ID: <20020512195404.GA1412@nevyn.them.org> (raw)
In-Reply-To: <200205121948.VAA02252@reisser.regent.e-technik.tu-muenchen.de>
On Sun, May 12, 2002 at 09:48:56PM +0200, Peter.Schauer wrote:
> > I had to make some substantial changes to this. First of all, I wanted
> > to kill the now-obsolete static_memfuncp argument to find_method_list.
> > Secondly, the way you were skipping THIS in typecmp caused segfaults
> > for some methods which only expected one argument. Here's what I
> > checked in.
> >
> > I -think- I'm caught up on all the patches you sent me now, Peter.
>
> Yes you are, thank you very much.
>
> Thanks also for fixing the segfaults, but I'd be interested in an example
> where this happened. I tried to simplify the typcmp logic as much as possible,
> but obviously failed.
You incremented t1 after the check for whether the next type was VOID.
If it was, the following type could be a garbage pointer. I got
segfaults in userdef.exp, I believe.
>
> One minor nit, the comments should reflect the elimination of static_memfuncp:
>
> --- ./valops.c.orig Sun May 12 17:16:37 2002
> +++ ./valops.c Sun May 12 17:55:37 2002
> @@ -2515,7 +2516,6 @@ value_struct_elt (struct value **argp, s
> * ARGP is a pointer to a pointer to a value (the object)
> * METHOD is a string containing the method name
> * OFFSET is the offset within the value
> - * STATIC_MEMFUNCP is set if the method is static
> * TYPE is the assumed type of the object
> * NUM_FNS is the number of overloaded instances
> * BASETYPE is set to the actual type of the subobject where the method is found
> @@ -2606,7 +2606,6 @@ find_method_list (struct value **argp, c
> * ARGP is a pointer to a pointer to a value (the object)
> * METHOD is the method name
> * OFFSET is the offset within the value contents
> - * STATIC_MEMFUNCP is set if the method is static
> * NUM_FNS is the number of overloaded instances
> * BASETYPE is set to the type of the base subobject that defines the method
> * BOFFSET is the offset of the base subobject which defines the method */
>
> Thanks again,
Quite right. Would you please commit that update?
--
Daniel Jacobowitz Carnegie Mellon University
MontaVista Software Debian GNU/Linux Developer
next prev parent reply other threads:[~2002-05-12 19:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-03-15 2:44 Peter.Schauer
2002-04-14 17:29 ` Andrew Cagney
2002-04-14 18:50 ` Daniel Jacobowitz
2002-05-11 19:21 ` Daniel Jacobowitz
2002-05-12 12:49 ` Peter.Schauer
2002-05-12 12:54 ` Daniel Jacobowitz [this message]
2002-07-12 12:24 ` Daniel Jacobowitz
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=20020512195404.GA1412@nevyn.them.org \
--to=drow@mvista.com \
--cc=Peter.Schauer@Regent.E-Technik.TU-Muenchen.DE \
--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