+2009-12-04 Jason Merrill <jason@redhat.com>
+
+ PR c++/42277
+ * semantics.c (finish_decltype_type): Defer handling of decltype
+ of a non-dependent COMPONENT_REF in a template.
+
2009-12-04 Dodji Seketeli <dodji@redhat.com>
PR c++/42218
return error_mark_node;
}
- if (type_dependent_expression_p (expr))
+ if (type_dependent_expression_p (expr)
+ /* In a template, a COMPONENT_REF has an IDENTIFIER_NODE for op1 even
+ if it isn't dependent, so that we can check access control at
+ instantiation time, so defer the decltype as well (PR 42277). */
+ || (id_expression_or_member_access_p
+ && processing_template_decl
+ && TREE_CODE (expr) == COMPONENT_REF))
{
if (id_expression_or_member_access_p)
{
+2009-12-04 Jason Merrill <jason@redhat.com>
+
+ PR c++/42277
+ * g++.dg/cpp0x/decltype20.C: New.
+
2009-12-04 David Daney <ddaney@caviumnetworks.com>
PR rtl-optimization/42164