Code inspection: Simplify negated pattern
This inspection reports a pattern that negates another negated pattern. This makes the code harder to read without changing the result.
Example
if (o is not not string)
{
}
if (o is string)
{
}
Quick-fix
Remove the double negation from the pattern.
29 March 2026