contrib/perf.py
changeset 42138 caebe5e7f4bd
parent 42063 912d82daeda3
child 42359 563cd9a72682
--- a/contrib/perf.py	Fri Feb 01 15:51:02 2019 +0100
+++ b/contrib/perf.py	Fri Apr 12 15:41:32 2019 +0200
@@ -94,6 +94,10 @@
 except ImportError:
     pass
 try:
+    from mercurial.utils import repoviewutil # since 5.0
+except ImportError:
+    repoviewutil = None
+try:
     from mercurial import scmutil # since 1.9 (or 8b252e826c68)
 except ImportError:
     pass
@@ -471,7 +475,8 @@
     # subsettable is defined in:
     # - branchmap since 2.9 (or 175c6fd8cacc)
     # - repoview since 2.5 (or 59a9f18d4587)
-    for mod in (branchmap, repoview):
+    # - repoviewutil since 5.0
+    for mod in (branchmap, repoview, repoviewutil):
         subsettable = getattr(mod, 'subsettable', None)
         if subsettable:
             return subsettable