aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp')
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/tree.c4
2 files changed, 8 insertions, 1 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index c81a1e6..1a9ca4f 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+2009-01-12 Jason Merrill <jason@redhat.com>
+
+ PR c++/31488
+ * tree.c (pod_type_p): Return 1 for structs created by the back end.
+
2009-01-12 Jakub Jelinek <jakub@redhat.com>
PR c/32041
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index 1f2c631..ad84cc8 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -2127,8 +2127,10 @@ pod_type_p (const_tree t)
if (TREE_CODE (t) == VECTOR_TYPE)
return 1; /* vectors are (small) arrays of scalars */
- if (! CLASS_TYPE_P (t))
+ if (! RECORD_OR_UNION_CODE_P (TREE_CODE (t)))
return 0; /* other non-class type (reference or function) */
+ if (! CLASS_TYPE_P (t))
+ return 1; /* struct created by the back end */
if (CLASSTYPE_NON_POD_P (t))
return 0;
return 1;