summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/argumentsPassedToBuiltin.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/jit-test/tests/basic/argumentsPassedToBuiltin.js')
-rw-r--r--js/src/jit-test/tests/basic/argumentsPassedToBuiltin.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/basic/argumentsPassedToBuiltin.js b/js/src/jit-test/tests/basic/argumentsPassedToBuiltin.js
new file mode 100644
index 0000000000..d8edfffffa
--- /dev/null
+++ b/js/src/jit-test/tests/basic/argumentsPassedToBuiltin.js
@@ -0,0 +1,14 @@
+// bug 504797
+
+function f() {
+ g(arguments, 1);
+}
+
+function g(a, b) {
+ var s = Array.prototype.slice.call(a, b);
+ assertEq(s[0] == undefined, false);
+}
+
+for (var i = 0; i < 10; ++i) {
+ f(1, 2, 3, 4);
+}