Merge pull request #5675 from mono/glib-debug-symbols
[mono.git] / mcs / errors / cs1624-4.cs
1 // CS1624: The body of `C.Test<TSource>(System.Collections.Generic.IEnumerable<TSource>)' cannot be an iterator block because `TSource' is not an iterator interface type
2 // Line: 8
3
4 using System.Collections.Generic;
5
6 public class C
7 {
8         public static TSource Test<TSource>(IEnumerable<TSource> source)
9         {
10                 foreach (TSource element in source)
11                         yield return element;
12         }
13 }