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/2016-September/146095.html below:

[Python-Dev] PEP 467: last round (?)

[Python-Dev] PEP 467: last round (?) [Python-Dev] PEP 467: last round (?)Ethan Furman ethan at stoneleaf.us
Fri Sep 2 19:44:08 EDT 2016
On 09/01/2016 04:07 PM, Victor Stinner wrote:
> 2016-09-02 0:04 GMT+02:00 Ethan Furman:

>> - `fromord` to replace the mistaken purpose of the default constructor
>
> To replace a bogus bytes(obj)? If someone writes bytes(obj) but expect
> to create a byte string from an integer, why not using bchr() to fix
> the code?

The problem with only having `bchr` is that it doesn't help with `bytearray`; the problem with not having `bchr` is who wants to write `bytes.fromord`?

So we need `bchr`, and we need `bytearray.fromord`; and since the major difference between `bytes` and `bytearray` is that one is mutable and one is not, `bytes` should also have `fromord`.

--
~Ethan~
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