In Kotlin, anonymous functions can access all variables in the scope they're defined in. Is there any interest in there being "pure" anonymous functions (ie, ones that cannot do this)? And I suppose, is it even a feasible thing to try to implement?
I think it would be nice if we could guarantee that certain lambdas will have no side-effects. It might make code with lots of lambdas easier to follow.