Index: test/mjsunit/strict-mode-eval.js |
diff --git a/test/mjsunit/strict-mode-eval.js b/test/mjsunit/strict-mode-eval.js |
index 391daaa37c6fdb996faa8878492c2eea4ed2abc3..e0722552cecdbe07fb59d5edd0911e136af3f168 100644 |
--- a/test/mjsunit/strict-mode-eval.js |
+++ b/test/mjsunit/strict-mode-eval.js |
@@ -31,6 +31,7 @@ var code1 = "function f(eval) {}"; |
var code2 = "function f(a, a) {}"; |
var code3 = "var x = '\\020;'"; |
var code4 = "function arguments() {}"; |
+var code5 = "(() => { function a({ eval = false } = {}) {} })()"; |
adamk
2016/07/28 18:33:44
Is the outer arrow function an important part of t
|
// Verify the code compiles just fine in non-strict mode |
// (using aliased eval to force non-strict mode) |
@@ -80,6 +81,18 @@ function strict1() { |
assertInstanceof(e, SyntaxError); |
} |
assertTrue(exception); |
+ |
+ function strict5() { |
+ var exception = false; |
+ try { |
+ eval(code5); |
+ } catch (e) { |
+ exception = true; |
+ assertInstanceof(e, SyntaxError); |
+ } |
+ assertTrue(exception); |
+ } |
+ strict5(); |
} |
strict4(); |
} |