diff options
author | Zac Pullar-Strecker <[email protected]> | 2020-06-16 06:50:18 +0100 |
---|---|---|
committer | Zac Pullar-Strecker <[email protected]> | 2020-06-30 09:10:24 +0100 |
commit | f98e311617f66654b7799a966fc16b272438ed00 (patch) | |
tree | f8b4371f23d3fcb95ae584a7e8ab580bbcb82994 /crates | |
parent | 10c50b140aa67f74a135e7a48ff6d954cc757cb8 (diff) |
Return a resolver for Definition::Local
Diffstat (limited to 'crates')
-rw-r--r-- | crates/ra_ide_db/src/defs.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/crates/ra_ide_db/src/defs.rs b/crates/ra_ide_db/src/defs.rs index b07395a64..bc6e89cbc 100644 --- a/crates/ra_ide_db/src/defs.rs +++ b/crates/ra_ide_db/src/defs.rs | |||
@@ -89,8 +89,7 @@ impl Definition { | |||
89 | } | 89 | } |
90 | Definition::Macro(m) => Into::<ModuleId>::into(m.module(db)?).resolver(db), | 90 | Definition::Macro(m) => Into::<ModuleId>::into(m.module(db)?).resolver(db), |
91 | Definition::SelfType(imp) => Into::<ImplId>::into(imp.clone()).resolver(db), | 91 | Definition::SelfType(imp) => Into::<ImplId>::into(imp.clone()).resolver(db), |
92 | // it's possible, read probable, that other arms of this are also unreachable | 92 | Definition::Local(local) => Into::<DefWithBodyId>::into(local.parent(db)).resolver(db), |
93 | Definition::Local(_local) => unreachable!(), | ||
94 | Definition::TypeParam(tp) => Into::<ModuleId>::into(tp.module(db)).resolver(db), | 93 | Definition::TypeParam(tp) => Into::<ModuleId>::into(tp.module(db)).resolver(db), |
95 | }) | 94 | }) |
96 | } | 95 | } |