ruby-changes:44528
From: shugo <ko1@a...>
Date: Sun, 6 Nov 2016 00:02:21 +0900 (JST)
Subject: [ruby-changes:44528] shugo:r56601 (trunk): * numeric.c (rb_int_round): cast to SIGNED_VALUE to suppress
shugo 2016-11-06 00:02:17 +0900 (Sun, 06 Nov 2016) New Revision: 56601 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=56601 Log: * numeric.c (rb_int_round): cast to SIGNED_VALUE to suppress warnings by -Wsign-compare. Modified files: trunk/ChangeLog trunk/numeric.c Index: ChangeLog =================================================================== --- ChangeLog (revision 56600) +++ ChangeLog (revision 56601) @@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Sat Nov 5 23:58:32 2016 Shugo Maeda <shugo@r...> + + * numeric.c (rb_int_round): cast to SIGNED_VALUE to suppress + warnings by -Wsign-compare. + Sat Nov 5 23:48:27 2016 NARUSE, Yui <naruse@r...> * file.c (rb_home_dir_of): convert given username into filesystem Index: numeric.c =================================================================== --- numeric.c (revision 56600) +++ numeric.c (revision 56601) @@ -2075,7 +2075,7 @@ rb_int_round(VALUE num, int ndigits, enu https://github.com/ruby/ruby/blob/trunk/numeric.c#L2075 (FIXNUM_ZERO_P(r) && ROUND_TO(mode, int_pos_p(num), - int_odd_p(rb_int_idiv(n, f))))) { + (SIGNED_VALUE) int_odd_p(rb_int_idiv(n, f))))) { n = rb_int_plus(n, f); } return n; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/