Skip to content

Commit 6c09182

Browse files
committed
fix: use resolved order when computing loop variables
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: passed - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent ca6378c commit 6c09182

File tree

18 files changed

+36
-36
lines changed

18 files changed

+36
-36
lines changed

lib/node_modules/@stdlib/ndarray/base/every-by/lib/10d.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
// MODULES //
2424

25-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
25+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2626
var zeroTo = require( '@stdlib/array/base/zero-to' );
2727
var reverse = require( '@stdlib/array/base/reverse' );
2828
var take = require( '@stdlib/array/base/take-indexed' );
@@ -123,7 +123,7 @@ function every10d( x, predicate, thisArg ) { // eslint-disable-line max-statemen
123123
sh = x.shape;
124124
sx = x.strides;
125125
idx = zeroTo( sh.length );
126-
if ( isRowMajor( x.order ) ) {
126+
if ( strides2order( sx ) === 1 ) {
127127
// For row-major ndarrays, the last dimensions have the fastest changing indices...
128128
S0 = sh[ 9 ];
129129
S1 = sh[ 8 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/10d_accessors.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
// MODULES //
2424

25-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
25+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2626
var zeroTo = require( '@stdlib/array/base/zero-to' );
2727
var reverse = require( '@stdlib/array/base/reverse' );
2828
var take = require( '@stdlib/array/base/take-indexed' );
@@ -127,7 +127,7 @@ function every10d( x, predicate, thisArg ) { // eslint-disable-line max-statemen
127127
sh = x.shape;
128128
sx = x.strides;
129129
idx = zeroTo( sh.length );
130-
if ( isRowMajor( x.order ) ) {
130+
if ( strides2order( sx ) === 1 ) {
131131
// For row-major ndarrays, the last dimensions have the fastest changing indices...
132132
S0 = sh[ 9 ];
133133
S1 = sh[ 8 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/2d.js

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

2121
// MODULES //
2222

23-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
23+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2424
var zeroTo = require( '@stdlib/array/base/zero-to' );
2525
var reverse = require( '@stdlib/array/base/reverse' );
2626
var take = require( '@stdlib/array/base/take-indexed' );
@@ -97,7 +97,7 @@ function every2d( x, predicate, thisArg ) {
9797
sh = x.shape;
9898
sx = x.strides;
9999
idx = zeroTo( sh.length );
100-
if ( isRowMajor( x.order ) ) {
100+
if ( strides2order( sx ) === 1 ) {
101101
// For row-major ndarrays, the last dimensions have the fastest changing indices...
102102
S0 = sh[ 1 ];
103103
S1 = sh[ 0 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/2d_accessors.js

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

2121
// MODULES //
2222

23-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
23+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2424
var zeroTo = require( '@stdlib/array/base/zero-to' );
2525
var reverse = require( '@stdlib/array/base/reverse' );
2626
var take = require( '@stdlib/array/base/take-indexed' );
@@ -101,7 +101,7 @@ function every2d( x, predicate, thisArg ) {
101101
sh = x.shape;
102102
sx = x.strides;
103103
idx = zeroTo( sh.length );
104-
if ( isRowMajor( x.order ) ) {
104+
if ( strides2order( sx ) === 1 ) {
105105
// For row-major ndarrays, the last dimensions have the fastest changing indices...
106106
S0 = sh[ 1 ];
107107
S1 = sh[ 0 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/3d.js

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

2121
// MODULES //
2222

23-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
23+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2424
var zeroTo = require( '@stdlib/array/base/zero-to' );
2525
var reverse = require( '@stdlib/array/base/reverse' );
2626
var take = require( '@stdlib/array/base/take-indexed' );
@@ -100,7 +100,7 @@ function every3d( x, predicate, thisArg ) {
100100
sh = x.shape;
101101
sx = x.strides;
102102
idx = zeroTo( sh.length );
103-
if ( isRowMajor( x.order ) ) {
103+
if ( strides2order( sx ) === 1 ) {
104104
// For row-major ndarrays, the last dimensions have the fastest changing indices...
105105
S0 = sh[ 2 ];
106106
S1 = sh[ 1 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/3d_accessors.js

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

2121
// MODULES //
2222

23-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
23+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2424
var zeroTo = require( '@stdlib/array/base/zero-to' );
2525
var reverse = require( '@stdlib/array/base/reverse' );
2626
var take = require( '@stdlib/array/base/take-indexed' );
@@ -104,7 +104,7 @@ function every3d( x, predicate, thisArg ) {
104104
sh = x.shape;
105105
sx = x.strides;
106106
idx = zeroTo( sh.length );
107-
if ( isRowMajor( x.order ) ) {
107+
if ( strides2order( sx ) === 1 ) {
108108
// For row-major ndarrays, the last dimensions have the fastest changing indices...
109109
S0 = sh[ 2 ];
110110
S1 = sh[ 1 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/4d.js

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

2121
// MODULES //
2222

23-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
23+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2424
var zeroTo = require( '@stdlib/array/base/zero-to' );
2525
var reverse = require( '@stdlib/array/base/reverse' );
2626
var take = require( '@stdlib/array/base/take-indexed' );
@@ -103,7 +103,7 @@ function every4d( x, predicate, thisArg ) {
103103
sh = x.shape;
104104
sx = x.strides;
105105
idx = zeroTo( sh.length );
106-
if ( isRowMajor( x.order ) ) {
106+
if ( strides2order( sx ) === 1 ) {
107107
// For row-major ndarrays, the last dimensions have the fastest changing indices...
108108
S0 = sh[ 3 ];
109109
S1 = sh[ 2 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/4d_accessors.js

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

2121
// MODULES //
2222

23-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
23+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2424
var zeroTo = require( '@stdlib/array/base/zero-to' );
2525
var reverse = require( '@stdlib/array/base/reverse' );
2626
var take = require( '@stdlib/array/base/take-indexed' );
@@ -107,7 +107,7 @@ function every4d( x, predicate, thisArg ) {
107107
sh = x.shape;
108108
sx = x.strides;
109109
idx = zeroTo( sh.length );
110-
if ( isRowMajor( x.order ) ) {
110+
if ( strides2order( sx ) === 1 ) {
111111
// For row-major ndarrays, the last dimensions have the fastest changing indices...
112112
S0 = sh[ 3 ];
113113
S1 = sh[ 2 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/5d.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
// MODULES //
2424

25-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
25+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2626
var zeroTo = require( '@stdlib/array/base/zero-to' );
2727
var reverse = require( '@stdlib/array/base/reverse' );
2828
var take = require( '@stdlib/array/base/take-indexed' );
@@ -108,7 +108,7 @@ function every5d( x, predicate, thisArg ) {
108108
sh = x.shape;
109109
sx = x.strides;
110110
idx = zeroTo( sh.length );
111-
if ( isRowMajor( x.order ) ) {
111+
if ( strides2order( sx ) === 1 ) {
112112
// For row-major ndarrays, the last dimensions have the fastest changing indices...
113113
S0 = sh[ 4 ];
114114
S1 = sh[ 3 ];

lib/node_modules/@stdlib/ndarray/base/every-by/lib/5d_accessors.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
// MODULES //
2424

25-
var isRowMajor = require( '@stdlib/ndarray/base/assert/is-row-major-string' );
25+
var strides2order = require( '@stdlib/ndarray/base/strides2order' );
2626
var zeroTo = require( '@stdlib/array/base/zero-to' );
2727
var reverse = require( '@stdlib/array/base/reverse' );
2828
var take = require( '@stdlib/array/base/take-indexed' );
@@ -112,7 +112,7 @@ function every5d( x, predicate, thisArg ) {
112112
sh = x.shape;
113113
sx = x.strides;
114114
idx = zeroTo( sh.length );
115-
if ( isRowMajor( x.order ) ) {
115+
if ( strides2order( sx ) === 1 ) {
116116
// For row-major ndarrays, the last dimensions have the fastest changing indices...
117117
S0 = sh[ 4 ];
118118
S1 = sh[ 3 ];

0 commit comments

Comments
 (0)