From d5b28bf2b4a5a26de67e4de731ad19699f33e75e Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Mon, 11 Nov 2019 18:20:24 +0000 Subject: rustfmt --- dhall/src/phase/binary.rs | 8 ++++++-- dhall/src/phase/normalize.rs | 4 +++- dhall_syntax/src/core/visitor.rs | 4 +++- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/dhall/src/phase/binary.rs b/dhall/src/phase/binary.rs index 464d71a..0639120 100644 --- a/dhall/src/phase/binary.rs +++ b/dhall/src/phase/binary.rs @@ -187,7 +187,9 @@ fn cbor_value_to_dhall(data: &cbor::Value) -> Result { let y = cbor_value_to_dhall(&y)?; ProjectionByExpr(x, y) } else { - Err(DecodeError::WrongFormatError("projection-by-expr".to_owned()))? + Err(DecodeError::WrongFormatError( + "projection-by-expr".to_owned(), + ))? } } [U64(10), x, rest @ ..] => { @@ -586,7 +588,9 @@ where .chain(once(expr(x))) .chain(ls.iter().map(label)), ), - ProjectionByExpr(x, y) => ser_seq!(ser; tag(10), expr(x), vec![expr(y)]), + ProjectionByExpr(x, y) => { + ser_seq!(ser; tag(10), expr(x), vec![expr(y)]) + } Import(import) => serialize_import(ser, import), Embed(_) => unimplemented!( "An expression with resolved imports cannot be binary-encoded" diff --git a/dhall/src/phase/normalize.rs b/dhall/src/phase/normalize.rs index ae1aefe..b712027 100644 --- a/dhall/src/phase/normalize.rs +++ b/dhall/src/phase/normalize.rs @@ -738,7 +738,9 @@ pub(crate) fn normalize_one_layer( } } } - ExprF::ProjectionByExpr(_, _) => unimplemented!("selection by expression"), + ExprF::ProjectionByExpr(_, _) => { + unimplemented!("selection by expression") + } ExprF::Merge(ref handlers, ref variant, _) => { let handlers_borrow = handlers.as_whnf(); diff --git a/dhall_syntax/src/core/visitor.rs b/dhall_syntax/src/core/visitor.rs index 6189f26..143e556 100644 --- a/dhall_syntax/src/core/visitor.rs +++ b/dhall_syntax/src/core/visitor.rs @@ -161,7 +161,9 @@ where } Field(e, l) => Field(v.visit_subexpr(e)?, l.clone()), Projection(e, ls) => Projection(v.visit_subexpr(e)?, ls.clone()), - ProjectionByExpr(e, x) => ProjectionByExpr(v.visit_subexpr(e)?, v.visit_subexpr(x)?), + ProjectionByExpr(e, x) => { + ProjectionByExpr(v.visit_subexpr(e)?, v.visit_subexpr(x)?) + } Assert(e) => Assert(v.visit_subexpr(e)?), Import(i) => Import(i.traverse_ref(|e| v.visit_subexpr(e))?), Embed(a) => Embed(v.visit_embed(a)?), -- cgit v1.2.3