From 6c3ddcfa501060cff3a7f81c179f712ef072c808 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Sun, 22 Dec 2019 15:37:07 +0100 Subject: Simplify --- crates/ra_hir_def/src/body/scope.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'crates/ra_hir_def/src/body') diff --git a/crates/ra_hir_def/src/body/scope.rs b/crates/ra_hir_def/src/body/scope.rs index ab6599b23..a63552327 100644 --- a/crates/ra_hir_def/src/body/scope.rs +++ b/crates/ra_hir_def/src/body/scope.rs @@ -183,8 +183,8 @@ mod tests { let crate_def_map = db.crate_def_map(krate); let module = crate_def_map.modules_for_file(file_id).next().unwrap(); - let (_, res) = crate_def_map[module].scope.entries().next().unwrap(); - match res.def.take_values().unwrap() { + let (_, def) = crate_def_map[module].scope.entries().next().unwrap(); + match def.take_values().unwrap() { ModuleDefId::FunctionId(it) => it, _ => panic!(), } -- cgit v1.2.3