cp-lang.c (ok_to_generate_alias_set_for_type): Backend-created structs are safe.

* cp-lang.c (ok_to_generate_alias_set_for_type): Backend-created
        structs are safe.

From-SVN: r53402
This commit is contained in:
Jason Merrill 2002-05-12 13:29:05 -04:00 committed by Jason Merrill
parent 51286de650
commit 0d08ea488f
2 changed files with 8 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2002-05-12 Jason Merrill <jason@redhat.com>
* cp-lang.c (ok_to_generate_alias_set_for_type): Backend-created
structs are safe.
2002-05-09 Neil Booth <neil@daikokuya.demon.co.uk>
* cp-tree.h (flag_ansi): Remove.

View File

@ -210,6 +210,9 @@ ok_to_generate_alias_set_for_type (t)
if ((TREE_CODE (t) == RECORD_TYPE) || (TREE_CODE (t) == UNION_TYPE))
{
tree fields;
/* Backend-created structs are safe. */
if (! CLASS_TYPE_P (t))
return true;
/* PODs are safe. */
if (! CLASSTYPE_NON_POD_P(t))
return true;