From a5283f322810189a156a0fb080bf6d65e6f7970e Mon Sep 17 00:00:00 2001 From: jason Date: Tue, 13 Feb 2018 14:22:07 +0000 Subject: Fix more variadic capture issues. * pt.c (find_parameter_packs_r): Also look at explicit captures. (check_for_bare_parameter_packs): Check current_class_type for lambda context. (extract_locals_r): Handle seeing a full instantiation of a pack. (tsubst_pack_expansion): Likewise. Force lambda capture. * parser.c (cp_parser_lambda_introducer): Don't check_for_bare_parameter_packs. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@257627 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/cp/parser.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'gcc/cp/parser.c') diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c index 9a05e4fc812..81c6f0128e6 100644 --- a/gcc/cp/parser.c +++ b/gcc/cp/parser.c @@ -10412,8 +10412,6 @@ cp_parser_lambda_introducer (cp_parser* parser, tree lambda_expr) cp_lexer_consume_token (parser->lexer); capture_init_expr = make_pack_expansion (capture_init_expr); } - else - check_for_bare_parameter_packs (capture_init_expr); } if (LAMBDA_EXPR_DEFAULT_CAPTURE_MODE (lambda_expr) != CPLD_NONE -- cgit v1.2.1