This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: Problem with virtual function pointers
- From: Corinna Vinschen <vinschen at redhat dot com>
- To: gdb at sources dot redhat dot com
- Date: Tue, 1 Apr 2003 19:33:51 +0200
- Subject: Re: Problem with virtual function pointers
- References: <20030327142412.GK23762@cygbert.vinschen.de> <20030327145346.GA7253@nevyn.them.org> <20030327152022.GL23762@cygbert.vinschen.de> <20030327152652.GA8010@nevyn.them.org> <20030327161824.GM23762@cygbert.vinschen.de>
- Reply-to: gdb at sources dot redhat dot com
Is there any news on that?
Corinna
On Thu, Mar 27, 2003 at 05:18:24PM +0100, Corinna Vinschen wrote:
> On Thu, Mar 27, 2003 at 10:26:52AM -0500, Daniel Jacobowitz wrote:
> > There's your bug, right on schedule. Look at the line:
> > addr = unpack_pointer (lookup_pointer_type (builtin_type_void), valaddr);
> >
> > Recommend using builtin_type_void_func_ptr instead of
> > lookup_pointer_type (builtin_type_void). Does that fix it?
>
> Yes, it does fix the problem. Thank you!
>
> However, I don't understand why it's done this way. The incoming
> type into this function is already correct AFAICS (well, this time,
> I didn't get it when I wrote my first posting, apparently). type
> is a TYPE_CODE_PTR to a TYPE_CODE_METHOD to TYPE_CODE_VOID.
>
> So, from my point of view the correct call would just be
>
> addr = unpack_pointer (type, valaddr);
>
> Why isn't type just used as is?
>
> Btw., I've just ran the full c++ testsuite again and using just type shows
> no regressions (for xstormy16).
>
>
> Corinna
>
> --
> Corinna Vinschen
> Cygwin Developer
> Red Hat, Inc.
> mailto:vinschen at redhat dot com
--
Corinna Vinschen
Cygwin Developer
Red Hat, Inc.
mailto:vinschen at redhat dot com