fix: Always explicitly set trait ref self types when lowering

This commit is contained in:
Lukas Wirth 2024-09-06 14:04:57 +02:00
parent 70ee4e5545
commit 20f7ab5ab4
9 changed files with 80 additions and 64 deletions

View file

@ -95,8 +95,10 @@ pub trait WithFixture: Default + ExpandDatabase + SourceRootDatabase + 'static {
fn test_crate(&self) -> CrateId {
let crate_graph = self.crate_graph();
let mut it = crate_graph.iter();
let res = it.next().unwrap();
assert!(it.next().is_none());
let mut res = it.next().unwrap();
while crate_graph[res].origin.is_lang() {
res = it.next().unwrap();
}
res
}
}