diff options
Diffstat (limited to 'js/src/jit-test/tests/ion/bug1219883.js')
-rw-r--r-- | js/src/jit-test/tests/ion/bug1219883.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/ion/bug1219883.js b/js/src/jit-test/tests/ion/bug1219883.js new file mode 100644 index 000000000..27d65f9c5 --- /dev/null +++ b/js/src/jit-test/tests/ion/bug1219883.js @@ -0,0 +1,14 @@ +function test() { + var arr = new Int8Array(400); + var idx = "384"; + arr[idx] = 9; + assertEq(arr[idx], 9); + idx = "1000"; + arr[idx] = 10; + assertEq(arr[idx], undefined); + idx = "-1"; + arr[idx] = 0; + assertEq(arr[idx], undefined); +} +for (var i=0; i<10; i++) + test(); |