diff mercurial/crecord.py @ 51379:7d85c6e59dd1

crecord: add skipfolded param to previtem This just simplifies the API a bit so it matches `nextitem` and I can handle both nextitem and previtem symmetrically.
author Jordi Gutiérrez Hermoso <jordigh@octave.org>
date Wed, 14 Feb 2024 22:40:47 -0500
parents 18c8c18993f0
children e68908edebba
line wrap: on
line diff
--- a/mercurial/crecord.py	Wed Feb 14 15:23:59 2024 -0500
+++ b/mercurial/crecord.py	Wed Feb 14 22:40:47 2024 -0500
@@ -161,7 +161,7 @@
             except AttributeError:  # parent and/or grandparent was None
                 return None
 
-    def previtem(self):
+    def previtem(self, skipfolded=None):
         """
         Try to return the previous item closest to this item, regardless of
         item's type (header, hunk, or hunkline).