If a method is named GetEnumerator and returns an IEnumerator it should not be made static. If it was changed you could break existing foreachs. See reference on MSDN;
Example:
class MyList
{
public System.Collections.IEnumerator GetEnumerator()
{
yield return "x";
yield return "y";
}
}
If a method is named
GetEnumeratorand returns anIEnumeratorit should not be made static. If it was changed you could break existingforeachs. See reference on MSDN;Example: