diff options
author | Alan Modra <amodra@gmail.com> | 2022-05-27 15:28:34 +0930 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2022-05-27 22:08:59 +0930 |
commit | 601598589589734c21bacfc00cd4aed4f3fd1a1f (patch) | |
tree | 0aa92f84b76198ccaa2ba47b2ad647b920639289 /include/coff | |
parent | 65d13793d9ea142bc4383216e375b24cfa654751 (diff) | |
download | gdb-601598589589734c21bacfc00cd4aed4f3fd1a1f.zip gdb-601598589589734c21bacfc00cd4aed4f3fd1a1f.tar.gz gdb-601598589589734c21bacfc00cd4aed4f3fd1a1f.tar.bz2 |
Replace bfd_hostptr_t with uintptr_t
bfd_hostptr_t is defined as a type large enough to hold either a long
or a pointer. It mostly appears in the coff backend code in casts.
include/coff/internal.h struct internal_syment and union
internal_auxent have the only uses in data structures, where
comparison with include/coff/external.h and other code reveals that
the type only needs to be large enough for a 32-bit integer or a
pointer. That should mean replacing with uintptr_t is OK.
Diffstat (limited to 'include/coff')
-rw-r--r-- | include/coff/internal.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/include/coff/internal.h b/include/coff/internal.h index 4d2046e..4e03191 100644 --- a/include/coff/internal.h +++ b/include/coff/internal.h @@ -469,8 +469,8 @@ struct internal_syment char _n_name[SYMNMLEN] ATTRIBUTE_NONSTRING; /* old COFF version */ struct { - bfd_hostptr_t _n_zeroes; /* new == 0 */ - bfd_hostptr_t _n_offset; /* offset into string table */ + uintptr_t _n_zeroes; /* new == 0 */ + uintptr_t _n_offset; /* offset into string table */ } _n_n; char *_n_nptr[2]; /* allows for overlaying */ } _n; @@ -595,11 +595,11 @@ union internal_auxent char x_fname[20]; struct { - /* PR 28630: We use bfd_hostptr_t because these fields may be + /* PR 28630: We use uintptr_t because these fields may be used to hold pointers. We assume that this type is at least - as big as the long type. */ - bfd_hostptr_t x_zeroes; - bfd_hostptr_t x_offset; + 32 bits. */ + uintptr_t x_zeroes; + uintptr_t x_offset; } x_n; } x_n; |