chore: bow to the clippy

This commit is contained in:
rvcas 2023-03-14 17:03:28 -04:00
parent 724f1ac4b6
commit 2a00ef281b
No known key found for this signature in database
GPG Key ID: C09B64E263F7D68C
4 changed files with 3 additions and 10 deletions

View File

@ -718,18 +718,13 @@ impl Annotation {
}
}
#[derive(Debug, Clone, PartialEq, Eq)]
#[derive(Debug, Clone, PartialEq, Eq, Default)]
pub enum Layer {
#[default]
Value,
Type,
}
impl Default for Layer {
fn default() -> Self {
Layer::Value
}
}
impl Layer {
/// Returns `true` if the layer is [`Value`].
pub fn is_value(&self) -> bool {

View File

@ -792,7 +792,7 @@ Perhaps, try the following:
suggest_neighbor(
name,
variables.iter(),
&if name.chars().into_iter().next().unwrap().is_uppercase() {
&if name.chars().next().unwrap().is_uppercase() {
suggest_import_constructor()
} else {
"Did you forget to import it?".to_string()

View File

@ -4468,7 +4468,6 @@ impl<'a> CodeGenerator<'a> {
| DefaultFunction::Trace => unimplemented!("{func:#?}"),
DefaultFunction::ChooseData => {
let temp_vars = (0..func.arity())
.into_iter()
.map(|_| format!("__item_{}", self.id_gen.next()))
.collect_vec();

View File

@ -138,7 +138,6 @@ pub fn aiken_files_excluding_gitignore(dir: &Path) -> impl Iterator<Item = PathB
.follow_links(true)
.require_git(false)
.build()
.into_iter()
.filter_map(Result::ok)
.filter(|e| e.file_type().map(|t| t.is_file()).unwrap_or(false))
.map(ignore::DirEntry::into_path)