[前][次][番号順一覧][スレッド一覧]

ruby-changes:42429

From: nobu <ko1@a...>
Date: Wed, 6 Apr 2016 21:44:57 +0900 (JST)
Subject: [ruby-changes:42429] nobu:r54503 (trunk): configure.in: fix lgamma_r condition

nobu	2016-04-06 22:41:33 +0900 (Wed, 06 Apr 2016)

  New Revision: 54503

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=54503

  Log:
    configure.in: fix lgamma_r condition
    
    * configure.in (rb_cv_lgamma_r_m0): fix the condition for
      lgamma_r(-0.0).  [Bug #12249]

  Modified files:
    trunk/ChangeLog
    trunk/configure.in
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 54502)
+++ ChangeLog	(revision 54503)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Wed Apr  6 22:41:31 2016  Nobuyoshi Nakada  <nobu@r...>
+
+	* configure.in (rb_cv_lgamma_r_m0): fix the condition for
+	  lgamma_r(-0.0).  [Bug #12249]
+
 Wed Apr  6 17:38:42 2016  NAKAMURA Usaku  <usa@r...>
 
 	* tool/downloader.rb (RubyGems.download): follow the change of the
Index: configure.in
===================================================================
--- configure.in	(revision 54502)
+++ configure.in	(revision 54503)
@@ -2516,8 +2516,11 @@ int https://github.com/ruby/ruby/blob/trunk/configure.in#L2516
 main(int argc, char **argv)
 {
     int sign;
+    double x = lgamma_r(-0.0, &sign);
 
-    if (lgamma_r(-0.0, &sign) >= 0) return EXIT_FAILURE;
+    /* should be [+inf, -1] */
+    if (x <= 0) return EXIT_FAILURE;
+    if (!isinf(x)) return EXIT_FAILURE;
     if (sign != -1) return EXIT_FAILURE;
     return EXIT_SUCCESS;
 }

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]