OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 // | |
5 // Flags: --harmony-classes | |
6 | 4 |
7 'use strict'; | 5 'use strict'; |
8 (function TestArgumentsAccess() { | 6 (function TestArgumentsAccess() { |
9 class Base { | 7 class Base { |
10 constructor() { | 8 constructor() { |
11 assertEquals(2, arguments.length); | 9 assertEquals(2, arguments.length); |
12 assertEquals(1, arguments[0]); | 10 assertEquals(1, arguments[0]); |
13 assertEquals(2, arguments[1]); | 11 assertEquals(2, arguments[1]); |
14 } | 12 } |
15 } | 13 } |
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
330 var eua = new ExtendedUint8Array(10); | 328 var eua = new ExtendedUint8Array(10); |
331 assertEquals(10, eua.length); | 329 assertEquals(10, eua.length); |
332 assertEquals(10, eua.byteLength); | 330 assertEquals(10, eua.byteLength); |
333 eua[0] = 0xFF; | 331 eua[0] = 0xFF; |
334 eua[1] = 0xFFA; | 332 eua[1] = 0xFFA; |
335 assertEquals(0xFF, eua[0]); | 333 assertEquals(0xFF, eua[0]); |
336 assertEquals(0xFA, eua[1]); | 334 assertEquals(0xFA, eua[1]); |
337 assertSame(ExtendedUint8Array.prototype, eua.__proto__); | 335 assertSame(ExtendedUint8Array.prototype, eua.__proto__); |
338 assertEquals("[object Uint8Array]", Object.prototype.toString.call(eua)); | 336 assertEquals("[object Uint8Array]", Object.prototype.toString.call(eua)); |
339 }()); | 337 }()); |
OLD | NEW |