Skip to content

Add a spell checker to rust-analyzer #14597

@GilShoshan94

Description

@GilShoshan94

Discussed in #14389

Originally posted by GilShoshan94 March 22, 2023
Hi,

Now, we have a code formater with rustfmt, we have a linter with cargo check or cargo clippy, why not a spell checker?

....


Quoted from #14389 (comment)

For spell checker, a significant chunk of the logic indeed belongs to rust-analyzer. Specifically, rust-analyzer should:

separate keywords from identifiers
separate reference identifiers from definition identifiers. Typos should be checked only for definitions. Its compiler's job to point typos in the references.
separate declarations from definitions. Function names should be checked in traits, but not in trait impls.
find comments
unesape strings (values of string literals should be checked for typos, not the source syntax)

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-featureCategory: feature request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions