News for hackers. Stuff that matters.
Re:Code Review Best Practices by enqk on Sunday May 10, 2015 @09:48AM (#9519896)
This depends on the language capabilities. In the C/Lisp/ML families of languages at least you can create isolated scopes. It's unfortunately not true of Javascript (and Ruby?).
Re:Code Review Best Practices by jbbarth on Sunday May 10, 2015 @01:50PM (#9520685)
In Ruby some people achieve this by wrapping actions in their own class, which does the trick if the classes are kept independent from each other (no shared state, except global vars, which nobody uses in the ruby world).
Re:Code Review Best Practices by enqk on Sunday May 10, 2015 @03:07PM (#9520962)
I should have been clearer. I meant isolated scope within a function.