mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 23:04:49 +00:00
1.65 clippy fixes
This commit is contained in:
parent
f0d6e418fa
commit
66a1ba00eb
53 changed files with 224 additions and 225 deletions
|
@ -284,7 +284,7 @@ impl AbilityAliases {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
pub enum CapturedSymbols<'a> {
|
||||
None,
|
||||
Captured(&'a [(Symbol, Variable)]),
|
||||
|
@ -317,7 +317,7 @@ pub struct Proc<'a> {
|
|||
pub host_exposed_layouts: HostExposedLayouts<'a>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
pub enum HostExposedLayouts<'a> {
|
||||
NotHostExposed,
|
||||
HostExposed {
|
||||
|
@ -326,13 +326,13 @@ pub enum HostExposedLayouts<'a> {
|
|||
},
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
pub enum SelfRecursive {
|
||||
NotSelfRecursive,
|
||||
SelfRecursive(JoinPointId),
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
pub enum Parens {
|
||||
NotNeeded,
|
||||
InTypeParam,
|
||||
|
@ -1575,7 +1575,7 @@ impl<'a, 'i> Env<'a, 'i> {
|
|||
#[derive(Clone, Debug, PartialEq, Copy, Eq, Hash)]
|
||||
pub struct JoinPointId(pub Symbol);
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
pub struct Param<'a> {
|
||||
pub symbol: Symbol,
|
||||
pub borrow: bool,
|
||||
|
@ -1659,7 +1659,7 @@ pub enum Stmt<'a> {
|
|||
}
|
||||
|
||||
/// in the block below, symbol `scrutinee` is assumed be be of shape `tag_id`
|
||||
#[derive(Clone, Debug, PartialEq)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
pub enum BranchInfo<'a> {
|
||||
None,
|
||||
Constructor {
|
||||
|
@ -1702,7 +1702,7 @@ impl<'a> BranchInfo<'a> {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
pub enum ModifyRc {
|
||||
/// Increment a reference count
|
||||
Inc(Symbol, u64),
|
||||
|
@ -1848,7 +1848,7 @@ impl<'a> Call<'a> {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
pub struct CallSpecId {
|
||||
id: u32,
|
||||
}
|
||||
|
@ -1863,7 +1863,7 @@ impl CallSpecId {
|
|||
pub const BACKEND_DUMMY: Self = Self { id: 0 };
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
pub struct UpdateModeId {
|
||||
id: u32,
|
||||
}
|
||||
|
@ -1878,7 +1878,7 @@ impl UpdateModeId {
|
|||
pub const BACKEND_DUMMY: Self = Self { id: 0 };
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
pub struct UpdateModeIds {
|
||||
next: u32,
|
||||
}
|
||||
|
@ -1914,7 +1914,7 @@ pub enum CallType<'a> {
|
|||
HigherOrder(&'a HigherOrderLowLevel<'a>),
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug, PartialEq)]
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
|
||||
pub struct PassedFunction<'a> {
|
||||
/// name of the top-level function that is passed as an argument
|
||||
/// e.g. in `List.map xs Num.abs` this would be `Num.abs`
|
||||
|
@ -1931,7 +1931,7 @@ pub struct PassedFunction<'a> {
|
|||
pub owns_captured_environment: bool,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
pub struct HigherOrderLowLevel<'a> {
|
||||
pub op: crate::low_level::HigherOrder,
|
||||
|
||||
|
@ -7009,7 +7009,7 @@ fn substitute_in_call<'a>(
|
|||
} => substitute(subs, name.name()).map(|new| CallType::ByName {
|
||||
name: name.replace_name(new),
|
||||
arg_layouts,
|
||||
ret_layout: *ret_layout,
|
||||
ret_layout,
|
||||
specialization_id: *specialization_id,
|
||||
}),
|
||||
CallType::Foreign { .. } => None,
|
||||
|
@ -7158,7 +7158,7 @@ fn substitute_in_expr<'a>(
|
|||
} => match substitute(subs, *structure) {
|
||||
Some(structure) => Some(StructAtIndex {
|
||||
index: *index,
|
||||
field_layouts: *field_layouts,
|
||||
field_layouts,
|
||||
structure,
|
||||
}),
|
||||
None => None,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue