From 6053e48575cf3b421f3eb8a6af33c853a518d9c9 Mon Sep 17 00:00:00 2001 From: Ceri Storey Date: Sat, 27 Mar 2021 10:10:54 +0000 Subject: Replace a bunch of Err(…)? and format!("constant") calls. --- dhall/src/semantics/resolve/resolve.rs | 2 +- dhall/src/semantics/tck/typecheck.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'dhall/src') diff --git a/dhall/src/semantics/resolve/resolve.rs b/dhall/src/semantics/resolve/resolve.rs index 7d74cd6..5ec16e5 100644 --- a/dhall/src/semantics/resolve/resolve.rs +++ b/dhall/src/semantics/resolve/resolve.rs @@ -558,7 +558,7 @@ pub fn skip_resolve<'cx>( parsed: Parsed, ) -> Result, Error> { let parsed = Parsed::from_expr_without_imports(parsed.0); - Ok(resolve(cx, parsed)?) + resolve(cx, parsed) } impl Parsed { diff --git a/dhall/src/semantics/tck/typecheck.rs b/dhall/src/semantics/tck/typecheck.rs index 23c2bd2..b0a4f21 100644 --- a/dhall/src/semantics/tck/typecheck.rs +++ b/dhall/src/semantics/tck/typecheck.rs @@ -256,7 +256,7 @@ pub fn type_with<'cx, 'hir>( HirKind::Expr(ExprKind::Let(binder, annot, val, body)) => { let val_annot = annot .as_ref() - .map(|t| Ok(type_with(env, t, None)?.eval_to_type(env)?)) + .map(|t| type_with(env, t, None)?.eval_to_type(env)) .transpose()?; let val = type_with(env, &val, val_annot)?; let val_nf = val.eval(env); -- cgit v1.2.3