mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-08-22 19:34:16 +00:00
Better strip turbofishes
This commit is contained in:
parent
5168ab16e1
commit
778deb38fe
5 changed files with 52 additions and 8 deletions
|
@ -91,6 +91,10 @@ pub fn path_from_segments(
|
|||
})
|
||||
}
|
||||
|
||||
pub fn path_from_text(text: &str) -> ast::Path {
|
||||
ast_from_text(&format!("fn main() {{ let test = {}; }}", text))
|
||||
}
|
||||
|
||||
pub fn glob_use_tree() -> ast::UseTree {
|
||||
ast_from_text("use *;")
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue