News for hackers. Stuff that matters.
Re:Signs your code sucks by eru on Friday October 23, 2009 @10:10PM (#900016)
Yes, nested functions are probably good for this. (I was about to suggest use of the reader monad in the original comment, but then left out this suggestion for being to arcane (and did not include the nested function suggestion either).)

Nested functions are good for this kind of code, even when they are only used once and do not abstract --- because you have less variables in the innermost scope. (And when you are going to mutate variables at all, then strongly prefer to do it to variables in the innermost scope.)

There are no comments on this comment yet.