Skip to content

Commit ea398df

Browse files
committed
refactor: apply suggestions from code review
--- 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: passed - task: lint_javascript_benchmarks status: passed - 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: passed - task: lint_license_headers status: passed ---
1 parent 5f6e0b9 commit ea398df

File tree

7 files changed

+512
-238
lines changed

7 files changed

+512
-238
lines changed

lib/node_modules/@stdlib/blas/ext/last-index-of/benchmark/benchmark.assign.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ function createBenchmark( len ) {
7171

7272
b.tic();
7373
for ( i = 0; i < b.iterations; i++ ) {
74-
o = lastIndexOf.assign( x, 10.0, out );
74+
o = lastIndexOf.assign( x, 100.0, out );
7575
if ( typeof o !== 'object' ) {
7676
b.fail( 'should return an ndarray' );
7777
}

lib/node_modules/@stdlib/blas/ext/last-index-of/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ function createBenchmark( len ) {
6363

6464
b.tic();
6565
for ( i = 0; i < b.iterations; i++ ) {
66-
o = lastIndexOf( x, 10.0 );
66+
o = lastIndexOf( x, 100.0 );
6767
if ( typeof o !== 'object' ) {
6868
b.fail( 'should return an ndarray' );
6969
}

lib/node_modules/@stdlib/blas/ext/last-index-of/docs/types/test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ import lastIndexOf = require( './index' );
140140
}
141141

142142

143-
// The compiler throws an error if the function is provided a options argument which is not an object...
143+
// The compiler throws an error if the function is provided an options argument which is not an object...
144144
{
145145
const x = zeros( [ 2, 2 ], {
146146
'dtype': 'float64'
@@ -355,7 +355,7 @@ import lastIndexOf = require( './index' );
355355
lastIndexOf.assign( x, 0.0, ( x: number ): number => x, y, {} ); // $ExpectError
356356
}
357357

358-
// The compiler throws an error if the `assign` method is provided a output argument which is not an ndarray...
358+
// The compiler throws an error if the `assign` method is provided an output argument which is not an ndarray...
359359
{
360360
const x = zeros( [ 2, 2 ], {
361361
'dtype': 'float64'
@@ -394,7 +394,7 @@ import lastIndexOf = require( './index' );
394394
lastIndexOf.assign( x, 0.0, 1, ( x: number ): number => x, {} ); // $ExpectError
395395
}
396396

397-
// The compiler throws an error if the `assign` method is provided a options argument which is not an object...
397+
// The compiler throws an error if the `assign` method is provided an options argument which is not an object...
398398
{
399399
const x = zeros( [ 2, 2 ], {
400400
'dtype': 'float64'

lib/node_modules/@stdlib/blas/ext/last-index-of/lib/assign.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ var DEFAULT_DTYPE = defaults.get( 'dtypes.integer_index' );
5656
* @throws {TypeError} third argument must be either an ndarray-like object or an integer
5757
* @throws {TypeError} output argument must be an ndarray-like object
5858
* @throws {TypeError} options argument must be an object
59-
* @throws {RangeError} dimension dimension index must not exceed input ndarray bounds
59+
* @throws {RangeError} dimension index must not exceed input ndarray bounds
6060
* @throws {RangeError} first argument must have at least one dimension
6161
* @throws {Error} must provide valid options
6262
* @returns {ndarray} output ndarray

lib/node_modules/@stdlib/blas/ext/last-index-of/lib/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ var DEFAULT_DTYPE = defaults.get( 'dtypes.integer_index' );
5353
* @param {boolean} [options.keepdims=false] - boolean indicating whether the reduced dimensions should be included in the returned ndarray as singleton dimensions
5454
* @param {string} [options.dtype] - output ndarray data type
5555
* @throws {TypeError} first argument must be an ndarray-like object
56-
* @throws {TypeError} the function must be provided at least two arguments
56+
* @throws {TypeError} second argument must be either an ndarray-like object or a scalar value
5757
* @throws {TypeError} third argument must be either an ndarray-like object or an integer
5858
* @throws {TypeError} options argument must be an object
5959
* @throws {RangeError} dimension index must not exceed input ndarray bounds

0 commit comments

Comments
 (0)