This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/54891] [C++11] lambda-expression and explicit type conversion (cast notation)
- From: "paolo at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 30 Jun 2014 18:31:23 +0000
- Subject: [Bug c++/54891] [C++11] lambda-expression and explicit type conversion (cast notation)
- Auto-submitted: auto-generated
- References: <bug-54891-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54891
--- Comment #2 from paolo at gcc dot gnu.org <paolo at gcc dot gnu.org> ---
Author: paolo
Date: Mon Jun 30 18:30:50 2014
New Revision: 212162
URL: https://gcc.gnu.org/viewcvs?rev=212162&root=gcc&view=rev
Log:
/cp
2014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54891
* parser.c (cp_parser_tokens_start_cast_expression): In C++11
a '[' can also start a primary-expression.
(cp_parser_cast_expression): Parse a cast-expression only tentatively
when cp_parser_tokens_start_cast_expression returns -1.
/testsuite
2014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54891
* g++.dg/cpp0x/lambda/lambda-cast1.C: New.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-cast1.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/parser.c
trunk/gcc/testsuite/ChangeLog