Bug 1032956 - Self-hosted functions in {Object,Function}.{,prototype.}* are broken and fail on an assert. r=jwalden

This commit is contained in:
Nathan Braswell
2014-07-07 11:48:48 -07:00
parent eb039c30e3
commit e6a90e0d06
3 changed files with 19 additions and 1 deletions

View File

@@ -168,6 +168,13 @@ FinishObjectClassInit(JSContext *cx, JS::HandleObject ctor, JS::HandleObject pro
return false;
}
/*
* Define self-hosted functions after setting the intrinsics holder
* (which is needed to define self-hosted functions)
*/
if (!JS_DefineFunctions(cx, ctor, object_static_selfhosted_methods))
return false;
/*
* The global object should have |Object.prototype| as its [[Prototype]].
* Eventually we'd like to have standard classes be there from the start,