D5414: rust: improved docstring

gracinet (Georges Racinet) phabricator at mercurial-scm.org
Thu Dec 13 07:33:03 EST 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rHGceb695c3c154: rust: improved docstring (authored by gracinet, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D5414?vs=12827&id=12834

REVISION DETAIL
  https://phab.mercurial-scm.org/D5414

AFFECTED FILES
  rust/hg-core/src/ancestors.rs

CHANGE DETAILS

diff --git a/rust/hg-core/src/ancestors.rs b/rust/hg-core/src/ancestors.rs
--- a/rust/hg-core/src/ancestors.rs
+++ b/rust/hg-core/src/ancestors.rs
@@ -101,9 +101,9 @@
 ///
 /// - there's no filtering of invalid parent revisions. Actually, it should be
 ///   consistent and more efficient to filter them from the end caller.
-/// - we don't have the optimization for adjacent revs
-///   (case where p1 == rev-1), because it amounts to update the first element
-///   of the heap without sifting, which Rust's BinaryHeap doesn't let us do.
+/// - we don't have the optimization for adjacent revisions (i.e., the case
+///   where `p1 == rev - 1`), because it amounts to update the first element of
+///   the heap without sifting, which Rust's BinaryHeap doesn't let us do.
 /// - we save a few pushes by comparing with `stoprev` before pushing
 impl<G: Graph> Iterator for AncestorsIterator<G> {
     type Item = Result<Revision, GraphError>;



To: gracinet, #hg-reviewers
Cc: durin42, kevincox, mercurial-devel


More information about the Mercurial-devel mailing list