From 7e104ea4a885c8fd6f348a0d7d30911fe49d91e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lauren=C8=9Biu=20Nicola?= Date: Mon, 22 Jun 2020 14:18:10 +0300 Subject: Bump chalk --- crates/ra_hir_ty/src/traits/chalk/interner.rs | 1 + crates/ra_hir_ty/src/traits/chalk/mapping.rs | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) (limited to 'crates/ra_hir_ty/src/traits/chalk') diff --git a/crates/ra_hir_ty/src/traits/chalk/interner.rs b/crates/ra_hir_ty/src/traits/chalk/interner.rs index 56aab640c..15426b022 100644 --- a/crates/ra_hir_ty/src/traits/chalk/interner.rs +++ b/crates/ra_hir_ty/src/traits/chalk/interner.rs @@ -42,6 +42,7 @@ impl chalk_ir::interner::Interner for Interner { type DefId = InternId; type InternedAdtId = crate::TypeCtorId; type Identifier = TypeAliasId; + type FnAbi = (); fn debug_adt_id(type_kind_id: AdtId, fmt: &mut fmt::Formatter<'_>) -> Option { tls::with_current_program(|prog| Some(prog?.debug_struct_id(type_kind_id, fmt))) diff --git a/crates/ra_hir_ty/src/traits/chalk/mapping.rs b/crates/ra_hir_ty/src/traits/chalk/mapping.rs index 18e5c9c16..ac82ea831 100644 --- a/crates/ra_hir_ty/src/traits/chalk/mapping.rs +++ b/crates/ra_hir_ty/src/traits/chalk/mapping.rs @@ -65,7 +65,10 @@ impl ToChalk for Ty { &Interner, predicates.iter().filter(|p| !p.is_error()).cloned().map(|p| p.to_chalk(db)), ); - let bounded_ty = chalk_ir::DynTy { bounds: make_binders(where_clauses, 1) }; + let bounded_ty = chalk_ir::DynTy { + bounds: make_binders(where_clauses, 1), + lifetime: LIFETIME_PLACEHOLDER.to_lifetime(&Interner), + }; chalk_ir::TyData::Dyn(bounded_ty).intern(&Interner) } Ty::Opaque(opaque_ty) => { @@ -319,6 +322,10 @@ impl ToChalk for TypeCtor { // this should not be reached, since we don't represent TypeName::Error with TypeCtor unreachable!() } + TypeName::Closure(_) => { + // FIXME: implement closure support + unreachable!() + } } } } -- cgit v1.2.3