[#78633] ruby/spec needs help from CRuby committers — Benoit Daloze <eregontp@...>
Currently, ruby/spec is maintained mostly by individuals and enjoys the
13 messages
2016/12/13
[#78963] Re: ruby/spec needs help from CRuby committers
— Urabe Shyouhei <shyouhei@...>
2017/01/04
I did ask attendees of last developer meeting to join this
[#78642] Re: ruby/spec needs help from CRuby committers
— Eric Wong <normalperson@...>
2016/12/14
Benoit Daloze <eregontp@gmail.com> wrote:
[ruby-core:78572] [Ruby trunk Bug#10286][Closed] BigDecimal - inconsistency with other numeric classes
From:
muraken@...
Date:
2016-12-10 07:13:24 UTC
List:
ruby-core #78572
Issue #10286 has been updated by Kenta Murata.
Status changed from Assigned to Closed
This was fixed in the latest master branch of [ruby/bigdecimal](https://github.com/ruby/bigdecimal).
----------------------------------------
Bug #10286: BigDecimal - inconsistency with other numeric classes
https://bugs.ruby-lang.org/issues/10286#change-61957
* Author: Konstantin /
* Status: Closed
* Priority: Normal
* Assignee: Kenta Murata
* ruby -v: ruby 2.1.3p242 (2014-09-19 revision 47630) [x86_64-darwin13.0]
* Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN
----------------------------------------
Unlike other numerical classes, BigDecimal does not raise ArgumentError when I try to parse invalid value.
~~~
require 'bigdecimal'
BigDecimal('invalid value')
# => #<BigDecimal:7fe6f9a6a058,'0.0',9(9)>
Float('invalid value')
# ArgumentError: invalid value for Float(): "invalid value"
Integer('invalid value')
# ArgumentError: invalid value for Integer(): "invalid value"
Complex('invalid value')
# ArgumentError: invalid value for convert(): "invalid value"
Rational('invalid value')
# ArgumentError: invalid value for convert(): "invalid value"
~~~
--
https://bugs.ruby-lang.org/
Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>