~ubuntu-branches/ubuntu/trusty/mozjs24/trusty-proposed

« back to all changes in this revision

Viewing changes to js/src/jit-test/tests/basic/testBranchingUnstableLoop.js

  • Committer: Package Import Robot
  • Author(s): Tim Lunn
  • Date: 2014-02-11 21:55:34 UTC
  • Revision ID: package-import@ubuntu.com-20140211215534-m1zyq5aj59md3y07
Tags: upstream-24.2.0
ImportĀ upstreamĀ versionĀ 24.2.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
function testBranchingUnstableLoop() {
 
2
  var x = 0;
 
3
  for (var i=0; i < 100; ++i) {
 
4
    if (i == 51) {
 
5
      x += 10.1;
 
6
    }
 
7
    x++;
 
8
  }
 
9
  return x;
 
10
}
 
11
assertEq(testBranchingUnstableLoop(), 110.1);