mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-28 20:55:39 +00:00
Bug 963641 - Tests for __proto__ in object literals with jsreflect and asm.js module export objects. r=jorendorff
--HG-- extra : rebase_source : cc570fcbc018618079843df2d07f87bbf30f18a7
This commit is contained in:
parent
357d670c46
commit
7636ef8c84
@ -75,6 +75,7 @@ assertEq(exp.f(), 3);
|
||||
assertEq(Object.keys(exp).join(), 'f');
|
||||
|
||||
assertAsmTypeFail(USE_ASM + "function f() { return 3 } return {1:f}");
|
||||
assertAsmTypeFail(USE_ASM + "function f() { return 3 } return {__proto__:f}");
|
||||
assertAsmTypeFail(USE_ASM + "function f() { return 3 } return {get x() {} }");
|
||||
|
||||
var exp = asmLink(asmCompile(USE_ASM + 'function internal() { return ((g()|0)+2)|0 } function f() { return 1 } function g() { return 2 } function h() { return internal()|0 } return {f:f,g1:g,h1:h}'));
|
||||
|
@ -0,0 +1,11 @@
|
||||
// |reftest| skip-if(!xulRuntime.shell)
|
||||
// bug 963641
|
||||
|
||||
Reflect.parse("({ __proto__: null });");
|
||||
|
||||
if (typeof reportCompare === "function")
|
||||
reportCompare(true, true);
|
||||
|
||||
|
||||
|
||||
print("Tests complete");
|
Loading…
Reference in New Issue
Block a user