[Bug c++/51422] New: [c++0x] ICE with invalid lambda expression
reichelt at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Dec 5 07:56:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51422
Bug #: 51422
Summary: [c++0x] ICE with invalid lambda expression
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: reichelt@gcc.gnu.org
The following invalid code snippet triggers an ICE on trunk:
===================================
template<typename> struct A {};
void foo()
{
[i] { A<decltype(i)>(); };
[i] { A<decltype(i)>(); };
}
===================================
bug.cc: In function 'void foo()':
bug.cc:5:4: error: 'i' was not declared in this scope
bug.cc: In lambda function:
bug.cc:5:22: error: template argument 1 is invalid
bug.cc: In lambda function:
bug.cc:6:20: internal compiler error: in is_normal_capture_proxy, at
cp/semantics.c:8797
Please submit a full bug report, [etc.]
More information about the Gcc-bugs
mailing list