/cp
2014-06-27 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/61614
* semantics.c (finish_compound_literal): Revert r204228.
/testsuite
2014-06-27 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/61614
* g++.dg/ext/complit14.C: New.
From-SVN: r212073
2014-06-27 Paolo Carlini <paolo.carlini@oracle.com>
+ PR c++/61614
+ * semantics.c (finish_compound_literal): Revert r204228.
+
+2014-06-27 Paolo Carlini <paolo.carlini@oracle.com>
+
* parser.c (cp_parser_compound_literal_p): New.
(cp_parser_postfix_expression, cp_parser_sizeof_operand): Use it.
if ((!at_function_scope_p () || CP_TYPE_CONST_P (type))
&& TREE_CODE (type) == ARRAY_TYPE
&& !TYPE_HAS_NONTRIVIAL_DESTRUCTOR (type)
- && !cp_unevaluated_operand
&& initializer_constant_valid_p (compound_literal, type))
{
tree decl = create_temporary_var (type);
+2014-06-27 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/61614
+ * g++.dg/ext/complit14.C: New.
+
2014-06-27 Martin Jambor <mjambor@suse.cz>
PR ipa/61160
--- /dev/null
+// PR c++/61614
+// { dg-options "" }
+
+int Fn (...);
+
+void
+Test ()
+{
+ int j = Fn ((const int[]) { 0 }); // OK
+ unsigned long sz = sizeof Fn ((const int[]) { 0 }); // Error
+}