Bug 779841 - Escape inline cache if invalidated by the lookup. r=dvander

This commit is contained in:
Nicolas B. Pierron 2012-08-07 18:31:11 -07:00
parent 3ffd33a2cb
commit d611f5686d
2 changed files with 11 additions and 0 deletions

View File

@ -329,6 +329,10 @@ js::ion::GetPropertyCache(JSContext *cx, size_t cacheIndex, HandleObject obj, Mu
topScript->invalidatedIdempotentCache = true;
// Do not re-invalidate if the lookup already caused invalidation.
if (!topScript->hasIonScript())
return true;
return Invalidate(cx, topScript);
}

View File

@ -0,0 +1,7 @@
// |jit-test| error: TypeError
function outer2() {
"use strict";
new (function () {}).arguments
}
outer2();