Y
Hacker News
new
|
ask
|
show
|
jobs
by
mishafb
1698 days ago
The lambdas aren't actually lambdas, they are anonymous classes with a single metthod according to the type-inferred interface, and they can't use variables that aren't effectively final.
1 comments
gpderetta
1698 days ago
That's just a way to make them work in the existing ecosystem (in C++ lambdas for example are just function objects with overloaded operator()).
The final is to avoid some mistakes, but they are still effectively closures.
link
The final is to avoid some mistakes, but they are still effectively closures.