clippy --fix fixes

This commit is contained in:
Folkert 2023-04-21 12:05:51 +02:00
parent 9973d4b8d2
commit 4cd8f0a056
57 changed files with 366 additions and 374 deletions

View file

@ -280,7 +280,9 @@ impl AbilityAliases {
}
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
#[derive(Default)]
pub enum CapturedSymbols<'a> {
#[default]
None,
Captured(&'a [(Symbol, Variable)]),
}
@ -294,11 +296,7 @@ impl<'a> CapturedSymbols<'a> {
}
}
impl<'a> Default for CapturedSymbols<'a> {
fn default() -> Self {
CapturedSymbols::None
}
}
#[derive(Clone, Debug, PartialEq)]
pub struct Proc<'a> {
@ -2722,8 +2720,8 @@ fn patterns_to_when<'a>(
/// { x } -> body
///
/// conversion of one-pattern when expressions will do the most optimal thing
fn pattern_to_when<'a>(
env: &mut Env<'a, '_>,
fn pattern_to_when(
env: &mut Env<'_, '_>,
pattern_var: Variable,
pattern: Loc<roc_can::pattern::Pattern>,
body_var: Variable,
@ -5740,8 +5738,8 @@ fn compile_struct_like<'a, L, UnusedLayout>(
}
#[inline(always)]
fn late_resolve_ability_specialization<'a>(
env: &mut Env<'a, '_>,
fn late_resolve_ability_specialization(
env: &mut Env<'_, '_>,
member: Symbol,
specialization_id: Option<SpecializationId>,
specialization_var: Variable,