aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/ty.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_hir/src/ty.rs')
-rw-r--r--crates/ra_hir/src/ty.rs6
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;
17use std::sync::Arc; 17use std::sync::Arc;
18use std::{fmt, iter, mem}; 18use std::{fmt, iter, mem};
19 19
20use hir_def::{generics::GenericParams, AdtId}; 20use hir_def::{generics::GenericParams, AdtId, GenericDefId};
21use ra_db::{impl_intern_key, salsa}; 21use ra_db::{impl_intern_key, salsa};
22 22
23use crate::{ 23use 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}