about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/librustc/infer/error_reporting/named_anon_conflict.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/librustc/infer/error_reporting/named_anon_conflict.rs b/src/librustc/infer/error_reporting/named_anon_conflict.rs
index 7027c868e6e..80fb4ce8e03 100644
--- a/src/librustc/infer/error_reporting/named_anon_conflict.rs
+++ b/src/librustc/infer/error_reporting/named_anon_conflict.rs
@@ -78,8 +78,7 @@ impl<'a, 'gcx, 'tcx> InferCtxt<'a, 'gcx, 'tcx> {
             return false;
         }
 
-        if let Some(anon_ty) = self.find_anon_type(anon, &br) {
-            let (_, fndecl) = anon_ty;
+        if let Some((_, fndecl)) = self.find_anon_type(anon, &br) {
             if self.is_return_type_anon(scope_def_id, br, fndecl).is_some() ||
                self.is_self_anon(is_first, scope_def_id) {
                 return false;