tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

tco-cond-strict.js (615B)


      1 // |reftest| skip -- tail-call-optimization is not supported
      2 'use strict';
      3 // Copyright (C) 2016 the V8 project authors. All rights reserved.
      4 // This code is governed by the BSD license found in the LICENSE file.
      5 /*---
      6 description: Expression is a candidate for tail-call optimization.
      7 esid: sec-static-semantics-hascallintailposition
      8 flags: [onlyStrict]
      9 features: [tail-call-optimization]
     10 includes: [tcoHelper.js]
     11 ---*/
     12 
     13 var callCount = 0;
     14 (function f(n) {
     15  if (n === 0) {
     16    callCount += 1
     17    return;
     18  }
     19  return true ? f(n - 1) : 0;
     20 }($MAX_ITERATIONS));
     21 assert.sameValue(callCount, 1);
     22 
     23 reportCompare(0, 0);