aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/source_binder.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2019-10-08 12:46:14 +0100
committerGitHub <[email protected]>2019-10-08 12:46:14 +0100
commit92cf0eba93b8d2705ed39bef1a4ea665ed3c25dc (patch)
treea015a8a8162acacb61b3353b4642c93cd80e51ae /crates/ra_hir/src/source_binder.rs
parent93199002af05f3a3dfd274fe10633372f2471b73 (diff)
parentb043358be936b7f139efd49b7d187d64e319830e (diff)
Merge #1924
1924: Support inferring&completing `Self` type in enum/struct/union definitions r=ice1000 a=ice1000 Signed-off-by: ice1000 <[email protected]> An attempt to fix #1908. This code works, but I believe the implementation is ugly. Please give me suggestions! Co-authored-by: ice1000 <[email protected]>
Diffstat (limited to 'crates/ra_hir/src/source_binder.rs')
-rw-r--r--crates/ra_hir/src/source_binder.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_hir/src/source_binder.rs b/crates/ra_hir/src/source_binder.rs
index 088335e66..a907d6a9f 100644
--- a/crates/ra_hir/src/source_binder.rs
+++ b/crates/ra_hir/src/source_binder.rs
@@ -216,7 +216,7 @@ impl SourceAnalyzer {
216 let types = self.resolver.resolve_path_in_type_ns_fully(db, &path).map(|ty| match ty { 216 let types = self.resolver.resolve_path_in_type_ns_fully(db, &path).map(|ty| match ty {
217 TypeNs::SelfType(it) => PathResolution::SelfType(it), 217 TypeNs::SelfType(it) => PathResolution::SelfType(it),
218 TypeNs::GenericParam(it) => PathResolution::GenericParam(it), 218 TypeNs::GenericParam(it) => PathResolution::GenericParam(it),
219 TypeNs::Adt(it) => PathResolution::Def(it.into()), 219 TypeNs::AdtSelfType(it) | TypeNs::Adt(it) => PathResolution::Def(it.into()),
220 TypeNs::EnumVariant(it) => PathResolution::Def(it.into()), 220 TypeNs::EnumVariant(it) => PathResolution::Def(it.into()),
221 TypeNs::TypeAlias(it) => PathResolution::Def(it.into()), 221 TypeNs::TypeAlias(it) => PathResolution::Def(it.into()),
222 TypeNs::BuiltinType(it) => PathResolution::Def(it.into()), 222 TypeNs::BuiltinType(it) => PathResolution::Def(it.into()),