* class.c (finish_struct_1): Always reset TYPE_FIELDS for empty classes.

From-SVN: r25944
This commit is contained in:
Martin v. Löwis 1999-03-24 03:01:03 +00:00 committed by Martin v. Löwis
parent 9747e84add
commit 5c6e1aa14a
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
1999-03-24 Martin von Löwis <loewis@informatik.hu-berlin.de>
* class.c (finish_struct_1): Always reset TYPE_FIELDS for empty
classes.
1999-03-24 Jason Merrill <jason@yorick.cygnus.com>
* decl.c (lookup_name_real): Do nested field lookup regardless of

View File

@ -3985,7 +3985,7 @@ finish_struct_1 (t, warn_anon)
if (n_baseclasses)
/* layout_basetypes will remove the base subobject fields. */
max_has_virtual = layout_basetypes (t, max_has_virtual);
else if (empty)
if (empty)
TYPE_FIELDS (t) = fields;
my_friendly_assert (TYPE_FIELDS (t) == fields, 981117);