diff options
author | Jason Merrill <jason@redhat.com> | 2010-02-10 21:12:53 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2010-02-10 21:12:53 -0500 |
commit | 19030d779a0d27dbdf3f774a15137cec8f4a1550 (patch) | |
tree | c026a8558e03de540d0342d079d43fa8908967e5 /gcc/cp/cp-tree.h | |
parent | 94d7ad5fa7705d68d6c05207a871397d9ec2a6ee (diff) | |
download | gcc-19030d779a0d27dbdf3f774a15137cec8f4a1550.zip gcc-19030d779a0d27dbdf3f774a15137cec8f4a1550.tar.gz gcc-19030d779a0d27dbdf3f774a15137cec8f4a1550.tar.bz2 |
re PR c++/41896 ([c++0x] Segfault because of a nested lambda function)
PR c++/41896
* semantics.c (outer_lambda_capture_p): Revert.
(add_capture): Only finish_member_declaration if
we're in the lambda class.
(register_capture_members): New.
* cp-tree.h: Declare it.
* parser.c (cp_parser_lambda_expression): Call it.
From-SVN: r156678
Diffstat (limited to 'gcc/cp/cp-tree.h')
-rw-r--r-- | gcc/cp/cp-tree.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h index 27c820b..f32c6e8 100644 --- a/gcc/cp/cp-tree.h +++ b/gcc/cp/cp-tree.h @@ -5193,6 +5193,7 @@ extern tree lambda_function (tree); extern void apply_lambda_return_type (tree, tree); extern tree add_capture (tree, tree, tree, bool, bool); extern tree add_default_capture (tree, tree, tree); +extern void register_capture_members (tree); extern tree lambda_expr_this_capture (tree); extern void maybe_add_lambda_conv_op (tree); |