Make `lookup_impl_method()` query transparent
The bulk of the work is trait solving and cached in the trait solver's cache, and this will save memory.
diff --git a/crates/hir-ty/src/consteval.rs b/crates/hir-ty/src/consteval.rs
index 002e082..761d722 100644
--- a/crates/hir-ty/src/consteval.rs
+++ b/crates/hir-ty/src/consteval.rs
@@ -5,13 +5,12 @@
 
 use base_db::Crate;
 use hir_def::{
-    EnumVariantId, GeneralConstId,
+    EnumVariantId, GeneralConstId, HasModule, StaticId,
     expr_store::{Body, HygieneId, path::Path},
     hir::{Expr, ExprId},
     resolver::{Resolver, ValueNs},
     type_ref::LiteralConstRef,
 };
-use hir_def::{HasModule, StaticId};
 use hir_expand::Lookup;
 use rustc_type_ir::{UnevaluatedConst, inherent::IntoKind};
 use stdx::never;
diff --git a/crates/hir-ty/src/db.rs b/crates/hir-ty/src/db.rs
index 4b33c8a..6c1d05a 100644
--- a/crates/hir-ty/src/db.rs
+++ b/crates/hir-ty/src/db.rs
@@ -96,6 +96,7 @@
     ) -> Result<i128, ConstEvalError<'db>>;
 
     #[salsa::invoke(crate::method_resolution::lookup_impl_method_query)]
+    #[salsa::transparent]
     fn lookup_impl_method<'db>(
         &'db self,
         env: Arc<TraitEnvironment<'db>>,