diff --git a/crates/editor/src/editor.rs b/crates/editor/src/editor.rs index ba6f378a9a19c50bcdf27eff91e80909595e7ede..46cae97f7d665b231251e8ad89b8983eef853030 100644 --- a/crates/editor/src/editor.rs +++ b/crates/editor/src/editor.rs @@ -8778,6 +8778,13 @@ impl Editor { self.change_selections(None, window, cx, |s| { s.select_anchors(selections.to_vec()); }); + } else { + log::error!( + "No entry in selection_history found for undo. \ + This may correspond to a bug where undo does not update the selection. \ + If this is occurring, please add details to \ + https://github.com/zed-industries/zed/issues/22692" + ); } self.request_autoscroll(Autoscroll::fit(), cx); self.unmark_text(window, cx); @@ -8799,6 +8806,13 @@ impl Editor { self.change_selections(None, window, cx, |s| { s.select_anchors(selections.to_vec()); }); + } else { + log::error!( + "No entry in selection_history found for redo. \ + This may correspond to a bug where undo does not update the selection. \ + If this is occurring, please add details to \ + https://github.com/zed-industries/zed/issues/22692" + ); } self.request_autoscroll(Autoscroll::fit(), cx); self.unmark_text(window, cx);