multi_buffer: Remove redundant buffer id field (#43459)
It is easy for us to get the two fields out of sync causing weird problems, there is no reason to have both here so. Release Notes: - N/A *or* Added/Fixed/Improved ... Co-authored by: Antonio Scandurra <antonio@zed.dev>
This commit is contained in:
@@ -284,7 +284,7 @@ impl DiagnosticBlock {
|
||||
if range.context.overlaps(&diagnostic.range, &snapshot) {
|
||||
Self::jump_to(
|
||||
editor,
|
||||
Anchor::range_in_buffer(excerpt_id, buffer_id, diagnostic.range),
|
||||
Anchor::range_in_buffer(excerpt_id, diagnostic.range),
|
||||
window,
|
||||
cx,
|
||||
);
|
||||
|
||||
@@ -308,7 +308,7 @@ impl ProjectDiagnosticsEditor {
|
||||
.selections
|
||||
.all_anchors(&snapshot)
|
||||
.iter()
|
||||
.filter_map(|anchor| anchor.start.buffer_id)
|
||||
.filter_map(|anchor| anchor.start.text_anchor.buffer_id)
|
||||
.collect::<HashSet<_>>()
|
||||
});
|
||||
for buffer_id in buffer_ids {
|
||||
|
||||
Reference in New Issue
Block a user