[PATCH] localrepo: rename proxycls to filteredrepo
Jun Wu
quark at fb.com
Thu Mar 9 23:12:09 UTC 2017
# HG changeset patch
# User Jun Wu <quark at fb.com>
# Date 1489101027 28800
# Thu Mar 09 15:10:27 2017 -0800
# Node ID 4e98743085e0706c827e786930c817d79256c8b6
# Parent 1871a1ee64ed49172b1568b89cdbab126284b309
# Available At https://bitbucket.org/quark-zju/hg-draft
# hg pull https://bitbucket.org/quark-zju/hg-draft -r 4e98743085e0
localrepo: rename proxycls to filteredrepo
When debugging in a Python shell, the type of "repo" is "proxycls", which
could confuse new people.
In [1]: repo
Out[1]: <mercurial.localrepo.proxycls at 0x7f65d4b976d0>
Let's rename it to "filteredrepo" to make it clearer.
diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py
--- a/mercurial/localrepo.py
+++ b/mercurial/localrepo.py
@@ -485,7 +485,7 @@ class localrepository(object):
# build a new class with the mixin and the current class
# (possibly subclass of the repo)
- class proxycls(repoview.repoview, self.unfiltered().__class__):
+ class filteredrepo(repoview.repoview, self.unfiltered().__class__):
pass
- return proxycls(self, name)
+ return filteredrepo(self, name)
@repofilecache('bookmarks', 'bookmarks.current')
More information about the Mercurial-devel
mailing list