﻿<?xml version="1.0" encoding="utf-8"?>
<ErrorDocumentation xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <ErrorName>CS1579</ErrorName>
  <Examples>
    <string>// cs1579.cs: foreach statement cannot operate on variables of type 'Foo' because 'Foo' does not contain a public definition for 'GetEnumerator'
// Line: 12

using System;
using System.Collections;

public class Test
{
        public static void Main ()
        {
                Foo f = new Foo ();
                foreach (object o in f)
                        Console.WriteLine (o);
        }
}

public class Foo
{
        internal IEnumerator GetEnumerator ()
        {
                return new ArrayList ().GetEnumerator ();
        }
}</string>
    <string>// cs1579.cs: foreach statement cannot operate on variables of type X because X does not contain a definition for GetEnumerator or is not accessible
// Line: 10
class X {
}

class Y {
	void yy (X b)
	{
		
		foreach (object a in b)
			;
	}
}
</string>
  </Examples>
</ErrorDocumentation>