[Python-ideas] Better stdlib support for Path objects

Barry Warsaw barry at python.org
Tue Oct 7 15:47:31 CEST 2014


On Oct 07, 2014, at 02:45 PM, Ed Kellett wrote:

>On 7 October 2014 14:37, Barry Warsaw <barry at python.org> wrote:
>> What would __strpath__ do that __str__ wouldn't do?  Or do you think it's
>> better to explicitly disallow str-like objects that aren't path objects?
>
>What is a str-like object? A lot of objects are acceptable to str();
>most of them aren't "str-like" in any reasonable sense of the term
>(e.g. function, int), and probably shouldn't be acceptable as paths.

Sorry, str-able is probably a better term to use in the above.

-Barry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20141007/2e6bf6ca/attachment-0001.sig>


More information about the Python-ideas mailing list