js/src/jit-test/tests/basic/testIncDec.js

Thu, 15 Jan 2015 15:55:04 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 15:55:04 +0100
branch
TOR_BUG_9701
changeset 9
a63d609f5ebe
permissions
-rw-r--r--

Back out 97036ab72558 which inappropriately compared turds to third parties.

     1 function testIncDec2(ii) {
     2     var x = [];
     3     for (let j=0;j<5;++j) {
     4         ii=j;
     5         jj=j;
     6         var kk=j;
     7         x.push(ii--);
     8         x.push(jj--);
     9         x.push(kk--);
    10         x.push(++ii);
    11         x.push(++jj);
    12         x.push(++kk);
    13     }
    14     return x.join(",");
    15 }
    16 function testIncDec() {
    17     return testIncDec2(0);
    18 }
    19 assertEq(testIncDec(), "0,0,0,0,0,0,1,1,1,1,1,1,2,2,2,2,2,2,3,3,3,3,3,3,4,4,4,4,4,4");

mercurial