context: add a getfileset() method so fewer things need fileset directly
authorAugie Fackler <raf@durin42.com>
Tue, 04 Feb 2014 15:27:49 -0500
changeset 20400 f0137d994c83
parent 20399 74daabdf5ab5
child 20401 906358d0350e
context: add a getfileset() method so fewer things need fileset directly Allows me to break an import cycle in a subsequent change.
mercurial/context.py
--- a/mercurial/context.py	Tue Feb 04 18:09:20 2014 -0500
+++ b/mercurial/context.py	Tue Feb 04 15:27:49 2014 -0500
@@ -12,6 +12,7 @@
 import os, errno, stat
 import obsolete as obsmod
 import repoview
+import fileset
 
 propertycache = util.propertycache
 
@@ -79,6 +80,9 @@
     def mutable(self):
         return self.phase() > phases.public
 
+    def getfileset(self, expr):
+        return fileset.getfileset(self, expr)
+
     def obsolete(self):
         """True if the changeset is obsolete"""
         return self.rev() in obsmod.getrevs(self._repo, 'obsolete')