ReSharper 2016.1 Help

Code Inspection: Parameter type can be IEnumerable of T

If you have a method whose parameter is an array, a List or some other type that implements IEnumerable<T>, ReSharper will offer you an option to change the parameter type accordingly – provided, of course, that the method itself only iterates the collection and does not access any non-IEnumerable members.

The benefit from this change, if you choose to make it, is that the method becomes agnostic with respect to the type of collection you give it.

See Also

Last modified: 19 August 2016