Paul demonstrates the shortcoming of commonprefix:
>>> os.path.commonprefix(["foo\\bar\\baz", "foo/bar/boink"])
'foo'
With the patch in issue4755:
>>> import ntpath
>>> ntpath.commonpathprefix(["foo\\bar\\baz", "foo/bar/boink"])
'foo\\bar'
Ta da ...
Skip
_______________________________________________
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
