[Python-ideas] Working with Path objects: p-strings?

Ethan Furman ethan at stoneleaf.us
Tue Mar 29 18:07:07 EDT 2016


On 03/29/2016 02:47 PM, Koos Zevenhoven wrote:
> On Mar 30, 2016 00:39, "Ethan Furman" wrote:
>> On 03/29/2016 02:30 PM, Greg Ewing wrote:

>>> If P were a suitable seed object, this could be
>>>
>>>    P/wherever/youwant/togo
>>
>> An interesting idea, but how would you differentiate between relative
>> and absolute paths?
>
> Indeed interesting. It would currently work with P = Path(''), kinda
> like my earlier p'' / ... example. It works even with relative paths,
> although they would not look like relative ones because of the first /.

Please provide an example of both a relative and an absolute path 
construction using `P`.

--
~Ethan~


More information about the Python-ideas mailing list