OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 10 matching lines...) Expand all Loading... |
21 // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | 21 // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
22 // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 22 // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
23 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 23 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
27 | 27 |
28 | 28 |
29 // A namespace stub. It will become more clear how to declare it properly | 29 // A namespace stub. It will become more clear how to declare it properly |
30 // during integration of this script into Dev Tools. | 30 // during integration of this script into Dev Tools. |
31 goog = { structs: {} }; | 31 var goog = goog || {}; |
| 32 goog.structs = goog.structs || {}; |
32 | 33 |
33 | 34 |
34 /** | 35 /** |
35 * Constructs a Splay tree. A splay tree is a self-balancing binary | 36 * Constructs a Splay tree. A splay tree is a self-balancing binary |
36 * search tree with the additional property that recently accessed | 37 * search tree with the additional property that recently accessed |
37 * elements are quick to access again. It performs basic operations | 38 * elements are quick to access again. It performs basic operations |
38 * such as insertion, look-up and removal in O(log(n)) amortized time. | 39 * such as insertion, look-up and removal in O(log(n)) amortized time. |
39 * | 40 * |
40 * @constructor | 41 * @constructor |
41 */ | 42 */ |
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
312 /** | 313 /** |
313 * @type {goog.structs.SplayTree.Node} | 314 * @type {goog.structs.SplayTree.Node} |
314 */ | 315 */ |
315 goog.structs.SplayTree.Node.prototype.left = null; | 316 goog.structs.SplayTree.Node.prototype.left = null; |
316 | 317 |
317 | 318 |
318 /** | 319 /** |
319 * @type {goog.structs.SplayTree.Node} | 320 * @type {goog.structs.SplayTree.Node} |
320 */ | 321 */ |
321 goog.structs.SplayTree.Node.prototype.right = null; | 322 goog.structs.SplayTree.Node.prototype.right = null; |
OLD | NEW |