Patchwork D1696: copies: consistently use """ for docstrings

login
register
mail settings
Submitter phabricator
Date Dec. 15, 2017, 1:52 p.m.
Message ID <fe99a302026a64b8cbed5870e6110b76@localhost.localdomain>
Download mbox | patch
Permalink /patch/26306/
State Not Applicable
Headers show

Comments

phabricator - Dec. 15, 2017, 1:52 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG9cf37d111acb: copies: consistently use &quot;&quot;&quot; for docstrings (authored by martinvonz, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D1696?vs=4445&id=4477

REVISION DETAIL
  https://phab.mercurial-scm.org/D1696

AFFECTED FILES
  mercurial/copies.py

CHANGE DETAILS




To: martinvonz, #hg-reviewers, yuja
Cc: mercurial-devel

Patch

diff --git a/mercurial/copies.py b/mercurial/copies.py
--- a/mercurial/copies.py
+++ b/mercurial/copies.py
@@ -107,7 +107,7 @@ 
     return min(limit, a, b)
 
 def _chain(src, dst, a, b):
-    '''chain two sets of copies a->b'''
+    """chain two sets of copies a->b"""
     t = a.copy()
     for k, v in b.iteritems():
         if v in t:
@@ -130,8 +130,8 @@ 
     return t
 
 def _tracefile(fctx, am, limit=-1):
-    '''return file context that is the ancestor of fctx present in ancestor
-    manifest am, stopping after the first ancestor lower than limit'''
+    """return file context that is the ancestor of fctx present in ancestor
+    manifest am, stopping after the first ancestor lower than limit"""
 
     for f in fctx.ancestors():
         if am.get(f.path(), None) == f.filenode():
@@ -157,7 +157,7 @@ 
     return mb.filesnotin(ma, match=match)
 
 def _forwardcopies(a, b, match=None):
-    '''find {dst@b: src@a} copy mapping where a is an ancestor of b'''
+    """find {dst@b: src@a} copy mapping where a is an ancestor of b"""
 
     # check for working copy
     w = None
@@ -223,7 +223,7 @@ 
     return r
 
 def pathcopies(x, y, match=None):
-    '''find {dst@y: src@x} copy mapping for directed compare'''
+    """find {dst@y: src@x} copy mapping for directed compare"""
     if x == y or not x or not y:
         return {}
     a = y.ancestor(x)
@@ -861,13 +861,13 @@ 
                     return
 
 def duplicatecopies(repo, wctx, rev, fromrev, skiprev=None):
-    '''reproduce copies from fromrev to rev in the dirstate
+    """reproduce copies from fromrev to rev in the dirstate
 
     If skiprev is specified, it's a revision that should be used to
     filter copy records. Any copies that occur between fromrev and
     skiprev will not be duplicated, even if they appear in the set of
     copies between fromrev and rev.
-    '''
+    """
     exclude = {}
     if (skiprev is not None and
         repo.ui.config('experimental', 'copytrace') != 'off'):