aboutsummaryrefslogtreecommitdiff
path: root/helix-view/src/macros.rs
diff options
context:
space:
mode:
authorMichael Davis2022-11-23 03:28:49 +0000
committerGitHub2022-11-23 03:28:49 +0000
commit42e37a571e75aaf4feb1717dfebe8cf215e535dd (patch)
tree385e494b1d10ce6d40b59162dae0b059d4eeb583 /helix-view/src/macros.rs
parent642a961c032b2a7e7fa67bfc3da54588d0ae8c5b (diff)
Apply transactions to all views (#4733)
* Add a test case for updating jumplists across windows * Apply transactions to all views on history changes This ensures that jumplist selections follow changes in documents, even when there are multiple views (for example a split where both windows edit the same document). * Leave TODOs for cleaning up View::apply * Use Iterator::reduce to compose history transactions Co-authored-by: Blaž Hrastnik <blaz@mxxn.io> Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
Diffstat (limited to 'helix-view/src/macros.rs')
-rw-r--r--helix-view/src/macros.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/helix-view/src/macros.rs b/helix-view/src/macros.rs
index 53ab4346..ee9cd411 100644
--- a/helix-view/src/macros.rs
+++ b/helix-view/src/macros.rs
@@ -67,7 +67,7 @@ macro_rules! view {
#[macro_export]
macro_rules! doc {
($editor:expr, $id:expr) => {{
- $editor.documents[$id]
+ &$editor.documents[$id]
}};
($editor:expr) => {{
$crate::current_ref!($editor).1