Topic | Value |
---|---|
Id | IDISP019 |
Severity | Warning |
Enabled | True |
Category | IDisposableAnalyzers.Correctness |
Code | DisposeMethodAnalyzer |
Call SuppressFinalize as there is a virtual dispose method.
Call SuppressFinalize(this) as the type has a virtual dispose method.
Use the code fix.
Configure the severity per project, for more info see MSDN.
#pragma warning disable IDISP019 // Call SuppressFinalize
Code violating the rule here
#pragma warning restore IDISP019 // Call SuppressFinalize
Or put this at the top of the file to disable all instances.
#pragma warning disable IDISP019 // Call SuppressFinalize
[System.Diagnostics.CodeAnalysis.SuppressMessage("IDisposableAnalyzers.Correctness",
"IDISP019:Call SuppressFinalize",
Justification = "Reason...")]