Steeltoe
Steeltoe copied to clipboard
Address S4487: Unread "private" fields should be removed
Address existing violations of S4487: Unread "private" fields should be removed in the codebase and set severity to Info in Steeltoe.Debug.ruleset and to Warning in Steeltoe.Release.ruleset.
Note: The difference in severities between Debug/Release is to avoid distraction or hindrance while writing/debugging code.
To find existing violations, enable the rule (see above) and rebuild src/Steeltoe.All.sln to make them appear in the Output window.
To address the violations, choose from the following on a case-by-case basis:
- Remove the field and its assignments
- Add code that reads the field
- ~Suppress the violation in code using
#pragma warning disable/restore, preceded by a justification comment if not obvious~