Skip to content

Commit 629ce7b

Browse files
committed
fix: ensure support for typed arrays larger than 2^32-1
1 parent fb1ca76 commit 629ce7b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/node_modules/@stdlib/array/to-fancy/lib/factory.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020

2121
// MODULES //
2222

23+
var isCollection = require( '@stdlib/assert/is-collection' );
2324
var isArrayLike = require( '@stdlib/assert/is-array-like' );
2425
var Proxy = require( '@stdlib/proxy/ctor' );
2526
var arraylike2object = require( '@stdlib/array/base/arraylike2object' );
@@ -124,7 +125,7 @@ function factory() {
124125
var arr;
125126
var dt;
126127
var o;
127-
if ( !isArrayLike( x ) ) {
128+
if ( !isArrayLike( x ) && !isCollection( x ) ) {
128129
throw new TypeError( format( 'invalid argument. First argument must be array-like. Value: `%s`.', x ) );
129130
}
130131
if ( hasProxySupport ) {

lib/node_modules/@stdlib/array/to-fancy/lib/set.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ var setSlice = require( './set_slice.js' );
3737
*
3838
* @private
3939
* @param {Object} ctx - context object
40-
* @param {Function} ctx.setter - accessor for setting array elements
4140
* @param {string} ctx.dtype - array data type
4241
* @param {boolean} ctx.strict - boolean indicating whether to enforce strict bounds checking
4342
* @param {Function} ctx.validator - function for validating new values

0 commit comments

Comments
 (0)