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 pitrou
Recipients exarkun, pitrou, skrah
Date 2012-09-15.12:37:25
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1347712645.61.0.638230140824.issue15945@psf.upfronthosting.co.za>
In-reply-to
Content
Just prepend the empty bytestring if you want to make sure the result is a bytes object:

>>> b'' + memoryview(b'foo') + b'bar'
b'foobar'

I think the following limitation may be more annoying, though:

>>> b''.join([memoryview(b'foo'), b'bar'])
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: sequence item 0: expected bytes, memoryview found
History
Date User Action Args
2012-09-15 12:37:25pitrousetrecipients: + pitrou, exarkun, skrah
2012-09-15 12:37:25pitrousetmessageid: <1347712645.61.0.638230140824.issue15945@psf.upfronthosting.co.za>
2012-09-15 12:37:25pitroulinkissue15945 messages
2012-09-15 12:37:25pitroucreate