Page MenuHomePhabricator

Fix an issue where the last line of block-based diffs could be incorrectly hidden
ClosedPublic

Authored by epriestley on Thu, Jan 30, 4:17 PM.

Details

Summary

Fixes T13468. See that task for discussion. The older source-rendering code mixes "line number" / "1-based" lists with "block number" / "0-based" lists and then has other bugs which cancel this out.

For block-based diffs, build an explicit block-based mask with only block numbers. This sort of sidesteps the whole issue.

Test Plan

Viewed the diff with the original reproduction case, plus various other block-based diffs, including one-block image diffs, in unified and side-by-side mode. Didn't spot any oddities.

Diff Detail

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

Event Timeline

epriestley created this revision.Thu, Jan 30, 4:17 PM
This revision was not accepted when it landed; it landed in state Needs Review.Thu, Jan 30, 4:19 PM
epriestley requested review of this revision.
This revision was automatically updated to reflect the committed changes.