[Python-ideas] PEP 428 - object-oriented filesystem paths
Ethan Furman
ethan at stoneleaf.us
Sat Oct 6 20:59:29 CEST 2012
Mike Graham wrote:
> On Sat, Oct 6, 2012 at 2:39 PM, Ethan Furman <ethan at stoneleaf.us> wrote:
>> Georg Brandl wrote:
>>> If you inherit from str, you cannot override any of the operations that
>>> str already has (i.e. __add__, __getitem__).
>>
>> Is this a 3.x thing? My 2.x version of Path overrides many of the str
>> methods and works just fine.
>
> This is for theoretical/practical reasons, not technical ones.
Ah, you mean you can't give them different semantics. Gotcha.
~Ethan~
More information about the Python-ideas
mailing list