Skip to content

Commit

Permalink
Elide unused named lifetimes
Browse files Browse the repository at this point in the history
  • Loading branch information
sholderbach committed Dec 19, 2024
1 parent 8f23bda commit aada8af
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/completion/history.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ pub(crate) struct HistoryCompleter<'menu>(&'menu dyn History);

// Safe to implement Send since the HistoryCompleter should only be used when
// updating the menu and that must happen in the same thread
unsafe impl<'menu> Send for HistoryCompleter<'menu> {}
unsafe impl Send for HistoryCompleter<'_> {}

fn search_unique(
completer: &HistoryCompleter,
Expand All @@ -30,7 +30,7 @@ fn search_unique(
.filter(move |value| seen_matching_command_lines.insert(value.command_line.clone())))
}

impl<'menu> Completer for HistoryCompleter<'menu> {
impl Completer for HistoryCompleter<'_> {
fn complete(&mut self, line: &str, pos: usize) -> Vec<Suggestion> {
match search_unique(self, line) {
Err(_) => vec![],
Expand Down

0 comments on commit aada8af

Please sign in to comment.