tor-browser

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

11.2.3-3_3.js (598B)


      1 // Copyright (c) 2012 Ecma International.  All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 
      4 /*---
      5 es5id: 11.2.3-3_3
      6 description: >
      7    Call arguments are not evaluated before the check is made to see
      8    if the object is actually callable (undefined member)
      9 ---*/
     10 
     11    var fooCalled = false;
     12    function foo(){ fooCalled = true; } 
     13    
     14    var o = { }; 
     15 assert.throws(TypeError, function() {
     16        o.bar.gar( foo() );
     17        throw new Test262Error("o.bar does not exist!");
     18 });
     19 assert.sameValue(fooCalled, false, 'fooCalled');
     20 
     21 reportCompare(0, 0);