mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* missing/isinf.c (isinf): don't define is the macro is defined.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13915 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
fd3ef45a42
commit
093fe3b839
2 changed files with 11 additions and 0 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
Wed Nov 14 01:52:59 2007 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
|
* missing/isinf.c (isinf): don't define is the macro is defined.
|
||||||
|
|
||||||
Wed Nov 14 01:34:42 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Wed Nov 14 01:34:42 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* numeric.c (round): fallback definition.
|
* numeric.c (round): fallback definition.
|
||||||
|
|
|
@ -27,11 +27,18 @@ isinf(double n)
|
||||||
#include <ieeefp.h>
|
#include <ieeefp.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
* isinf may be provided only as a macro.
|
||||||
|
* ex. HP-UX, Solaris 10
|
||||||
|
* http://www.gnu.org/software/automake/manual/autoconf/Function-Portability.html
|
||||||
|
*/
|
||||||
|
#ifndef isinf
|
||||||
int
|
int
|
||||||
isinf(double n)
|
isinf(double n)
|
||||||
{
|
{
|
||||||
return (!finite(n) && !isnan(n));
|
return (!finite(n) && !isnan(n));
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue