This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients elias, ethan.furman, martin.panter, serhiy.storchaka
Date 2016-09-01.18:19:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I'm not convinced that the zeros() method is needed. Zero-initialized sequences can be created via sequence repetition. Sorry, but arguments against this sound like "we made bad design decision in the past, let repeat it with new name" to me.

In any case if you want to write a code for different Python versions you should use sequence repetition.

Here is a patch that replaces all creations of zero-initialized bytes and bytearray objects in the stdlib and tests with repetitions. All tests (except test_bytes of course) are passed on Linux if disallow an int argument in bytes and bytearray constructors.
Date User Action Args
2016-09-01 18:19:15serhiy.storchakasetrecipients: + serhiy.storchaka, ethan.furman, elias, martin.panter
2016-09-01 18:19:14serhiy.storchakasetmessageid: <>
2016-09-01 18:19:14serhiy.storchakalinkissue27923 messages
2016-09-01 18:19:13serhiy.storchakacreate