From 9482353fa8e1e88cb720a029b9bb6304819c7399 Mon Sep 17 00:00:00 2001 From: Kirill Bulatov Date: Sun, 28 Feb 2021 09:57:54 +0200 Subject: Properly handle turbofishes in qualifiers --- crates/hir_def/src/path.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'crates/hir_def') diff --git a/crates/hir_def/src/path.rs b/crates/hir_def/src/path.rs index 0e60dc2b6..1dc085199 100644 --- a/crates/hir_def/src/path.rs +++ b/crates/hir_def/src/path.rs @@ -44,6 +44,10 @@ pub enum ImportAlias { } impl ModPath { + pub fn from_src_unhygienic(path: ast::Path) -> Option { + lower::lower_path(path, &Hygiene::new_unhygienic()).map(|it| it.mod_path) + } + pub fn from_src(path: ast::Path, hygiene: &Hygiene) -> Option { lower::lower_path(path, hygiene).map(|it| it.mod_path) } -- cgit v1.2.3