Added test case for bug 456667.
authorDavid Anderson <danderson@mozilla.com>
Thu, 25 Sep 2008 14:16:24 -0700
changeset 19982 da80ff92f1fad5f9186cf1269cf0edb6f5a5d640
parent 19981 437331f166fe9f8070fc5e54cd273933195083c6
child 19983 308e7e1eb1cf76567939a51089a02ef602a2f37f
push id2577
push userbrendan@mozilla.com
push dateWed, 01 Oct 2008 04:35:27 +0000
treeherdermozilla-central@a613924403d6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs456667
milestone1.9.1b1pre
Added test case for bug 456667.
js/src/trace-test.js
--- a/js/src/trace-test.js
+++ b/js/src/trace-test.js
@@ -1600,11 +1600,32 @@ function testArrayNaNIndex()
 {
     for (var j = 0; j < 4; ++j) { [this[NaN]]; }
     for (var j = 0; j < 5; ++j) { if([1][-0]) { } }
     return "ok";
 }
 testArrayNaNIndex.expected = "ok";
 test(testArrayNaNIndex);
 
+function innerTestInnerMissingArgs(a,b,c,d)
+{
+        if (a) {
+        } else {
+        }
+}
+function doTestInnerMissingArgs(k)
+{
+    for (i = 0; i < 10; i++) {
+        innerTestInnerMissingArgs(k);
+    }
+}
+function testInnerMissingArgs()
+{
+    doTestInnerMissingArgs(1);
+    doTestInnerMissingArgs(0);
+    return 1;
+}
+testInnerMissingArgs.expected = 1;  //Expected: that we don't crash.
+test(testInnerMissingArgs);
+
 /* Keep these at the end so that we can see the summary after the trace-debug spew. */
 print("\npassed:", passes.length && passes.join(","));
 print("\nFAILED:", fails.length && fails.join(","));