[PATCH 1 of 2] util: state docstring of rename more precisely

Adrian Buehlmann adrian at cadifra.com
Wed Oct 7 17:59:19 UTC 2009


# HG changeset patch
# User Adrian Buehlmann <adrian at cadifra.com>
# Date 1254916310 -7200
# Node ID 4741ed461aa6618881e34fe24382913653944aef
# Parent  98feea5659d902bdca558ea7c9fed7670eb4f5e9
util: state docstring of rename more precisely

diff --git a/mercurial/util.py b/mercurial/util.py
--- a/mercurial/util.py
+++ b/mercurial/util.py
@@ -400,7 +400,7 @@ def lexists(filename):
     return True
 
 def rename(src, dst):
-    """forcibly rename a file"""
+    '''atomically rename file src to dst, replacing dst if it exists'''
     try:
         os.rename(src, dst)
     except OSError, err: # FIXME: check err (EEXIST ?)



More information about the Mercurial-devel mailing list