Can the compiler implicitly copy i, basically convert it to:
for i := 0; i < n; i++ {
i := i
doAThing(i)
} for i := 0; i < n; i++ {
i := i
doAThing(i)
}I basically just wanted to point out that the problem isn't so much an implementation question (or about performance). But that no one thought of it and it's now mainly a question of how to best phrase the spec for this :)