diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2014-09-22 10:49:58 -0400 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2014-09-26 17:04:51 -0400 |
commit | 7c7d45f111f77c38375e9d5a8f89a4a7b17fad21 (patch) | |
tree | a137bec9a0c938ffa8f3b4e85a0a7e3780d1de70 /ext | |
parent | bcd8bfa93f638d0b45800be6431b3bd9b54e1af6 (diff) | |
download | perl-7c7d45f111f77c38375e9d5a8f89a4a7b17fad21.tar.gz |
Tru64 nan() function broken.
Exists in libm, but no proto or man page, probably for a reason.
Return values seem to be garbage, or at least not NaN.
Also add a todo for the nan() payload.
Diffstat (limited to 'ext')
-rw-r--r-- | ext/POSIX/POSIX.xs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/ext/POSIX/POSIX.xs b/ext/POSIX/POSIX.xs index 0de280ab82..fff04a0cee 100644 --- a/ext/POSIX/POSIX.xs +++ b/ext/POSIX/POSIX.xs @@ -480,6 +480,7 @@ # undef c99_isunordered # undef c99_lrint # undef c99_lround +# undef c99_nan /* in libm, but seems broken (no proto, either) */ # undef c99_nearbyint # undef c99_nexttoward # undef c99_remquo @@ -2509,11 +2510,12 @@ nan(s = 0) CODE: #ifdef c99_nan RETVAL = c99_nan(s ? s : ""); -#else +#elif defined(NV_NAN) + /* XXX if s != NULL, warn about unused argument, + * or implement the nan payload setting. */ RETVAL = NV_NAN; -# ifndef NV_NAN +#else not_here("nan"); -# endif #endif OUTPUT: RETVAL |