Skip to content

Commit

Permalink
cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
jonybur committed Oct 11, 2023
1 parent 3dac5c6 commit a1360f8
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions tooling/nargo_fmt/src/visitor/expr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,11 @@ impl FmtVisitor<'_> {
}
ExpressionKind::Constructor(constructor_expr) => {
let type_str = constructor_expr.type_name.to_string();
let formatted_fields = vecmap(&constructor_expr.fields, |(field_ident, field_value)| {
format!("{}: {}", field_ident, self.format_expr(field_value.clone()))
})
.join(", ");
let formatted_fields =
vecmap(&constructor_expr.fields, |(field_ident, field_value)| {
format!("{}: {}", field_ident, self.format_expr(field_value.clone()))
})
.join(", ");
format!("{} {{ {} }}", type_str, formatted_fields)
}
ExpressionKind::Index(index_expr) => {
Expand Down

0 comments on commit a1360f8

Please sign in to comment.