Skip to content

Commit

Permalink
Clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
d0cd committed Jul 3, 2024
1 parent 6404d22 commit 72d09ff
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions compiler/passes/src/type_checking/check_program.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,8 @@ impl<'a, N: Network> ProgramVisitor<'a> for TypeChecker<'a, N> {
check_has_field(sym::owner, Type::Address);
}
// For structs, check that there is at least one member.
else {
if input.members.is_empty() {
self.emit_err(TypeCheckerError::empty_struct(input.span()));
}
else if input.members.is_empty() {
self.emit_err(TypeCheckerError::empty_struct(input.span()));
}

if !(input.is_record && self.scope_state.is_stub) {
Expand Down

0 comments on commit 72d09ff

Please sign in to comment.