comparison mercurial/context.py @ 25195:472a685a4961

merge with stable
author Matt Mackall <mpm@selenic.com>
date Tue, 19 May 2015 07:17:57 -0500
parents 755d23a49170 ccb1623266eb
children b7876b8fa063
comparison
equal deleted inserted replaced
25191:08d1ef09ed37 25195:472a685a4961
7 7
8 from node import nullid, nullrev, short, hex, bin 8 from node import nullid, nullrev, short, hex, bin
9 from i18n import _ 9 from i18n import _
10 import mdiff, error, util, scmutil, subrepo, patch, encoding, phases 10 import mdiff, error, util, scmutil, subrepo, patch, encoding, phases
11 import match as matchmod 11 import match as matchmod
12 import os, errno, stat 12 import copy, os, errno, stat
13 import obsolete as obsmod 13 import obsolete as obsmod
14 import repoview 14 import repoview
15 import fileset 15 import fileset
16 import revlog 16 import revlog
17 17
590 590
591 def walk(self, match): 591 def walk(self, match):
592 '''Generates matching file names.''' 592 '''Generates matching file names.'''
593 593
594 # Override match.bad method to have message with nodeid 594 # Override match.bad method to have message with nodeid
595 match = copy.copy(match)
595 oldbad = match.bad 596 oldbad = match.bad
596 def bad(fn, msg): 597 def bad(fn, msg):
598 # The manifest doesn't know about subrepos, so don't complain about
599 # paths into valid subrepos.
600 if any(fn == s or fn.startswith(s + '/')
601 for s in self.substate):
602 return
597 oldbad(fn, _('no such file in rev %s') % self) 603 oldbad(fn, _('no such file in rev %s') % self)
598 match.bad = bad 604 match.bad = bad
599 605
600 return self._manifest.walk(match) 606 return self._manifest.walk(match)
601 607