News for hackers. Stuff that matters.
Re:Golang landmines by dilap on Saturday September 17, 2016 @10:57PM (#12523721)
i was surprised by it. objc gives you a new variable each time through the loop.

it's basically never what you want; if it were changed and you did sometimes want it, it would be easy to get

    var i int
    for blah blah blah...
oh well, the cure isn't bad:

    i := i
Re:Golang landmines by zalmoxes on Saturday September 17, 2016 @11:08PM (#12523752)
This is mentioned in the Effective Go document.