Note that this rule is disabled by default and must be enabled manually using an .editorconfig
file.
You should use string.Equals
instead of is
, to make string comparison rules explicit. Similar to MA0006 but for patterns.
_ str = is "foo";
// Should be
string.Equals(str, foo, StringComparison.Ordinal);