# HG changeset patch # User Martin von Zweigbergk # Date 2015-05-19 18:36:05 # Node ID 144085249c3f55ca5abf071f6d253e35589ee713 # Parent 8e0e334bad42066efb76b21b62d48a8f15bad8f4 commit: avoid match.files() in conditions See 9789b4a7c595 (match: introduce boolean prefix() method, 2014-10-28) for reasons to avoid match.files() in conditions. diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py --- a/mercurial/localrepo.py +++ b/mercurial/localrepo.py @@ -1444,7 +1444,7 @@ class localrepository(object): status.removed.insert(0, '.hgsubstate') # make sure all explicit patterns are matched - if not force and match.files(): + if not force and (match.isexact() or match.prefix()): matched = set(status.modified + status.added + status.removed) for f in match.files():