diff --git a/lib/node_modules/@stdlib/math/base/special/pow/manifest.json b/lib/node_modules/@stdlib/math/base/special/pow/manifest.json index 317d41fb746c..2df287eab1b0 100644 --- a/lib/node_modules/@stdlib/math/base/special/pow/manifest.json +++ b/lib/node_modules/@stdlib/math/base/special/pow/manifest.json @@ -55,7 +55,8 @@ "@stdlib/math/base/assert/is-integer", "@stdlib/math/base/special/sqrt", "@stdlib/number/float64/base/to-words", - "@stdlib/constants/float64/num-high-word-significand-bits" + "@stdlib/constants/float64/num-high-word-significand-bits", + "@stdlib/constants/float64/nan" ] }, { @@ -87,7 +88,8 @@ "@stdlib/math/base/assert/is-integer", "@stdlib/math/base/special/sqrt", "@stdlib/number/float64/base/to-words", - "@stdlib/constants/float64/num-high-word-significand-bits" + "@stdlib/constants/float64/num-high-word-significand-bits", + "@stdlib/constants/float64/nan" ] }, { @@ -119,7 +121,8 @@ "@stdlib/math/base/assert/is-integer", "@stdlib/math/base/special/sqrt", "@stdlib/number/float64/base/to-words", - "@stdlib/constants/float64/num-high-word-significand-bits" + "@stdlib/constants/float64/num-high-word-significand-bits", + "@stdlib/constants/float64/nan" ] } ] diff --git a/lib/node_modules/@stdlib/math/base/special/pow/src/main.c b/lib/node_modules/@stdlib/math/base/special/pow/src/main.c index ed38e0727570..b6a131f614fa 100644 --- a/lib/node_modules/@stdlib/math/base/special/pow/src/main.c +++ b/lib/node_modules/@stdlib/math/base/special/pow/src/main.c @@ -44,6 +44,7 @@ #include "stdlib/constants/float64/ln_two.h" #include "stdlib/constants/float64/exponent_bias.h" #include "stdlib/constants/float64/high_word_significand_mask.h" +#include "stdlib/constants/float64/nan.h" #include "stdlib/math/base/assert/is_nan.h" #include "stdlib/math/base/assert/is_infinite.h" #include "stdlib/math/base/assert/is_integer.h" @@ -209,7 +210,7 @@ static double polyval_p( const double x ) { */ static double y_is_infinite( const double x, const double y ) { if ( x == -1.0 ) { - return 0.0 / 0.0; // NaN + return STDLIB_CONSTANT_FLOAT64_NAN; } if ( x == 1.0 ) { return 1.0; @@ -569,7 +570,7 @@ double stdlib_base_pow( const double x, const double y ) { xc = x; if ( stdlib_base_is_nan( xc ) || stdlib_base_is_nan( y ) ) { - return 0.0/0.0; // NaN + return STDLIB_CONSTANT_FLOAT64_NAN; } // Split `y` into high and low words: @@ -639,7 +640,7 @@ double stdlib_base_pow( const double x, const double y ) { stdlib_base_is_integer( y ) == false ) { // Signal NaN... - return 0.0/0.0; + return STDLIB_CONSTANT_FLOAT64_NAN; } ax = stdlib_base_abs( x );