aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
Diffstat (limited to 'crates')
-rw-r--r--crates/hir_ty/src/traits/chalk.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/crates/hir_ty/src/traits/chalk.rs b/crates/hir_ty/src/traits/chalk.rs
index 08c2c9a3e..17c83b6a4 100644
--- a/crates/hir_ty/src/traits/chalk.rs
+++ b/crates/hir_ty/src/traits/chalk.rs
@@ -246,7 +246,8 @@ impl<'a> chalk_solve::RustIrDatabase<Interner> for ChalkContext<'a> {
246 } 246 }
247 // FIXME: lookup names 247 // FIXME: lookup names
248 fn adt_name(&self, struct_id: chalk_ir::AdtId<Interner>) -> String { 248 fn adt_name(&self, struct_id: chalk_ir::AdtId<Interner>) -> String {
249 format!("Adt_{:?}", struct_id.0).replace("TypeCtorId(", "").replace(")", "") 249 let datum = self.db.struct_datum(self.krate, struct_id);
250 format!("{:?}", datum.name(&Interner))
250 } 251 }
251 fn assoc_type_name(&self, assoc_ty_id: chalk_ir::AssocTypeId<Interner>) -> String { 252 fn assoc_type_name(&self, assoc_ty_id: chalk_ir::AssocTypeId<Interner>) -> String {
252 format!("Assoc_{}", assoc_ty_id.0) 253 format!("Assoc_{}", assoc_ty_id.0)