comparison mercurial/merge.py @ 31170:487ec7b096e2

merge: make "linear" an input in docstring table Instead of having two ouputs, it seem simpler to have an addition input. This will allow further simplification.
author Martin von Zweigbergk <martinvonz@google.com>
date Mon, 27 Feb 2017 14:58:53 -0800
parents 955b3a6d3dd5
children 351207bfdde9
comparison
equal deleted inserted replaced
31169:955b3a6d3dd5 31170:487ec7b096e2
1466 is dirty, whether a revision is specified, and the relationship of 1466 is dirty, whether a revision is specified, and the relationship of
1467 the parent rev to the target rev (linear or not). 1467 the parent rev to the target rev (linear or not).
1468 1468
1469 This logic is tested by test-update-branches.t. 1469 This logic is tested by test-update-branches.t.
1470 1470
1471 -c -C dirty rev | linear non-linear 1471 -c -C dirty rev linear | result
1472 n n n n | ok x 1472 n n n n n | x
1473 n n n y | ok ok 1473 n n n n y | ok
1474 n n y n | merge x 1474 n n n y * | ok
1475 n n y y | merge (1) 1475 n n y n n | x
1476 n y * * | discard discard 1476 n n y n y | merge
1477 y n y * | (2) (2) 1477 n n y y n | (1)
1478 y n n * | ok ok 1478 n n y y y | merge
1479 y y * * | (3) (3) 1479 n y * * * | discard
1480 y n y * * | (2)
1481 y n n * * | ok
1482 y y * * * | (3)
1480 1483
1481 x = can't happen 1484 x = can't happen
1482 * = don't-care 1485 * = don't-care
1483 1 = abort: uncommitted changes (commit or update --clean to discard changes) 1486 1 = abort: uncommitted changes (commit or update --clean to discard changes)
1484 2 = abort: uncommitted changes (checked in commands.py) 1487 2 = abort: uncommitted changes (checked in commands.py)