Mercurial > hg
comparison tests/test-glog.t @ 22913:cb4449921a1d
status: create class for status lists
Callers of various status() methods (on dirstate, context, repo) get a
tuple of 7 elements, where each element is a list of files. This
results in lots of uses of indexes where names would be much more
readable. For example, "status.ignored" seems clearer than "status[4]"
[1]. So, let's introduce a simple named tuple containing the 7 status
fields: modified, added, removed, deleted, unknown, ignored, clean.
This patch introduces the class and updates the status methods to
return instances of it. Later patches will update the callers.
[1] Did you even notice that it should have been "status[5]"?
(tweaked by mpm to introduce the class in scmutil and only change one user)
author | Martin von Zweigbergk <martinvonz@gmail.com> |
---|---|
date | Fri, 10 Oct 2014 14:32:36 -0700 |
parents | 1dd178277cf5 |
children | c63a09b6b337 |
comparison
equal
deleted
inserted
replaced
22912:3b8e6c095239 | 22913:cb4449921a1d |
---|