Skip to content

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

Closed
@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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    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