From 508e136a86da4057ae47c9d8ab0dea2398d83703 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 5 May 2026 13:19:16 +0000 Subject: [PATCH 1/2] fix: add missing API_SUFFIX wrappers to internal `_ndarray` calls Propagates fixes from a65e1fd9f ("fix: add suffix wrappers and replace inline NaN literal") and 851675024 ("fix: add missing suffix wrappers") to sibling packages whose `API_SUFFIX`-wrapped routines call other `API_SUFFIX`-wrapped strided routines without the macro. Affected packages: - `blas/ext/base/snansumpw` - `blas/ext/base/ssumpw` - `stats/strided/dsempn` - `stats/strided/dsmeanpn` - `stats/strided/dsvariancepn` - `stats/strided/dztest` - `stats/strided/dztest2` - `stats/strided/sztest` - `stats/strided/sztest2` --- lib/node_modules/@stdlib/blas/ext/base/snansumpw/src/main.c | 2 +- lib/node_modules/@stdlib/blas/ext/base/ssumpw/src/main.c | 2 +- lib/node_modules/@stdlib/stats/strided/dsempn/src/main.c | 2 +- lib/node_modules/@stdlib/stats/strided/dsmeanpn/src/main.c | 4 ++-- .../@stdlib/stats/strided/dsvariancepn/src/main.c | 2 +- lib/node_modules/@stdlib/stats/strided/dztest/src/main.c | 2 +- lib/node_modules/@stdlib/stats/strided/dztest2/src/main.c | 4 ++-- lib/node_modules/@stdlib/stats/strided/sztest/src/main.c | 2 +- lib/node_modules/@stdlib/stats/strided/sztest2/src/main.c | 4 ++-- 9 files changed, 12 insertions(+), 12 deletions(-) diff --git a/lib/node_modules/@stdlib/blas/ext/base/snansumpw/src/main.c b/lib/node_modules/@stdlib/blas/ext/base/snansumpw/src/main.c index fe2fe34f8f4e..87c3979f7ff8 100644 --- a/lib/node_modules/@stdlib/blas/ext/base/snansumpw/src/main.c +++ b/lib/node_modules/@stdlib/blas/ext/base/snansumpw/src/main.c @@ -149,5 +149,5 @@ float API_SUFFIX(stdlib_strided_snansumpw_ndarray)( const CBLAS_INT N, const flo // Recurse by dividing by two, but avoiding non-multiples of unroll factor... n = N / 2; n -= n % 8; - return stdlib_strided_snansumpw_ndarray( n, X, strideX, ix ) + stdlib_strided_snansumpw_ndarray( N-n, X, strideX, ix+(n*strideX) ); + return API_SUFFIX(stdlib_strided_snansumpw_ndarray)( n, X, strideX, ix ) + API_SUFFIX(stdlib_strided_snansumpw_ndarray)( N-n, X, strideX, ix+(n*strideX) ); } diff --git a/lib/node_modules/@stdlib/blas/ext/base/ssumpw/src/main.c b/lib/node_modules/@stdlib/blas/ext/base/ssumpw/src/main.c index 0e0352b31784..266d406566f7 100644 --- a/lib/node_modules/@stdlib/blas/ext/base/ssumpw/src/main.c +++ b/lib/node_modules/@stdlib/blas/ext/base/ssumpw/src/main.c @@ -128,5 +128,5 @@ float API_SUFFIX(stdlib_strided_ssumpw_ndarray)( const CBLAS_INT N, const float // Recurse by dividing by two, but avoiding non-multiples of unroll factor... n = N / 2; n -= n % 8; - return stdlib_strided_ssumpw_ndarray( n, X, strideX, ix ) + stdlib_strided_ssumpw_ndarray( N-n, X, strideX, ix+(n*strideX) ); + return API_SUFFIX(stdlib_strided_ssumpw_ndarray)( n, X, strideX, ix ) + API_SUFFIX(stdlib_strided_ssumpw_ndarray)( N-n, X, strideX, ix+(n*strideX) ); } diff --git a/lib/node_modules/@stdlib/stats/strided/dsempn/src/main.c b/lib/node_modules/@stdlib/stats/strided/dsempn/src/main.c index f18d6976370e..fe21a4e732c5 100644 --- a/lib/node_modules/@stdlib/stats/strided/dsempn/src/main.c +++ b/lib/node_modules/@stdlib/stats/strided/dsempn/src/main.c @@ -47,5 +47,5 @@ double API_SUFFIX(stdlib_strided_dsempn)( const CBLAS_INT N, const double correc * @return output value */ double API_SUFFIX(stdlib_strided_dsempn_ndarray)( const CBLAS_INT N, const double correction, const double *X, const CBLAS_INT strideX, const CBLAS_INT offsetX ) { - return stdlib_base_sqrt( stdlib_strided_dvariancepn_ndarray( N, correction, X, strideX, offsetX ) / (double)N ); + return stdlib_base_sqrt( API_SUFFIX(stdlib_strided_dvariancepn_ndarray)( N, correction, X, strideX, offsetX ) / (double)N ); } diff --git a/lib/node_modules/@stdlib/stats/strided/dsmeanpn/src/main.c b/lib/node_modules/@stdlib/stats/strided/dsmeanpn/src/main.c index 59d9e863413d..b28bbf5cfc2d 100644 --- a/lib/node_modules/@stdlib/stats/strided/dsmeanpn/src/main.c +++ b/lib/node_modules/@stdlib/stats/strided/dsmeanpn/src/main.c @@ -67,11 +67,11 @@ double API_SUFFIX(stdlib_strided_dsmeanpn_ndarray)( const CBLAS_INT N, const flo dN = (double)N; // Compute an estimate for the mean: - mu = stdlib_strided_dssum_ndarray( N, X, strideX, offsetX ); + mu = API_SUFFIX(stdlib_strided_dssum_ndarray)( N, X, strideX, offsetX ); mu /= dN; // Compute an error term: - c = stdlib_strided_dsapxsum_ndarray( N, -mu, X, strideX, offsetX ); + c = API_SUFFIX(stdlib_strided_dsapxsum_ndarray)( N, -mu, X, strideX, offsetX ); c /= dN; return mu + c; diff --git a/lib/node_modules/@stdlib/stats/strided/dsvariancepn/src/main.c b/lib/node_modules/@stdlib/stats/strided/dsvariancepn/src/main.c index cc288e008803..09612e1d30a8 100644 --- a/lib/node_modules/@stdlib/stats/strided/dsvariancepn/src/main.c +++ b/lib/node_modules/@stdlib/stats/strided/dsvariancepn/src/main.c @@ -73,7 +73,7 @@ double API_SUFFIX(stdlib_strided_dsvariancepn_ndarray)( const CBLAS_INT N, const return 0.0; } // Compute an estimate for the mean: - mu = stdlib_strided_dssum_ndarray( N, X, strideX, offsetX ) / dN; + mu = API_SUFFIX(stdlib_strided_dssum_ndarray)( N, X, strideX, offsetX ) / dN; // Compute the variance... ix = offsetX; diff --git a/lib/node_modules/@stdlib/stats/strided/dztest/src/main.c b/lib/node_modules/@stdlib/stats/strided/dztest/src/main.c index d5e0e24c88d0..6e039c4441f5 100644 --- a/lib/node_modules/@stdlib/stats/strided/dztest/src/main.c +++ b/lib/node_modules/@stdlib/stats/strided/dztest/src/main.c @@ -98,7 +98,7 @@ void API_SUFFIX(stdlib_strided_dztest_ndarray)( const CBLAS_INT N, const enum ST stderr = sigma / stdlib_base_sqrt( (double)N ); // Compute the arithmetic mean of the input array: - xmean = stdlib_strided_dmean_ndarray( N, X, strideX, offsetX ); + xmean = API_SUFFIX(stdlib_strided_dmean_ndarray)( N, X, strideX, offsetX ); // Compute the test statistic (i.e., the z-score, which is the distance of the sample mean from the population mean in units of standard error): stat = ( xmean - mu ) / stderr; diff --git a/lib/node_modules/@stdlib/stats/strided/dztest2/src/main.c b/lib/node_modules/@stdlib/stats/strided/dztest2/src/main.c index bd17db15827c..939859322b0e 100644 --- a/lib/node_modules/@stdlib/stats/strided/dztest2/src/main.c +++ b/lib/node_modules/@stdlib/stats/strided/dztest2/src/main.c @@ -117,8 +117,8 @@ void API_SUFFIX(stdlib_strided_dztest2_ndarray)( const CBLAS_INT NX, const CBLAS stderr = stdlib_base_sqrt( ( xvar / (double)NX ) + ( yvar / (double)NY ) ); // Compute the arithmetic means of the input arrays: - xmean = stdlib_strided_dmean_ndarray( NX, X, strideX, offsetX ); - ymean = stdlib_strided_dmean_ndarray( NY, Y, strideY, offsetY ); + xmean = API_SUFFIX(stdlib_strided_dmean_ndarray)( NX, X, strideX, offsetX ); + ymean = API_SUFFIX(stdlib_strided_dmean_ndarray)( NY, Y, strideY, offsetY ); // Compute the test statistic (i.e., the z-score, which is the standardized difference between the sample means of x and y, adjusted by the hypothesized difference, in units of the standard error): stat = ( xmean - ymean - diff ) / stderr; diff --git a/lib/node_modules/@stdlib/stats/strided/sztest/src/main.c b/lib/node_modules/@stdlib/stats/strided/sztest/src/main.c index 760b867d6617..1fa98e6fa47b 100644 --- a/lib/node_modules/@stdlib/stats/strided/sztest/src/main.c +++ b/lib/node_modules/@stdlib/stats/strided/sztest/src/main.c @@ -98,7 +98,7 @@ void API_SUFFIX(stdlib_strided_sztest_ndarray)( const CBLAS_INT N, const enum ST stderr = sigma / stdlib_base_sqrt( (double)N ); // note: intentionally evaluated in double-precision to avoid `N` exceeding max safe float32 integer // Compute the arithmetic mean of the input array: - xmean = stdlib_strided_smean_ndarray( N, X, strideX, offsetX ); + xmean = API_SUFFIX(stdlib_strided_smean_ndarray)( N, X, strideX, offsetX ); // Compute the test statistic (i.e., the z-score, which is the distance of the sample mean from the population mean in units of standard error): stat = ( (double)xmean - (double)mu ) / stderr; diff --git a/lib/node_modules/@stdlib/stats/strided/sztest2/src/main.c b/lib/node_modules/@stdlib/stats/strided/sztest2/src/main.c index cf4242e79d71..e118d2a80d72 100644 --- a/lib/node_modules/@stdlib/stats/strided/sztest2/src/main.c +++ b/lib/node_modules/@stdlib/stats/strided/sztest2/src/main.c @@ -117,8 +117,8 @@ void API_SUFFIX(stdlib_strided_sztest2_ndarray)( const CBLAS_INT NX, const CBLAS stderr = stdlib_base_sqrt( ( xvar / (double)NX ) + ( yvar / (double)NY ) ); // note: intentionally evaluated in double-precision to avoid `NX` and `NY` exceeding max safe float32 integer // Compute the arithmetic means of the input arrays: - xmean = stdlib_strided_smean_ndarray( NX, X, strideX, offsetX ); - ymean = stdlib_strided_smean_ndarray( NY, Y, strideY, offsetY ); + xmean = API_SUFFIX(stdlib_strided_smean_ndarray)( NX, X, strideX, offsetX ); + ymean = API_SUFFIX(stdlib_strided_smean_ndarray)( NY, Y, strideY, offsetY ); // Compute the test statistic (i.e., the z-score, which is the standardized difference between the sample means of x and y, adjusted by the hypothesized difference, in units of the standard error): stat = ( (double)xmean - (double)ymean - (double)diff ) / stderr; From 49b8ea8491b2820e02d8cd1d54d2c51658f81a58 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 5 May 2026 13:19:26 +0000 Subject: [PATCH 2/2] docs: align test descriptions with canonical complex-number wording Propagates fixes from b0713eab3 ("docs: update descriptions to be consistent with elsewhere in project") and a3a5677b7 ("docs: follow-up fixes") to test descriptions that still use the reverse word order "complex {single,double}-precision floating-point". Project canonical wording is "{single,double}-precision complex floating-point", which matches the JSDoc in each package's `lib/main.js`. Affected packages: - `complex/float32/base/assert/is-almost-equal` - `complex/float32/base/assert/is-almost-same-value` - `complex/float64/base/assert/is-almost-equal` - `complex/float64/base/assert/is-almost-same-value` --- .../float32/base/assert/is-almost-equal/test/test.js | 6 +++--- .../float32/base/assert/is-almost-same-value/test/test.js | 6 +++--- .../float64/base/assert/is-almost-equal/test/test.js | 6 +++--- .../float64/base/assert/is-almost-same-value/test/test.js | 6 +++--- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-equal/test/test.js b/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-equal/test/test.js index 441f1dfa4476..fd75f277ca4f 100644 --- a/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-equal/test/test.js +++ b/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-equal/test/test.js @@ -55,7 +55,7 @@ tape( 'the function returns `false` if provided `NaN` as either real or imaginar t.end(); }); -tape( 'the function returns `true` if provided two complex single-precision floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two single-precision complex floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { var z1; var z2; @@ -77,7 +77,7 @@ tape( 'the function returns `true` if provided two complex single-precision floa t.end(); }); -tape( 'the function returns `true` if provided two complex single-precision floating-point numbers which are approximately equal within a specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two single-precision complex floating-point numbers which are approximately equal within a specified number of ULPs', function test( t ) { var z1; var z2; @@ -93,7 +93,7 @@ tape( 'the function returns `true` if provided two complex single-precision floa t.end(); }); -tape( 'the function returns `false` if provided two complex single-precision floating-point numbers which are not approximately equal within a specified number of ULPs', function test( t ) { +tape( 'the function returns `false` if provided two single-precision complex floating-point numbers which are not approximately equal within a specified number of ULPs', function test( t ) { var z1; var z2; diff --git a/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-same-value/test/test.js b/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-same-value/test/test.js index a58deed176c1..19458bef99eb 100644 --- a/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-same-value/test/test.js +++ b/lib/node_modules/@stdlib/complex/float32/base/assert/is-almost-same-value/test/test.js @@ -55,7 +55,7 @@ tape( 'the function treats `NaNs` as the same value', function test( t ) { t.end(); }); -tape( 'the function returns `true` if provided two complex single-precision floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two single-precision complex floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { var z1; var z2; @@ -77,7 +77,7 @@ tape( 'the function returns `true` if provided two complex single-precision floa t.end(); }); -tape( 'the function returns `true` if provided two complex single-precision floating-point numbers which are approximately the same value within a specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two single-precision complex floating-point numbers which are approximately the same value within a specified number of ULPs', function test( t ) { var z1; var z2; @@ -93,7 +93,7 @@ tape( 'the function returns `true` if provided two complex single-precision floa t.end(); }); -tape( 'the function returns `false` if provided two complex single-precision floating-point numbers which are not approximately the same value within a specified number of ULPs', function test( t ) { +tape( 'the function returns `false` if provided two single-precision complex floating-point numbers which are not approximately the same value within a specified number of ULPs', function test( t ) { var z1; var z2; diff --git a/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-equal/test/test.js b/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-equal/test/test.js index 9efbfba3c8ba..378e5c0cfeb4 100644 --- a/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-equal/test/test.js +++ b/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-equal/test/test.js @@ -55,7 +55,7 @@ tape( 'the function returns `false` if provided `NaN` as either real or imaginar t.end(); }); -tape( 'the function returns `true` if provided two complex double-precision floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two double-precision complex floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { var z1; var z2; @@ -77,7 +77,7 @@ tape( 'the function returns `true` if provided two complex double-precision floa t.end(); }); -tape( 'the function returns `true` if provided two complex double-precision floating-point numbers which are approximately equal within a specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two double-precision complex floating-point numbers which are approximately equal within a specified number of ULPs', function test( t ) { var z1; var z2; @@ -93,7 +93,7 @@ tape( 'the function returns `true` if provided two complex double-precision floa t.end(); }); -tape( 'the function returns `false` if provided two complex double-precision floating-point numbers which are not approximately equal within a specified number of ULPs', function test( t ) { +tape( 'the function returns `false` if provided two double-precision complex floating-point numbers which are not approximately equal within a specified number of ULPs', function test( t ) { var z1; var z2; diff --git a/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-same-value/test/test.js b/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-same-value/test/test.js index 3d2b0c36d8bd..84f5b2200e2a 100644 --- a/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-same-value/test/test.js +++ b/lib/node_modules/@stdlib/complex/float64/base/assert/is-almost-same-value/test/test.js @@ -55,7 +55,7 @@ tape( 'the function treats `NaNs` as the same value', function test( t ) { t.end(); }); -tape( 'the function returns `true` if provided two complex double-precision floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two double-precision complex floating-point numbers which are the same value irrespective of the specified number of ULPs', function test( t ) { var z1; var z2; @@ -77,7 +77,7 @@ tape( 'the function returns `true` if provided two complex double-precision floa t.end(); }); -tape( 'the function returns `true` if provided two complex double-precision floating-point numbers which are approximately the same value within a specified number of ULPs', function test( t ) { +tape( 'the function returns `true` if provided two double-precision complex floating-point numbers which are approximately the same value within a specified number of ULPs', function test( t ) { var z1; var z2; @@ -93,7 +93,7 @@ tape( 'the function returns `true` if provided two complex double-precision floa t.end(); }); -tape( 'the function returns `false` if provided two complex double-precision floating-point numbers which are not approximately the same value within a specified number of ULPs', function test( t ) { +tape( 'the function returns `false` if provided two double-precision complex floating-point numbers which are not approximately the same value within a specified number of ULPs', function test( t ) { var z1; var z2;