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

ruby-changes:42150

From: usa <ko1@a...>
Date: Tue, 22 Mar 2016 10:25:04 +0900 (JST)
Subject: [ruby-changes:42150] usa:r54224 (trunk): * time.c (divmodv): void function never returns any value.

usa	2016-03-22 10:24:55 +0900 (Tue, 22 Mar 2016)

  New Revision: 54224

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

  Log:
    * time.c (divmodv): void function never returns any value.

  Modified files:
    trunk/ChangeLog
    trunk/time.c
Index: time.c
===================================================================
--- time.c	(revision 54223)
+++ time.c	(revision 54224)
@@ -148,7 +148,10 @@ divmodv(VALUE n, VALUE d, VALUE *q, VALU https://github.com/ruby/ruby/blob/trunk/time.c#L148
     VALUE tmp, ary;
     if (FIXNUM_P(d)) {
 	if (FIX2LONG(d) == 0) rb_num_zerodiv();
-	if (FIXNUM_P(n)) return rb_fix_divmod_fix(n, d, q, r);
+	if (FIXNUM_P(n)) {
+	    rb_fix_divmod_fix(n, d, q, r);
+	    return;
+	}
     }
     tmp = rb_funcall(n, id_divmod, 1, d);
     ary = rb_check_array_type(tmp);
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 54223)
+++ ChangeLog	(revision 54224)
@@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Tue Mar 22 10:24:04 2016  NAKAMURA Usaku  <usa@r...>
+
+	* time.c (divmodv): void function never returns any value.
+
 Tue Mar 22 10:11:01 2016  Nobuyoshi Nakada  <nobu@r...>
 
 	* test/lib/test/unit.rb (Test::Unit::StatusLine#failed): print

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

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