summaryrefslogtreecommitdiff
path: root/helix-core/src/history.rs
diff options
context:
space:
mode:
authorBlaž Hrastnik2021-03-18 04:28:27 +0000
committerBlaž Hrastnik2021-03-18 04:39:56 +0000
commit8eaf9a432d14b6c2dd084dabbea606e4b1e3baa0 (patch)
treea353a3a9182622b8434165825e03e2264bb444ea /helix-core/src/history.rs
parent51c15da3c32b2f0bf3da6db9bca9496d333ec15a (diff)
Make Transaction::change only rely on the rope.
Diffstat (limited to 'helix-core/src/history.rs')
-rw-r--r--helix-core/src/history.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/helix-core/src/history.rs b/helix-core/src/history.rs
index 99de3f7c..c92c2a89 100644
--- a/helix-core/src/history.rs
+++ b/helix-core/src/history.rs
@@ -96,7 +96,7 @@ mod test {
let mut state = State::new(doc);
let transaction1 =
- Transaction::change(&state, vec![(5, 5, Some(" world!".into()))].into_iter());
+ Transaction::change(&state.doc, vec![(5, 5, Some(" world!".into()))].into_iter());
// Need to commit before applying!
history.commit_revision(&transaction1, &state);
@@ -106,7 +106,7 @@ mod test {
// ---
let transaction2 =
- Transaction::change(&state, vec![(6, 11, Some("世界".into()))].into_iter());
+ Transaction::change(&state.doc, vec![(6, 11, Some("世界".into()))].into_iter());
// Need to commit before applying!
history.commit_revision(&transaction2, &state);