From b22beed737531e78cb0aa8a20d3b49e679295779 Mon Sep 17 00:00:00 2001 From: Andrew Cann Date: Mon, 1 Aug 2016 12:56:23 +0800 Subject: [PATCH] Fix build after rebase to lastest master --- src/librustc_typeck/check/_match.rs | 2 +- src/librustc_typeck/check/mod.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/librustc_typeck/check/_match.rs b/src/librustc_typeck/check/_match.rs index 6b9917afdfb..dae7bc9662f 100644 --- a/src/librustc_typeck/check/_match.rs +++ b/src/librustc_typeck/check/_match.rs @@ -610,7 +610,7 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> { let scheme = tcx.lookup_item_type(def.def_id()); let scheme = if scheme.ty.is_fn() { // Replace constructor type with constructed type for tuple struct patterns. - let fn_ret = tcx.no_late_bound_regions(&scheme.ty.fn_ret()).unwrap().unwrap(); + let fn_ret = tcx.no_late_bound_regions(&scheme.ty.fn_ret()).unwrap(); ty::TypeScheme { ty: fn_ret, generics: scheme.generics } } else { // Leave the type as is for unit structs (backward compatibility). diff --git a/src/librustc_typeck/check/mod.rs b/src/librustc_typeck/check/mod.rs index 6d19babf41f..3e8852d6332 100644 --- a/src/librustc_typeck/check/mod.rs +++ b/src/librustc_typeck/check/mod.rs @@ -4090,7 +4090,7 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> { def: Def, span: Span, node_id: ast::NodeId, - node_is_expr: bool) { + node_is_expr: bool) -> Ty<'tcx> { debug!("instantiate_value_path(path={:?}, def={:?}, node_id={}, type_scheme={:?})", segments,