basectx: move flags from changectx
authorSean Farley <sean.michael.farley@gmail.com>
Mon, 05 Aug 2013 18:28:54 -0500
changeset 19561 7806e63598b0
parent 19560 f256e1108053
child 19562 389d7767630d
basectx: move flags from changectx
mercurial/context.py
--- a/mercurial/context.py	Mon Aug 05 18:28:40 2013 -0500
+++ b/mercurial/context.py	Mon Aug 05 18:28:54 2013 -0500
@@ -113,6 +113,12 @@
     def filenode(self, path):
         return self._fileinfo(path)[0]
 
+    def flags(self, path):
+        try:
+            return self._fileinfo(path)[1]
+        except error.LookupError:
+            return ''
+
 class changectx(basectx):
     """A changecontext object makes access to data related to a particular
     changeset convenient. It represents a read-only context already presnt in
@@ -334,12 +340,6 @@
             troubles.append('divergent')
         return troubles
 
-    def flags(self, path):
-        try:
-            return self._fileinfo(path)[1]
-        except error.LookupError:
-            return ''
-
     def filectx(self, path, fileid=None, filelog=None):
         """get a file context from this changeset"""
         if fileid is None: