/cp
2014-09-22 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/62219
* pt.c (check_default_tmpl_args): Check LAMBDA_FUNCTION_P.
/testsuite
2014-09-22 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/62219
* g++.dg/cpp0x/lambda/lambda-template14.C: New.
From-SVN: r215477
+2014-09-22 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/62219
+ * pt.c (check_default_tmpl_args): Check LAMBDA_FUNCTION_P.
+
2014-09-22 Jason Merrill <jason@redhat.com>
* decl.c (poplevel): Don't warn about unused vars in template scope.
local scope. */
return true;
- if (TREE_CODE (decl) == TYPE_DECL
- && TREE_TYPE (decl)
- && LAMBDA_TYPE_P (TREE_TYPE (decl)))
+ if ((TREE_CODE (decl) == TYPE_DECL
+ && TREE_TYPE (decl)
+ && LAMBDA_TYPE_P (TREE_TYPE (decl)))
+ || (TREE_CODE (decl) == FUNCTION_DECL
+ && LAMBDA_FUNCTION_P (decl)))
/* A lambda doesn't have an explicit declaration; don't complain
about the parms of the enclosing class. */
return true;
+2014-09-22 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/62219
+ * g++.dg/cpp0x/lambda/lambda-template14.C: New.
+
2014-09-22 Alan Lawrence <alan.lawrence@arm.com>
* gcc.dg/vect/vect-reduc-or_1.c: New test.
--- /dev/null
+// PR c++/62219
+// { dg-do compile { target c++11 } }
+
+template< class = void >
+struct S
+{
+ friend void foo( S )
+ {
+ [](){};
+ }
+};