|
|
|
|
|
by crazygringo
4737 days ago
|
|
I don't see how that's refuting my point -- of course they don't share "y" because they're two completely different y's in two completely different local scopes. I had understood your comment to mean that closures don't share variables, and I was just explaining that they certainly can. Maybe I'd misinterpreted what you were trying to say... |
|
I was saying that two functions side by side have distinct closures, no matter how many variables they share.
The reason I said that was to point out that variables closed over by one function shouldn't affect which variables are closed over by nearby functions.
Actually I think I see how to make the wording clearer in the original. Brb.