Page MenuHomePhabricator

rust-status: refactor status into a struct
ClosedPublic

Authored by Alphare on Jun 25 2020, 5:02 AM.

Details

Summary

The code for dirstate/status has grown too large for comfort, this is the
first of three patches that try to improve maintainability.
In this patch, refactoring dirstate's status into a struct allows for slimming
down function signatures drastically, keeping the mental (and maintenance)
burden lower, since pretty much all of them shared a few common arguments.

This had the pleasant side-effect of simplifying lifetimes a little. This has
no observable impact on performance.

The next patch will add/improve documentation and refactor some types. I tried
to keep new code down to a minimum in this patch because it's already pretty
big.

Diff Detail

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

Event Timeline

Alphare created this revision.Jun 25 2020, 5:02 AM
This revision was not accepted when it landed; it landed in state Needs Review.
This revision was automatically updated to reflect the committed changes.