Author skrah
Recipients chris.jerdonek, docs@python, eric.araujo, ezio.melotti, pitrou, skrah, terry.reedy
Date 2012-11-23.23:18:03
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <20121123231804.GA4321@sleipnir.bytereef.org>
In-reply-to <1353707804.3343.9.camel@localhost.localdomain>
Content
Antoine Pitrou <report@bugs.python.org> wrote:
> > How about "object does not provide a byte buffer" for error messages
> > and "(byte) buffer provider" as a shorthand for "any buffer provider
> > that exposes its memory as a sequence of unsigned bytes in response
> > to a PyBUF_SIMPLE request"?
> 
> It's not too bad, I think. However, what I think is important is that
> the average (non-expert) Python developer understand that the function
> really accepts a bytes object, and other similar types (because, really,
> bytes is the only bytes-like type most developers will ever face).
> That's why I'm proposing "bytes-like object".

If it is somehow possible to establish the term as a shorthand for the real
meaning, then I guess it's the most economical option for documenting Python
methods (I don't think it should be used in the C-API docs though).

help (b''.join) for example would sound better with "bytes-like object"
than with "(byte) buffer provider".
History
Date User Action Args
2012-11-23 23:18:03skrahsetrecipients: + skrah, terry.reedy, pitrou, ezio.melotti, eric.araujo, chris.jerdonek, docs@python
2012-11-23 23:18:03skrahlinkissue16518 messages
2012-11-23 23:18:03skrahcreate