aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir_ty/src/traits
diff options
context:
space:
mode:
authorFlorian Diebold <[email protected]>2020-02-07 14:13:15 +0000
committerFlorian Diebold <[email protected]>2020-02-07 17:28:10 +0000
commitdded90a748737c3661aad043524f2248e324c867 (patch)
treef871cdf435b0c4d5cafa9f4c3f5c725e823e8088 /crates/ra_hir_ty/src/traits
parent6787f124b5557120cd1e4557cbdb59aa7f215be6 (diff)
Formatting
Diffstat (limited to 'crates/ra_hir_ty/src/traits')
-rw-r--r--crates/ra_hir_ty/src/traits/chalk.rs11
1 files changed, 8 insertions, 3 deletions
diff --git a/crates/ra_hir_ty/src/traits/chalk.rs b/crates/ra_hir_ty/src/traits/chalk.rs
index 8260bd157..4974c565b 100644
--- a/crates/ra_hir_ty/src/traits/chalk.rs
+++ b/crates/ra_hir_ty/src/traits/chalk.rs
@@ -144,8 +144,11 @@ impl ToChalk for Ty {
144 } 144 }
145 Ty::Param(id) => { 145 Ty::Param(id) => {
146 let interned_id = db.intern_type_param_id(id); 146 let interned_id = db.intern_type_param_id(id);
147 PlaceholderIndex { ui: UniverseIndex::ROOT, idx: interned_id.as_intern_id().as_usize() } 147 PlaceholderIndex {
148 .to_ty::<TypeFamily>() 148 ui: UniverseIndex::ROOT,
149 idx: interned_id.as_intern_id().as_usize(),
150 }
151 .to_ty::<TypeFamily>()
149 } 152 }
150 Ty::Bound(idx) => chalk_ir::TyData::BoundVar(idx as usize).intern(), 153 Ty::Bound(idx) => chalk_ir::TyData::BoundVar(idx as usize).intern(),
151 Ty::Infer(_infer_ty) => panic!("uncanonicalized infer ty"), 154 Ty::Infer(_infer_ty) => panic!("uncanonicalized infer ty"),
@@ -178,7 +181,9 @@ impl ToChalk for Ty {
178 }, 181 },
179 chalk_ir::TyData::Placeholder(idx) => { 182 chalk_ir::TyData::Placeholder(idx) => {
180 assert_eq!(idx.ui, UniverseIndex::ROOT); 183 assert_eq!(idx.ui, UniverseIndex::ROOT);
181 let interned_id = crate::db::GlobalTypeParamId::from_intern_id(crate::salsa::InternId::from(idx.idx)); 184 let interned_id = crate::db::GlobalTypeParamId::from_intern_id(
185 crate::salsa::InternId::from(idx.idx),
186 );
182 Ty::Param(db.lookup_intern_type_param_id(interned_id)) 187 Ty::Param(db.lookup_intern_type_param_id(interned_id))
183 } 188 }
184 chalk_ir::TyData::Alias(proj) => { 189 chalk_ir::TyData::Alias(proj) => {