This is an archive of the discontinued Mercurial Phabricator instance.

dirstate: don't remove normallookup files from nonnormalset
ClosedPublic

Authored by mbthomas on Nov 8 2017, 12:30 PM.

Details

Summary

The dirstate typically tries to keep the nonnormalset and otherparentset
up-to-date when making changes to the dirstate. In the case of files marked
normallookup, however, it erroneously removes the file from the nonnormalset,
after _addpath had just added it.

This doesn't seem to matter at the moment, as nothing relies on the
nonnormalset being correct at this point, however a future re-implementations
of the dirstate map will require this to be kept up-to-date correctly.

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

mbthomas created this revision.Nov 8 2017, 12:30 PM

I was going to review this series. But I fear my dirstate knowledge is not good enough to understand the implications of all the changes. So I don't plan to look at it unless another reviewer can't be found.

Based on a very shaky understanding of the code gained by spending 10 minutes looking around at uses of nonnormalset, I think this is right.

I'd appreciate a patch that describes what all these attributes are intended to contain, especially if there's about to be some api-ish contracts going on between this and other code (even if there's no stability contract)

durin42 accepted this revision.Nov 10 2017, 5:03 PM
This revision is now accepted and ready to land.Nov 10 2017, 5:03 PM
This revision was automatically updated to reflect the committed changes.