News for hackers. Stuff that matters.
Re:Go: Redefining For Loop Variable Semantics by int_19h on Tuesday October 11, 2022 @05:17PM (#33169362)
C# made the same decision because it did not have closures initially, and so there was no practical way to observe the difference.

But Go did have closures initially, and worse yet, they already had C# as an example of how closures and loops interact. So they definitely had the opportunity to learn from that mistake, and I don't think it's unreasonable to ask why they did not.

There are no comments on this comment yet.