dirstatemap: also discard item from sets
This seems more consistent to do that. I don't think any test was actually
barking about it, but the code feels a bit more robust now.
Differential Revision: https://phab.mercurial-scm.org/D11332
--- a/mercurial/dirstatemap.py Fri Jul 16 18:25:01 2021 +0200
+++ b/mercurial/dirstatemap.py Fri Aug 20 16:12:33 2021 +0200
@@ -199,8 +199,12 @@
self._map[f] = new_entry
if new_entry.dm_nonnormal:
self.nonnormalset.add(f)
+ else:
+ self.nonnormalset.discard(f)
if new_entry.dm_otherparent:
self.otherparentset.add(f)
+ else:
+ self.otherparentset.discard(f)
def reset_state(
self,