Skip to content

Commit

Permalink
Remove unnecessary changes in push
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasschafer committed Jun 15, 2024
1 parent 381660c commit fa15699
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions helix-view/src/view.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,12 @@ impl JumpList {
if self.jumps.back() != Some(&jump) {
// If the jumplist is full, drop the oldest item.
while self.jumps.len() >= JUMP_LIST_CAPACITY {
if self.jumps.pop_front().is_some() {
self.current = self.current.saturating_sub(1);
}
self.jumps.pop_front();
}

self.jumps.push_back(jump);
self.current = self.jumps.len();
}
self.current = self.jumps.len();
}

pub fn forward(&mut self, count: usize) -> Option<&Jump> {
Expand Down

0 comments on commit fa15699

Please sign in to comment.