/cp
2011-07-25 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/49838
* parser.c (cp_parser_perform_range_for_lookup): Early return if
error_operand_p (range).
/testsuite
2011-07-25 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/49838
* g++.dg/cpp0x/range-for19.C: New.
From-SVN: r176754
+2011-07-25 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/49838
+ * parser.c (cp_parser_perform_range_for_lookup): Early return if
+ error_operand_p (range).
+
2011-07-23 Jason Merrill <jason@redhat.com>
PR c++/49823
static tree
cp_parser_perform_range_for_lookup (tree range, tree *begin, tree *end)
{
+ if (error_operand_p (range))
+ return error_mark_node;
+
if (!COMPLETE_TYPE_P (complete_type (TREE_TYPE (range))))
{
error ("range-based %<for%> expression of type %qT "
+2011-07-25 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/49838
+ * g++.dg/cpp0x/range-for19.C: New.
+
2011-07-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
PR testsuite/49753
--- /dev/null
+// PR c++/49838
+
+// { dg-do compile }
+// { dg-options "-std=c++0x" }
+
+int main()
+{
+ auto a; // { dg-error "no initializer" }
+ for(auto i: a) // { dg-error "deduce" }
+ ;
+}