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

ruby-changes:6299

From: shyouhei <ko1@a...>
Date: Wed, 2 Jul 2008 19:05:15 +0900 (JST)
Subject: [ruby-changes:6299] Ruby:r17813 (ruby_1_8_7): merge revision(s) 17749:17752:

shyouhei	2008-07-02 19:05:01 +0900 (Wed, 02 Jul 2008)

  New Revision: 17813

  Modified files:
    branches/ruby_1_8_7/ChangeLog
    branches/ruby_1_8_7/numeric.c
    branches/ruby_1_8_7/version.h

  Log:
    merge revision(s) 17749:17752:
    * numeric.c (num_coerce): call rb_Float(x) first.  don't depend on
      evaluation order of function arguments.



  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=17813

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_7/ChangeLog?r1=17813&r2=17812&diff_format=u
  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_7/numeric.c?r1=17813&r2=17812&diff_format=u
  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_7/version.h?r1=17813&r2=17812&diff_format=u

Index: ruby_1_8_7/numeric.c
===================================================================
--- ruby_1_8_7/numeric.c	(revision 17812)
+++ ruby_1_8_7/numeric.c	(revision 17813)
@@ -121,7 +121,9 @@
 {
     if (CLASS_OF(x) == CLASS_OF(y))
 	return rb_assoc_new(y, x);
-    return rb_assoc_new(rb_Float(y), rb_Float(x));
+    x = rb_Float(x);
+    y = rb_Float(y);
+    return rb_assoc_new(y, x);
 }
 
 static VALUE
Index: ruby_1_8_7/ChangeLog
===================================================================
--- ruby_1_8_7/ChangeLog	(revision 17812)
+++ ruby_1_8_7/ChangeLog	(revision 17813)
@@ -1,3 +1,8 @@
+Wed Jul  2 19:03:37 2008  Tanaka Akira  <akr@f...>
+
+	* numeric.c (num_coerce): call rb_Float(x) first.  don't depend on
+	  evaluation order of function arguments.
+
 Wed Jul  2 18:57:19 2008  Yukihiro Matsumoto  <matz@r...>
 
 	* ext/syslog/syslog.c (syslog_write): syslog operations should be
Index: ruby_1_8_7/version.h
===================================================================
--- ruby_1_8_7/version.h	(revision 17812)
+++ ruby_1_8_7/version.h	(revision 17813)
@@ -2,7 +2,7 @@
 #define RUBY_RELEASE_DATE "2008-07-02"
 #define RUBY_VERSION_CODE 187
 #define RUBY_RELEASE_CODE 20080702
-#define RUBY_PATCHLEVEL 44
+#define RUBY_PATCHLEVEL 45
 
 #define RUBY_VERSION_MAJOR 1
 #define RUBY_VERSION_MINOR 8

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

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