summaryrefslogtreecommitdiff
path: root/gcc/cp/class.c
diff options
context:
space:
mode:
authorjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>2003-03-31 20:25:11 +0000
committerjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>2003-03-31 20:25:11 +0000
commit066b1d5287e4399deb39b038c2b21e0b0bd858f6 (patch)
tree4a8375fa12eae842753474c9b26fb22fd446774f /gcc/cp/class.c
parentf0904069ae3893971102ffeb50f68e0723f4960c (diff)
downloadgcc-066b1d5287e4399deb39b038c2b21e0b0bd858f6.tar.gz
PR java/10145
* stor-layout.c (update_alignment_for_field): Respect DECL_USER_ALIGN for zero-length bitfields, too. * c-decl.c (finish_struct): Don't set DECL_ALIGN for normal fields. * cp/class.c (check_field_decl): Don't set DECL_ALIGN. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@65103 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/class.c')
-rw-r--r--gcc/cp/class.c9
1 files changed, 0 insertions, 9 deletions
diff --git a/gcc/cp/class.c b/gcc/cp/class.c
index e899c571406..01d4dd215ed 100644
--- a/gcc/cp/class.c
+++ b/gcc/cp/class.c
@@ -3057,15 +3057,6 @@ check_field_decl (tree field,
cp_error_at ("multiple fields in union `%T' initialized");
*any_default_members = 1;
}
-
- /* Non-bit-fields are aligned for their type, except packed fields
- which require only BITS_PER_UNIT alignment. */
- DECL_ALIGN (field) = MAX (DECL_ALIGN (field),
- (DECL_PACKED (field)
- ? BITS_PER_UNIT
- : TYPE_ALIGN (TREE_TYPE (field))));
- if (! DECL_PACKED (field))
- DECL_USER_ALIGN (field) |= TYPE_USER_ALIGN (TREE_TYPE (field));
}
/* Check the data members (both static and non-static), class-scoped