A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2003-May/035848.html below:

[Python-Dev] RE: Decimal class

[Python-Dev] RE: Decimal class [Python-Dev] RE: Decimal classTim Peters tim.one@comcast.net
Mon, 26 May 2003 19:13:17 -0400
[Greg Ewing]
> Having mutable decimal instances would feel *very* strange
> to me, given that all other numeric types in Python are
> immutable.
>
> +1 on making them immutable.

I don't believe there's any argument in favor of making them mutable.  The
question may arise because my old FixedPoint class had mutable instances.
That was a mistake -- I wrote that class in an afternoon, and wasn't
thinking when I added the .set_precision() method.  If they're not
immutable, they can't be used as dict keys, and that's a killer-strong
argument all by itself.




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4