Mercurial > hg
comparison mercurial/dirstate.py @ 47861:1c797757f5bb
dirstate: directly call the dirstatemap in `set_untracked`
This function is only called in two places: the deprecated "remove" method and
in the new `set_untracked` method.
So we simply inline the appropriate content in `set_untracked`, paving the way
to dropping the deprecated code and its associated function.
Differential Revision: https://phab.mercurial-scm.org/D11313
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Fri, 20 Aug 2021 11:23:41 +0200 |
parents | 97acbced3a99 |
children | 6614ab9f061d |
comparison
equal
deleted
inserted
replaced
47860:08f16b3331df | 47861:1c797757f5bb |
---|---|
498 return False | 498 return False |
499 elif entry.added: | 499 elif entry.added: |
500 self._drop(filename) | 500 self._drop(filename) |
501 return True | 501 return True |
502 else: | 502 else: |
503 self._remove(filename) | 503 self._dirty = True |
504 self._updatedfiles.add(filename) | |
505 self._map.removefile(filename, in_merge=self.in_merge) | |
504 return True | 506 return True |
505 | 507 |
506 @requires_no_parents_change | 508 @requires_no_parents_change |
507 def set_clean(self, filename, parentfiledata=None): | 509 def set_clean(self, filename, parentfiledata=None): |
508 """record that the current state of the file on disk is known to be clean""" | 510 """record that the current state of the file on disk is known to be clean""" |