Community
Participate
Working Groups
Steps to reproduce: 1. Start with the following code: template <typename F> void foo(F); int main() { foo([](int x){ return x + 1; }); } 2. Select the lambda expression and perform the 'extract local variable' refactoring. The result is: template <typename F> void foo(F); int main() { f = [](int x) { return x + 1; }; foo (f); } which does not compile. The type of the lambda should be 'auto' instead.
Created attachment 226586 [details] Minimal project to verify the problem I've now verified (a slight modification of) this using eclipse-SDK-N20130203-2000-win32 with org.eclipse.cdt_8.2.0.201212170456 . Here's the project, to make it easier for other people to verify it.
Sorry, it didn't actually require any modifications. Copy-paste error.