completions: speed up completions by filtering non-applicable traits

This commit is contained in:
David Barsky 2024-02-13 13:25:03 -05:00
parent 9f0495761a
commit c246a93046
6 changed files with 243 additions and 4 deletions

View file

@ -139,6 +139,7 @@ fn solve(
block: Option<BlockId>,
goal: &chalk_ir::UCanonical<chalk_ir::InEnvironment<chalk_ir::Goal<Interner>>>,
) -> Option<chalk_solve::Solution<Interner>> {
let _p = tracing::span!(tracing::Level::INFO, "solve", ?krate, ?block).entered();
let context = ChalkContext { db, krate, block };
tracing::debug!("solve goal: {:?}", goal);
let mut solver = create_chalk_solver();