# Use anchors for line movement edits to support multi-buffers · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/984378e12cf331e494caaced614d7617da301ab1)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 984378e12cf331e494caaced614d7617da301ab1

Requested commit: 984378e12cf331e494caaced614d7617da301ab1

Commit: 984378e12cf331e494caaced614d7617da301ab1

Tree: 510b6cdd5897be348d387aa5a61a61d5386c683d

Author: Nathan Sobo

Committer: Nathan Sobo

## Message

```
Use anchors for line movement edits to support multi-buffers

Because multi-buffers can contain the same content multiple times, we need to use anchors to track our desired insertion and removal locations when moving lines. This is because deleting a line in order to move it might end up deleting *multiple* lines.

```

## Parents

- [7c9e4e513c813a09bce5abdea0632da7374cf2bb](https://git.cafe/gitcafe/zed/commit/7c9e4e513c813a09bce5abdea0632da7374cf2bb?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/984378e12cf331e494caaced614d7617da301ab1?format=markdown)
