This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/54947] [4.7/4.8 Regression] [C++11] lambda cannot capture-by-copy inside braced-init-list
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 07 Nov 2012 12:15:04 +0000
- Subject: [Bug c++/54947] [4.7/4.8 Regression] [C++11] lambda cannot capture-by-copy inside braced-init-list
- Auto-submitted: auto-generated
- References: <bug-54947-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54947
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-11-07 12:15:04 UTC ---
(In reply to comment #1)
> Guess perhaps the designated array initializers need to be parsed tentatively
> for C++11, and if they aren't valid, we'd retry as lambdas.
Shouldn't we try as lambdas, and if not valid retry as non-standard designated
initializers? If it's ambiguous we should assume it's a standard C+ not the
extension.