Skip to content

S1854: Improve message when issue is raised in the context of increment or decrement operator #8330

Open
@mary-georgiou-sonarsource

Description

The current message that this rule is raising is causing confusion in the context of increment and decrement operators.
See community posts here and here.

The message should be improved to give a more accurate proposal as action, for example, instead of just remove this assignment it can be replace this not used assignment with [variable]+1 and even explain a bit more that these operators are creating an assignment in the background.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    Area: C#C# rules related issues.Type: MessagesChange rule primary and/or secondary messages

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions