Skip to content

Commit 549d048

Browse files
committed
Auto-generated commit
1 parent 663766e commit 549d048

28 files changed

+163
-27
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1283,6 +1283,7 @@ A total of 7 people contributed to this release. Thank you to the following cont
12831283

12841284
<details>
12851285

1286+
- [`b28f85a`](https://github.com/stdlib-js/stdlib/commit/b28f85a0469dd2f4ace20c220f6718cce912eaea) - **refactor:** use assertion utility to check for row-major order _(by Athan Reines)_
12861287
- [`b47a8a7`](https://github.com/stdlib-js/stdlib/commit/b47a8a74795416cbf42790c89aedb5d1958c53b1) - **docs:** fix argument name _(by Athan Reines)_
12871288
- [`fdf4cc1`](https://github.com/stdlib-js/stdlib/commit/fdf4cc10816de43b8a73890e1f93f1635104c79f) - **docs:** fix signature _(by Athan Reines)_
12881289
- [`1e3aa40`](https://github.com/stdlib-js/stdlib/commit/1e3aa40c44b6d1fe63e8426c9c78ed00ffecc7f0) - **docs:** update copy _(by Athan Reines)_

base/every/lib/10d.js

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

2121
'use strict';
2222

23+
// MODULES //
24+
25+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
26+
27+
2328
// MAIN //
2429

2530
/**
@@ -105,7 +110,7 @@ function every10d( x ) { // eslint-disable-line max-statements
105110
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
106111
sh = x.shape;
107112
sx = x.strides;
108-
if ( x.order === 'row-major' ) {
113+
if ( isRowMajor( x.order ) ) {
109114
// For row-major ndarrays, the last dimensions have the fastest changing indices...
110115
S0 = sh[ 9 ];
111116
S1 = sh[ 8 ];

base/every/lib/10d_accessors.js

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

2121
'use strict';
2222

23+
// MODULES //
24+
25+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
26+
27+
2328
// MAIN //
2429

2530
/**
@@ -109,7 +114,7 @@ function every10d( x ) { // eslint-disable-line max-statements
109114
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
110115
sh = x.shape;
111116
sx = x.strides;
112-
if ( x.order === 'row-major' ) {
117+
if ( isRowMajor( x.order ) ) {
113118
// For row-major ndarrays, the last dimensions have the fastest changing indices...
114119
S0 = sh[ 9 ];
115120
S1 = sh[ 8 ];

base/every/lib/10d_complex.js

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

2121
'use strict';
2222

23+
// MODULES //
24+
25+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
26+
27+
2328
// MAIN //
2429

2530
/**
@@ -105,7 +110,7 @@ function every10d( x ) { // eslint-disable-line max-statements
105110
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
106111
sh = x.shape;
107112
sx = x.strides;
108-
if ( x.order === 'row-major' ) {
113+
if ( isRowMajor( x.order ) ) {
109114
// For row-major ndarrays, the last dimensions have the fastest changing indices...
110115
S0 = sh[ 9 ];
111116
S1 = sh[ 8 ];

base/every/lib/2d.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818

1919
'use strict';
2020

21+
// MODULES //
22+
23+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
24+
25+
2126
// MAIN //
2227

2328
/**
@@ -79,7 +84,7 @@ function every2d( x ) {
7984
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
8085
sh = x.shape;
8186
sx = x.strides;
82-
if ( x.order === 'row-major' ) {
87+
if ( isRowMajor( x.order ) ) {
8388
// For row-major ndarrays, the last dimensions have the fastest changing indices...
8489
S0 = sh[ 1 ];
8590
S1 = sh[ 0 ];

base/every/lib/2d_accessors.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818

1919
'use strict';
2020

21+
// MODULES //
22+
23+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
24+
25+
2126
// MAIN //
2227

2328
/**
@@ -83,7 +88,7 @@ function every2d( x ) {
8388
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
8489
sh = x.shape;
8590
sx = x.strides;
86-
if ( x.order === 'row-major' ) {
91+
if ( isRowMajor( x.order ) ) {
8792
// For row-major ndarrays, the last dimensions have the fastest changing indices...
8893
S0 = sh[ 1 ];
8994
S1 = sh[ 0 ];

base/every/lib/2d_complex.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818

1919
'use strict';
2020

21+
// MODULES //
22+
23+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
24+
25+
2126
// MAIN //
2227

2328
/**
@@ -79,7 +84,7 @@ function every2d( x ) {
7984
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
8085
sh = x.shape;
8186
sx = x.strides;
82-
if ( x.order === 'row-major' ) {
87+
if ( isRowMajor( x.order ) ) {
8388
// For row-major ndarrays, the last dimensions have the fastest changing indices...
8489
S0 = sh[ 1 ];
8590
S1 = sh[ 0 ];

base/every/lib/3d.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818

1919
'use strict';
2020

21+
// MODULES //
22+
23+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
24+
25+
2126
// MAIN //
2227

2328
/**
@@ -82,7 +87,7 @@ function every3d( x ) {
8287
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
8388
sh = x.shape;
8489
sx = x.strides;
85-
if ( x.order === 'row-major' ) {
90+
if ( isRowMajor( x.order ) ) {
8691
// For row-major ndarrays, the last dimensions have the fastest changing indices...
8792
S0 = sh[ 2 ];
8893
S1 = sh[ 1 ];

base/every/lib/3d_accessors.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818

1919
'use strict';
2020

21+
// MODULES //
22+
23+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
24+
25+
2126
// MAIN //
2227

2328
/**
@@ -86,7 +91,7 @@ function every3d( x ) {
8691
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
8792
sh = x.shape;
8893
sx = x.strides;
89-
if ( x.order === 'row-major' ) {
94+
if ( isRowMajor( x.order ) ) {
9095
// For row-major ndarrays, the last dimensions have the fastest changing indices...
9196
S0 = sh[ 2 ];
9297
S1 = sh[ 1 ];

base/every/lib/3d_complex.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818

1919
'use strict';
2020

21+
// MODULES //
22+
23+
var isRowMajor = require( './../../../base/assert/is-row-major-string' );
24+
25+
2126
// MAIN //
2227

2328
/**
@@ -82,7 +87,7 @@ function every3d( x ) {
8287
// Extract loop variables for purposes of loop interchange: dimensions and loop offset (pointer) increments...
8388
sh = x.shape;
8489
sx = x.strides;
85-
if ( x.order === 'row-major' ) {
90+
if ( isRowMajor( x.order ) ) {
8691
// For row-major ndarrays, the last dimensions have the fastest changing indices...
8792
S0 = sh[ 2 ];
8893
S1 = sh[ 1 ];

0 commit comments

Comments
 (0)