diff options
Diffstat (limited to 'js/src/jit-test/tests/ion/bug1317943.js')
-rw-r--r-- | js/src/jit-test/tests/ion/bug1317943.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/ion/bug1317943.js b/js/src/jit-test/tests/ion/bug1317943.js new file mode 100644 index 0000000000..10b36d3681 --- /dev/null +++ b/js/src/jit-test/tests/ion/bug1317943.js @@ -0,0 +1,14 @@ +"use strict"; +function test() { + for (var i=0; i<10; i++) { + try { + var arr = []; + arr[0] = 1; + Object.freeze(arr); + arr[0] = 2; + } catch (e) { + assertEq(e.toString().includes("TypeError: 0 is read-only"), true); + } + } +} +test(); |