From 921ff3029b87f51f701e71cdea9721fb1eafcb53 Mon Sep 17 00:00:00 2001 From: usa Date: Mon, 23 May 2016 06:55:48 +0000 Subject: * ext/bigdecimal/bigdecimal.c (isfinite): isfinite does not always exist. fixed build error on Windows itroduced at r55123. I found that more complex definition of isfinite in numeric.c. But it's unused because it inplicitly checks not defined _WIN32. I don't know why the code do that. IMO, the definition of isfinite should be put at missing.h. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55129 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/bigdecimal/bigdecimal.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'ext/bigdecimal') diff --git a/ext/bigdecimal/bigdecimal.c b/ext/bigdecimal/bigdecimal.c index 3ccad9a508..1354242b0b 100644 --- a/ext/bigdecimal/bigdecimal.c +++ b/ext/bigdecimal/bigdecimal.c @@ -30,6 +30,10 @@ #include #endif +#if !defined(HAVE_ISFINITE) && defined(HAVE_FINITE) +# define isfinite(x) finite(x) +#endif + /* #define ENABLE_NUMERIC_STRING */ #define MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, min, max) ( \ -- cgit v1.2.3