Skip to content

Commit d0b4351

Browse files
authored
Apply suggestions from code review
Signed-off-by: Athan <kgryte@gmail.com>
1 parent 834daf5 commit d0b4351

6 files changed

Lines changed: 9 additions & 9 deletions

File tree

lib/node_modules/@stdlib/blas/ext/base/ndarray/dsum/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ console.log( v );
121121
#include "stdlib/blas/ext/base/ndarray/dsum.h"
122122
```
123123

124-
#### stdlib_blas_dsum( arrays )
124+
#### stdlib_blas_ext_dsum( arrays )
125125

126126
Computes the sum of all elements in a one-dimensional double-precision floating-point ndarray.
127127

@@ -143,7 +143,7 @@ struct ndarray *x = stdlib_ndarray_allocate( STDLIB_NDARRAY_FLOAT64, (uint8_t *)
143143

144144
// Compute the sum:
145145
const struct ndarray *arrays[] = { x };
146-
double v = stdlib_blas_dsum( arrays );
146+
double v = stdlib_blas_ext_dsum( arrays );
147147
// returns 10.0
148148

149149
// Free allocated memory:
@@ -155,7 +155,7 @@ The function accepts the following arguments:
155155
- **arrays**: `[in] struct ndarray**` list containing a one-dimensional input ndarray.
156156
157157
```c
158-
double stdlib_blas_dsum( const struct ndarray *arrays[] );
158+
double stdlib_blas_ext_dsum( const struct ndarray *arrays[] );
159159
```
160160

161161
</section>
@@ -224,7 +224,7 @@ int main( void ) {
224224
const struct ndarray *arrays[] = { x };
225225

226226
// Compute the sum:
227-
double v = stdlib_blas_dsum( arrays );
227+
double v = stdlib_blas_ext_dsum( arrays );
228228

229229
// Print the result:
230230
printf( "sum: %lf\n", v );

lib/node_modules/@stdlib/blas/ext/base/ndarray/dsum/benchmark/c/benchmark.length.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ static double benchmark( int iterations, int len ) {
137137
v = 0.0;
138138
t = tic();
139139
for ( i = 0; i < iterations; i++ ) {
140-
v = stdlib_blas_dsum( arrays );
140+
v = stdlib_blas_ext_dsum( arrays );
141141
if ( v != v ) {
142142
printf( "should not return NaN\n" );
143143
break;

lib/node_modules/@stdlib/blas/ext/base/ndarray/dsum/examples/c/example.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ int main( void ) {
6464
const struct ndarray *arrays[] = { x };
6565

6666
// Compute the sum:
67-
double v = stdlib_blas_dsum( arrays );
67+
double v = stdlib_blas_ext_dsum( arrays );
6868

6969
// Print the result:
7070
printf( "sum: %lf\n", v );

lib/node_modules/@stdlib/blas/ext/base/ndarray/dsum/include/stdlib/blas/ext/base/ndarray/dsum.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ extern "C" {
3131
/**
3232
* Computes the sum of all elements in a one-dimensional double-precision floating-point ndarray.
3333
*/
34-
double stdlib_blas_dsum( const struct ndarray *arrays[] );
34+
double stdlib_blas_ext_dsum( const struct ndarray *arrays[] );
3535

3636
#ifdef __cplusplus
3737
}

lib/node_modules/@stdlib/blas/ext/base/ndarray/dsum/src/addon.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ static napi_value addon( napi_env env, napi_callback_info info ) {
4646
return NULL;
4747
}
4848
// Perform computation:
49-
STDLIB_NAPI_CREATE_DOUBLE( env, stdlib_blas_dsum( arrays ), v );
49+
STDLIB_NAPI_CREATE_DOUBLE( env, stdlib_blas_ext_dsum( arrays ), v );
5050

5151
// Free allocated memory:
5252
stdlib_ndarray_free( arrays[ 0 ] );

lib/node_modules/@stdlib/blas/ext/base/ndarray/dsum/src/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
* @param arrays list containing an input ndarray
2828
* @return sum
2929
*/
30-
double stdlib_blas_dsum( const struct ndarray *arrays[] ) {
30+
double stdlib_blas_ext_dsum( const struct ndarray *arrays[] ) {
3131
const struct ndarray *x = arrays[ 0 ];
3232
return API_SUFFIX(stdlib_strided_dsum_ndarray)( stdlib_ndarray_dimension( x, 0 ), (const double *)stdlib_ndarray_data( x ), stdlib_ndarray_stride_elements( x, 0 ), stdlib_ndarray_offset_elements( x ) );
3333
}

0 commit comments

Comments
 (0)