https://bugs.ruby-lang.org/
https://bugs.ruby-lang.org/favicon.ico?1711330511
2010-08-01T22:09:31Z
Ruby Issue Tracking System
Ruby master - Bug #3640: BigDecimal#hash returns -2 for all negative finite numbers.
https://bugs.ruby-lang.org/issues/3640?journal_id=12647
2010-08-01T22:09:31Z
mrkn (Kenta Murata)
muraken@gmail.com
<ul></ul><p>=begin<br>
Sorry, the code I've shown is improper.</p>
<p>The proper code is here:</p>
<p>$ ruby -rbigdecimal -ve '<br>
a = []<br>
b = BigDecimal("-1")<br>
10.times { a << (b *= 10).hash }<br>
p a'<br>
ruby 1.9.3dev (2010-08-01 trunk 28823) [x86_64-darwin10.4.0]<br>
[-2, -2, -2, -2, -2, -2, -2, -2, -2, -2]</p>
<p>=end</p>
Ruby master - Bug #3640: BigDecimal#hash returns -2 for all negative finite numbers.
https://bugs.ruby-lang.org/issues/3640?journal_id=13046
2010-08-27T14:02:19Z
mrkn (Kenta Murata)
muraken@gmail.com
<ul><li><strong>Status</strong> changed from <i>Assigned</i> to <i>Closed</i></li></ul><p>=begin<br>
This bug fixed by r28825.</p>
<p>=end</p>