Debian Codegraph @

js/src/tests/test262/language/statements/function/S13.2_A5.js

raw
1 // Copyright 2009 the Sputnik authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3
4 /*---
5 info: |
6 When Function object(F) is constructed
7 the [[Prototype]] property of F is set to the original Function prototype object as specified in 15.3.3.1
8 es5id: 13.2_A5
9 description: Function.prototype.isPrototypeOf() is used
10 ---*/
11
12 function __func(){};
13
14 //////////////////////////////////////////////////////////////////////////////
15 //CHECK#1
16 if (!(Function.prototype.isPrototypeOf(__func))) {
17 throw new Test262Error('#1: Function.prototype.isPrototypeOf(__func)');
18 }
19 //
20 //////////////////////////////////////////////////////////////////////////////
21
22
23 var __gunc = function(){};
24
25 //////////////////////////////////////////////////////////////////////////////
26 //CHECK#2
27 if (!(Function.prototype.isPrototypeOf(__gunc))) {
28 throw new Test262Error('#1: Function.prototype.isPrototypeOf(__gunc)');
29 }
30 //
31 //////////////////////////////////////////////////////////////////////////////
32
33 reportCompare(0, 0);