mercurial/context.py
changeset 3207 0790dce2f3a8
parent 3165 5c93dd0ae413
child 3209 9e8dd6114a4e
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -130,6 +130,12 @@ class filectx(object):
     def __repr__(self):
         return "<filectx %s@%s>" % (self.path(), short(self.node()))
 
+    def filectx(self, fileid):
+        '''opens an arbitrary revision of the file without
+        opening a new filelog'''
+        return filectx(self._repo, self._path, fileid=fileid,
+                       filelog=self._filelog)
+
     def filerev(self): return self._filerev
     def filenode(self): return self._filenode
     def filelog(self): return self._filelog