Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
git: Fix another `WrapPointCursor` panic in `spacer_blocks` (#48932)
Cole Miller40b468e69e5d
diff --git a/crates/editor/src/display_map/block_map.rs b/crates/editor/src/display_map/block_map.rsindex 3acef01f444..a43c61c8617 100644--- a/crates/editor/src/display_map/block_map.rs+++ b/crates/editor/src/display_map/block_map.rs@@ -1314,7 +1314,8 @@ impl BlockMap {(first_point, edit_for_first_point.new.start)};let our_baseline = our_wrapper(our_baseline);- let their_baseline = companion_wrapper(their_baseline);+ let their_baseline =+ companion_wrapper(their_baseline.min(excerpt.target_excerpt_range.end));let mut delta = their_baseline.0 as i32 - our_baseline.0 as i32;