D6229: rust-dagops: range of revisions

gracinet (Georges Racinet) phabricator at mercurial-scm.org
Mon Apr 15 05:50:41 EDT 2019


gracinet marked 2 inline comments as done.
gracinet added inline comments.

INLINE COMMENTS

> kevincox wrote in dagops.rs:140
> Can you use:
> 
>   for rev in heads_ancestors.into_iter().rev() {
>      // ...
>   }

Ah yes, thanks, I've been looking for something like that on `DoubleEndedIterator` and couldn't find it, because it's actually on `Iterator` with a `where Self: DoubleEndedIterator`.

> kevincox wrote in dagops.rs:215
> Can you use `.into_iter()` instead of `.iter().cloned()`?

Sure, I should probably take more advantage of such cases, where we don't need the original object anymore.

REPOSITORY
  rHG Mercurial

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

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


More information about the Mercurial-devel mailing list