mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 04:44:57 +00:00
fix: Recognize Self
as a proper keyword
This commit is contained in:
parent
8f504dc873
commit
c0d6471143
27 changed files with 98 additions and 49 deletions
|
@ -327,7 +327,7 @@ fn traverse(
|
|||
// as otherwise we won't ever visit them
|
||||
match (token.kind(), parent.kind()) {
|
||||
(T![ident], NAME | NAME_REF) => parent.into(),
|
||||
(T![self] | T![super] | T![crate], NAME_REF) => parent.into(),
|
||||
(T![self] | T![super] | T![crate] | T![Self], NAME_REF) => parent.into(),
|
||||
(INT_NUMBER, NAME_REF) => parent.into(),
|
||||
(LIFETIME_IDENT, LIFETIME) => parent.into(),
|
||||
_ => token.into(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue