| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Flags: --allow-natives-syntax | 5 // Flags: --allow-natives-syntax |
| 6 | 6 |
| 7 function PrintDesc(desc, s) { | 7 function PrintDesc(desc, s) { |
| 8 var json; | 8 var json; |
| 9 if (desc) { | 9 if (desc) { |
| 10 json = JSON.stringify(desc); | 10 json = JSON.stringify(desc); |
| (...skipping 434 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 445 assertEquals(true, GetDescriptor().configurable); | 445 assertEquals(true, GetDescriptor().configurable); |
| 446 assertEquals(false, GetDescriptor().writable); | 446 assertEquals(false, GetDescriptor().writable); |
| 447 | 447 |
| 448 assertEquals(42, LoadVar()); | 448 assertEquals(42, LoadVar()); |
| 449 assertEquals(true, GetDescriptor().configurable); | 449 assertEquals(true, GetDescriptor().configurable); |
| 450 assertThrows('DefineVar(153)'); | 450 assertThrows('DefineVar(153)'); |
| 451 assertEquals(42, LoadVar()); | 451 assertEquals(42, LoadVar()); |
| 452 assertThrows('StoreVar(113)'); | 452 assertThrows('StoreVar(113)'); |
| 453 assertThrows('StoreVar(113)'); | 453 assertThrows('StoreVar(113)'); |
| 454 assertEquals(42, LoadVar()); | 454 assertEquals(42, LoadVar()); |
| 455 assertThrows('StoreVar(42)'); |
| 456 assertEquals(42, LoadVar()); |
| 455 assertThrows('LoadStoreLoop()'); | 457 assertThrows('LoadStoreLoop()'); |
| 456 assertEquals(42, LoadVar()); | 458 assertEquals(42, LoadVar()); |
| 457 TearDown(); | 459 TearDown(); |
| 458 })(); | 460 })(); |
| 459 | 461 |
| 460 | 462 |
| 461 (function() { | 463 (function() { |
| 462 SetUp(); | 464 SetUp(); |
| 463 cfg = {optimize: opt_cfg.optimize, strict: true}; | 465 cfg = {optimize: opt_cfg.optimize, strict: true}; |
| 464 ForceMutablePropertyCellType(); | 466 ForceMutablePropertyCellType(); |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 564 assertEquals(0, counters.set_count); | 566 assertEquals(0, counters.set_count); |
| 565 | 567 |
| 566 TearDown(); | 568 TearDown(); |
| 567 })(); | 569 })(); |
| 568 | 570 |
| 569 } // testSuite | 571 } // testSuite |
| 570 | 572 |
| 571 | 573 |
| 572 testSuite({optimize: false}); | 574 testSuite({optimize: false}); |
| 573 testSuite({optimize: true}); | 575 testSuite({optimize: true}); |
| OLD | NEW |