fix: Don't force draw a dependency edge to the real_span_map query

This commit is contained in:
Lukas Wirth 2024-03-07 14:14:59 +01:00
parent bd0ffb0248
commit c04c0dd5ba
16 changed files with 125 additions and 114 deletions

View file

@ -611,8 +611,10 @@ mod tests {
let parsed_path_file = syntax::SourceFile::parse(&format!("use {path};"));
let ast_path =
parsed_path_file.syntax_node().descendants().find_map(syntax::ast::Path::cast).unwrap();
let mod_path =
ModPath::from_src(&db, ast_path, db.span_map(pos.file_id.into()).as_ref()).unwrap();
let mod_path = ModPath::from_src(&db, ast_path, &mut |range| {
db.span_map(pos.file_id.into()).as_ref().span_for_range(range).ctx
})
.unwrap();
let def_map = module.def_map(&db);
let resolved = def_map