Bug 1091900 - Remove iteratorObject hook. r=jorendorff

* * *
Bug 1091900 - Fix build on CLOSED TREE
This commit is contained in:
Tom Schuster
2014-11-05 20:36:49 +01:00
parent b40f803725
commit 19ecd5993a
15 changed files with 6 additions and 139 deletions

View File

@@ -666,11 +666,8 @@ js::GetIterator(JSContext *cx, HandleObject obj, unsigned flags, MutableHandleVa
bool keysOnly = (flags == JSITER_ENUMERATE);
if (obj) {
if (JSIteratorOp op = obj->getClass()->ext.iteratorObject) {
JSObject *iterobj = op(cx, obj, !(flags & JSITER_FOREACH));
if (!iterobj)
return false;
vp.setObject(*iterobj);
if (obj->is<PropertyIteratorObject>() || obj->is<LegacyGeneratorObject>()) {
vp.setObject(*obj);
return true;
}
@@ -891,12 +888,6 @@ static const JSFunctionSpec iterator_methods[] = {
JS_FS_END
};
static JSObject *
iterator_iteratorObject(JSContext *cx, HandleObject obj, bool keysonly)
{
return obj;
}
size_t
PropertyIteratorObject::sizeOfMisc(mozilla::MallocSizeOf mallocSizeOf) const
{
@@ -935,12 +926,6 @@ const Class PropertyIteratorObject::class_ = {
nullptr, /* hasInstance */
nullptr, /* construct */
trace,
JS_NULL_CLASS_SPEC,
{
nullptr, /* outerObject */
nullptr, /* innerObject */
iterator_iteratorObject,
}
};
enum {