Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Claudiu Zissulescu <claudiu.zissulescu-ianculescu@amd.com>
Cc: <gdb-patches@sourceware.org>, <pedro@palves.net>, <Lancelot.Six@amd.com>
Subject: Re: [PATCH] gdb: return the object's address for dynamic_cast<void *>
Date: Thu, 05 Nov 2026 09:36:28 -0700	[thread overview]
Message-ID: <877birz14j.fsf@tromey.com> (raw)
In-Reply-To: <20261105110854.56434-1-claudiu.zissulescu-ianculescu@amd.com> (Claudiu Zissulescu's message of "Thu, 5 Nov 2026 13:08:54 +0200")

>>>>> Claudiu Zissulescu <claudiu.zissulescu-ianculescu@amd.com> writes:

> From: Claudiu Zissulescu-Ianculescu <claudiu.zissulescu-ianculescu@amd.com>
> value_dynamic_cast computes the address of the most derived object, but
> for a cast to "void *" it then returns value_at_lazy (type, addr): the
> "void *" stored at that address, i.e. the first word of the object.  For
> a polymorphic class that is the vtable pointer:

Thanks for the patch.  This is ok.

Approved-By: Tom Tromey <tom@tromey.com>

Tom

  reply	other threads:[~2026-11-05 16:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-05 11:08 Claudiu Zissulescu
2026-11-05 16:36 ` Tom Tromey [this message]
2026-11-06 12:01   ` Zissulescu-Ianculescu, Claudiu

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=877birz14j.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=Lancelot.Six@amd.com \
    --cc=claudiu.zissulescu-ianculescu@amd.com \
    --cc=gdb-patches@sourceware.org \
    --cc=pedro@palves.net \
    /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