for(var i in list) {
(function(element) {
someAsyncCallThatNeedsTheRightIndexedElement(element);
})(list[i]);
}
I've seen people grumble that this is "too clever"I've been known to snap back "Bootcamps don't have a monopoly on what technical solutions are valid"
Pointers are probably too clever for most people.
Admittedly, goto is too clever for me. :(