Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Fix compilation on main (#53257)
Cole Miller1d0967cdda39
diff --git a/crates/project_symbols/src/project_symbols.rs b/crates/project_symbols/src/project_symbols.rsindex 351b6e7afb5..931e332d93d 100644--- a/crates/project_symbols/src/project_symbols.rs+++ b/crates/project_symbols/src/project_symbols.rs@@ -1,6 +1,4 @@-use editor::{- Anchor, Bias, Editor, SelectionEffects, scroll::Autoscroll, styled_runs_for_code_label,-};+use editor::{Bias, Editor, SelectionEffects, scroll::Autoscroll, styled_runs_for_code_label};use fuzzy::{StringMatch, StringMatchCandidate};use gpui::{App, Context, DismissEvent, Entity, HighlightStyle, ParentElement, StyledText, Task, TextStyle,@@ -143,13 +141,14 @@ impl PickerDelegate for ProjectSymbolsDelegate {editor.update(cx, |editor, cx| {let multibuffer_snapshot = editor.buffer().read(cx).snapshot(cx);- let Some((excerpt_id, _, buffer_snapshot)) =- multibuffer_snapshot.as_singleton()- else {+ let Some(buffer_snapshot) = multibuffer_snapshot.as_singleton() else {return;};let text_anchor = buffer_snapshot.anchor_before(position);- let anchor = Anchor::in_buffer(excerpt_id, text_anchor);+ let Some(anchor) = multibuffer_snapshot.anchor_in_buffer(text_anchor)+ else {+ return;+ };editor.change_selections(SelectionEffects::scroll(Autoscroll::center()),window,