On Feb 11, 2016, at 00:22, Georg Brandl <g.brandl at gmx.net> wrote: > > Allowing underscores in string arguments to the ``Decimal`` constructor. It > could be argued that these are akin to literals, since there is no Decimal > literal available (yet). I'm +1 on this. Partly for consistency (see below)--but also, one of the use cases for Decimal is when you need more precision than float, meaning you'll often have even more digits to separate. > * Allowing underscores in string arguments to ``int()`` with base argument 0, > ``float()`` and ``complex()``. +1, because these are actually defined in terms of literals. For example, under int, "Base 0 means to interpret exactly as a code literal". This isn't actually quite true, because "-2" is not an integer literal but is accepted here--but see float for an example that *is* rigorously defined, and still defers to literal syntax and semantics. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/python-dev/attachments/20160211/633e8a5d/attachment.html>
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