chore: bow to the clippy

This commit is contained in:
rvcas
2023-03-14 17:03:28 -04:00
parent 724f1ac4b6
commit 2a00ef281b
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();