Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement S1123 - Obsolete attributes need explanation - for VB.NET #6459

Closed
pavel-mikula-sonarsource opened this issue Nov 28, 2022 · 0 comments · Fixed by #5737
Closed
Assignees
Labels
Area: VB.NET VB.NET rules related issues.
Milestone

Comments

@pavel-mikula-sonarsource
Copy link
Contributor

See: RSPEC-2289, and #365

Description

The Obsolete attribute can be applied with or without arguments, but marking something Obsolete without including advice as to why it's obsolete or on what to use instead will lead maintainers to waste time trying to figure those things out - every single time the warning is encountered.

Noncompliant Code Example

Public Class Car
  <Obsolete>
  Public Sub CrankEngine(turnsOfCrank As Integer) 
  ' ...
End Class

Compliant Solution

Public Class Car
  <Obsolete("Replaced by the automatic starter")>
  Public Sub CrankEngine(turnsOfCrank As Integer) 
  ' ...
End Class
@github-actions github-actions bot added this to New Feature in Backlog Nov 28, 2022
@pavel-mikula-sonarsource pavel-mikula-sonarsource added this to the 8.50 milestone Nov 29, 2022
@github-actions github-actions bot added this to To do in Best Kanban Nov 29, 2022
@pavel-mikula-sonarsource pavel-mikula-sonarsource moved this from To do to Review approved in Best Kanban Nov 29, 2022
@pavel-mikula-sonarsource pavel-mikula-sonarsource moved this from Review approved to Review in progress in Best Kanban Nov 29, 2022
Backlog automation moved this from New Feature to Done Nov 29, 2022
Best Kanban automation moved this from Review in progress to Validate Peach Nov 29, 2022
@pavel-mikula-sonarsource pavel-mikula-sonarsource moved this from Validate Peach to Done in Best Kanban Nov 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: VB.NET VB.NET rules related issues.
Projects
Best Kanban
  
Done
Backlog
  
Done
Development

Successfully merging a pull request may close this issue.

1 participant