This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 4/5] Make sect_offset and cu_offset strong typedefs instead of structs
- From: Pedro Alves <palves at redhat dot com>
- To: Simon Marchi <simon dot marchi at polymtl dot ca>
- Cc: gdb-patches at sourceware dot org
- Date: Wed, 5 Apr 2017 16:13:01 +0100
- Subject: Re: [PATCH 4/5] Make sect_offset and cu_offset strong typedefs instead of structs
- Authentication-results: sourceware.org; auth=none
- References: <1490754298-9455-1-git-send-email-palves@redhat.com> <1490754298-9455-5-git-send-email-palves@redhat.com> <ff9cee4d3eee2fbb0eb7273397ead7e1@polymtl.ca>
On 03/29/2017 04:46 PM, Simon Marchi wrote:
> A while ago (in the pre C++ era), I asked you if we could make some
> integer types that couldn't be assigned to each other, to represent
> 8-bit bytes and target bytes. That would help avoid mixing incompatible
> lengths or offsets for targets that have 16 or 32 bit bytes, forcing us
> to do the appropriate conversion. There was no way to do it in C. Do
> you think offset-type could be used for that now?
Indeed, that might work.
Thanks,
Pedro Alves