This is an archive of the discontinued Mercurial Phabricator instance.

dirstate-tree: Add add_file, remove_file, and drop_file
ClosedPublic

Authored by SimonSapin on Apr 20 2021, 10:17 AM.

Diff Detail

Repository
rHG Mercurial
Branch
default
Lint
No Linters Available
Unit
No Unit Test Coverage

Event Timeline

SimonSapin created this revision.Apr 20 2021, 10:17 AM
baymax updated this revision to Diff 27141.Apr 20 2021, 1:03 PM

✅ refresh by Heptapod after a successful CI run (🐙 💚)

Alphare added inline comments.
rust/hg-core/src/dirstate_tree/dirstate_map.rs
338–339

Maybe leave a comment saying why old_state isn't useful in this implementation.

368

I think we should remove it from the tree.

SimonSapin added inline comments.May 3 2021, 6:07 AM
rust/hg-core/src/dirstate_tree/dirstate_map.rs
338–339

A later commit “dirstate-tree: Fold "tracked descendants" counter update in main walk” ends up using it. (The same info is already in the tree, but having it available before tree lookup enables some optimization.)

368

I agree. I’ll do that in a future separate patch.

SimonSapin updated this revision to Diff 27317.May 3 2021, 6:24 AM
Alphare accepted this revision.May 3 2021, 9:01 AM
This revision is now accepted and ready to land.May 3 2021, 9:01 AM