⬆️ rust-analyzer

This commit is contained in:
Laurențiu Nicola 2023-03-20 08:31:01 +02:00
parent 544b4cfe4d
commit dbf04a5ee2
106 changed files with 2219 additions and 609 deletions

View file

@ -6,7 +6,7 @@ use std::{
};
use crate::{
db::AstDatabase,
db::ExpandDatabase,
hygiene::Hygiene,
name::{known, Name},
};
@ -37,7 +37,11 @@ pub enum PathKind {
}
impl ModPath {
pub fn from_src(db: &dyn AstDatabase, path: ast::Path, hygiene: &Hygiene) -> Option<ModPath> {
pub fn from_src(
db: &dyn ExpandDatabase,
path: ast::Path,
hygiene: &Hygiene,
) -> Option<ModPath> {
convert_path(db, None, path, hygiene)
}
@ -162,7 +166,7 @@ impl From<Name> for ModPath {
}
fn convert_path(
db: &dyn AstDatabase,
db: &dyn ExpandDatabase,
prefix: Option<ModPath>,
path: ast::Path,
hygiene: &Hygiene,