Use text anchors as hint position in hints cache

co-authored-by: Max Brunsfeld <max@zed.dev>
This commit is contained in:
Kirill Bulatov 2023-06-22 22:07:09 +03:00
parent 781fa0cff4
commit 96a34ad0ee
2 changed files with 107 additions and 118 deletions

View file

@ -2614,9 +2614,12 @@ impl Editor {
let invalidate_cache = match reason {
InlayRefreshReason::SettingsChange(new_settings) => {
let new_splice = self
.inlay_hint_cache
.update_settings(new_settings, get_update_state(self, cx));
let new_splice = self.inlay_hint_cache.update_settings(
&self.buffer,
new_settings,
get_update_state(self, cx),
cx,
);
if let Some(InlaySplice {
to_remove,
to_insert,