Skip to content

Unused function warnings should return a span of only the function name #58729

Closed
@jackmott

Description

@jackmott

Currently a warning for an unused function returns a span of the entire function. As a consequence, RLS based IDE environments may then put green squiggles on the entire function. This makes it very annoying to work on a function, if you have not yet written the function that uses it.

There may be other unused warnings for structs/traits that could be similarly adjusted.

This issue has been assigned to @Quantumplation via this comment.

Metadata

Metadata

Assignees

Labels

A-diagnosticsArea: Messages for errors, warnings, and lintsA-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.D-papercutDiagnostics: An error or lint that needs small tweaks.E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions