mirror of
https://github.com/rust-lang/rust-analyzer
synced 2025-01-16 07:03:57 +00:00
2223b4fa71
Setup infra for handling auto trait bounds disabled due to perf problems
This patch updates some of the partially-implemented functions of `ChalkContext as RustIrDatabase`, namely `adt_datum()` and `impl_provided_for()`. With those, we can now correctly work with auto trait bounds and distinguish methods based on them.
Resolves #7856 (the second code; the first one is resolved by #13074)
**IMPORTANT**: I don't think we want to merge this until #7637 is resolved. Currently this patch introduces A LOT of unknown types and type mismtaches as shown below. This is because we cannot resolve items like `hashbrown::HashMap` in `std` modules, leading to auto trait bounds on them and their dependents unprovable.
|crate (from `rustc-perf@c52ee6` except for r-a)|e3dc5a588f07d6f1d3a0f33051d4af26190abe9e|HEAD of this branch|
|---|---|---|
|rust-analyzer @
|
||
---|---|---|
.. | ||
consteval | ||
diagnostics | ||
infer | ||
layout | ||
mir | ||
tests | ||
autoderef.rs | ||
builder.rs | ||
chalk_db.rs | ||
chalk_ext.rs | ||
consteval.rs | ||
db.rs | ||
diagnostics.rs | ||
display.rs | ||
infer.rs | ||
inhabitedness.rs | ||
interner.rs | ||
lang_items.rs | ||
layout.rs | ||
lib.rs | ||
lower.rs | ||
mapping.rs | ||
method_resolution.rs | ||
mir.rs | ||
primitive.rs | ||
test_db.rs | ||
tests.rs | ||
tls.rs | ||
traits.rs | ||
utils.rs |