Source code
Revision control
Copy as Markdown
Other Tools
/*
* Any copyright is dedicated to the Public Domain.
*/
var a = [];
// Test up to 200 to cover tunables such as js::PropertyTree::MAX_HEIGHT.
for (var i = 0; i < 200; i++) {
a.push("b" + i);
assertThrowsInstanceOfWithMessage(
() => eval("(function ([" + a.join("],[") + "],a,a){})"),
SyntaxError,
'duplicate argument names not allowed in this context');
}
reportCompare(0, 0, "ok");