Remove the hardcoded prototype count.

This commit is contained in:
Josh Matthews 2013-08-22 16:19:10 -04:00
parent 0c50d4374f
commit 1c087ab507

View file

@ -624,8 +624,7 @@ pub extern fn ThrowingConstructor(_cx: *JSContext, _argc: uint, _vp: *JSVal) ->
}
pub fn initialize_global(global: *JSObject) {
let protoArray = @mut ([0 as *JSObject, ..53]);
assert!(protoArray.len() == PrototypeList::id::_ID_Count as uint);
let protoArray = @mut ([0 as *JSObject, ..PrototypeList::id::_ID_Count as uint]);
unsafe {
//XXXjdm we should be storing the box pointer instead of the inner
let box = squirrel_away(protoArray);