This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug python/23936] python: cast of typedef loses address
- From: "tromey at sourceware dot org" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Fri, 30 Nov 2018 11:24:58 +0000
- Subject: [Bug python/23936] python: cast of typedef loses address
- Auto-submitted: auto-generated
- References: <bug-23936-4717@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=23936
Tom Tromey <tromey at sourceware dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |tromey at sourceware dot org
--- Comment #1 from Tom Tromey <tromey at sourceware dot org> ---
I'm not completely sure this is a bug.
Casting an rvalue will sometimes convert it to a different size.
So preserving the address definitely can't always work.
On the other hand, casting from a typedef to the underlying type
does seem like it should always be safe and so could be
location-preserving.
A workaround for this case is to cast the address instead of the
value.
--
You are receiving this mail because:
You are on the CC list for the bug.