Patchwork [03,of,11,V5] merge: make "linear" an input in docstring table

login
register
mail settings
Submitter via Mercurial-devel
Date Feb. 28, 2017, 12:31 a.m.
Message ID <4287db2a458cd9497c52.1488241880@martinvonz.mtv.corp.google.com>
Download mbox | patch
Permalink /patch/18821/
State Accepted
Headers show

Comments

via Mercurial-devel - Feb. 28, 2017, 12:31 a.m.
# HG changeset patch
# User Martin von Zweigbergk <martinvonz@google.com>
# Date 1488236333 28800
#      Mon Feb 27 14:58:53 2017 -0800
# Node ID 4287db2a458cd9497c5273bb129d4e32798fabc1
# Parent  63a4df2dc6339d6d5c555eb8caaf9ad202b87f21
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.

Patch

diff -r 63a4df2dc633 -r 4287db2a458c mercurial/merge.py
--- a/mercurial/merge.py	Mon Feb 27 14:33:17 2017 -0800
+++ b/mercurial/merge.py	Mon Feb 27 14:58:53 2017 -0800
@@ -1468,15 +1468,18 @@ 
 
     This logic is tested by test-update-branches.t.
 
-    -c  -C  dirty  rev  |  linear   non-linear
-     n   n    n     n   |    ok         x
-     n   n    n     y   |    ok        ok
-     n   n    y     n   |   merge       x
-     n   n    y     y   |   merge      (1)
-     n   y    *     *   |   discard   discard
-     y   n    y     *   |    (2)       (2)
-     y   n    n     *   |    ok        ok
-     y   y    *     *   |    (3)       (3)
+    -c  -C  dirty  rev  linear  |  result
+     n   n    n     n     n     |     x
+     n   n    n     n     y     |    ok
+     n   n    n     y     *     |    ok
+     n   n    y     n     n     |     x
+     n   n    y     n     y     |   merge
+     n   n    y     y     n     |    (1)
+     n   n    y     y     y     |   merge
+     n   y    *     *     *     |  discard
+     y   n    y     *     *     |    (2)
+     y   n    n     *     *     |    ok
+     y   y    *     *     *     |    (3)
 
     x = can't happen
     * = don't-care