[Bug c++/62272] Gimplify throws error on method call from inside nested lambdas
guille at cal dot berkeley.edu
gcc-bugzilla@gcc.gnu.org
Sat Feb 21 20:48:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62272
Guille <guille at cal dot berkeley.edu> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |guille at cal dot berkeley.edu
--- Comment #3 from Guille <guille at cal dot berkeley.edu> ---
For what it's worth, it compiles with the following modification [adding
"this->" to the Foo call]:
template<typename T> class B
{
public:
void Foo() {}
void Bar()
{
[&]()
{
[&]() { this->Foo(); }();
}();
}
};
int main( int argc, char** argv )
{
B<int> b;
b.Bar();
return 0;
}
Without the "this->", it compiles in neither 4.9.2, nor 5.0.0.
More information about the Gcc-bugs
mailing list