diff --git a/dwarves.c b/dwarves.c index 81fa47b..8ab0152 100644 --- a/dwarves.c +++ b/dwarves.c @@ -1607,7 +1607,7 @@ void type__check_structs_at_unnatural_alignments(struct type *type, const struct struct class *cls = tag__class(member_type); cls->is_packed = true; - cls->type.packed_attributes_inferred = true; + cls->type.packed_attributes_inferred = 1; } } } @@ -1663,7 +1663,7 @@ bool class__infer_packed_attributes(struct class *cls, const struct cu *cu) cls->is_packed = true; out: - ctype->packed_attributes_inferred = true; + ctype->packed_attributes_inferred = 1; return cls->is_packed; } @@ -1695,11 +1695,11 @@ void union__infer_packed_attributes(struct type *type, const struct cu *cu) struct class *cls = tag__class(member_type); cls->is_packed = true; - cls->type.packed_attributes_inferred = true; + cls->type.packed_attributes_inferred = 1; } } - type->packed_attributes_inferred = true; + type->packed_attributes_inferred = 1; } /** class__has_hole_ge - check if class has a hole greater or equal to @size diff --git a/dwarves.h b/dwarves.h index 2d68510..67d1a9e 100644 --- a/dwarves.h +++ b/dwarves.h @@ -1038,7 +1038,7 @@ struct type { uint16_t member_prefix_len; uint16_t max_tag_name_len; uint16_t natural_alignment; - bool packed_attributes_inferred; + uint8_t packed_attributes_inferred:1; uint8_t declaration:1; uint8_t definition_emitted:1; uint8_t fwd_decl_emitted:1;