Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide-db/src/search.rs')
| -rw-r--r-- | crates/ide-db/src/search.rs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/crates/ide-db/src/search.rs b/crates/ide-db/src/search.rs index e2b20ef92f..7769d8fba1 100644 --- a/crates/ide-db/src/search.rs +++ b/crates/ide-db/src/search.rs @@ -536,14 +536,12 @@ impl<'a> FindUsages<'a> { // Search for occurrences of the items name for offset in match_indices(&text, finder, search_range) { - tree.token_at_offset(offset).into_iter().for_each(|token| { + tree.token_at_offset(offset).for_each(|token| { let Some(str_token) = ast::String::cast(token.clone()) else { return }; if let Some((range, nameres)) = sema.check_for_format_args_template(token, offset) { - if self.found_format_args_ref(file_id, range, str_token, nameres, sink) { - return; - } + if self.found_format_args_ref(file_id, range, str_token, nameres, sink) {} } }); |