aboutsummaryrefslogtreecommitdiff
path: root/crates/ide/src
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-03-21 15:49:31 +0000
committerGitHub <[email protected]>2021-03-21 15:49:31 +0000
commitd51cf133f68eec63eee27a8666c7590d2e8b4ef8 (patch)
treecd74909ed13e4a697459bf66afffcb06d89820cd /crates/ide/src
parent5bb65bb4962cfad613e9744a340ae23b533f479e (diff)
parent202b51bc7b6999900e06ec2cfb8d72fe9aa4af29 (diff)
Merge #8135
8135: more clippy::{perf, complexity, style} fixes r=Veykril a=matthiaskrgr Co-authored-by: Matthias Krüger <[email protected]>
Diffstat (limited to 'crates/ide/src')
-rw-r--r--crates/ide/src/extend_selection.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/crates/ide/src/extend_selection.rs b/crates/ide/src/extend_selection.rs
index e187243cb..5201ce587 100644
--- a/crates/ide/src/extend_selection.rs
+++ b/crates/ide/src/extend_selection.rs
@@ -263,11 +263,10 @@ fn extend_list_item(node: &SyntaxNode) -> Option<TextRange> {
263 ) -> Option<SyntaxToken> { 263 ) -> Option<SyntaxToken> {
264 node.siblings_with_tokens(dir) 264 node.siblings_with_tokens(dir)
265 .skip(1) 265 .skip(1)
266 .skip_while(|node| match node { 266 .find(|node| match node {
267 NodeOrToken::Node(_) => false, 267 NodeOrToken::Node(_) => true,
268 NodeOrToken::Token(it) => is_single_line_ws(it), 268 NodeOrToken::Token(it) => !is_single_line_ws(it),
269 }) 269 })
270 .next()
271 .and_then(|it| it.into_token()) 270 .and_then(|it| it.into_token())
272 .filter(|node| node.kind() == delimiter_kind) 271 .filter(|node| node.kind() == delimiter_kind)
273 } 272 }