ReSharper 2026.1 Help

Code inspection: The expression of 'is' operator is never of the provided type

This inspection reports is type checks that can never succeed. This usually happens when the operand type and the checked type are incompatible, so the condition is always false and the guarded code is unreachable.

Example

void M(int number) { if (number is string) { Use(number); } }
void M(int number) { if (false) { Use(number); } }

Quick-fix

Remove the unreachable code or correct the type check.

01 April 2026