File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed
lib/node_modules/@stdlib/ndarray/iter/values/lib Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ var isndarrayLike = require( '@stdlib/assert/is-ndarray-like' );
2727var hasOwnProp = require ( '@stdlib/assert/has-own-property' ) ;
2828var iteratorSymbol = require ( '@stdlib/symbol/iterator' ) ;
2929var zeros = require ( '@stdlib/array/base/zeros' ) ;
30- var copyIndexed = require ( '@stdlib/array/base/copy-indexed ' ) ;
30+ var getShape = require ( '@stdlib/ndarray/shape ' ) ;
3131var numel = require ( '@stdlib/ndarray/base/numel' ) ;
3232var nextCartesianIndex = require ( '@stdlib/ndarray/base/next-cartesian-index' ) . assign ;
3333var format = require ( '@stdlib/string/format' ) ;
@@ -74,7 +74,6 @@ function nditerValues( x ) {
7474 var FLG ;
7575 var idx ;
7676 var dim ;
77- var sh ;
7877 var N ;
7978 var i ;
8079
@@ -97,14 +96,11 @@ function nditerValues( x ) {
9796 }
9897 }
9998 // Retrieve input array meta data:
100- shape = x . shape ;
99+ shape = getShape ( x ) ;
101100 ndims = shape . length ;
102101
103- // Copy the input shape:
104- sh = copyIndexed ( shape ) ;
105-
106102 // Check whether the input array is empty...
107- N = numel ( sh ) ;
103+ N = numel ( shape ) ;
108104 if ( N === 0 ) {
109105 FLG = true ;
110106 }
You can’t perform that action at this time.
0 commit comments