ok/jj
1
0
Fork 0
forked from mirrors/jj
jj/lib
Martin von Zweigbergk e3254fa5c4 rewrite: don't rewrite the "removed" side of a branch conflict
Let's say we have a simple history like this:

```
B C D
 \|/
  A
```

Branch `main` initially points to commit B. Two concurrent operations
then move the branch to commits C and D. When the two concurrent
operations get merged, the branch will be recorded as pointing to
"C+D-B". If a subsequent operation now abandons commit B, we would
update the "removed" side of the branch conflict. That seems a little
dishonest. I think the reason I did it that way was in order to not
keep B visible back when having it present in the "removed" side would
keep it visible (before 33bf6ce1d5).

I noticed this issue while working on #241 because
`test_import_refs_reimport()` started failing. That test case is
pretty much exactly the case above.
2022-04-28 11:28:09 -07:00
..
protos working_copy: record sparse patterns in the tree state (#52) 2022-04-26 14:52:17 -07:00
src rewrite: don't rewrite the "removed" side of a branch conflict 2022-04-28 11:28:09 -07:00
tests rewrite: don't rewrite the "removed" side of a branch conflict 2022-04-28 11:28:09 -07:00
build.rs build: conditionally use map_first_last feature if available 2022-02-20 22:21:14 -08:00
Cargo.toml cargo: upgrade uuid to 1.0.0 2022-04-20 14:18:59 -07:00