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 wim.glenn
Recipients aeros, docs@python, rhettinger, wim.glenn
Date 2019-07-26.16:09:31
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1564157371.38.0.645869938432.issue37684@roundup.psfhosted.org>
In-reply-to
Content
Raymond,

I understand that consecutive appends could potentially trigger multiple resizes behind the scenes, and so it's not really showing that extend is more like a bulk update as you mentioned. That's a good point!

However I think it's a more important consideration to make sure the equivalent actually gives a correct *result*. Can you suggest an alternative code snippet to use which is correct, or perhaps soften the language claiming that the code is equivalent?

For what it's worth, the stdtypes.html docs writes that extend is "for the most part the same as" the slice assignment:

https://docs.python.org/3/library/stdtypes.html#mutable-sequence-types
History
Date User Action Args
2019-07-26 16:09:31wim.glennsetrecipients: + wim.glenn, rhettinger, docs@python, aeros
2019-07-26 16:09:31wim.glennsetmessageid: <1564157371.38.0.645869938432.issue37684@roundup.psfhosted.org>
2019-07-26 16:09:31wim.glennlinkissue37684 messages
2019-07-26 16:09:31wim.glenncreate