This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/72775] [6/7 Regression] internal compiler error: in finish_expr_stmt, at cp/semantics.c:677
- From: "mpolacek 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 Dec 2016 14:11:30 +0000
- Subject: [Bug c++/72775] [6/7 Regression] internal compiler error: in finish_expr_stmt, at cp/semantics.c:677
- Auto-submitted: auto-generated
- References: <bug-72775-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=72775
--- Comment #12 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
(In reply to Matteo Bertello from comment #10)
> Just had the same internal compiler error on a different piece of code,
> using GCC 6.1.1 on Fedora 24.
> Might be useful to investigate the cause.
This code doesn't compile for me at all:
r3.cc: In function ‘int main(int, char**)’:
r3.cc:8:27: error: expected primary-expression before ‘(’ token
auto thread = std::thread([&, =val]() { func(val); });
^
r3.cc:8:32: error: expected identifier before ‘=’ token
auto thread = std::thread([&, =val]() { func(val); });
^
clang++ rejects it, too.