obsolete: simplify relevantmarker
Drop duplicate assignment from a merge failure. Save
one loop iteration by exploiting that pendingnodes will
be seennodes after the first round anyway, so just
pre-initialize the set accordingly. From Anton Shestakov's
review on !867. Performance difference for my test case is
in the noise.
--- a/mercurial/obsolete.py Tue Jun 11 18:47:50 2024 +0200
+++ b/mercurial/obsolete.py Mon Jun 24 03:16:52 2024 +0200
@@ -799,8 +799,7 @@
if rev is not None and rev in revs:
pendingnodes.add(node)
seenmarkers = set()
- seenmarkers = set()
- seennodes = set()
+ seennodes = set(pendingnodes)
precursorsmarkers = self.predecessors
succsmarkers = self.successors
children = self.children