summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/testNativeSetter.js
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--js/src/jit-test/tests/basic/testNativeSetter.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/basic/testNativeSetter.js b/js/src/jit-test/tests/basic/testNativeSetter.js
new file mode 100644
index 0000000000..79ddf56f93
--- /dev/null
+++ b/js/src/jit-test/tests/basic/testNativeSetter.js
@@ -0,0 +1,8 @@
+function testNativeSetter() {
+ var re = /foo/;
+ var N = 19;
+ for (var i = 0; i < N; i++)
+ re.lastIndex = i;
+ assertEq(re.lastIndex, N - 1);
+}
+testNativeSetter();