2006-12-05 Chris Toshok <toshok@ximian.com>
[mcs.git] / tests / test-anon-52.cs
blobd653736c11f44a728ac4d0ac753cbabd1acbed09
1 using System;
2 using System.Collections;
4 class X {
5 delegate void A ();
7 static IEnumerator GetIt (int [] args)
9 foreach (int arg in args) {
10 Console.WriteLine ("OUT: {0}", arg);
11 A a = delegate {
12 Console.WriteLine ("arg: {0}", arg);
13 return;
15 a ();
16 yield return arg;
20 static int Main ()
22 IEnumerator enumerator = GetIt (new int [] { 1, 2, 3});
23 enumerator.MoveNext ();
24 return 0;