Support diagnostic navigation in multibuffers (#22620)

cc @nathansobo 

Release Notes:

- Support diagnostic navigation in multibuffers
This commit is contained in:
Cole Miller
2025-01-03 18:07:56 +00:00
committed by GitHub
parent 39af06085a
commit 11ec25aedb
13 changed files with 209 additions and 150 deletions
+6
View File
@@ -3047,6 +3047,12 @@ pub trait FromAnchor {
fn from_anchor(anchor: &Anchor, snapshot: &BufferSnapshot) -> Self;
}
impl FromAnchor for Anchor {
fn from_anchor(anchor: &Anchor, _snapshot: &BufferSnapshot) -> Self {
*anchor
}
}
impl FromAnchor for Point {
fn from_anchor(anchor: &Anchor, snapshot: &BufferSnapshot) -> Self {
snapshot.summary_for_anchor(anchor)