summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/bug642772-1.js
blob: b7dc483fcc5e3ff143f6aac450af8e1b4c21d349 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
var n1 = Number.prototype.toFixed;
var s1 = String.prototype.split;
delete Number;
delete String;

var n2 = (5).toFixed;
var s2 = ("foo").split;

// Check enumeration doesn't resurrect deleted standard classes
for (x in this) {}

// Ensure the prototypes are shared.
var n3 = (5).toFixed;
var s3 = ("foo").split;

assertEq(s1, s2);
assertEq(s1, s3);
assertEq(n1, n2);
assertEq(n1, n3);