re PR c++/43831 ([C++0x] gcc-4.5.0 does not fail invalid lambda captures (against...
authorJason Merrill <jason@redhat.com>
Mon, 20 Jun 2011 14:39:44 +0000 (10:39 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Mon, 20 Jun 2011 14:39:44 +0000 (10:39 -0400)
commit4b7d9ed4a8e049e777252718c4cddb85fece7cde
treecde6f088985ae859fdb6f847866868f41f9a337e
parentc2954af9266e69bc422c3ca6c77fdecd92199070
re PR c++/43831 ([C++0x] gcc-4.5.0 does not fail invalid lambda captures (against n3092 5.1.2/8))

PR c++/43831
* parser.c (cp_parser_lambda_introducer): Complain about redundant
captures.
* semantics.c (add_capture): Likewise.
(register_capture_members): Clear IDENTIFIER_MARKED.

From-SVN: r175211
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/cp/semantics.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/cpp0x/lambda/lambda-capture-redundancy.C [new file with mode: 0644]