Skip to content

Commit da78bfd

Browse files
committed
docs: minor clean-up and fix array bounds error in example code
--- 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: passed - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - 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 defed16 commit da78bfd

File tree

1 file changed

+4
-4
lines changed
  • lib/node_modules/@stdlib/blas/ext/base/dlast-index-of

1 file changed

+4
-4
lines changed

lib/node_modules/@stdlib/blas/ext/base/dlast-index-of/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ var idx = dlastIndexOf( 4, 3.0, x, 2 );
8282
// returns 2
8383
```
8484

85-
Note that indexing is relative to the last index. To introduce an offset, use [`typed array`][mdn-typed-array] views.
85+
Note that indexing is relative to the first index. To introduce an offset, use [`typed array`][mdn-typed-array] views.
8686

8787
```javascript
8888
var Float64Array = require( '@stdlib/array/float64' );
@@ -94,7 +94,7 @@ var x0 = new Float64Array( [ -2.0, 3.0, -6.0, -4.0, 5.0, 3.0 ] );
9494
var x1 = new Float64Array( x0.buffer, x0.BYTES_PER_ELEMENT*1 ); // start at 2nd element
9595

9696
// Find index:
97-
var idx = dlastIndexOf( 5, 3.0, x1, 2 );
97+
var idx = dlastIndexOf( 3, 3.0, x1, 2 );
9898
// returns 2
9999
```
100100

@@ -212,7 +212,7 @@ The function accepts the following arguments:
212212
- **strideX**: `[in] CBLAS_INT` stride length.
213213
214214
```c
215-
CBLAS_INT N stdlib_strided_dlast_index_of( const CBLAS_INT N, const double searchElement, const double *X, const CBLAS_INT strideX );
215+
CBLAS_INT stdlib_strided_dlast_index_of( const CBLAS_INT N, const double searchElement, const double *X, const CBLAS_INT strideX );
216216
```
217217

218218
#### stdlib_strided_dlast_index_of_ndarray( N, searchElement, \*X, strideX, offsetX )
@@ -222,7 +222,7 @@ Returns the last index of a specified search element in a double-precision float
222222
```c
223223
double x[] = { 1.0, 2.0, 3.0, 2.0 };
224224

225-
int idx = stdlib_strided_dlast_index_of( 4, 2.0, x, 1, 0 );
225+
int idx = stdlib_strided_dlast_index_of_ndarray( 4, 2.0, x, 1, 0 );
226226
// returns 3
227227
```
228228

0 commit comments

Comments
 (0)