diff options
author | Blaž Hrastnik | 2021-03-22 04:16:56 +0000 |
---|---|---|
committer | Blaž Hrastnik | 2021-03-22 04:16:56 +0000 |
commit | 698e4ddea46e9c94d537c8e4a6c69e7dc9ee1947 (patch) | |
tree | 5411ea3186d1a1481776ad4d84af38cd5a0c595f /helix-term/src/ui/mod.rs | |
parent | cbcacb1063c9b6384867a6078a75595ae2ff6861 (diff) |
clippy: Factor out a Completion type.
Diffstat (limited to 'helix-term/src/ui/mod.rs')
-rw-r--r-- | helix-term/src/ui/mod.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/helix-term/src/ui/mod.rs b/helix-term/src/ui/mod.rs index b35cba60..ca133b66 100644 --- a/helix-term/src/ui/mod.rs +++ b/helix-term/src/ui/mod.rs @@ -137,9 +137,10 @@ pub fn buffer_picker(views: &[View], current: usize) -> Picker<(Option<PathBuf>, } pub mod completers { - use std::{borrow::Cow, ops::RangeFrom}; + use crate::ui::prompt::Completion; + use std::borrow::Cow; // TODO: we could return an iter/lazy thing so it can fetch as many as it needs. - pub fn filename(input: &str) -> Vec<(RangeFrom<usize>, Cow<'static, str>)> { + pub fn filename(input: &str) -> Vec<Completion> { // Rust's filename handling is really annoying. use ignore::WalkBuilder; |