mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 21:05:02 +00:00
Nest all the or-patterns!
This commit is contained in:
parent
c82a9141ab
commit
95c8c65139
26 changed files with 133 additions and 151 deletions
|
@ -294,7 +294,7 @@ fn traverse(
|
|||
Some(parent) => {
|
||||
// We only care Name and Name_ref
|
||||
match (token.kind(), parent.kind()) {
|
||||
(IDENT, NAME) | (IDENT, NAME_REF) => parent.into(),
|
||||
(IDENT, NAME | NAME_REF) => parent.into(),
|
||||
_ => token.into(),
|
||||
}
|
||||
}
|
||||
|
@ -310,7 +310,7 @@ fn traverse(
|
|||
Some(parent) => {
|
||||
// We only care Name and Name_ref
|
||||
match (token.kind(), parent.kind()) {
|
||||
(IDENT, NAME) | (IDENT, NAME_REF) => parent.into(),
|
||||
(IDENT, NAME | NAME_REF) => parent.into(),
|
||||
_ => token.into(),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue