MCPcopy Index your code
hub / github.com/nodejs/node / Uint16Array

Function Uint16Array

deps/v8/test/mjsunit/array-indexing-receiver.js:461–484  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

459 },
460
461 Uint16Array() {
462 var array = new Uint16Array([-1, 65536,
463 NaN /* 0 */, Infinity /* 0 */,
464 -Infinity /* 0 */, -0 /* 0 */, +0 /* 0 */,
465 0x7FFFF /* 65535 */, 300000 /* 37856 */,
466 3000000 /* 50880 */]);
467 assertEquals(Array.prototype.indexOf.call(array, -1), -1);
468 assertEquals(Array.prototype.indexOf.call(array, 65536), -1);
469
470 assertEquals(Array.prototype.indexOf.call(array, 0, 2), 2);
471 assertEquals(Array.prototype.indexOf.call(array, 0, 3), 3);
472 assertEquals(Array.prototype.indexOf.call(array, 0, 4), 4);
473 assertEquals(Array.prototype.indexOf.call(array, 0, 5), 5);
474 assertEquals(Array.prototype.indexOf.call(array, 0, 6), 6);
475 assertEquals(Array.prototype.indexOf.call(array, 0, 7), -1);
476
477 assertEquals(Array.prototype.indexOf.call(array, 65535, 7), 7);
478 assertEquals(Array.prototype.indexOf.call(array, 65535, 8), -1);
479
480 assertEquals(Array.prototype.indexOf.call(array, 37856, 8), 8);
481 assertEquals(Array.prototype.indexOf.call(array, 37856, 9), -1);
482
483 assertEquals(Array.prototype.indexOf.call(array, 50880, 9), 9);
484 },
485
486 Detached_Uint16Array() {
487 var array = new Uint16Array(10);

Callers 1

messages.jsFile · 0.70

Calls 2

assertEqualsFunction · 0.50
callMethod · 0.45

Tested by

no test coverage detected