mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 05:15:04 +00:00
Fix parsing of parenthesized type args and RTN
This commit is contained in:
parent
edb432639b
commit
65c0b29720
44 changed files with 1022 additions and 700 deletions
|
@ -286,7 +286,8 @@ impl Ctx<'_> {
|
|||
return None;
|
||||
}
|
||||
if path.segment().map_or(false, |s| {
|
||||
s.param_list().is_some() || (s.self_token().is_some() && path.parent_path().is_none())
|
||||
s.parenthesized_arg_list().is_some()
|
||||
|| (s.self_token().is_some() && path.parent_path().is_none())
|
||||
}) {
|
||||
// don't try to qualify `Fn(Foo) -> Bar` paths, they are in prelude anyway
|
||||
// don't try to qualify sole `self` either, they are usually locals, but are returned as modules due to namespace clashing
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue