Move fixed slot count from JSObject to Shape, bug 594561.

This commit is contained in:
Brian Hackett
2011-10-14 11:06:15 -07:00
parent 739b3fc2c3
commit 82400c0d5c
23 changed files with 394 additions and 247 deletions

View File

@@ -413,11 +413,12 @@ NewIteratorObject(JSContext *cx, uintN flags)
if (!type)
return NULL;
Shape *emptyEnumeratorShape = BaseShape::lookupInitialShape(cx, &IteratorClass, NULL);
Shape *emptyEnumeratorShape = BaseShape::lookupInitialShape(cx, &IteratorClass, NULL,
FINALIZE_OBJECT2);
if (!emptyEnumeratorShape)
return NULL;
obj->init(cx, type, false);
obj->init(cx, type);
obj->setInitialPropertyInfallible(emptyEnumeratorShape);
JS_ASSERT(obj->numFixedSlots() == JSObject::ITER_CLASS_NFIXED_SLOTS);