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:
bors 2023-05-24 11:13:52 +00:00
commit 2df56cadcb
10 changed files with 71 additions and 30 deletions

View file

@ -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())