Skip to content

Commit 7cc966f

Browse files
committed
Rename file and method
1 parent 1fd94a0 commit 7cc966f

3 files changed

Lines changed: 9 additions & 11 deletions

File tree

lib/node_modules/@stdlib/ndarray/dtypes/lib/enumerate.js renamed to lib/node_modules/@stdlib/ndarray/dtypes/lib/enumerator.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,14 @@ var dt = dtypes();
4242
* @returns {(integer|void)} integer value or undefined
4343
*
4444
* @example
45-
* var v = enumerate( 'int8' );
45+
* var v = enumerator( 'int8' );
4646
* // returns <number>
4747
*/
48-
function enumerate( dtype ) {
48+
function enumerator( dtype ) {
4949
return dt[ dtype ];
5050
}
5151

5252

5353
// EXPORTS //
5454

55-
module.exports = enumerate;
55+
module.exports = enumerator;

lib/node_modules/@stdlib/ndarray/dtypes/lib/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@
3535
var setReadOnly = require( '@stdlib/utils/define-nonenumerable-read-only-property' );
3636
var dtypes = require( './main.js' );
3737
var enumeration = require( './enum.js' );
38-
var enumerate = require( './enumerate.js' );
38+
var enumerator = require( './enumerator.js' );
3939

4040

4141
// MAIN //
4242

4343
setReadOnly( dtypes, 'enum', enumeration );
44-
setReadOnly( dtypes, 'enumerate', enumerate );
44+
setReadOnly( dtypes, 'enumerator', enumerator );
4545

4646

4747
// EXPORTS //

lib/node_modules/@stdlib/ndarray/dtypes/test/test.js

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,13 +93,12 @@ tape( 'attached to the main function is an `enum` method to return an object map
9393
t.end();
9494
});
9595

96-
tape( 'attached to the main function is an `enumerate` method to the integer value associated with a provided dtype for C inter-operation', function test( t ) {
97-
var obj;
96+
tape( 'attached to the main function is an `enumerator` method to the integer value associated with a provided dtype for C inter-operation', function test( t ) {
9897
var dt;
9998
var i;
10099

101-
t.strictEqual( hasOwnProp( dtypes, 'enumerate' ), true, 'has property' );
102-
t.strictEqual( typeof dtypes.enumerate, 'function', 'has method' );
100+
t.strictEqual( hasOwnProp( dtypes, 'enumerator' ), true, 'has property' );
101+
t.strictEqual( typeof dtypes.enumerator, 'function', 'has method' );
103102

104103
// List of native C types which should be supported...
105104
dt = [
@@ -117,8 +116,7 @@ tape( 'attached to the main function is an `enumerate` method to the integer val
117116
'complex128'
118117
];
119118
for ( i = 0; i < dt.length; i++ ) {
120-
t.strictEqual( isNonNegativeInteger( dtypes.enumerate( dt[i] ) ), true, 'returns expected value' );
119+
t.strictEqual( isNonNegativeInteger( dtypes.enumerator( dt[i] ) ), true, 'returns expected value' );
121120
}
122121
t.end();
123122
});
124-

0 commit comments

Comments
 (0)