Skip to content

Commit

Permalink
Fixing clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
notdanilo committed Nov 5, 2023
1 parent 2270586 commit 559d255
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion ecosystem/rust/parser/src/types/type_.rs
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ mod test {
type_: Type::i32().into()
}
),
TypeParser.parse(quote! {&i32}, &&Default::default())?
TypeParser.parse(quote! {&i32}, &Default::default())?
);
Ok(())
}
Expand Down
4 changes: 1 addition & 3 deletions ligen/ir/src/identifier/naming_convention.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ impl Identifier {
NamingConvention::SnakeCase
} else if self.name.chars().next().unwrap().is_uppercase() {
NamingConvention::PascalCase
} else if self.name.chars().find(|c| c.is_uppercase()).is_some() {
} else if self.name.chars().any(|c| c.is_uppercase()) {
NamingConvention::CamelCase
} else {
NamingConvention::Unknown
Expand Down Expand Up @@ -110,7 +110,6 @@ impl Identifier {
.chain(std::iter::once(self.name.len()))
.collect::<Vec<_>>();
(0 .. indices.len() - 1)
.into_iter()
.map(|i| {
&self.name[indices[i]..=(indices[i + 1] - 1)]
})
Expand All @@ -128,7 +127,6 @@ impl Identifier {
.chain(std::iter::once(self.name.len()))
).collect::<Vec<_>>();
(0 .. indices.len() - 1)
.into_iter()
.map(|i| {
&self.name[indices[i]..=(indices[i + 1] - 1)]
})
Expand Down

0 comments on commit 559d255

Please sign in to comment.