Page MenuHomePhabricator

rust-status: refactor dispatch case for normal files
ClosedPublic

Authored by Alphare on Thu, Nov 7, 5:18 AM.

Details

Summary

This should make the code easier to read and more idiomatic.

Diff Detail

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

Event Timeline

Alphare created this revision.Thu, Nov 7, 5:18 AM
kevincox accepted this revision.Thu, Nov 7, 1:24 PM
kevincox added inline comments.
rust/hg-core/src/dirstate/status.rs
30–42

I see a lot of these and in general I would recommend against it. The compiler is smart. Unless profiling shows an advantage in a specific case I would leave them out.

Alphare updated this revision to Diff 17741.Fri, Nov 8, 7:51 AM
Alphare marked an inline comment as done.Fri, Nov 8, 7:54 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.