OK for trunk and 4.9; I'd hold off on 4.8 unless someone asks for it there.
Jason
Hi,
On 09/19/2014 07:32 PM, Jason Merrill wrote:
On 09/19/2014 11:40 AM, Paolo Carlini wrote:
if (TREE_CODE (CP_DECL_CONTEXT (decl)) == FUNCTION_DECL
- || (TREE_CODE (decl) == FUNCTION_DECL && DECL_LOCAL_FUNCTION_P
(decl)))
+ || (TREE_CODE (decl) == FUNCTION_DECL
+ && (DECL_
On 09/19/2014 11:40 AM, Paolo Carlini wrote:
if (TREE_CODE (CP_DECL_CONTEXT (decl)) == FUNCTION_DECL
- || (TREE_CODE (decl) == FUNCTION_DECL && DECL_LOCAL_FUNCTION_P (decl)))
+ || (TREE_CODE (decl) == FUNCTION_DECL
+ && (DECL_LOCAL_FUNCTION_P (decl) || LAMBDA_FUNCTION_P (decl
Hi,
I had a quick look at this issue and it immediately reminded me
c++/60605, which Jason fixed by handling local functions at the
beginning of check_default_tmpl_args. In the present case of:
template< class = void >
struct S
{
friend void foo( S )
{
[](){};
}
};
it occurs to me