ruby-changes:4276
From: ko1@a...
Date: Fri, 14 Mar 2008 01:43:44 +0900 (JST)
Subject: [ruby-changes:4276] matz - Ruby:r15766 (trunk): * test/ruby/test_numeric.rb (TestNumeric::test_num2long): bit-and
matz 2008-03-14 01:38:56 +0900 (Fri, 14 Mar 2008) New Revision: 15766 Modified files: trunk/ChangeLog trunk/test/ruby/test_numeric.rb Log: * test/ruby/test_numeric.rb (TestNumeric::test_num2long): bit-and should not raise RangeError. http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/ChangeLog?r1=15766&r2=15765&diff_format=u http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/test/ruby/test_numeric.rb?r1=15766&r2=15765&diff_format=u Index: ChangeLog =================================================================== --- ChangeLog (revision 15765) +++ ChangeLog (revision 15766) @@ -17,6 +17,9 @@ * enum.c (zip_ary): wrong boundary condition. + * test/ruby/test_numeric.rb (TestNumeric::test_num2long): bit-and + should not raise RangeError. + Thu Mar 13 03:12:48 2008 Yukihiro Matsumoto <matz@r...> * lib/irb/cmd/help.rb: should be updated for new ri structure. Index: test/ruby/test_numeric.rb =================================================================== --- test/ruby/test_numeric.rb (revision 15765) +++ test/ruby/test_numeric.rb (revision 15766) @@ -211,10 +211,8 @@ def test_num2long assert_raise(TypeError) { 1 & nil } assert_equal(1, 1 & 1.0) - assert_raise(RangeError) do - 1 & 2147483648.0 - 1 & 9223372036854777856.0 - end + assert_equal(0, 1 & 2147483648.0) + assert_equal(0, 1 & 9223372036854777856.0) o = Object.new def o.to_int; 1; end assert_equal(1, 1 & o) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/