https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82643
Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2018-07-06 Ever confirmed|0 |1 --- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> --- GCC 6 rejected that code with a more sensible diagnostic: c.cc:14:30: error: the value of 'f' is not usable in a constant expression GCC 7 regressed to saying: c.cc:14:30: error: '__closure' is not a constant expression Clang and EDG both reject the code, but diagnosing different lines.