mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-03-26 16:51:46 -07:00
Fix igc_header for Mingw64
* src/igc-types.h (union igc_header): Use uint32_t instead for size_t. Apparently needed for Mingw64; with size_t the header grows to 16 bytes. * src/igc.c: Move static assert to igc-types.h.
This commit is contained in:
parent
6a321be685
commit
a4eb23205a
2 changed files with 7 additions and 6 deletions
|
|
@ -96,15 +96,15 @@ union igc_header
|
|||
{
|
||||
enum igc_tag tag : IGC_HEADER_TAG_BITS;
|
||||
enum igc_obj_type obj_type : IGC_HEADER_TYPE_BITS;
|
||||
size_t hash : IGC_HEADER_HASH_BITS;
|
||||
size_t nwords : IGC_HEADER_NWORDS_BITS;
|
||||
uint32_t hash : IGC_HEADER_HASH_BITS;
|
||||
uint32_t nwords : IGC_HEADER_NWORDS_BITS;
|
||||
} s;
|
||||
#endif
|
||||
#ifdef WORDS_BIGENDIAN
|
||||
struct
|
||||
{
|
||||
size_t nwords : IGC_HEADER_NWORDS_BITS;
|
||||
size_t hash : IGC_HEADER_HASH_BITS;
|
||||
uint32_t nwords : IGC_HEADER_NWORDS_BITS;
|
||||
uint32_t hash : IGC_HEADER_HASH_BITS;
|
||||
enum igc_obj_type obj_type : IGC_HEADER_TYPE_BITS;
|
||||
enum igc_tag tag : IGC_HEADER_TAG_BITS;
|
||||
} s;
|
||||
|
|
@ -113,4 +113,7 @@ union igc_header
|
|||
GCALIGNED_UNION_MEMBER
|
||||
};
|
||||
|
||||
static_assert (sizeof (*(union igc_header*) 0).s == 8);
|
||||
static_assert (sizeof (union igc_header) == 8);
|
||||
|
||||
#endif /* EMACS_IGC_TYPES_H */
|
||||
|
|
|
|||
|
|
@ -663,8 +663,6 @@ struct igc_fwd
|
|||
mps_addr_t new_addr;
|
||||
};
|
||||
|
||||
static_assert (sizeof (union igc_header) == 8);
|
||||
|
||||
static void
|
||||
check_header_bit (union igc_header h1, size_t i, size_t shift)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue