(original) (raw)

changeset: 78223:61d0e3526a51 branch: 3.2 parent: 78220:c8534d55c5e6 user: R David Murray rdmurray@bitdance.com date: Sat Jul 21 14:33:56 2012 -0400 files: Lib/posixpath.py description: #15342: Add clarifying sentence to posixpath.join docstring. This sentence appears as a clarifying note in the HTML docs, and seems worth having in the docstring since it covers a very common use case that isn't otherwise obvious. Thanks to Yongzhi Pan for the suggestion. diff -r c8534d55c5e6 -r 61d0e3526a51 Lib/posixpath.py --- a/Lib/posixpath.py Sat Jul 21 20:28:46 2012 +0300 +++ b/Lib/posixpath.py Sat Jul 21 14:33:56 2012 -0400 @@ -71,7 +71,8 @@ def join(a, *p): """Join two or more pathname components, inserting '/' as needed. If any component is an absolute path, all previous path components - will be discarded.""" + will be discarded. An empty last part will result in a path that + ends with a separator.""" sep = _get_sep(a) path = a try: /rdmurray@bitdance.com