Alphare added inline comments.

INLINE COMMENTS

> marmoute wrote in status.rs:74
> If I understand you code correctly you currently do:
> 
>   filenames = listdir()
>   result = [(f, entry(f)) for f in filenames]
>   result.sort()
> 
> Would it make sense to do:
> 
>   filenames = listdir()
>   filenames.sort()
>   result = [(f, entry(f)) for f in filenames]

std::fs::read_dir <https://doc.rust-lang.org/nightly/std/fs/fn.read_dir.html> 
returns an iterator, so I would have to collect it first, unsure if that would 
be more expensive... and also, a `Vec` of heap-allocated elements being just an 
array of pointers I'm not convinced that would help. Maybe we can do some 
benchmarking further down the line.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7927/new/

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

To: Alphare, #hg-reviewers, marmoute
Cc: marmoute, durin42, kevincox, mercurial-devel
_______________________________________________
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel

Reply via email to