Patchwork [28,of,48,RFC] commitablectx: move ignored from workingctx

login
register
mail settings
Submitter Sean Farley
Date Sept. 5, 2013, 8:07 p.m.
Message ID <5179b78504fe65feda5e.1378411642@laptop.local>
Download mbox | patch
Permalink /patch/2366/
State Accepted
Commit e4088cec976b2b4f6d8b0905358021f5e7794fea
Headers show

Comments

Sean Farley - Sept. 5, 2013, 8:07 p.m.
# HG changeset patch
# User Sean Farley <sean.michael.farley@gmail.com>
# Date 1376515352 18000
#      Wed Aug 14 16:22:32 2013 -0500
# Node ID 5179b78504fe65feda5e4d6aa6d00da19c7096cb
# Parent  89ad988524a170f3ec66403d5f2a0785c08f3d90
commitablectx: move ignored from workingctx

Patch

diff --git a/mercurial/context.py b/mercurial/context.py
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -979,10 +979,13 @@ 
     def deleted(self):
         return self._status[3]
     def unknown(self):
         assert self._unknown is not None  # must call status first
         return self._unknown
+    def ignored(self):
+        assert self._ignored is not None  # must call status first
+        return self._ignored
 
 class workingctx(commitablectx):
     """A workingctx object makes access to data related to
     the current working directory convenient.
     date - any valid date string or (unixtime, offset), or None.
@@ -1006,13 +1009,10 @@ 
         p = self._repo.dirstate.parents()
         if p[1] == nullid:
             p = p[:-1]
         return [changectx(self._repo, x) for x in p]
 
-    def ignored(self):
-        assert self._ignored is not None  # must call status first
-        return self._ignored
     def clean(self):
         assert self._clean is not None  # must call status first
         return self._clean
     def branch(self):
         return encoding.tolocal(self._extra['branch'])