Skip to content

Commit

Permalink
clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
evan-schott committed Nov 30, 2023
1 parent 0badbd8 commit 7630601
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions compiler/passes/src/code_generation/visit_expressions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -540,8 +540,8 @@ impl<'a> CodeGenerator<'a> {
Some(program) => program,
None => {
let stub_program = self.program.stubs.get(&program_name);
if stub_program.is_some() {
stub_scope = ProgramScope::from(stub_program.unwrap().clone());
if let Some(stub_program_unwrapped) = stub_program {
stub_scope = ProgramScope::from(stub_program_unwrapped.clone());
&stub_scope
} else {
unreachable!("Type checking guarantees that imported and stub programs are well defined.")
Expand Down
2 changes: 1 addition & 1 deletion compiler/passes/src/destructuring/destructure_statement.rs
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ impl StatementReconstructor for Destructurer<'_> {
let statements = lhs_tuple
.elements
.into_iter()
.zip_eq(rhs_tuple.elements.into_iter())
.zip_eq(rhs_tuple.elements)
.map(|(lhs, rhs)| {
// Get the type of the rhs.
let type_ = match self.type_table.get(&lhs.id()) {
Expand Down

0 comments on commit 7630601

Please sign in to comment.