[PATCH 3 of 4] phase: document the replace method
Pierre-Yves David
pierre-yves.david at ens-lyon.org
Wed Jun 17 02:09:20 UTC 2015
# HG changeset patch
# User Pierre-Yves David <pierre-yves.david at fb.com>
# Date 1434409584 25200
# Mon Jun 15 16:06:24 2015 -0700
# Node ID 18cc713258b6240bc0543aa5ceb537a80a8a85e5
# Parent 2acfb673a817808b6993ae5e84466a42d4cd63b7
phase: document the replace method
This is a minor documentation update to answer a co-worker question.
diff --git a/mercurial/phases.py b/mercurial/phases.py
--- a/mercurial/phases.py
+++ b/mercurial/phases.py
@@ -169,10 +169,11 @@ class phasecache(object):
ph._phaserevs = self._phaserevs
ph._phasesets = self._phasesets
return ph
def replace(self, phcache):
+ """replace all values in 'self' with content of phcache"""
for a in 'phaseroots dirty opener _phaserevs _phasesets'.split():
setattr(self, a, getattr(phcache, a))
def _getphaserevsnative(self, repo):
repo = repo.unfiltered()
More information about the Mercurial-devel
mailing list