diff rust/hg-core/src/utils/files.rs @ 51566:529a655874fb stable

matchers: fix the bug in rust PatternMatcher that made it cut off early This brings the rust output in line with the Python output.
author Arseniy Alekseyev <aalekseyev@janestreet.com>
date Fri, 12 Apr 2024 14:09:55 +0100
parents 532e74ad3ff6
children
line wrap: on
line diff
--- a/rust/hg-core/src/utils/files.rs	Fri Apr 12 13:48:38 2024 +0100
+++ b/rust/hg-core/src/utils/files.rs	Fri Apr 12 14:09:55 2024 +0100
@@ -120,6 +120,10 @@
     dirs
 }
 
+pub fn dir_ancestors(path: &HgPath) -> Ancestors {
+    Ancestors { next: Some(path) }
+}
+
 /// Returns an iterator yielding ancestor directories of the given repository
 /// path.
 ///