Why generic lambdas are allowed while nested structs with templated methods aren’t?
This is core issue 728, which was filed before generic lambdas were a thing. You mentioned generic lambdas and that they were identical to local classes with corresponding member template operator(). However, they actually aren’t, and the differences are related to implementation characteristics. Consider template <typename T> class X { template <typename> void foo() { … Read more