&gt; optimization decisions that the V8 team have made<p>Optimization decisions that V8 team have made are much more universal than it might seem.<p>It is true there are sometimes strange artificial corner cases - but those are often either bugs or temporary solutions that are going to be replaced with something more generic as soon as they start to hurt too much code.<p>&gt; which ends up with having to jump through some hoops in a for-in loop<p>Could you clarify which hoops precisely do you need to jump through?<p>I am not sure I can imagine a reasonable chunk of code that strives to be both fast, well written and wants to use a context captured or global for-in variable.<p><pre><code>    for (IWantThisVariableToEndUpOnGlobalObject in obj) { }
</code></pre>
How often do you write code like this?