Feature #13984
closed
BigDecimal should be immutable/frozen and return itself on #dup
Added by Eregon (Benoit Daloze) about 7 years ago.
Updated almost 6 years ago.
Description
Currently, BigDecimal instances are not frozen, and supports #dup by returning a new instance.
In the spirit of #12979 and #13983, I think BigDecimal instances should always be frozen.
Then BigDecimal#dup/clone should just return the same instance.
- Related to Feature #13985: Avoid exception for #dup/#clone on Rational and Complex added
- Status changed from Open to Assigned
- Assignee set to mrkn (Kenta Murata)
I decided to make a BigDecimal is frozen and remove dup-support.
But it introduces incompatibilities, so during Ruby 2.5 period, I'll make them deprecated and issue warning messages.
- Target version set to 2.6
- Target version deleted (
2.6)
- Status changed from Assigned to Closed
Also available in: Atom
PDF
Like0
Like0Like0Like0Like0Like0Like0Like0