# vim: Ensure surrounding markers contain cursor for Helix surround operations \(\#47163\) · gitcafe/zed

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

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

Visibility: public

Requested revision: 74456c8b496a967ee9203ceb2690452ca28783ca

Requested commit: 74456c8b496a967ee9203ceb2690452ca28783ca

Commit: 74456c8b496a967ee9203ceb2690452ca28783ca

Tree: 9cb72de46236cdbdc4ade2dbcf085e021f9edca3

Author: Leon Qadirie

Committer: GitHub

## Message

```
vim: Ensure surrounding markers contain cursor for Helix surround operations (#47163)

Closes #47155, introduced by #44317

I naively trusted `crates/vim/src/object.rs:1624`'s
`surrounding_markers` to check whether the cursor is actually
surrounded, but it has nearest match fallback behavior, apparently by
design as indicated by `test_anyquotes_object` in the same file.

Release Notes:

- Fixed Helix surround operations falling back to closest match if
cursor not surrounded

Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
```

## Parents

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

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