This is an archive of the discontinued Mercurial Phabricator instance.

hg-core: add `files_with_nodes` to `Manifest`

Authored by acezar on Sep 18 2020, 12:01 PM.

Diff Detail

rHG Mercurial
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

acezar created this revision.Sep 18 2020, 12:01 PM
Alphare accepted this revision.Sep 22 2020, 8:34 AM
Alphare added a subscriber: Alphare.
Alphare added inline comments.

Docstring should mention that it iterates over the files and the hashes.


Maybe explain the 40 number and/or reuse from a constant?


Possibly this indexing could panic in the case of corrupted data, maybe we should have a more explicit panic message. I'm not certain as doing this everywhere would probably not be worth it. What do you think?

This revision was not accepted when it landed; it landed in state Needs Review.
This revision was automatically updated to reflect the committed changes.