* decl.c (reshape_init_class): Handle repeated reshaping.
* search.c (lookup_field_1): Add sanity check.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185587
138bc75d-0d04-0410-961f-
82ee72b054a4
+2012-03-20 Jason Merrill <jason@redhat.com>
+
+ PR c++/52510
+ * decl.c (reshape_init_class): Handle repeated reshaping.
+ * search.c (lookup_field_1): Add sanity check.
+
2012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/14710
return error_mark_node;
}
- field = lookup_field_1 (type, d->cur->index, /*want_type=*/false);
+ if (TREE_CODE (d->cur->index) == FIELD_DECL)
+ /* We already reshaped this. */
+ gcc_assert (d->cur->index == field);
+ else
+ field = lookup_field_1 (type, d->cur->index, /*want_type=*/false);
if (!field || TREE_CODE (field) != FIELD_DECL)
{
{
tree field;
+ gcc_assert (TREE_CODE (name) == IDENTIFIER_NODE);
+
if (TREE_CODE (type) == TEMPLATE_TYPE_PARM
|| TREE_CODE (type) == BOUND_TEMPLATE_TEMPLATE_PARM
|| TREE_CODE (type) == TYPENAME_TYPE)
+2012-03-20 Jason Merrill <jason@redhat.com>
+
+ PR c++/52510
+ * g++.dg/cpp0x/initlist66.C: New.
+
2012-03-20 Georg-Johann Lay <avr@gjlay.de>
* gcc.target/avr/progmem.h (pgm_read_char): Define depending on
--- /dev/null
+// PR c++/52510
+// { dg-do compile { target c++11 } }
+
+typedef unsigned char uint8_t;
+typedef unsigned short uint16_t;
+typedef unsigned int uint32_t;
+typedef unsigned long long uint64_t;
+typedef uint64_t upad64_t;
+
+typedef struct _pthread_cond {
+ struct {
+ uint8_t __pthread_cond_flag[4];
+ uint16_t __pthread_cond_type;
+ uint16_t __pthread_cond_magic;
+ } __pthread_cond_flags;
+ upad64_t __pthread_cond_data;
+} pthread_cond_t;
+
+class gtm_rwlock
+{
+ pthread_cond_t c_readers;
+ public:
+ gtm_rwlock();
+};
+
+gtm_rwlock::gtm_rwlock()
+ : c_readers ({{{0, 0, 0, 0}, 0, 0x4356}, 0})
+{ }
+