# Bump FoldSnapshot version if excerpt gets edited outside of its bounds · gitcafe/zed

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

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

Visibility: public

Requested revision: c0bf4a5bfd09911ee51eb67557b5b5c2562b40ed

Requested commit: c0bf4a5bfd09911ee51eb67557b5b5c2562b40ed

Commit: c0bf4a5bfd09911ee51eb67557b5b5c2562b40ed

Tree: ee94153c6a4f19c580ae8775edeeb7eb7a7482f7

Author: Antonio Scandurra

Committer: Antonio Scandurra

## Message

```
Bump FoldSnapshot version if excerpt gets edited outside of its bounds

This will cause layers above `FoldMap` to grab a fresh snapshot of the `FoldMap`
and, as a result, of the underlying `MultiBufferSnapshot`. It is a necessary change
because, even though the coordinate space is not affected, a buffer edit taking place
*before* an excerpt range could cause the excerpt buffer rows to change, e.g. if
lines were added or removed. This manifested itself in a randomized test.

```

## Parents

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

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