[Bug c++/58062] [C++11] bogus __func__ lookup in lambda body

2016-04-04 Thread msebor at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58062

Martin Sebor  changed:

   What|Removed |Added

   Keywords|wrong-code  |
 Status|UNCONFIRMED |RESOLVED
 CC||msebor at gcc dot gnu.org
 Resolution|--- |INVALID

--- Comment #3 from Martin Sebor  ---
C++ was clarified via core issue #1172
(www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#1772) to define the
__func__ identifier "at the beginning of the compound-statement of the
lambda-expression" rendering this bug report no longer valid (at least not in
C++ 14).  I don't think it's worth implementing something different for C++ 11
so I'm closing this report as invalid.  (I note that this is also consistent
with what Clang does.)

[Bug c++/58062] [C++11] bogus __func__ lookup in lambda body

2013-08-03 Thread daniel.kruegler at googlemail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58062

Daniel Krügler  changed:

   What|Removed |Added

 CC||daniel.kruegler@googlemail.
   ||com

--- Comment #2 from Daniel Krügler  ---
The fact that MSVC is giving the "expected error" is a bit misleading. It
rejects it, because it still is not conforming and is not aware of __func__ in
any context. But I agree that correct MSVC behaviour can be deduced when
__FUNCTION__ is used instead.

While I agree that gcc is not conforming I would like to add that many existing
compilers do not and to my knowledge there is an core language issue planned in
regard to exactly this problem, so I recommend to defer working on that.

[Bug c++/58062] [C++11] bogus __func__ lookup in lambda body

2013-08-02 Thread hstong at ca dot ibm.com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58062

--- Comment #1 from Hubert Tong  ---
Compiler invocation was:
g++ -std='c++11' main.cpp -Wall -Wextra -pedantic -c