From 5f2efae3ba29df77ef481cdda10b337a8f91d153 Mon Sep 17 00:00:00 2001 From: Jonas Schievink Date: Sun, 11 Apr 2021 01:41:40 +0200 Subject: Include more info in assert --- crates/hir_ty/src/method_resolution.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/hir_ty/src') diff --git a/crates/hir_ty/src/method_resolution.rs b/crates/hir_ty/src/method_resolution.rs index ece884241..6178b36c8 100644 --- a/crates/hir_ty/src/method_resolution.rs +++ b/crates/hir_ty/src/method_resolution.rs @@ -22,8 +22,8 @@ use crate::{ primitive::{self, FloatTy, IntTy, UintTy}, static_lifetime, utils::all_super_traits, - AdtId, Canonical, CanonicalVarKinds, DebruijnIndex, ForeignDefId, InEnvironment, Interner, - Scalar, Substitution, TraitEnvironment, TraitRefExt, Ty, TyBuilder, TyExt, TyKind, + AdtId, Canonical, CanonicalVarKinds, DebruijnIndex, ForeignDefId, HirDisplay, InEnvironment, + Interner, Scalar, Substitution, TraitEnvironment, TraitRefExt, Ty, TyBuilder, TyExt, TyKind, }; /// This is used as a key for indexing impls. @@ -259,7 +259,7 @@ impl InherentImpls { let self_ty = db.impl_self_ty(impl_id); let fp = TyFingerprint::for_inherent_impl(self_ty.skip_binders()); - always!(fp.is_some()); + always!(fp.is_some(), "no fingerprint for {}", self_ty.skip_binders().display(db)); if let Some(fp) = fp { map.entry(fp).or_default().push(impl_id); } -- cgit v1.2.3