[Differential] [Request, 2 lines] D83: match: make base matcher return True for visitdir

durham (Durham Goode) phabricator at mercurial-scm.org
Fri Jul 14 17:57:53 UTC 2017


durham created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  If a matcher doesn't implement visitdir, we should be returning True so that
  tree traversals are not prematurely pruned. The old value of False would prevent
  tree traversals when using any matcher that didn't implement visitdir.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D83

AFFECTED FILES
  mercurial/match.py

CHANGE DETAILS

Index: mercurial/match.py
===================================================================
--- mercurial/match.py
+++ mercurial/match.py
@@ -305,7 +305,7 @@
         This function's behavior is undefined if it has returned False for
         one of the dir's parent directories.
         '''
-        return False
+        return True
 
     def always(self):
         '''Matcher will match everything and .files() will be empty --


EMAIL PREFERENCES
  https://phab.mercurial-scm.org/settings/panel/emailpreferences/

To: durham, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list