diff options
Diffstat (limited to 'crates/ra_hir/src/ty.rs')
-rw-r--r-- | crates/ra_hir/src/ty.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_hir/src/ty.rs b/crates/ra_hir/src/ty.rs index f62316c1f..2473ac574 100644 --- a/crates/ra_hir/src/ty.rs +++ b/crates/ra_hir/src/ty.rs | |||
@@ -17,7 +17,7 @@ use std::ops::Deref; | |||
17 | use std::sync::Arc; | 17 | use std::sync::Arc; |
18 | use std::{fmt, iter, mem}; | 18 | use std::{fmt, iter, mem}; |
19 | 19 | ||
20 | use hir_def::{generics::GenericParams, AdtId}; | 20 | use hir_def::{generics::GenericParams, AdtId, GenericDefId}; |
21 | use ra_db::{impl_intern_key, salsa}; | 21 | use ra_db::{impl_intern_key, salsa}; |
22 | 22 | ||
23 | use crate::{ | 23 | use crate::{ |
@@ -176,7 +176,7 @@ impl TypeCtor { | |||
176 | } | 176 | } |
177 | } | 177 | } |
178 | 178 | ||
179 | pub fn as_generic_def(self) -> Option<crate::GenericDef> { | 179 | pub fn as_generic_def(self) -> Option<GenericDefId> { |
180 | match self { | 180 | match self { |
181 | TypeCtor::Bool | 181 | TypeCtor::Bool |
182 | | TypeCtor::Char | 182 | | TypeCtor::Char |
@@ -193,7 +193,7 @@ impl TypeCtor { | |||
193 | | TypeCtor::Closure { .. } => None, | 193 | | TypeCtor::Closure { .. } => None, |
194 | TypeCtor::Adt(adt) => Some(adt.into()), | 194 | TypeCtor::Adt(adt) => Some(adt.into()), |
195 | TypeCtor::FnDef(callable) => Some(callable.into()), | 195 | TypeCtor::FnDef(callable) => Some(callable.into()), |
196 | TypeCtor::AssociatedType(type_alias) => Some(type_alias.into()), | 196 | TypeCtor::AssociatedType(type_alias) => Some(type_alias.id.into()), |
197 | } | 197 | } |
198 | } | 198 | } |
199 | } | 199 | } |