Thu, 22 Jan 2015 13:21:57 +0100
Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6
michael@0 | 1 | function f(v, value) |
michael@0 | 2 | { |
michael@0 | 3 | var b = v == undefined; |
michael@0 | 4 | assertEq(b, value, |
michael@0 | 5 | "failed: " + v + " " + value); |
michael@0 | 6 | } |
michael@0 | 7 | |
michael@0 | 8 | f({}, false); |
michael@0 | 9 | f({}, false); |
michael@0 | 10 | f(null, true); |
michael@0 | 11 | f(null, true); |
michael@0 | 12 | f(undefined, true); |
michael@0 | 13 | f(undefined, true); |
michael@0 | 14 | f(objectEmulatingUndefined(), true); |
michael@0 | 15 | f(objectEmulatingUndefined(), true); |
michael@0 | 16 | f(Object.prototype, false); |
michael@0 | 17 | f(Object.prototype, false); |
michael@0 | 18 | |
michael@0 | 19 | function g(v, value) |
michael@0 | 20 | { |
michael@0 | 21 | var b = v == undefined; |
michael@0 | 22 | assertEq(b, value, |
michael@0 | 23 | "failed: " + v + " " + value); |
michael@0 | 24 | } |
michael@0 | 25 | |
michael@0 | 26 | g({}, false); |
michael@0 | 27 | g({}, false); |
michael@0 | 28 | |
michael@0 | 29 | function h(v, value) |
michael@0 | 30 | { |
michael@0 | 31 | var b = v == undefined; |
michael@0 | 32 | assertEq(b, value, |
michael@0 | 33 | "failed: " + v + " " + value); |
michael@0 | 34 | } |
michael@0 | 35 | |
michael@0 | 36 | h(objectEmulatingUndefined(), true); |
michael@0 | 37 | h(objectEmulatingUndefined(), true); |