Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: test/mjsunit/es6/array-species-neg-zero.js

Issue 1950073002: Convert negative zero in ArraySpeciesCreate (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« src/js/array.js ('K') | « src/js/array.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 /**
6 * 9.4.2.3 ArraySpeciesCreate(originalArray, length)
7 *
8 * 1. Assert: length is an integer Number ≥ 0.
9 * 2. If length is −0, let length be +0.
10 * [...]
11 */
12
13 var x = [];
14 var deleteCount;
15
16 x.constructor = function() {};
17 x.constructor[Symbol.species] = function(param) {
18 deleteCount = param;
19 };
20
21 x.splice(0, -0);
22
23 assertEquals(0, deleteCount);
OLDNEW
« src/js/array.js ('K') | « src/js/array.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698