I ran it over runtime, and the only things flagged were for exceptional cases where it's not worth using. Rather than a bunch of suppressions, I'm just enabling it as info-level.
# CA1862: Prefer using 'StringComparer'/'StringComparison' to perform case-insensitive string comparisons
dotnet_diagnostic.CA1862.severity = warning
+# CA1863: Use 'CompositeFormat'
+dotnet_diagnostic.CA1863.severity = suggestion
+
# CA1864: Prefer the 'IDictionary.TryAdd(TKey, TValue)' method
dotnet_diagnostic.CA1864.severity = warning
# CA1862: Prefer using 'StringComparer'/'StringComparison' to perform case-insensitive string comparisons
dotnet_diagnostic.CA1862.severity = none
+# CA1863: Use 'CompositeFormat'
+dotnet_diagnostic.CA1863.severity = none
+
# CA1864: Prefer the 'IDictionary.TryAdd(TKey, TValue)' method
dotnet_diagnostic.CA1864.severity = none
else if (!declaredType.IsAssignableFrom(reflectedType))
{
// declaredType is not Array, not generic, and not assignable from reflectedType
- throw new ArgumentException(string.Format(
- CultureInfo.CurrentCulture, SR.Argument_ResolveMethodHandle,
+ throw new ArgumentException(SR.Format(
+ SR.Argument_ResolveMethodHandle,
reflectedType.ToString(), declaredType.ToString()));
}
}