tor-browser

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

conditional-test-guard.js (225B)


      1 function f(x) {
      2    return (+(x || 1) ? 0 : x);
      3 }
      4 
      5 // Prevent top-level Ion-compilation, so we don't inline |f|.
      6 with ({});
      7 
      8 for (let i = 0; i < 100; ++i) {
      9  assertEq(f(), 0);
     10 }
     11 
     12 assertEq(f("not-a-number"), "not-a-number");