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/2015-October/141911.html below:

[Python-Dev] PEP 0484 - the Numeric Tower

[Python-Dev] PEP 0484 - the Numeric Tower [Python-Dev] PEP 0484 - the Numeric TowerSteven D'Aprano steve at pearwood.info
Tue Oct 13 20:08:07 EDT 2015
On Tue, Oct 13, 2015 at 04:37:43PM -0700, Raymond Hettinger wrote:

> We could have (and still could) make the choice to always coerce to 
> decimal (every float is exactly representable in decimal).  Further, 
> any decimal float or binary float could be losslessly coerced to a 
> Fraction, but that probably isn't what you really want most of the 
> time.  I think people who work in decimal usually want to stay there 
> and people who work with binary floating point want to stay there as 
> well (invisible coercions being more likely to cause pain than relieve 
> pain).

Further to what Raymond says, if anyone wants to persue this further, 
and wants to argue for such automatic promotion of float to Decimal (or 
vice versa), I think a good place to start would be a survey of other 
languages with a numeric tower. How do they handle similar situations?


-- 
Steve
More information about the Python-Dev mailing list

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