Yeah, thanks for the explanation. The key is "all closures reference the same scalar". Somehow I assumed that the closure would use the current value of the scalar (in a new slot). Thanks also to LanX and Hippo for their (similar) explanations!
In reply to Re^2: Closures and scope of lexicals
by haj
in thread Closures and scope of lexicals
by haj
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |