Strangely PHP has an answer for this. It requires you to name each local variable that your lambda will access. E.g.: $a = 1; $b = 2; $fn = function() use($a ...
In reply to: The new and the not new in Java 8 by xav ...
Some results have been hidden because they may be inaccessible to you
Show inaccessible results