Bug 888463 - Remove code to skip shrinkSlots for call objects. r=jandem

This commit is contained in:
Terrence Cole 2013-07-02 11:24:47 -07:00
parent 4935019126
commit 2d3a62044f

View File

@ -2611,15 +2611,6 @@ JSObject::shrinkSlots(JSContext *cx, HandleObject obj, uint32_t oldCount, uint32
{
JS_ASSERT(newCount < oldCount);
/*
* Refuse to shrink slots for call objects. This only happens in a very
* obscure situation (deleting names introduced by a direct 'eval') and
* allowing the slots pointer to change may require updating pointers in
* the function's active args/vars information.
*/
if (obj->is<CallObject>())
return;
if (newCount == 0) {
FreeSlots(cx, obj->slots);
obj->slots = NULL;