One big cleanup pass of clippy lints
Co-authored-by: Mikayla <mikayla@zed.dev>
This commit is contained in:
parent
e7540d2833
commit
8ba2f77148
138 changed files with 1328 additions and 1366 deletions
|
@ -126,10 +126,10 @@ fn motion(motion: Motion, cx: &mut MutableAppContext) {
|
|||
impl Motion {
|
||||
pub fn linewise(self) -> bool {
|
||||
use Motion::*;
|
||||
match self {
|
||||
Down | Up | StartOfDocument | EndOfDocument | CurrentLine => true,
|
||||
_ => false,
|
||||
}
|
||||
matches!(
|
||||
self,
|
||||
Down | Up | StartOfDocument | EndOfDocument | CurrentLine
|
||||
)
|
||||
}
|
||||
|
||||
pub fn inclusive(self) -> bool {
|
||||
|
@ -282,8 +282,7 @@ fn next_word_end(
|
|||
// we have backtraced already
|
||||
if !map
|
||||
.chars_at(point)
|
||||
.skip(1)
|
||||
.next()
|
||||
.nth(1)
|
||||
.map(|c| c == '\n')
|
||||
.unwrap_or(true)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue