mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 04:19:13 +00:00
Auto merge of #14755 - poliorcetics:clippy-fixes, r=Veykril
Fix: a TODO and some clippy fixes - fix(todo): implement IntoIterator for ArenaMap<IDX, V> - chore: remove unused method - fix: remove useless `return`s - fix: various clippy lints - fix: simplify boolean test to a single negation
This commit is contained in:
commit
2df56cadcb
10 changed files with 71 additions and 30 deletions
|
@ -109,13 +109,6 @@ pub enum ChangeKind {
|
|||
}
|
||||
|
||||
impl Vfs {
|
||||
/// Amount of files currently stored.
|
||||
///
|
||||
/// Note that this includes deleted files.
|
||||
pub fn len(&self) -> usize {
|
||||
self.data.len()
|
||||
}
|
||||
|
||||
/// Id of the given path if it exists in the `Vfs` and is not deleted.
|
||||
pub fn file_id(&self, path: &VfsPath) -> Option<FileId> {
|
||||
self.interner.get(path).filter(|&it| self.get(it).is_some())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue