Skip to content

Commit

Permalink
fix: wrap void function call in API_SUFFIX
Browse files Browse the repository at this point in the history
PR-URL: #4603
Reviewed-by: Athan Reines <[email protected]>
  • Loading branch information
aayush0325 authored Jan 8, 2025
1 parent 25c58d7 commit 99378ce
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 12 deletions.
5 changes: 3 additions & 2 deletions lib/node_modules/@stdlib/stats/base/dcumax/src/addon.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
#include "stdlib/napi/export.h"
#include "stdlib/napi/argv.h"
#include "stdlib/napi/argv_int64.h"
#include "stdlib/blas/base/shared.h"
#include "stdlib/napi/argv_strided_float64array.h"
#include <node_api.h>

Expand All @@ -37,7 +38,7 @@ static napi_value addon( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 4 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 3 );
stdlib_strided_dcumax( N, X, strideX, Y, strideY );
API_SUFFIX(stdlib_strided_dcumax)( N, X, strideX, Y, strideY );
return NULL;
}

Expand All @@ -57,7 +58,7 @@ static napi_value addon_method( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, offsetY, argv, 6 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 4 );
stdlib_strided_dcumax_ndarray( N, X, strideX, offsetX, Y, strideY, offsetY );
API_SUFFIX(stdlib_strided_dcumax_ndarray)( N, X, strideX, offsetX, Y, strideY, offsetY );
return NULL;
}

Expand Down
5 changes: 3 additions & 2 deletions lib/node_modules/@stdlib/stats/base/dcumaxabs/src/addon.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
#include "stdlib/napi/export.h"
#include "stdlib/napi/argv.h"
#include "stdlib/napi/argv_int64.h"
#include "stdlib/blas/base/shared.h"
#include "stdlib/napi/argv_strided_float64array.h"
#include <node_api.h>

Expand All @@ -37,7 +38,7 @@ static napi_value addon( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 4 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 3 );
stdlib_strided_dcumaxabs( N, X, strideX, Y, strideY );
API_SUFFIX(stdlib_strided_dcumaxabs)( N, X, strideX, Y, strideY );
return NULL;
}

Expand All @@ -57,7 +58,7 @@ static napi_value addon_method( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, offsetY, argv, 6 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 4 );
stdlib_strided_dcumaxabs_ndarray( N, X, strideX, offsetX, Y, strideY, offsetY );
API_SUFFIX(stdlib_strided_dcumaxabs_ndarray)( N, X, strideX, offsetX, Y, strideY, offsetY );
return NULL;
}

Expand Down
5 changes: 3 additions & 2 deletions lib/node_modules/@stdlib/stats/base/dcumin/src/addon.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
#include "stdlib/napi/export.h"
#include "stdlib/napi/argv.h"
#include "stdlib/napi/argv_int64.h"
#include "stdlib/blas/base/shared.h"
#include "stdlib/napi/argv_strided_float64array.h"
#include <node_api.h>

Expand All @@ -37,7 +38,7 @@ static napi_value addon( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 4 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 3 );
stdlib_strided_dcumin( N, X, strideX, Y, strideY );
API_SUFFIX(stdlib_strided_dcumin)( N, X, strideX, Y, strideY );
return NULL;
}

Expand All @@ -57,7 +58,7 @@ static napi_value addon_method( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, offsetY, argv, 6 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 4 );
stdlib_strided_dcumin_ndarray( N, X, strideX, offsetX, Y, strideY, offsetY );
API_SUFFIX(stdlib_strided_dcumin_ndarray)( N, X, strideX, offsetX, Y, strideY, offsetY );
return NULL;
}

Expand Down
9 changes: 5 additions & 4 deletions lib/node_modules/@stdlib/stats/base/dcuminabs/src/addon.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#include "stdlib/stats/base/dcuminabs.h"
#include "stdlib/napi/export.h"
#include "stdlib/napi/argv.h"
#include "stdlib/blas/base/shared.h"
#include "stdlib/napi/argv_int64.h"
#include "stdlib/napi/argv_strided_float64array.h"
#include <node_api.h>
Expand All @@ -37,7 +38,7 @@ static napi_value addon( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 4 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 3 );
stdlib_strided_dcuminabs( N, X, strideX, Y, strideY );
API_SUFFIX(stdlib_strided_dcuminabs)( N, X, strideX, Y, strideY );
return NULL;
}

Expand All @@ -52,12 +53,12 @@ static napi_value addon_method( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV( env, info, argv, argc, 7 );
STDLIB_NAPI_ARGV_INT64( env, N, argv, 0 );
STDLIB_NAPI_ARGV_INT64( env, strideX, argv, 2 );
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 5 );
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 5 );
STDLIB_NAPI_ARGV_INT64( env, offsetX, argv, 3 );
STDLIB_NAPI_ARGV_INT64( env, offsetY, argv, 6 );
STDLIB_NAPI_ARGV_INT64( env, offsetY, argv, 6 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 4 );
stdlib_strided_dcuminabs_ndarray( N, X, strideX, offsetX, Y, strideY, offsetY );
API_SUFFIX(stdlib_strided_dcuminabs_ndarray)( N, X, strideX, offsetX, Y, strideY, offsetY );
return NULL;
}

Expand Down
5 changes: 3 additions & 2 deletions lib/node_modules/@stdlib/stats/base/scumax/src/addon.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
#include "stdlib/napi/export.h"
#include "stdlib/napi/argv.h"
#include "stdlib/napi/argv_int64.h"
#include "stdlib/blas/base/shared.h"
#include "stdlib/napi/argv_strided_float32array.h"
#include <node_api.h>

Expand All @@ -37,7 +38,7 @@ static napi_value addon( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 4 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT32ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT32ARRAY( env, Y, N, strideY, argv, 3 );
stdlib_strided_scumax( N, X, strideX, Y, strideY );
API_SUFFIX(stdlib_strided_scumax)( N, X, strideX, Y, strideY );
return NULL;
}

Expand All @@ -57,7 +58,7 @@ static napi_value addon_method( napi_env env, napi_callback_info info ) {
STDLIB_NAPI_ARGV_INT64( env, offsetY, argv, 6 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT32ARRAY( env, X, N, strideX, argv, 1 );
STDLIB_NAPI_ARGV_STRIDED_FLOAT32ARRAY( env, Y, N, strideY, argv, 4 );
stdlib_strided_scumax_ndarray( N, X, strideX, offsetX, Y, strideY, offsetY );
API_SUFFIX(stdlib_strided_scumax_ndarray)( N, X, strideX, offsetX, Y, strideY, offsetY );
return NULL;
}

Expand Down

1 comment on commit 99378ce

@stdlib-bot
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coverage Report

Package Statements Branches Functions Lines
stats/base/dcumax $\color{green}404/404$
$\color{green}+100.00\%$
$\color{green}27/27$
$\color{green}+100.00\%$
$\color{green}4/4$
$\color{green}+100.00\%$
$\color{green}404/404$
$\color{green}+100.00\%$
stats/base/dcumaxabs $\color{green}405/405$
$\color{green}+100.00\%$
$\color{green}25/25$
$\color{green}+100.00\%$
$\color{green}4/4$
$\color{green}+100.00\%$
$\color{green}405/405$
$\color{green}+100.00\%$
stats/base/dcumin $\color{green}404/404$
$\color{green}+100.00\%$
$\color{green}27/27$
$\color{green}+100.00\%$
$\color{green}4/4$
$\color{green}+100.00\%$
$\color{green}404/404$
$\color{green}+100.00\%$
stats/base/dcuminabs $\color{green}407/407$
$\color{green}+100.00\%$
$\color{green}25/25$
$\color{green}+100.00\%$
$\color{green}4/4$
$\color{green}+100.00\%$
$\color{green}407/407$
$\color{green}+100.00\%$
stats/base/scumax $\color{green}404/404$
$\color{green}+100.00\%$
$\color{green}27/27$
$\color{green}+100.00\%$
$\color{green}4/4$
$\color{green}+100.00\%$
$\color{green}404/404$
$\color{green}+100.00\%$

The above coverage report was generated for the changes in this push.

Please sign in to comment.